03.03.2014 Views

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

8.4. GAUSSIAN QUADRATURE 111<br />

Exercises<br />

(8.1) Use the composite trapezoidal rule, by hand, to approximate<br />

∫ 3<br />

0<br />

x 2 dx (= 9)<br />

Use the partition {x i } 2 i=0<br />

= {0, 1, 3} . Why is your approximation an overestimate?<br />

(8.2) Use the composite trapezoidal rule, by hand, to approximate<br />

∫ 1<br />

0<br />

1<br />

dx (= ln 2 ≈ 0.693)<br />

x + 1<br />

Use the partition {x i } 3 i=0 = { 0, 1 4 , 1 2 , 1} . Why is your approximation an overestimate? (Check:<br />

I think the answer is 0.7)<br />

(8.3) Use the composite trapezoidal rule, by hand to approximate<br />

∫ 1<br />

0<br />

4<br />

1 + x 2 dx.<br />

Use n = 4 subintervals. How good is your answer?<br />

(8.4) Use<br />

∫<br />

Theorem 8.8 to bound the error of the composite trapezoidal rule approximation of<br />

2<br />

0 x3 dx with n = 10 intervals. You should find that the approximation is an overestimate.<br />

(8.5) How many equal subintervals of [0, 1] are required to approximate ∫ 1<br />

0<br />

cos x dx with error<br />

smaller than 1 × 10 −6 by the composite trapezoidal rule? (Use Theorem 8.8.)<br />

(8.6) How many equal subintervals would be required to approximate<br />

∫ 1<br />

0<br />

4<br />

1 + x 2 dx.<br />

to within 0.0001 by the composite trapezoidal rule? (Hint: Use the fact that |f ′′ (x)| ≤ 8 on<br />

[0, 1] for f(x) = 4/(1 + x 2 ))<br />

(8.7) How many equal subintervals of [2, 3] are required to approximate ∫ 3<br />

2 ex dx with error smaller<br />

than 1 × 10 −3 by the composite trapezoidal rule?<br />

(8.8) Simpson’s Rule for quadrature is given as<br />

∫ b<br />

a<br />

f(x) dx ≈ ∆x<br />

3 [f(x 0) + 4f(x 1 ) + 2f(x 2 ) + 4f(x 3 ) + . . . + 2f(x n−2 ) + 4f(x n−1 ) + f(x n )] ,<br />

where ∆x = (b − a)/n, and n is assumed to be even. Show that Simpson’s Rule for n = 2 is<br />

actually given by Romberg’s Algorithm as R(1, 1). As such we expect Simpson’s Rule to be<br />

a O ( h 4) approximation to the integral.<br />

(8.9) Find a quadrature rule of the form<br />

∫ 1<br />

0<br />

f(x) dx ≈ Af(0) + Bf(1/2) + Cf(1)<br />

that is exact for polynomials of highest possible degree. What is the highest degree polynomial<br />

for which this rule is exact?

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!