Académique Documents
Professionnel Documents
Culture Documents
Approximation
Problems of
Population (x 1000)...
200000
interpolation
150000
100000
1920 1930 1940 1950 1960 1970 1980 1990
year
Solution: using a
function that fit (best)
?
to the data
6/3/2018 by Adam Pamudji R 2
Algebraic Polynomials
Uniformly approximate continuous
functions
Derivative and indefinite integral of any
polynomial are
easy to determinate and
results to a polynomial again
Used for approximating continuous
functions
Pn(x)...
0.6 0.3 0.408 0.4161 0.418871 0.420118 0.420658
0.7 0.35 0.497 0.509863 0.515964 0.519409
3 0.521296
0.8 0.4 0.592 0.6112 0.623483 0.632012 0.637886
0.9 0.45 0.693 0.720338 0.743401 0.762796 0.779675
1 0.5 0.8 0.8375 0.87846 0.919663
2 0.965617
1.1 0.55 0.913 0.962913 1.032396 1.115178 1.23626
1.2 0.6 1.032 1.0968 1.210228 1.36895 1.683147
1.3 0.65 1.157 1.239388 1.418586 1.711025
1 2.525979
1.4 0.7 1.288 1.3909 1.66611 2.18668 4.325732
1.5 0.75 1.425 1.551563 1.963906 2.863086 8.60061
1.6 0.8 1.568 1.7216 2.326083 3.838464
0 19.67833
1.7 0.85 1.717 1.901238 2.77036 5.254533 50.46277
0 0.5 1 1.5 2
1.8 0.9 1.872 2.0907 3.318771 7.313236 140.9308
1.9 0.95 2.033 2.290213 3.998455 10.29901 418.9507 x
2 1 2.2 2.5 4.84256 14.60819 1304.193
y
0.9 -0.24737 0.052632 0.352632 0.04437
1 -0.3 0 0.3 -0.02 0
1.1 -0.34762 -0.04762 0.252381 -0.07757
1.2 -0.39091 -0.09091 0.209091 -0.12816
1.3 -0.43043 -0.13043 0.169565 -0.17159 -0.5
1.4 -0.46667 -0.16667 0.133333 -0.20768
1.5 -0.5 -0.2 0.1 -0.23625
1.6 -0.53077 -0.23077 0.069231 -0.25712
-1
1.7 -0.55926 -0.25926 0.040741 -0.27011
0 0.5 1 1.5 2
1.8 -0.58571 -0.28571 0.014286 -0.27504
1.9 -0.61034 -0.31034 -0.01034 -0.27173 x
2 -0.63333 -0.33333 -0.03333 -0.26
6/3/2018 by Adam Pamudji R 5
Polynomials and Interpolation
The Taylor Polynomials
The Lagrange Polynomials
Interpolation
Lagrange interpolating polynomials
Iterated interpolation
Devided-difference methods
Hermite interpolation
Cubic spline interpolation
Piecewise polynomial approximation
Ln ,k ( x)
x x0 x xk 1 x xk 1 x xn
xk x0 xk xk 1 xk xk 1 xk xn
Ln ,k ( x)
n
x xi
.
i 0 xk xi
ik
n: degree of polynomial
k: the th point number
Lagrange polynomial of n degree passes to n+1 points
linear, n = 1
x0 = 0 1.2
L1,0(x)
x1 = 1
1 L1,1(x)
k= 0 1
x L1,0(x) L1,1(x) 0.8
Ln,k(x)...
0 1 0
0.1 0.9 0.1 0.6
0.2 0.8 0.2
0.3 0.7 0.3 0.4
0.4 0.6 0.4
0.2
0.5 0.5 0.5
0.6 0.4 0.6
0
0.7 0.3 0.7
0 0.2 0.4 0.6 0.8 1
0.8 0.2 0.8
0.9 0.1 0.9 x
1 0 1
Pn ( x) f ( x0 ) Ln ,0 ( x) f ( xn ) Ln,n ( x)
n
Pn ( x) f ( xk ) Ln,k ( x)
k 0
L1,0(x)
0.9
L1,1(x)
f(x0)L1,0(x)
0.8
f(x1)L1,1(x)
Pn(x)
0.7
f(x)
0.6
y...
0.5
0.4
0.3
0.2
0.1
0
2 2.2 2.4 2.6 2.8 3
x
6/3/2018 by Adam Pamudji R 13
Lagrange Interpolation, n = 2
f(x) = 1/x the function to be approximated
take three points
x0 = 2 f(x 0) = 0.5
x1 = 2.5 f(x 1) = 0.4
x2 = 4 f(x 2) = 0.25
k= 0 1 2 0 1 2
x L2,0(x) L2,1(x) L2,2(x) f(x 0)L2,0(x) f(x 1)L2,1(x) f(x 2)L2,2(x) Pn(x) f(x)
2 1.00 0.00 0.00 0.500 0.000 0.000 0.500 0.500
2.1 0.76 0.25 -0.01 0.380 0.101 -0.003 0.478 0.476
2.2 0.54 0.48 -0.02 0.270 0.192 -0.005 0.457 0.455
2.3 0.34 0.68 -0.02 0.170 0.272 -0.005 0.437 0.435
2.4 0.16 0.85 -0.01 0.080 0.341 -0.003 0.418 0.417
2.5 0.00 1.00 0.00 0.000 0.400 0.000 0.400 0.400
2.6 -0.14 1.12 0.02 -0.070 0.448 0.005 0.383 0.385
2.7 -0.26 1.21 0.05 -0.130 0.485 0.012 0.367 0.370
2.8 -0.36 1.28 0.08 -0.180 0.512 0.020 0.352 0.357
2.9 -0.44 1.32 0.12 -0.220 0.528 0.030 0.338 0.345
3 -0.50 1.33 0.17 -0.250 0.533 0.042 0.325 0.333
3.1 -0.54 1.32 0.22 -0.270 0.528 0.055 0.313 0.323
3.2 -0.56 1.28 0.28 -0.280 0.512 0.070 0.302 0.313
3.3 -0.56 1.21 0.35 -0.280 0.485 0.087 0.292 0.303
3.4 -0.54 1.12 0.42 -0.270 0.448 0.105 0.283 0.294
3.5 -0.50 1.00 0.50 -0.250 0.400 0.125 0.275 0.286
3.6 -0.44 0.85 0.59 -0.220 0.341 0.147 0.268 0.278
3.7 -0.36 0.68 0.68 -0.180 0.272 0.170 0.262 0.270
3.8 -0.26 0.48 0.78 -0.130 0.192 0.195 0.257 0.263
3.9 -0.14 0.25 0.89 -0.070 0.101 0.222 0.253 0.256
4 0.00 0.00 1.00 0.000 0.000 0.250 0.250 0.250
6/3/2018 by Adam Pamudji R 14
1.50
L2,0(x)
L2,1(x)
L2,2(x)
1.00
f(x0)L2,0(x)
f(x1)L2,1(x)
f(x2)L2,2(x)
0.50 Pn(x)
f(x)
y..
0.00
-0.50
-1.00
2 2.5 3 3.5 4
n
Ln ,k , j ( x, y )
x xi n y yi
i 0 xk xi i 0 y j yi
ik i j
n n
Pn ( x, y) f ( xk , y j ) Ln,k , j ( x, y)
j 0 k 0