=================================== CHAPTER 5 PROBLEMS GERALD AND WHEATLEY, 6TH EDITION ==================================== ------------------ 31. For h=0.1: f(0.42) = .04346 f(0.22) = .01205 Plugging these into the center difference formula (the second line in the bottom box on p373), I get .04346 - .01205 --------------- = .15705 = f'(0.32) 0.42 - 0.22 For h=0.05: f(0.37) = .03384 f(0.27) = .01811 ...which yields f'(0.32) = .15730 To combine these two answers using equation 5.21 on page 370, you need to know (1) which of the two is more accurate and (2) what the exponent n is. Here, n=2 and the h=0.5 answer is more accurate, so the extrapolated answer is better answer = .15730 + 1/3 (.15730 - .15705) = .15738 You can continue to extrapolate, improving the answer with every step, as shown in table 5.6. For this particular problem, that would entail evaluating f(.295) and f(.345), using those to compute f'(0.32) using the center difference formula, and then using eqn 5.21 to extrapolate between the h=0.5 and h=0.25 answers with n=2. After that, you can extrapolate the two EXTRAPOLATED answers using eqn 5.21 with n=4. The answer then is 0.15728, as shown in the back of the book. ------------------ 40. a. h=0.1: 0.1 --- [1.543 + 2(1.669) + 2(1.811) + 2(1.971) + 2(2.151) + 2(2.352) 2 + 2(2.577) + 2(2.828) + 3.107] = 1.7684 b. h=0.2: 0.2 --- [1.543 + 2(1.811) + 2(2.151) + 2(2.577) + 3.107] 2 = 1.7728 c. h=0.4: 0.4 --- [1.543 + 2(2.151) + 3.107] 2 = 1.7904 ------------------ Repeat problem 40 (just the h=0.1 part), but using Simpson's 1/3 rule: The number of points between 1.0 and 1.8 is 9, which divides nicely into the three-point panels that this rule uses, and so we can just use the corresponding composite rule [eqn 5.35]: 0.1 --- [1.543 + 4(1.669) + 2(1.811) + 4(1.971) + 2(2.151) + 4(2.352) 3 + 2(2.577) + 4(2.828) + 3.107] = 1.76693 ------------------ Repeat problem 40 (just the h=0.1 part), but using Simpson's 3/8 rule: This one's not so easy because the points in the table don't divide neatly into 4-point panels. Because of this, you have to use some combination of different methods -- e.g., two panels of Simpson's 3/8 rule and one of Simpson's 1/3: 3(0.1) ------ [1.543 + 3(1.669) + 3(1.811) + 2(1.971) + 3(2.151) + 3(2.352) 8 + 2.577] 0.1 + --- [2.577 + 4(2.828) + 3.107] 3 = 1.76695