Numerical Methods
Numerical Methods
HOMEWORK 10
Determine weights w0 , w1 and points x0 , x1 for which the quadrature rule Q(f ) =
w0 f (x0 ) + w1 f (x1 ) is exact for polynomials of degree three or less, i.e.
Solve this problem by writing equations corresponding to Q(xi ) = I(xi ) for i =
0, 1, 2, 3 and then solving R 1 the equations.
Hint: Use the formula 0 x e x dx and try to solve the system by changing variables
n
to
x0 = x̄ , x0 = x̄ + , w0 = w̄ ⌘, w1 = w̄ + ⌘.
R1 n x
Also, the formula 0 x e dx = n! might be useful.
Exercise 2 (3 points). We now consider the inner product
Z 1
(f, g) = f (x)g(x)e x dx.
0
where xi are the roots of the Chebyshev polynomial Tn+1 (x) = cos((n + 1) arccos(x))
and the weights are the typically Gauss quadrature weights wi = I(`i ). This rule is
exact for polynomials of degree 2n + 1.
Derive an estimate for the quantity
E(f ) = |Q(f ) I(f )|
using polynomial interpolation theory.
Hint: You may want to use the inequality for a function g : [ 1, 1] ! R
Z 1
|g(x)|(1 x2 ) 1/2 dx ⇡ max |g(x)|.
1 1x1
Another true statement (but you should show this) is for a continuous function
g : [ 1, 1] ! R, we have
n
X
|Q(g)| = wi g(xi ) ⇡ max |g(x)|.
1x1
i=0
NUMERICAL METHODS HOMEWORK 10
For i o w.tw Se dx 1
For i 3 Woxo w xp ff Xe dx 6
Thing in Xo x̅ 8 x x̅ 8 Wo w̅ n w int n
w̅ 1
x̅ 8 w̅ n x̅ sicity 1
x̅ sit w̅ no ix stains 2
x̅ 8 w̅ n x̅ 8pct 7 6 4
Xo 2 52 X 2 52 W
24 W
2 a q 1 1 1 4 a ao e dx
2 a 1 do o 2 a do 0
q X f a ao xe dx
3 9 2 ao 1 6 29 an o
91 90 2 91 4
291 a 6 no 2
q X X2 4 2
b Go X 1
q 1 7 X co 1 where co 1
X 1
q x X C 9 x c 8 X where C
1 1 4
X2 41 1 2
2
co
X 4 2
3 nots X 4 2 0 X 1 42 2 a
Xo 2 T X 2 52 same as EX 1
weights l
wo
flex e
1ft F
w f b ex e same as Ex 1
4 a
q 1 St x ax ao x dx
32
Ex 290 72
Ja
a 2 no 0
1 2
q X Sf x aix ao x x dx
Ix Ea a
I F a no 0
5 alt 2 do
Fania
1
q x X
x
b Xo X are roots of q
IF x I x 3 its
e wo
flex x ax 1
lie we flax x ax 1
5 Ecf D f Icf 1
1 O f p 0 p Icf p I p
0 f p Icf p since Q p 1 p
q 5115 3 3 7X dx
Ex Ix É É ÉÉ 0
4
b Q f 0 7
É C F 7 1 E1 to E 7 1751
4
2 5 7 FF