You are on page 1of 5

Numerical Analysis –MTH603 VU

Interpolation Newton’s Forward Difference Formula


Let y = f (x) be a function which takes values f(x0), f(x0+ h), f(x0+2h), …, corresponding
to various equi-spaced values of x with spacing h, say x0, x0 + h, x0 + 2h, … .
Suppose, we wish to evaluate the function f (x) for a value x0 + ph, where p is any real
number, then for any real number p, we have the operator E such that
E p f ( x) = f ( x + ph).
f ( x0 + ph) = E p f ( x0 ) = (1 + ∆) p f ( x0 )
 p( p − 1) 2 p( p − 1)( p − 2) 3 
= 1 + p∆ + ∆ + ∆ + " f ( x0 )
 2! 3! 
f ( x0 + ph) = f ( x0 ) + p∆f ( x0 )
p( p − 1) 2 p ( p − 1)( p − 2) 3
+ ∆ f ( x0 ) + ∆ f ( x0 )
2! 3!
p ( p − 1)" ( p − n + 1) n
+" + ∆ f ( x0 ) + Error
n!
This is known as Newton’s forward difference formula for interpolation, which gives the
value of f(x + ph) in terms of f(x ) and its leading differences.
0 0
This formula is also known as Newton-Gregory forward difference interpolation formula.
Here p=(x-x )/h.
0
An alternate expression is
p ( p − 1) 2 p ( p − 1)( p − 2) 3
y x = y0 + p ∆ y0 + ∆ y0 + ∆ y0 + "
2! 3!
p ( p − 1)( p − n + 1) n
+ ∆ y0 + Error
n!
If we retain (r + 1) terms, we obtain a polynomial of degree r agreeing with y at
x
x0, x1, …, xr.
This formula is mainly used for interpolating the values of y near the beginning of a set of
tabular values and for extrapolating values of y, a short distance backward from y0

Example:
Evaluate f (15), given the following table of values:

Solution:
The forward differences are tabulated as

© Copyright Virtual University of Pakistan 1


Numerical Analysis –MTH603 VU

We have Newton’s forward difference interpolation formula


p ( p − 1) 2 p ( p − 1)( p − 2) 3
y x = y0 + p∆y0 + ∆ y0 + ∆ y0 + "
2! 3!
p ( p − 1)( p − n + 1) n
+ ∆ y0 + Error
n!
Here we have
x0 = 10, y0 = 46, ∆y0 = 20,
∆ 2 y0 = −5, ∆ 3 y0 = 2, ∆ 4 y0 = −3

Let y be the value of y when x = 15, then


15
x − x0 15 − 10
p= = = 0.5
h 10
(0.5)(0.5 − 1)
f (15) = y15 = 46 + (0.5)(20) + (−5)
2
(0.5)(0.5 − 1)(0.5 − 2) (0.5)(0.5 − 1)(0.5 − 2)(0.5 − 3)
+ (2) + (−3)
6 24
= 46 + 10 + 0.625 + 0.125 + 0.1172
f (15) = 56.8672 correct to four decimal places.

Example
Find Newton’s forward difference, interpolating polynomial for the following data:

Solution;
The forward difference table to the given data is

© Copyright Virtual University of Pakistan 2


Numerical Analysis –MTH603 VU

rd th
Since, 3 and 4 leading differences are zero, we have Newton’s forward difference
interpolating formula as
p( p − 1) 2
y = y0 + p∆y0 + ∆ y0
2
In this problem,
x0 = 0.1, y0 = 1.40,
∆y0 = 0.16, ∆ 2 y0 = 0.04,
and
x − 0.1
p= = 10 x − 1
0.1
Substituting these values,
(10 x − 1)(10 x − 2)
y = f ( x) = 1.40 + (10 x − 1)(0.16) + (0.04)
2
This is the required Newton’s interpolating polynomial.
Example
Estimate the missing figure in the following table:

Solution
Since we are given four entries in the table, the function y = f (x) can be represented by a
polynomial of degree three.

∆ 3 f ( x) = Constant
and ∆ 4 f ( x) = 0, ∀x
In particular,
∆ 4 f ( x0 ) = 0
Equivalently,
( E − 1) 4 f ( x0 ) = 0

© Copyright Virtual University of Pakistan 3


Numerical Analysis –MTH603 VU

Expanding, we have
( E 4 − 4 E 3 + 6 E 2 − 4 E + 1) f ( x0 ) = 0
That is,
f ( x4 ) − 4 f ( x3 ) + 6 f ( x2 ) − 4 f ( x1 ) + f ( x0 ) = 0

Using the values given in the table, we obtain


32 − 4 f ( x3 ) + 6 × 7 − 4 × 5 + 2 = 0

which gives f (x ), the missing value equal to 14.


3
Example
Consider the following table of values
x .2 .3 .4 .5 .6
F(x) .2304 .2788 .3222 .3617 .3979
Find f (.36) using Newton’s Forward Difference Formula.
Solution

x y = f ( x) ∆y ∆2 y ∆3 y ∆4 y
0.2 0.2304 0.0484 -0.005 0.0011 -0.0005
0.3 0.2788 0.0434 -0.0039 0.0006
0.4 0.3222 0.0395 -0.0033
0.5 0.3617 0.0362
0.6 0.3979

p( p −1) 2 p( p −1)( p − 2) 3
yx = y0 + p∆y0 + ∆ y0 + ∆ y0
2! 3!
p( p −1)( p − 2)( p − 3) 4 p( p −1)( p − 2)........( p − n +1) n
+ ∆ y0 +"+ ∆ y0
4! n!
Where
x0 = 0.2, y0 = 0.2304, ∆y0 = 0.0484, x − x0 0.36 − 0.2
p= = = 1.6
∆ y0 = −0.005, ∆ y0 = 0.0011 , ∆ y0 = −.0005
2 3 4
h 0.1

1.6(1.6 −1) 1.6(1.6 −1)(1.6 − 2) 1.6(1.6 −1)(1.6 − 2)(1.6 − 3)


yx = 0.2304 +1.6(0.0484) + ( −0.005) + (0.0011) + (−.0005)
2! 3! 4!
1.6(.6)(−.4) 1.6(.6)(−.4)(−1.4)
= 0.2304 + .077441−.0024 + (.0011) + (−.0005)
6 24
= 0.3078 −.0024 −.00007 −.00001
= .3053

© Copyright Virtual University of Pakistan 4


Numerical Analysis –MTH603 VU

Example
Find a cubic polynomial in x which takes on the values
-3, 3, 11, 27, 57 and 107, when x = 0, 1, 2, 3, 4 and 5 respectively.
Solution
Here, the observations are given at equal intervals of unit width.
To determine the required polynomial, we first construct the difference table
Difference Table

th
Since the 4 and higher order differences are zero, the required Newton’s interpolation
formula

p ( p − 1) 2 p ( p − 1)( p − 2) 3
f ( x0 + ph) = f ( x0 ) + p∆f ( x0 ) + ∆ f ( x0 ) + ∆ f ( x0 )
2 6
Here
x − x0 x − 0
p= = =x
h 1
∆f ( x0 ) = 6
∆ 2 f ( x0 ) = 2
∆ 3 f ( x0 ) = 6
Substituting these values into the formula, we have
x( x − 1) x( x − 1)( x − 2)
f ( x) = −3 + 6 x + (2) + (6)
2 6
f ( x) = x 3 − 2 x 2 + 7 x − 3,
The required cubic polynomial.

© Copyright Virtual University of Pakistan 5

You might also like