Вы находитесь на странице: 1из 15

INTERPOLATION

OUTLINE
 Lagrange Interpolation
 Hermite Interpolation
 Divided Difference Interpolation
 Newton’s Forward/Backward Interpolation
 Gauss Forward/Backward Interpolation
 Stirling’s Formula
 Bessel’s Formula
WHAT IS INTERPOLATION?

Given (x0,y0), (x1,y1), …, (xn,yn), finding the value of ‘y’ at a


value of ‘x’ in (x0, xn) is called interpolation.

3
LAGRANGE POLYNOMIALS

 The formula used to interpolate between data


pairs (x0,f(x0)), (x1,f(x1)),…, (xn,f(xn)) is given by,

 Where the polynomial


n
Pj(x) is given by,
Px    Pj x 
j 1

n
x  xk
Pj  x   y j 
k 1 x j  xk
k j
LAGRANGE POLYNOMIALS

 In general,

P x   y1
 x  x2  x  x3 ... x  xn 
x1  x2 x1  x3 ...x1  xn 
 y2
 x  x1  x  x3 ... x  xn 
 ...
x2  x1 x2  x3 ...x2  xn 
 yn
 x  x1  x  x2 ... x  xn 1 
xn  x1 xn  x2 ...xn  xn 1 
HERMITE INTERPOLATION

 In Hermite Interpolation, the interpolating


polynomial p(x) coincides with f(x) as well as p’(x)
coincides with f ’(x) at the interpolating points.

 The formula is:

 
n n
p( x)   1  2 L ( xk )( x  xk ) Lk x  f ( xk )   ( x  xk )Lk ( x) f ' ( xk )
' 2 2
k
k 0 k 0

Where Lk(x) is Lagrange Polynomial of degree n


NEWTONS DIVIDED DIFFERENCE
 What is divided difference?
f[x1] – f[x0]
f[x0,x1] = x1 – x0

f[x0,x1,x2] = f[x1,x2] – f[x0,x1]


x2 – x1
f[x0, x1, …, xk-1,xk] = f[x1,x2 - xk ] - f[x0 ,...,xk-1]
xk - x 0
for k = 3, 4, ….. n.
These Ist, IInd... and kth order differences are denoted
by f, 2f, …, kf.

 The divided difference interpolation polynomial is:


P(x) = f(x0) + (x – x0) f [x0, x1] + (x –x0) (x – x1) f [x0, x1 , x2]
+ ……+ (x – x0)…..(x –xn-1) f[x0, x1, …, xn]

7
INTERPOLATION FOR
EQUALLY SPACED POINTS
Let (X0,,Y0), (X1,,Y1), …, (Xn,,Yn) be the given points with
Xi+1 = Xi +h, i= 0,1,2,…, (n-1).

 Finite Difference Operators

● Forward difference operator


f(xi) = f (xi + h) – f (xi)

● Backward difference operator


f(xi) = f (xi) – f (xi – h)

● Central difference operator

f(xi) =
 h  h
f  x i  - f  x i  
 2  2
 Shift operators
E f(xi) = f(xi +h)
Er f(xi) = f (xi +rh)
8
NEWTON FORWARD INTERPOLATION
x  x0
For convenience we put p= and f0 = y0. Then we have
h

p( p  1) 2 p( p  1).....( p  n  1) n
f ( x0  ph)  y0  py0   y 0 ..........   y0
2! n!

NEWTON BACKWARD INTERPOLATION


x  xn
For convenience we put p= and f0 = y0. Then we have
h

p( p  1) 2 p( p  1).....( p  n  1) n
f ( xn  ph)  yn  pyn   y n ..........   yn
2! n!

9
INTERPOLATION USING CENTRAL
DIFFERENCES
 Suppose the values of the function f (x) are known at the points a -3h, a
– 2h, a – h, a, a +h, a + 2h, a + 3h, ... etc. Let these values be y-3, y-2,
y-1, y0, y1, y2, y3 ..., and so on. Then we can form the central difference
table as:
x f(x) f 2f 3f 4f 5f 6f
a-3h y-3
y-3
a-2h y-2 2y-3
y-2 3y-3
a-h y-1 2y-2 4y-3
y-1 3y-2 5y-3
a y0 2y-1 4y-2 6y-3
y0 3y-1 5y-2
a+h y1 2y0 4y-1
y1 3y0
a+2h y2 2y1
y2
a+3h y3

We can relate the central difference operator  with  and E using the operator
relation  = E½.
10
GAUSS FORWARD INTERPOLATION
FORMULA
• The value p is measured forwardly from the origin and
0<p<1.

• The above formula involves odd differences below the


central horizontal line and even differences on the
line. This is explained in the following figure.
y0 2y-1 4y-2 6y-3

y0 3y-1 5y-2

• Formula is:

u  u  2  u  1 3  u  1 4 u  2 5
y x  y 0  y0    y1    y1    y2    y2  .......
1  2  3   4   5 

where    u (u  1)(u  2)......(u  r  1)


u
r r!
GAUSS BACKWARD INTERPOLATION
FORMULA
• The value p is measured forwardly from the origin
and -1<p<0.

• The above formula involves odd differences above


the central horizontal line and even differences on
the line.
y-1 3y-2 5y-3

y0 2y-1 4y-2 6y-3

• Formula is:

u   u  1 2  u  1 3 u  2 4  u  3 5
y x  y 0  y1    y1    y2    y2    y3  .......
1  2   3   4   5 

 u  u (u  1)(u  2)......(u  r  1)
where  r  
  r!
STIRLING’S FORMULA
 This formula gives the average of the values obtained by
Gauss forward and backward interpolation formulae. For
using this formula we should have – ½ < p< ½.

We can get very good estimates if - ¼ < p < ¼.


The formula is:

 y0  y1  u 2
2
u (u 2  1)  3 y1  3 y2  u 2 (u 2  1) 4
y  y0  u     y1     y 2 
 2  2! 3!  2  4!
u (u 2  1)(u 2  4)  5 y2  5 y3 
   .........
5!  2 

x  x0
where u 
h
13
BESSEL’S INTERPOLATION
FORMULA
 This formula involves means of even difference on and
below the central line and odd difference below the line.
 The formula is:
1
(u  )u (u  1)
1  1
y  ( y0  y1 )   u  y0 
u (u  1) 1 2

.  y1  2 y0  2  3 y1
2  2 2! 2 3!


4!

(u  1)u (u  1)(u  2) 1 4

.  y1  4 y 2  .........
2
x  x0
where u 
h
1 3
 Bessel’s formula gives better result for u
4 4
14
THANK YOU
Submitted by:
Rakesh Kumar,
(Deptt. Of Mathematics),
P.G.G.C.G, Sec-11,
Chandigarh.

Вам также может понравиться