Find the common difference of an AP whose first term is 5 and the sum of its first four terms is half the sum of the next four terms.