Numerical Differentiation
Numerical Differentiation
(B.Eng,M.Eng,Ph.D.)
Faculty of Engineering,
Nnamdi Azikiwe University,Awka
Recommended Textbooks:
Chapara, S. C. and Canale, R. P. (1998) Numerical Methods for Engineers, 3rd ed.
WCB/McGraw-Hill Boston.
Grading:
Attendance (10%)
Bi-Weekly homework (12%)
Midterm (28%)
Final Exam (50%)
Introduction
Numerical differentiation is an approximate and simplest method for
approximating solution for differential equation. This is an approximate
method
A.1.1Euler-Cauchys method
This an approximate method developed from Taylor series expansion of the
function y(x+h) for the solution of the initial value problem expressed as:
It is difficult to obtain an exact solution for the nonlinear form of (1) that
an approximate solution is usually applied. A solution of (1) in the interval
It is difficult to obtain an exact solution for the nonlinear form of (1) that
an approximate solution is usually applied. A solution of (1) in the interval
xo, h, x1, x2,.xn ie y(xo), y(x1), y(x2),.y(xn) where xn = xo + nh, n =
0,1,2,.n, which satisfies the differential equation in (1) together with the
initial conditions.
The Euler-Cauchys formula for the initial value problem
Example A.1:
Solve the initial value problem using the Eulers formula
so that
xn
0
0.1
0.2
0.3
0.4
0.5
0.6
yn
f(xn, yn)=(1+yn2 ) hf(xn, yn)=0.1(1+yn2 )
0
1
0.1
0.1
1.01
0.101
0.201
1.0404
1.10404
0.30504
1.09305
0.109305
0.41434
1-17168
0.117168
0.53151
1.2825
0.12825
0.6598
yn+1
0.1
0.201
0.30504
0.41434
0.53151
0.6598
Example A.2:
Apply the Eulers-Cauchys formula to solve the differential equation
Solution:
xn
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1.0
1.1
1.2
1.3
yn
0
0.1
0.202
0.3101
0.4287
0.5630
0.7193
0.9056
1.1324
1.4136
1.7680
2.2216
2.8104
3.5848
f(xn,yn)
1
1.02
1.0808
1.1861
1.3438
1.560
1.8632
2.2679
2.8118
3.5444
4.5361
5.8875
7.7448
h f(xn,yn)
0.1
0.102
0.1081
0.1186
0.1343
0.1563
0.1863
0.2268
0.2812
0.3544
0.4536
0.5888
0.7745
yn+1
0.1
0.202
0.3101
0.4287
0.5630
0.7193
0.9056
1.1324
1.4136
1.7680
2.2216
2.8104
3.5848
Example A.3:
Solve the initial value problem expressed as
Solution: The differential equation is transformed as
1.20
1.22
1.24
1.26
1.28
1.30
1.32
1.34
4.0
4.1556
4.3195
4.4925
4.6754
4.8692
5.0748
8
9
10
11
1.36
1.38
1.40
1.42
5.5266
5.7756
6.0422
6.3284
5.2935
f()
7.7778
8.1959
8.6511
9.1473
9.6895
10.2785
10.9358
11.6550
f()
0.1556
0.1639
0.1730
0.1829
0.1938
0.2056
0.2187
0.2331
4.1556
4.3195
4.4925
4.6754
4.8692
5.0748
5.2935
12.4497
13.3307
14.3107
15.4049
0.2490
0.2666
0.2862
0.3081
5.5266
5.7756
6.0422
6.3284
Example A.4:
n
0
1
2
3
4
5
1
1.1
1.2
1.3
1.4
1.5
1
1.2337
1.5527
1.9937
1.26117
3.4904
Table A.4b: Computations for example A.4 (Three term Taylor Method with h = 0.05)
n
0
1
2
3
4
5
6
7
8
1
1.05
1.10
1.15
1.20
1.25
1.30
1.35
1.40
1.0000
1.1075
1.2327
1.3788
1.5499
1.7509
1.9879
2.2681
2.6006
Example A.5
Table
n
0
1
2
3
4
5
0.00
0.10
0.20
0.30
0.40
0.50
n
0
1
2
3
4
5
6
7
0.00
0.05
0.10
0.15
0.20
0.25
0.30
0.35
2.0000
2.1200
2.2992
2.5726
3.0077
3.7511
2.0000
2.0550
2.1222
2.2045
2.3058
2.4315
2.5890
2.7889
Example A.6:
Use the 4th Order Runge-Kutta method with h = 0.1 to obtain an approximate
solution at y(1.5) for the boundary value problem
Solution: The 4th Order Runge-Kutta formula is expressed as
A.2
A.2.1
Example A9:
A.3
An initial value problem for a second order system-that is a system of two first
order differential equation is expresses as
Where
GOODLUCK