You are on page 1of 2
MAS1400 -HW9 7.2 Numerical Integration Based on Interpolation /90)f7 +824 1249247] =1. Sz) = 2: LHS = ff ads = 1/2, RHS = (1/90)[92(1/4) + 12(1/2) + 92(8/4) +7] = 1/2. [i de = 1/8, RHS = (1/90))82(1/4)? + 12(4/2)8 + 82(8/4)? + 7] =1/3 4, RUS = (1/90)]32(1/4)8 + 12(0/2}* + 39(8/4)8 + 7] = 1/5, RUS = (1/00)/32(1/4)*+12(4/2)4 + 39(9/4)4+-7] = 1/5, Since it and 2, it follows that i exact for any incr combination of Une, nately all polynomials of degree <4 3 cos(2/2)de = Ife ~2/(se), 8. f(a) =e" : LHS = fi e*de =e — 1, RHS = An + Ave. f(2) n(x /2)/(x/2) =3/, RUS = Ap, Solving. do = 2/x, A 10, a. f(a) = M2 2/8) : LHS = 1/2, RHS = A. &y(2) = S(2— 1/8) + LHS = 1/2, RHS = B. So 2. b. Let 2 = Mt) = (b—a)t + 90 de = (b—a)dt, So J? fla)dr = (b— a) XG) f(NE))at = (1/2)(b — a)[F(AC1/3)) + F(A(2/3))] = [(6 — @) /2][f((2a +b) /3) + f((a + 24)/3)].- aa (ts4s — 21-s)F(20) = (2A) SLA Fleas) since m 19. fe Fade = PS aaa Set Haid = Ee 7.3 Gaussian Quadrature ange = (2 ~ an)an-t ~ bagncp where Jo shade. —(6/5)2+ 7. a By Theorem 5, Section 6.8, we have a = Lar (tn = Artin, n-1)/ M1, cna) ancl ba = Agu1.dn-2)/Mn 2, 440-2). Here fg) For this problem, @; = 2/3,a2 = 8/15 and by = 1/18 so that q, = x —2/3 and qo (3/10). The roots of go are (6 + V6 )/10. Using method of undetermined coclfcicats, we obtain Ay + Ay = 1/2 and [(6— YB)/10}4o + [(6 + V@)/10]A, = 1/3. Solving, we obtain Ag = (3 — 2/V6)/12 and Ay = (34 2/y6)/12. Hence, fy #f(2)de x (8 —2/ f0)/12f((6 — VB)/10) + + 2/ VB) + VO )/10) Note: zy = (6 ~ v6)/10 ~ 0.35505 10259, = (6 + v6)/10 ~ 0.8149180743, and Ay = (8 2/ V) 12 = 0.181095 96188, Ay = (3+ 2/6) /12 ~ 0.31804 13817, These results agroe with those in Table 25.8 in Abramowitz and Stegun 1965, page 921) bb. Continuing, a3 = 18/35 and by = 9/50 20 that qy = 23 — (12/7}22 + (6/7)x — (4/35). Using ‘symbolic manipulation package to solve this eubie, we find 1 = (4/7) +a, 12 = [(4/7) — (a/2)| + albv3/2), 23 = {(4/7) ~ (a/2)] — {bV/2) where a = (2/40¢) + 0, b = ~(2/40e) +c, ¥Y/(2]1715) + 1(2/245). The numerical values of these roots of the cubie polynomial are 429 = 0.21254 05882, = 0.50058:31856, 29 = 0.91141 20405, Using the method of undetermined coefficients, we need to solve the system 1/2 = Ay + Ai + Aa, 1/3 = Ago + Arei + Azer, 1/4 = Aor} + Air} + Aor}, 1/5 = Aox} + Aix} + Aasi, 1/6 = Aor}+Ais$+Aach, 1/7 = Aor + Ava] + Anz. The solution ts q = 00608260700, 41 = 0.22924 11064, Ay = 0.20008 19137. ‘One can show numerically that this formula is exact for polynomials of degree < 5. Note: Here we use the values given in Abramowitz-Stegan (1965, Table 25.8, page 921] MAS1400 -HW9 ns LAS 9. J, fledde = e[f(av) + f(21) + fla). £2) LHS = 0, RHS = (2/3)[r0 +21 + 29)- f(z) 1 = 0, 29 = ~22 = ~1/V2. , RHS = o(3) > 6 = 2/3, f(x) 2/3, RUS = (2/3)[a3 + 23 + 29] 11, f(a) = 1; LHS = 2, RHS = 2, f(2) = 2: LHS = 2, RHS =2. f(a) = 2: LHS = 8/3, RHS = 2°; LHS = 4, RHS = 6a? — 120 +8. Solving, we have 3a? ~ 6a +2 = 0 or 74 Romberg Integration 6. a @=1b=5, fle) = 1/2: R00) = (1/2) —a[f(a) + FO] = 4/3, RUL,0) = (1/2) R(0,0) + (1/2}(b — a)if(a + (6 a)/2)] = 7/6, R(2,0) = (1/2)R,0) + 1406 — a)if(a+ (b— a)/4) + f(a +3(b— a)/A)] = 67/00, (1,1) = (4/3) R(L,0) ~ (1/3) R(0,0) = 10/9, R(2,1) = (4/3)R(2,0) ~ (1/3) RO) = 11/10, R22) = (16/15) (2.1) ~ (1/15) RC, 1) = 142/478. [From the onde: aaa 16067 RQ, 11667 (2, RO, R Re [Exact vale = In = 1.09861 au 10000 (2,2) = 1.00926 b. a= 0b = x/2, f(x) = (a/x}* + R00) = 7/16, R(1,0) = 3r/64, R(2,0) = 117/256, R(1,1) = 5/24, R21) = 7/24, R2,2) = 0/24. Prot code: (0,0) = 0.196350 1,0) = 0.147262 (1,1) = 0.130900 REL Exact value = 1/24 = 0.13080, 191990 R(2,1) =0.130900R(2,2) = 0.130000 9. 1 =T(f,h) + ch + coh? = --» and I = T(f,h/2) + cx(h/2) + ca(h/2)? +---. Combining, we have 1 = 20/2) — TU, h) + (1/2 teak? +--- Let R11) = 2R(1,0) ~ R00). Tn general, R(n,1) = 2R(n,0) — R(n— 1,0). Now, F= R(1) + byh? + bh +--+ and 14+ RQ,1) + bn (h/2)? +by(h/2)*-=---, Combining, we have I ~ (4/3) R(2, 1) ~(1/8)R(1,1)+ (1/2— hah be. Let R(2,2) = (4/3)R2,1) —(1/3)R(1.1). In general, R(n,2) = (4/3)R(n,1) —(1/3)R(n— 1,1). Now T= RQ2)+eoh® +eah! + and 1 = R(3,2) + es(h/2)? + e4(h/2)* + --. Combining, we have I = (8/7)R(3,2)—(1/7)R(2,2)+(1/2—Teah*+---. Let R(3,3) = (8/7)R(3,2)— (/)RO,2). New Eg (5) is Rn.) = Rn, —1) + (1/2" — Y[R(n,m— 1) — Rn — 1m 1)}

You might also like