7-Ode Ivp1
7-Ode Ivp1
7-Ode Ivp1
1
2/22/16
(*./ (*
lim = % &, (
5)
t
(*./ = (** + -
%(&,
* ()
Numerical methods for ODE-IVP:
Use best estimate of slope - to obtain ( &
Example
ODEIVP:
ODE: ( 8 = 2&(
Initial: ( 0 =1
2
2/22/16
@((*./)
3
2/22/16
Runge-Kutta Method:
(*./ = (* + -*
where, nth-order RK method gives slope as:
-* = A/ B/ + A? B? + + AD BD
4
2/22/16
Heuns Method
5
(*./ = (* + ? B/ + B?
B/ = @ & * ,(* , B? = @ & * + , (* + B/
Midpoint Method
(*./ = (* + B?
5 5EF
B/ = @ & * ,(* , B? = @ & * + ? , (* + ?
etc.
5
2/22/16
Syntax of ode45
6
2/22/16
7
2/22/16
8
2/22/16
5
(*./ = (* + B/ + 2B? + 2BM + BO + N L
P
B / = @ &*, (*
5 5EF
B ? = @ &* + ? , (* + ?
5 5EQ
B M = @ &* + ? , (* + ?
BO = @ &* + , (* + B M
9
2/22/16
10
2/22/16
5
Heuns Method: (*./ = (* + ? B/ + B? + N M
5
RK-3 (Std.) Method: (*./ = (* + B/ + 4B? + BM + N O
P
5
RK-4 (Std.) Method: (*./ = (* + B/ + 2B? + 2BM + BO + N L
P
11
2/22/16
12