Beruflich Dokumente
Kultur Dokumente
Dr. N. B. Vyas
Department of Mathematics,
Atmiya Institute of Tech. and Science,
Rajkot (Guj.)
niravbvyas@gmail.com
Dr. N. B. Vyas
Finite Differences
Forward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
Dr. N. B. Vyas
Finite Differences
Forward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The constant difference between two consecutive values of x is
called the interval of differences and is denoted by h.
Dr. N. B. Vyas
Finite Differences
Forward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The constant difference between two consecutive values of x is
called the interval of differences and is denoted by h.
The operator defined by
y0 = y1 y0
Dr. N. B. Vyas
Finite Differences
Forward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The constant difference between two consecutive values of x is
called the interval of differences and is denoted by h.
The operator defined by
y0 = y1 y0
y1 = y2 y1
Dr. N. B. Vyas
Finite Differences
Forward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The constant difference between two consecutive values of x is
called the interval of differences and is denoted by h.
The operator defined by
y0 = y1 y0
y1 = y2 y1
.......
.......
yn1 = yn yn1
Dr. N. B. Vyas
Finite Differences
Forward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The constant difference between two consecutive values of x is
called the interval of differences and is denoted by h.
The operator defined by
y0 = y1 y0
y1 = y2 y1
.......
.......
yn1 = yn yn1
is called Forward difference operator.
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Forward Difference Table:
x y
x0 y0
2 y
3 y
4 y
5 y
y0
2 y0
x1 y1
3 y0
y1
2 y1
x2 y2
4 y0
3 y1
y2
2 y2
x3 y3
5 y0
4 y1
3 y2
y3
2 y3
x4 y4
y4
x5 y5
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Backward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
Dr. N. B. Vyas
Finite Differences
Backward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The operator defined by
y1 = y1 y0
Dr. N. B. Vyas
Finite Differences
Backward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The operator defined by
y1 = y1 y0
y2 = y2 y1
Dr. N. B. Vyas
Finite Differences
Backward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The operator defined by
y1 = y1 y0
y2 = y2 y1
.......
.......
yn = yn yn1
Dr. N. B. Vyas
Finite Differences
Backward difference
Suppose that a function y = f (x) is tabulated for the equally
spaced arguments x0 , x0 + h, x0 + 2h, ..., x0 + nh giving the
functional values y0 , y1 , y2 , ..., yn .
The operator defined by
y1 = y1 y0
y2 = y2 y1
.......
.......
yn = yn yn1
is called Backward difference operator.
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
= (y2 ) = (y2 y1 ) = y2 y1
= y2 y1 (y1 y0 ) = y2 2y1 + y0
= y3 y2
= yn yn1
Dr. N. B. Vyas
Finite Differences
= (y2 ) = (y2 y1 ) = y2 y1
= y2 y1 (y1 y0 ) = y2 2y1 + y0
= y3 y2
= yn yn1
Dr. N. B. Vyas
Finite Differences
Backward Difference Table:
x y
x0 y0
2 y
3 y
4 y
5 y
y1
2 y2
x1 y1
3 y3
y2
2 y3
x2 y2
4 y4
3 y4
y3
2 y4
x3 y3
5 y5
4 y5
3 y5
y4
2 y5
x4 y4
y5
x5 y5
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
y 3 = y2 y1
2
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
y 3 = y2 y1
2
.......
.......
yn 1 = yn yn1
2
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
y 3 = y2 y1
2
.......
.......
yn 1 = yn yn1
2
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
y 3 = y2 y1
2
.......
.......
yn 1 = yn yn1
2
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
y 3 = y2 y1
2
.......
.......
yn 1 = yn yn1
2
Dr. N. B. Vyas
Finite Differences
Central difference
The operator defined by
y 1 = y1 y0
2
y 3 = y2 y1
2
.......
.......
yn 1 = yn yn1
2
Dr. N. B. Vyas
Finite Differences
Central Difference Table:
x y
x0 y0
2y
3y
4y
5y
y 1
2
x1 y1
2 y1
3y 3
y 3
2
x2 y2
3y
y 5
2
x3 y3
2 y3
x4 y4
5
2
4 y2
5y 5
4 y3
3y 7
y 7
2
2 y2
2 y4
y 9
2
x5 y5
Dr. N. B. Vyas
Finite Differences
NOTE:
From all three difference tables, we can see that only the
notations changes not the differences.
y1 y0 = y0 = y1 = y 1
2
Dr. N. B. Vyas
Finite Differences
NOTE:
From all three difference tables, we can see that only the
notations changes not the differences.
y1 y0 = y0 = y1 = y 1
2
Dr. N. B. Vyas
Finite Differences
NOTE:
From all three difference tables, we can see that only the
notations changes not the differences.
y1 y0 = y0 = y1 = y 1
2
Dr. N. B. Vyas
Finite Differences
NOTE:
From all three difference tables, we can see that only the
notations changes not the differences.
y1 y0 = y0 = y1 = y 1
2
Dr. N. B. Vyas
Finite Differences
NOTE:
From all three difference tables, we can see that only the
notations changes not the differences.
y1 y0 = y0 = y1 = y 1
2
Dr. N. B. Vyas
Finite Differences
NOTE:
From all three difference tables, we can see that only the
notations changes not the differences.
y1 y0 = y0 = y1 = y 1
2
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
E n f (x) = f (x nh);
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
E n f (x) = f (x nh);
If yx is the function f (x), then
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
E n f (x) = f (x nh);
If yx is the function f (x), then
Eyx = yx+h ;
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
E n f (x) = f (x nh);
If yx is the function f (x), then
Eyx = yx+h ;
E 1 yx = yxh ;
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
E n f (x) = f (x nh);
If yx is the function f (x), then
Eyx = yx+h ;
E 1 yx = yxh ;
E n yx = yx+nh ;
Dr. N. B. Vyas
Finite Differences
Other Difference Operator
1. Shift Operator E:
E does the operation of increasing the argument x by h so that
Ef (x) = f (x + h);
E 2 f (x) = E(Ef (x)) = Ef (x + h) = f (x + 2h);
E 3 f (x) = f (x + 3h);
E n f (x) = f (x + nh);
The inverse operator E 1 is defined as
E 1 f (x) = f (x h);
E n f (x) = f (x nh);
If yx is the function f (x), then
Eyx = yx+h ;
E 1 yx = yxh ;
E n yx = yx+nh ;
Dr. N. B. Vyas
Finite Differences
2. Averaging Operator :
It is defined as
1
h
h
f (x) =
f x+
+f x
;
2
2
2
Dr. N. B. Vyas
Finite Differences
2. Averaging Operator :
It is defined as
1
h
h
f (x) =
f x+
+f x
;
2
2
2
i
1h
i.e. yx =
yx+ h + yx h ;
2
2
2
Dr. N. B. Vyas
Finite Differences
2. Averaging Operator :
It is defined as
1
h
h
f (x) =
f x+
+f x
;
2
2
2
i
1h
i.e. yx =
yx+ h + yx h ;
2
2
2
3. Differential Operator D:
Dr. N. B. Vyas
Finite Differences
2. Averaging Operator :
It is defined as
1
h
h
f (x) =
f x+
+f x
;
2
2
2
i
1h
i.e. yx =
yx+ h + yx h ;
2
2
2
3. Differential Operator D:
It is defined as
Dr. N. B. Vyas
Finite Differences
2. Averaging Operator :
It is defined as
1
h
h
f (x) =
f x+
+f x
;
2
2
2
i
1h
i.e. yx =
yx+ h + yx h ;
2
2
2
3. Differential Operator D:
It is defined as
d
f (x) = f 0 (x);
Df (x) =
dx
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
Dr. N. B. Vyas
Finite Differences
3 = E 2 E 2
Dr. N. B. Vyas
Finite Differences
3 = E 2 E 2
1
1
1
4 = {E 2 + E 2 }
2
Dr. N. B. Vyas
Finite Differences
3 = E 2 E 2
1
1
1
4 = {E 2 + E 2 }
2
1
5 = E = E = E 2
Dr. N. B. Vyas
Finite Differences
3 = E 2 E 2
1
1
1
4 = {E 2 + E 2 }
2
1
5 = E = E = E 2
6 E = ehD
Dr. N. B. Vyas
Finite Differences
3 = E 2 E 2
1
1
1
4 = {E 2 + E 2 }
2
1
5 = E = E = E 2
6 E = ehD
7 (1 + )(1 ) = 1
Dr. N. B. Vyas
Finite Differences
3 = E 2 E 2
1
1
1
4 = {E 2 + E 2 }
2
1
5 = E = E = E 2
6 E = ehD
7 (1 + )(1 ) = 1
8 = = 2
Dr. N. B. Vyas
Finite Differences
9 1+
2 2
1 2 2
= 1+
2
Dr. N. B. Vyas
Finite Differences
1 2 2
9 1+
= 1+
2
1
10 2 = 1 + 2
4
2 2
Dr. N. B. Vyas
Finite Differences
1 2 2
9 1+
= 1+
2
1
10 2 = 1 + 2
4
1
1
11 E 2 = +
2
2 2
Dr. N. B. Vyas
Finite Differences
9
10
11
12
1 2 2
1+
= 1+
2
1
2 = 1 + 2
4
1
1
E2 = +
2
1
1
E 2 =
2
2 2
Dr. N. B. Vyas
Finite Differences
9
10
11
12
13
1 2 2
1+
= 1+
2
1
2 = 1 + 2
4
1
1
E2 = +
2
1
1
E 2 =
2r
1 2
2
= + 1+
2
4
2 2
Dr. N. B. Vyas
Finite Differences
9
10
11
12
13
14
1 2 2
1+
= 1+
2
1
2 = 1 + 2
4
1
1
E2 = +
2
1
1
E 2 =
2r
1 2
2
= + 1+
2
4
1
1
= E 1 +
2
2
2 2
Dr. N. B. Vyas
Finite Differences
9
10
11
12
13
14
1 2 2
1+
= 1+
2
1
2 = 1 + 2
4
1
1
E2 = +
2
1
1
E 2 =
2r
1 2
2
= + 1+
2
4
1
1
= E 1 +
2
2
2 2
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
p(p 1) 2
p(p 1)(p 2) 3
y0 +
y0 + ...
2!
3!
is called Newtons forward interpolation formula.
yx = y0 + py0 +
Dr. N. B. Vyas
Example
Ex. For the data construct the forward difference formula. Hence,
find f (0.5).
x
f(x)
-2
15
-1
5
Dr. N. B. Vyas
0
1
1
3
2
11
3
25
Example
1891
46
Dr. N. B. Vyas
1901
66
1911
81
1921
93
1931
101
Example
Ex. Estimate the value of production for the year 1984 using
Newtons forward method for the following data:
Year:
Production:
1976
20
Dr. N. B. Vyas
1978
27
1980
38
1982
50
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
p(p + 1) 2 p(p + 1)(p + 2) 3
= 1 + p +
+
+ ... yn
2!
3!
Dr. N. B. Vyas
p(p + 1) 2 p(p + 1)(p + 2) 3
= 1 + p +
+
+ ... yn
2!
3!
p(p + 1) 2
p(p + 1)(p + 2) 3
yn +
yn + ...
2!
3!
is called Newtons backward interpolation formula
yx = yn + pyn +
Dr. N. B. Vyas
Example
0.1
1.699
0.2
1.073
0.3
0.375
Dr. N. B. Vyas
0.4
0.443
0.5
1.429
0.6
2.631
Example
Ex. The table gives the distance in nautical miles of the visible
horizon for the given heights in feet above the earths surface.
Find the value of y when x=390 ft.
Height(x):
Distance(y):
100
10.63
150
13.03
200
15.04
Dr. N. B. Vyas
250
16.81
300
18.42
350
19.90
400
21.47
Dr. N. B. Vyas
1st
dif f erence
2nd
dif f erence
3rd
dif f erence
x0 2h y2
y2 (= y3/2 )
x0 h
2 y2 (= 2 y1 )
y1
3 y2 (= 3 y1/2 )
y1 (= y1/2 )
x0
2 y1 (= 2 y0 )
y0
x0 + h
y1
x0 + 2h
y2
3 y1 (= 3 y1/2 )
y0 (= y1/2 )
2 y0 (= 2 y1 )
y1 (= y3/2 )
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Dr. N. B. Vyas
Example
Ex.
Using Stirlings formula find y35
x:
y:
10
600
20
512
Dr. N. B. Vyas
30
439
40
346
50
243
Example
0.01
98.4342
0.02
48.4392
Dr. N. B. Vyas
0.03
31.7775
0.04
23.4492
0.05
18.4542
Central Difference
Gausss Forward interpolation formula:
Dr. N. B. Vyas
Central Difference
Gausss Forward interpolation formula:
Pn (x) = y0 + py0 +
(p + 1)p(p 1) 3
p(p 1) 2
y1 +
y1 +
2!
3!
(p + 1)p(p 1)(p 2) 4
y2 + ...
4!
Dr. N. B. Vyas
Central Difference
Gausss Forward interpolation formula:
Pn (x) = y0 + py0 +
(p + 1)p(p 1) 3
p(p 1) 2
y1 +
y1 +
2!
3!
(p + 1)p(p 1)(p 2) 4
y2 + ...
4!
Gausss Backward interpolation formula:
Dr. N. B. Vyas
Central Difference
Gausss Forward interpolation formula:
Pn (x) = y0 + py0 +
(p + 1)p(p 1) 3
p(p 1) 2
y1 +
y1 +
2!
3!
(p + 1)p(p 1)(p 2) 4
y2 + ...
4!
Gausss Backward interpolation formula:
Pn (x) = y0 + py1 +
p(p + 1) 2
(p + 1)p(p 1) 3
y1 +
y2 +
2!
3!
(p + 2)(p + 1)p(p 1) 4
y2 + ...
4!
Dr. N. B. Vyas
Example
Ex. Estimate the value of y(2.5) using Gausss forward formula given
that:
x:
y:
1
1
Dr. N. B. Vyas
2
4
3
9
4
16
Example
1901
12
Dr. N. B. Vyas
1911
15
1921
20
1931
27
1941
39
1951
52