3.2.3 Newton's Divided Difference Interpolation: Lagrange Method Has The Following Weaknesses
3.2.3 Newton's Divided Difference Interpolation: Lagrange Method Has The Following Weaknesses
3.2.3 Newton's Divided Difference Interpolation: Lagrange Method Has The Following Weaknesses
Symbol
Definition
f [xi]
f (xi)
f [xi , xi +1]
f [ xi ] f [ xi 1 ]
xi xi 1
f [xi , xi +1 , xi +2]
f [xi , xi +1 , xi +2 , xi +3]
f [ xi , xi 1 , xi 2 ] f [ xi 1 , xi 2 , xi 3 ]
xi xi 3
f [x0 , x1 ,, xn - 1 , xn]
f [ x0 ,, xn 1 ] f [ x1 ,, xn ]
x0 xn
f [ xi , xi 1 ] f [ xi 1 , xi 2 ]
xi xi 2
x f (x)
x0 f (x0)
f [ x0 , x1 ]
f ( x0 ) f ( x1 )
x0 x1
f [ x0 , x1 , x2 ]
x1 f (x1)
f [ x0 , x1 ] f [ x1 , x2 ]
x0 x2
f [ x0 , x1 , x2 , x3 ]
f [ x1 , x2 ]
f ( x1 ) f ( x2 )
x1 x2
f [ x0 , x1 , x2 ] f [ x1 , x2 , x3 ]
x0 x3
f [ x1 , x2 , x3 ]
x2 f (x2)
f [ x2 , x3 ]
x3 f (x3)
f ( x2 ) f ( x3 )
x2 x3
f [ x1 , x2 ] f [ x2 , x3 ]
x1 x3
Solution
Table of divided difference for this data is
5
f (x)
7/3
29/6
12
16
3
3 0
3
1 2
4
4
-8
65/72
17/8
21/6
-5
-2
17
6
( x x0 )( x x1 ) ( x xn 1 ) f [ x0 , x1 , , xn ].
7
Example 3.9
Find interpolation polynomial that passes through
(0,2), (1,3) dan (3,3) using Newtons divided
difference interpolation.
Solution
Table of divide difference for these three points is
x
1
1
1
3
0
3
3
8
1
2 ( x 0)(1) ( x 0)( x 1)
3
4
1
2 x x .
3
3
2
REMARKS
i)
when x 0, P (0) 2.
4
1
ii ) when x 1, P (1) 2 (1) (1) 2
3
3
3.
4
1
iii ) when x 3, P (3) 2 (3) (3) 2
3
3
3.
10
ba
h
.
n
xi+1 xi h
12
h
|
f (x)
h
|
x0 x1 x2 x3 xn
1
f ( xi ), xi ( xi xi 1 ).
2
Areas of all rectangles are computed.
Total area of these rectangles is the approximate area
below the curve of the function, which is also the
estimation of the integral that we want to determine.
*
14
f (x)
|
15
h f ( x1 ) h f ( x2 ) h f ( xn )
*
1
h [ f ( x ) f ( x2 ) f ( xn )].
16
RECTANGULAR RULE
*
1
f ( x) dx h [ f ( x ) f ( x2 ) f ( xn ) ]
1
where xi ( xi xi 1 ).
2
Note :
*
Estimation of
Example 3.10
Estimate
x2
Solution
Given a 0 and b 1, then the length of each
subinterval is
ba
h
n
1 0
0.1
10
Thus, from the table,
x2
dx 0.1(7.471308)
0.747131.
18
xi
xi *
f (xi* )
0.1
0.05
0.997503
0.2
0.15
0.977751
0.3
0.25
0.939413
0.4
0.35
0.884706
0.5
0.45
0.816686
0.6
0.55
0.738968
0.7
0.65
0.655406
0.8
0.75
0.569783
0.9
0.85
0.485537
10
0.95
0.405555
TOTAL
7.471308
19
f
(x)
x0 x1 x2
xn
21
Thus,
If the length of each subinterval is h,
Height of the left hand side of the ith trapezoid = f ( x ),
i 1
Height of the right hand side of the ith trapezoid = f ( x ),
i
1
h( f ( xi ) f ( xi 1 )).
2
22
h f ( x0 ) f ( x1 ) f ( x2 ) f ( xn 1 ) f ( xn ) .
2
2
23
TRAPEZOIDAL RULE
1
1
f ( x) dx h f (a ) f ( x1 ) f ( x2 ) f ( xn 1 ) f (b)
2
2
where x0 a and xn b
24
Example 3.11
Use Trapezoida l Rule with ten subintervals
to estimate
x2
dx.
Solution
Given a 0 and b 1, then the length of each
subinterval is
1 0
h
10
0.1
25
f (xi ), i=,, n
xi
f (a) & f (b )
TOTAL
26
x2
27
h
f ( x) dx ( f (a) f (b)
3
4( f ( x1 ) f ( x3 ) f ( x5 ) L f ( xn 1 ))
2( f ( x2 ) f ( x4 ) f ( x6 ) L f ( xn 2 )).
28
Example 3.12
Apply Simpson' s Rule with ten subintervals
to compute
x2
dx.
Solution
Given f ( x) e
x2
respect to x from a 0 to b 1.
1 0
The length of each interval h
0.1.
10
We make a table that will help us to compute the integral.
29
xi
TOTAL
f (xodd)
f (xeven)
30
31