

























































































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


























































































th-order Runge Kutta and
the Dormand-Prince Methods
Douglas Wilhelm Harder, M.Math. LEL
Department of Electrical and Computer Engineering
University of Waterloo
Waterloo, Ontario, Canada
ece.uwaterloo.ca
© 2012 by Douglas Wilhelm Harder. Some rights reserved.
th-order Runge Kutta
Adaptive methods
The Dormand-Prince method
The Matlab ode45 function
2
1 , x 2 , x 3 , x 4 , and x 5 is:
Suppose these were project grades and the last two projects had twice the weight of the other
projects
We can calculate the following weighted average :
(^1 2 3 4 5 1 1 1 1 )
5 1 5 2 5 3 5 4 5 5
1 1 1 2 2
7 1 7 2 7 3 7 4 7 5
4
1 , a 2 , a 3 , a 4 , and a 5 such that
allows us to calculate the weighted average
It is also possible to have negative weights:
Richardson extrapolation weights:
1 2 3 4 5
1 1 2 2 3 3 4 4 5 5
1 1 1 1 1
3 1 3 2 3 3 3 4 3 5
1 1 1 1 1
3 3 3 3 3
4 1 16 1
3 3 15 15
5
1 2 1
b
a
f x dx f x x x
a = = b
7
2 3 1
b
a
f x dx f x x x
a = = b
8
The composite
trapezoidal rule
1 2 3 3 1
b
a
f x dx f x f x f x x x
a = = b
10
Simpson’s rule
1 2 3 3 1
b
a
f x dx f x f x f x x x
a = = b
11
th-order Runge Kutta method
The Dormand-Prince method
Both use weighted averages
13
st-order ordinary-differential equation and an initial condition
Then, given an initial condition
we would like to approximate a solution
1 y t f t y t ,
14
0 0
y t y
16
1 2 1
y t y t t t t
y
k 1 k 1
y y hK
K 1 (^) f (^) t (^) k , yk
17
19
1 2 1
y t y t t t t
y
(^) 1 0
0.5 0.5 1
1 0.5 0.
y y y
20
1 2 1
y t y t t t t
y