R-K Method
R-K Method
Introduction: The Runge–Kutta methods are iterative ways to calculate the solution of a differential equation. Starting
from an initial condition, they calculate the solution forward step by step. The most widely known member of the Runge–
Kutta family is generally referred to as "RK4", "classical Runge–Kutta method" or simply as "the Runge–Kutta method".
These methods were developed around 1900 by the German mathematicians C. Runge and M. W. Kutta.
( ) ( )
Where ( ) is the differential equation and is the initial value of for which we get the initial value of is .
( )
( )
( ) ( )
Where ( ) is the differential equation and is the initial value of for which we get the initial value of is .
( )
( )
( )
( )
( ) ( )
At ( ) equally spaced numbers in the interval .
Step 1 ( ) ;
; ;
OUTPUT ( ).
Step 2 For = 1,2,……….., N do Steps 3-5.
Step 3 Set ( )
( );
( )
( )
(Compute )
Step 5 OUTPUT ( ).
Step 6 STOP.
Problem 01: Applying Runge-Kutta Method of order four to find an approximate value of ( ) and ( ) where
Hear ( ) .
--------------------------- (1)
------------------------------ (2)
where, ( )
( ) ( )
( )
[( ) ( ) ] [( ) ( ) ]
( )
[( ) ( ) ] [( ) ( ) ]
( )
( ) ( ) ( ) ( )
( ) ( ) ( )
( )
Again for finding the value of ( ) we may use and and put in equation ( ) we get.
------------------------------ (3)
where, ( )
( ) ( )
( )
[( ) ( ) ] [( ) ( ) ]
( )
[( ) ( ) ] [( ) ( ) ]
( )
( ) ( ) ( ) ( )
( ) ( ) ( )
( )
Problem-02: By employing Runge-Kutta method of fourth order solve the differential equation ( )
for in steps of (that is, find ( ) with ) correct to four decimal places.
Solution: Given data,
--------------------------- (1)
------------------------------ (2)
where, ( )
* + * +
( )
* ( ) ( )+ * ( ) ( )+
( )
* ( ) ( )+ * ( ) ( )+
( )
* ( ) ( )+ * ( ) ( )+
( ) ( ) ( )
( )
Again for finding the value of ( ) we may use and and put in equation ( ) we get.
------------------------------ (3)
where, ( )
* + * +
( )
* ( ) ( )+
* ( ) ( )+
( )
* ( ) ( )+
* ( ) ( )+
( )
* ( ) ( )+
* ( ) ( )+
( ) ( ) ( )
( )
Example-03. Using (i) second order (ii) fourth order Rungr-Kutta method, find the value of when given that,
with ( )
So, ( ) and
Let us take
--------------------------- (1)
------------------------------ (2)
Where, ( ) ( ) ( )
( ) [ ] = 0.1[ ]
( ) ( )
( )
( )
So, ( ) and
Let us take
--------------------------- (1)
Put in equation ( ) we get,
------------------------------ (2)
Where, ( ) ( ) ( )
( ) [ ] = 0.1[ ]
( ) ( )
( ) [ ] [ ]
( ) ( ) ( )
( ) *( )
+ *( ) ( )
+
( ) ( )
( )
Exercise:
1) Given ( ) , find ( ) ( ) using Runge-Kutta methods of (i) second order, (ii) fourth
order.
2) Solve with ( ) for by Runge-Kutta method of fourth order.
3) Solve given at for ( ) by using Runge-Kutta method.
4) Solve the initial value problem using Runge-Kutta method of fourth order where ( ) with ( )
for .
5) Solve the initial value problem using Runge-Kutta method of fourth order where , with ( ) for
and .
6) Using Runge-Kutta method of fourth order, solve for ( ) ( ) and ( ) given that and
( )
7) Solve the following for ( ) ( ) using R-K method of (i) second order (ii) fourth order.
(a) ; ( )
(b) ; ( )
8. Using Runge-Kutta method of fourth order, solve for ( ) ( ) given that and ( ) .
Answers: