MA64 -NUMERICAL METHODS UNIT V : INITIAL VALUE PROBLEMS FOR ORDINARY DIFFERENTIAL EQUATIONS B Dr.T.Kulandaivel Department of Applied Matematics SVCE
Numerical ordinar differential equations is te part of numerical analsis wic studies te numerical solution of ordinar differential equations (ODEs). It is ver important for industrial and practical engineering applications, Mecanics, Cemistr and Psics..
It is a numerical metods for solving ordinar differential equations (O.D.Es) wit a given conditions. d f (, ), ( ) d Talor series epansion of te function f() as te following form:. ( ) ( ) () ( ) () ()!!... Assume = ( ) () () () ()!!!...
Hint: - Wen te step size becomes small, te numerical solution becomes nearl te same as te eact solution. - computing approimate values of te solution f() at te points: = +, = +, = +,..
Solve te boundar value problem = - at =.,.4 given tat () = Given tat () &,.. Evaluate te derivatives at te point of epansion zero () ( ) ( ), () () ( ) ( ), () () ( ) ()
Talor epansion given b: ( ) () () ( ) ()!!!.... (.) (.) (.) ( )!! (.) ()! ( )...886 Here.,.8867 ( ) ( ) (.).8867 " ( ) ' ( ) ' ( ) " ( ).8867.8867
() () ( ) ( ) ( )!!!. (.) (.) (.4).8867 (.8867 ) (.8867 ) (.8867 )..!!!.67...
It is a first-order numerical procedure for solving ordinar differential equations (O.D.E) wit a given conditions. d f d (, ), ( ) Te general Euler formula for solving boundar value problem is: n n f( n, n )
Assume = n+ n Computing approimate values of te solution f() at te points: = +, = +, = +,. ( ), ( ), ( ),...
Solve te following boundar value problem at =.,.4,.6 and.8 given tat () =. d d Given tat., d d.4, ;,.6, 4,.8 General Euler formula is given b:
[ ], n n n n For n =...( ) [ ].( ). For n = [ ]..((.).).44
For n = [ ].44. ((.4).44 ).6
For n = [ 4 ].6.((.6).6).85 For n = 4 5 4 [ 4 4 ].85.((.8).85).4
We can put te results in a table: n n n n+......44.4.44.6.6.6.85 4.8.85.4
Tis metod tries to improve te error of Euler metod. Te general modified Euler formula for solving boundar value problem is:,,, n n n n n n f f
Using modified Euler s metod, find (.), if = /, () = wit =., tree decimal places are required Modified Eulr ' s formula : n n f n, n f,, n n
]] (.5 )[ [.5, (.) ] / [.,..,, f f f f.9548 ] (.)[.9548 /.5 ] (.5 ) (.)[.5 [.5,.5 ] (.) ]] (.5 )[ [.5, (.) f f
Te accurac of tis metod is equivalent to five terms of Talor s series. Te general Rung- kutta formula for solving boundar value problem is: n k (k k ) k 4 n. 6 Net Te Main Menu ا Previous
were k f( n, n ) k f ( ),( ) n n k ) k f ( ),( ) n n k k f ( ),( k 4 n n )
Find (.) and (.), if \ =, ()=, take =., four decimal places are required To get = (.) k f(, ).( ) n n. k f ( ),( ).(..5) n n k.5 k f ( n ),(n ).(.5.5) k.5
(, ),(,k ).(.5.). 5 k f 4 n n k (k k ) k 4 6. (.5.5 ).5 6.5 8. (.).5
To get = (.) k f(, ).(.5.) n n.5 k f ( n ),(n ).(.5.5) k.6 k f ( n ),(n ).(..5) k.6
(,),(,k ).(.45.). k f 4 n n k (k k ) k 4 6.5.445..5 (.6 6.6). (.) =.45
Milne s Metod It is a multi-step metod were we assume tat te solution to te given IVP is known at te past four equall spaced point t, t, t and t.
In general, Milne s predictorpredictorcorrector pair can be written as 4 P : n n ( n n n ) C : n n ( n 4 n n )
Using Milne s Metod, find (4.4) given 5 + -=, Given (4)=, (4.) =.49 and (4.) =.97, (4.) =.4, find (.4).
.4..97,.49,, 4.4. 4., 4., 4., 4,, 5 : 4 Given Solution ) 49. ( 45. ). 4 5 ( ) 4. ( 5 467. ). 4 5 ( ) 97. ( 5 49. ). 4 5 ( ) 49. ( 5 ' ' '
B Milne s predictor formula 4 ' ' ' 4, P 4(.) [(.49).467 (.45].897 (.897).47 5 4 5(4.4) ' 4 4
4, C ' 4 ' ' 4.97.874. [.467 4(.45).47]
Eample: Using Milne s metod, find (.4) given = +, ()=. Use Talor series to get te values of (.), (.), (.). Given ' Here,.,.,., 4.4,.
' " ' " "' ' ' " ' ) ( : ') ( '' ' '' "' : ' ' " : '.67 (.).666.5. () 6. ()..... ) (! ) (! ) (! ) ( ) (
)(.587 (.67.67 ) (.)(.587.587 ) (.67 ) (.)(.67 ' ' '' ' 6.4 ) ( 4.87 ' " ' " '''
!!!.....67..587 (.).767. (4.87 ) ( 6.4) 6
(.767)(.885).767 (.)(.885).885 (.767) (.)(.767) ' ' '' ' 8.6875 ) ( 6.4677 ' " ' " '''
.5 (.) ).6875 (8 6. ) (6.4677...885.767...!!! ] [ 4, ln '.,,,,, 4, 4 formula espredictor BMi wewillfind Nowknowing p
,.776 (.5) (.)(.5).885 (.767) (.)(.767).587 (.67) (.)(.67) ' ' ' Now Now,.897 (.776)].885 [(.587) 4(.) 4, p
, ' ln, sin 4.996 (.897) (.4)(.897) 4 4 4 4, formula s corrector e Mi g U p.8698 (.4) 4.996] 4(.776) [.885..767 ] 4 [ 4, 4, p c
Adam s predictor and corrector mtod mtod:: It is anoter predictor predictor--corrector metod, were we use te fact tat te solution to te given initial value problem is known at past four equall spaced points n, n, n, n Te task is to compute te values of at n
Let us consider te differential equation d d f (, ) In general, AdamAdam-Moulton predictor corrector pair can be written as P : n n 55 n 59 n 7 n 9 n 4 C : n n 9 n 9 n 5 n n 4
In general, AdamAdam-Basfort predictor -corrector formula can be written as P : n n 55 n 59 n 7 n 9 n 4 C : n n 9 n 9 n 5 n n 4
Problem: Using Adam s Basfort metod find (4.4) given 5 + =,Y94)= (4.)=.49,(4.)=.97, (4.)=.4. Solution: Given 4, 5,, Let 4.,..49, 4.,.97, 4.,.4.
Adam' s n, p 4, p putting n Now, 5 predictor n [55 n 4, we ave [55 4 5 formula 59 59.5.467, is n 7 7, 5 5 n 9 9.45 n ] ] ().48,
U sin g tese 4, p.4 values in (), we get. [55(.45) 59(.467) 4 7(.48) 9(.5)].4 (4.4).86. 4 4.7.5
Adam' s corrector n, c 4, c putting n Now, 4 n [9 n 4, we ave [9 4 4 5 4 4 formula 9 9.47 is n 5 5 n n ] ] ()
Eqn() becomes. 4, c.4 4 [9(.47) 9(.45) 5(.467).48]..4 (.669).87 4 (4.4).87
Using AdamAdam-Moulton predictor predictor-corrector metod, find te solution of te initial value problem d t, dt () at t =., taking =.. Compare it wit te analtical solution.
Solution In order to use Adam s P-C metod, we require te solution of te given differential equation at te past four equall spaced points, use R-K metod of 4 t points, for wic we order wic is self starting.
Tus taking t =, =, =., we compute k =., k =.8, 8, k =.98, 98, k4 =.596, 596, and get (k k k k4 ).859 6
Now, we take t =.4, =.468, 468, =., and compute k =.66, 66, k =.697, 697,k =.76, 76, k4 =.757 to get (.6) (k k k k4 ).7779 6
Now, we use Adam s PP-C pair to calculate ( (.8) and (.) as follows: P : n n 55 n 59 n 7 n 9 n 4 C : n n 9 n 9 n 5 n n 4 Tus 55 59 7 9 4 p 4 ()
From te given differential equation, we ave t. Terefore, t. t.7859 t.8 t.7779
Hence, from Eq. ( (), we get. (.8).7779 75.77845 77.7967 4.678 9 4 p 4.45 Now to obtain te corrector value of at t =.8, we use (.8) 9 4 9 5 4 c 4 c ()
But, p 9 4 9( 4 t4 ) 9[.45 (.8) ].759 Terefore,. 4 (.8).7779.759 6.78 6.5465.7859 4 c.44 () Proceeding similarl, we get (.) 4 55 4 59 7 9 4 p 5 p
Noting tat 4 4 t.74, 4 we calculate..44 75.5887 8.896 48.48.67 4 p 5.878 Now, te corrector formula for computing 5 is given b (.) 4 9 5 9 4 5 4 c 5 c (4)
From te given differential equation, we ave t. Terefore, t. t.7859 t.8 t.7779
Hence, from Eq. ( (), we get. (.8).7779 75.77845 77.7967 4.678 9 4 p 4.45 Now to obtain te corrector value of at t =.8, we use (.8) 9 4 9 5 4 c 4 c ()
But, p 9 4 9( 4 t4 ) 9[.45 (.8) ].759 Terefore,. 4 (.8).7779.759 6.78 6.5465.7859 4 c.44 () Proceeding similarl, we get (.) 4 55 4 59 7 9 4 p 5 p
Noting tat 4 4 t.74, 4 we calculate..44 75.5887 8.896 48.48.67 4 p 5.878 Now, te corrector formula for computing 5 is given b (.) 4 9 5 9 4 5 4 c 5 c (4)
9 9 t 5 But, p 5 5.56 Tus, finall we get. 5 (.).44.56 6.78 6.5465.7859 4.89
Te numerical solution of a differential equation can be sown to converge to its eact solution, if te step size is ver small.
Te numerical solution of a differential equation is said to be stable if te error do not grow eponentiall as we compute from one step to anoter.
Stabilit consideration are ver important in finding te numerical solutions of te differential equations eiter b single-stepstep metods or b using multi-step metods.