Ordinary Differential Equations. John Butcher. The University of Auckland. New Zealand. Universit`a degli Studi di Salerno. 9 September 2008. Trees and ...
Trees and Numerical Methods for Ordinary Differential Equations John Butcher
The University of Auckland New Zealand Universit`a degli Studi di Salerno 9 September 2008
Trees and numerical methods for ordinary differential equations – p. 1/41
Contents What are trees? What are differential equations? What are Runge–Kutta methods?
Trees and numerical methods for ordinary differential equations – p. 2/41
Contents What are trees? What are differential equations? What are Runge–Kutta methods? Order of methods: First approach Order of methods: Second approach
Trees and numerical methods for ordinary differential equations – p. 2/41
Contents What are trees? What are differential equations? What are Runge–Kutta methods? Order of methods: First approach Order of methods: Second approach Taylor expansion of exact solution Taylor expansion for numerical approximation Order conditions
Trees and numerical methods for ordinary differential equations – p. 2/41
Contents What are trees? What are differential equations? What are Runge–Kutta methods? Order of methods: First approach Order of methods: Second approach Taylor expansion of exact solution Taylor expansion for numerical approximation Order conditions Fourth order methods A method of order 4 or 5 Algebraic interpretation Trees and numerical methods for ordinary differential equations – p. 2/41
Contents What are trees? What are differential equations? What are Runge–Kutta methods? Order of methods: First approach Order of methods: Second approach Taylor expansion of exact solution Taylor expansion for numerical approximation Order conditions Fourth order methods A method of order 4 or 5 Algebraic interpretation Appendix Trees and numerical methods for ordinary differential equations – p. 2/41
What are trees? In this talk Trees means Rooted Trees. I will just give diagrams for the first few (rooted) trees and hope this is enough of an explanation.
Trees and numerical methods for ordinary differential equations – p. 3/41
What are trees? In this talk Trees means Rooted Trees. I will just give diagrams for the first few (rooted) trees and hope this is enough of an explanation.
Trees and numerical methods for ordinary differential equations – p. 3/41
What are trees? In this talk Trees means Rooted Trees. I will just give diagrams for the first few (rooted) trees and hope this is enough of an explanation. In each case the root is at the bottom of the diagram.
Trees and numerical methods for ordinary differential equations – p. 3/41
What are trees? In this talk Trees means Rooted Trees. I will just give diagrams for the first few (rooted) trees and hope this is enough of an explanation. In each case the root is at the bottom of the diagram.
There are applications in genealogies and the representation of nested arithmetic operations
Trees and numerical methods for ordinary differential equations – p. 3/41
What are trees? In this talk Trees means Rooted Trees. I will just give diagrams for the first few (rooted) trees and hope this is enough of an explanation. In each case the root is at the bottom of the diagram.
There are applications in genealogies and the representation of nested arithmetic operations rah Zoë a Z
rg Ma
ie ald la h r n p e El Fin So Em ael h c Mi
ite r e u J oh
rew d An
n
Trees and numerical methods for ordinary differential equations – p. 3/41
What are trees? In this talk Trees means Rooted Trees. I will just give diagrams for the first few (rooted) trees and hope this is enough of an explanation. In each case the root is at the bottom of the diagram.
There are applications in genealogies and the representation of nested arithmetic operations rah Zoë a Z
rg Ma
ie ald la h r n p e El Fin So Em ael h c Mi
ite r e u J oh
n
An
w dre
y
x
z + ∗ (x+y)∗z Trees and numerical methods for ordinary differential equations – p. 3/41
What are differential equations? In this talk, differential equations are initial value problems such as y ′ (x) = f (y(x)),
y(x0 ) = y0 ,
f : RN → RN
(1)
or y ′ (x) = f (x, y(x)), y(x0 ) = y0 , f : R×RN → RN (2)
Trees and numerical methods for ordinary differential equations – p. 4/41
What are differential equations? In this talk, differential equations are initial value problems such as y ′ (x) = f (y(x)),
y(x0 ) = y0 ,
f : RN → RN
(1)
or y ′ (x) = f (x, y(x)), y(x0 ) = y0 , f : R×RN → RN (2) It looks deceptively easy to assume that N = 1 but this doesn’t capture all the flavour of the problem, even for problem (2).
Trees and numerical methods for ordinary differential equations – p. 4/41
What are differential equations? In this talk, differential equations are initial value problems such as y ′ (x) = f (y(x)),
y(x0 ) = y0 ,
f : RN → RN
(1)
or y ′ (x) = f (x, y(x)), y(x0 ) = y0 , f : R×RN → RN (2) It looks deceptively easy to assume that N = 1 but this doesn’t capture all the flavour of the problem, even for problem (2). If we make no such assumption, then (1) is simpler than (2) and really just as general, because we can always add an additional differential equation whose solution is x. Trees and numerical methods for ordinary differential equations – p. 4/41
What are Runge–Kutta methods? In terms of the autonomous initial value system y ′ (x) = f (y(x)), y(x0 ) = y0 , the aim of a Runge–Kutta method is to calculate approximations: y1 ≈ y(x1 ),
y2 ≈ y(x2 ),
....
The basic example is the simple Euler method yn = yn−1 + hf (yn−1 ),
h = xn − xn−1
Trees and numerical methods for ordinary differential equations – p. 5/41
What are Runge–Kutta methods? In terms of the autonomous initial value system y ′ (x) = f (y(x)), y(x0 ) = y0 , the aim of a Runge–Kutta method is to calculate approximations: y1 ≈ y(x1 ),
y2 ≈ y(x2 ),
....
The basic example is the simple Euler method yn = yn−1 + hf (yn−1 ),
h = xn − xn−1
This can be made more accurate by using the mid-point quadrature formula: 1 yn = yn−1 + hf yn−1 + 2 hf (yn−1 ) . Trees and numerical methods for ordinary differential equations – p. 5/41
What are Runge–Kutta methods? In terms of the autonomous initial value system y ′ (x) = f (y(x)), y(x0 ) = y0 , the aim of a Runge–Kutta method is to calculate approximations: y1 ≈ y(x1 ),
y2 ≈ y(x2 ),
....
The basic example is the simple Euler method yn = yn−1 + hf (yn−1 ),
h = xn − xn−1
This can be made more accurate by using either the mid-point or the trapezoidal rule quadrature formula: 1 yn = yn−1 + hf yn−1 + 2 hf (yn−1 ) . yn = yn−1 + 21 hf (yn−1 ) + 12 hf yn−1 + hf (yn−1 ) . Trees and numerical methods for ordinary differential equations – p. 5/41
These methods from Runge’s 1895 paper are “second order” because the error in a single step behaves like O(h3 ). At a specific output point the error is O(h2 ).
Trees and numerical methods for ordinary differential equations – p. 6/41
These methods from Runge’s 1895 paper are “second order” because the error in a single step behaves like O(h3 ). At a specific output point the error is O(h2 ). It is recognised that for accurate calculations, high order is better than low order and Runge’s work was followed by contributions by Heun, Kutta, Nyström and others, pushing the available order up to 3, 4, 5 and higher.
Trees and numerical methods for ordinary differential equations – p. 6/41
These methods from Runge’s 1895 paper are “second order” because the error in a single step behaves like O(h3 ). At a specific output point the error is O(h2 ). It is recognised that for accurate calculations, high order is better than low order and Runge’s work was followed by contributions by Heun, Kutta, Nyström and others, pushing the available order up to 3, 4, 5 and higher. Our aim now will be to formulate a typical step in an “s stage method” and then find criteria for this method to have a specific order.
Trees and numerical methods for ordinary differential equations – p. 6/41
In carrying out a step we evaluate s stage values Y1 ,
Y2 ,
...,
Ys
and s stage derivatives F1 , F2 ,
...,
Fs ,
using the formula Fi = f (Yi ).
Trees and numerical methods for ordinary differential equations – p. 7/41
In carrying out a step we evaluate s stage values Y1 ,
Y2 ,
...,
Ys
and s stage derivatives F1 , F2 ,
...,
Fs ,
using the formula Fi = f (Yi ). Each Yi is found as a linear combination of the Fj added on to y0 : s X Yi = y0 + h aij Fj j=1
Trees and numerical methods for ordinary differential equations – p. 7/41
In carrying out a step we evaluate s stage values Y1 ,
Y2 ,
...,
Ys
and s stage derivatives F1 , F2 ,
...,
Fs ,
using the formula Fi = f (Yi ). Each Yi is found as a linear combination of the Fj added on to y0 : s X Yi = y0 + h aij Fj ≈ y(x0 + ci h) j=1
Trees and numerical methods for ordinary differential equations – p. 7/41
In carrying out a step we evaluate s stage values Y1 ,
Y2 ,
...,
Ys
and s stage derivatives F1 , F2 ,
...,
Fs ,
using the formula Fi = f (Yi ). Each Yi is found as a linear combination of the Fj added on to y0 : s X Yi = y0 + h aij Fj ≈ y(x0 + ci h) j=1
and the approximation at x1 = x0 + h is found from s X bi Fi y1 = y0 + h i=1
Trees and numerical methods for ordinary differential equations – p. 7/41
In carrying out a step we evaluate s stage values Y1 ,
Y2 ,
...,
Ys
and s stage derivatives F1 , F2 ,
...,
Fs ,
using the formula Fi = f (Yi ). Each Yi is found as a linear combination of the Fj added on to y0 : s X Yi = y0 + h aij Fj ≈ y(x0 + ci h) j=1
and the approximation at x1 = x0 + h is found from s X bi Fi ≈ y(x0 + h). y1 = y0 + h i=1
Trees and numerical methods for ordinary differential equations – p. 7/41
We represent the method by a tableau: c1 a11 c2 a21 .. .. . . cs as1 b1
a12 a22 .. . as2 b2
· · · a1s · · · a2s .. . · · · ass · · · bs
Trees and numerical methods for ordinary differential equations – p. 8/41
We represent the method by a tableau: c1 a11 a12 · · · a1s c2 a21 a22 · · · a2s .. .. .. .. . . . . cs as1 as2 · · · ass b1 b2 · · · bs or, if the method is explicit, by the simplified tableau 0 c2 a21 .. . . . .. .. . . . cs as1 as2 · · · as,s−1 b1 b2 · · · bs−1 bs Trees and numerical methods for ordinary differential equations – p. 8/41
Examples: 1 y1 = y0 + 0hf (y0 ) + 1hf y0 + 2 hf (y0 ) 0 1 2
1 2
0 1
Trees and numerical methods for ordinary differential equations – p. 9/41
Examples: 1 y1 = y0 + 0hf (y0 ) + 1hf y0 + 2 hf (y0 ) Y1
0 1 2
1 2
Y2
0 1
Trees and numerical methods for ordinary differential equations – p. 9/41
Examples: 1 y1 = y0 + 0hf (y0 ) + 1hf y0 + 2 hf (y0 ) 0
Y1
1 2
Y2
1 2
0 1 y1 = y0 +
1 hf (y0 ) 2
+
1 hf 2
y0 + 1hf (y0 )
0 1 1 1 2
1 2
Trees and numerical methods for ordinary differential equations – p. 9/41
Examples: 1 y1 = y0 + 0hf (y0 ) + 1hf y0 + 2 hf (y0 ) 0
Y1
1 2
Y2
1 2
0 1 y1 = y0 + Y1
1 hf (y0 ) 2
+
1 hf 2
y0 + 1hf (y0 )
0 1 1 1 2
Y2 1 2
Trees and numerical methods for ordinary differential equations – p. 9/41
Order of methods: First approach This approach has a proud history andv has been used by Runge, Heun, Kutta, Nyström and Huta to obtain methods up to order 6.
Trees and numerical methods for ordinary differential equations – p. 10/41
Order of methods: First approach This approach has a proud history andv has been used by Runge, Heun, Kutta, Nyström and Huta to obtain methods up to order 6. We start with the differential equation
Trees and numerical methods for ordinary differential equations – p. 10/41
Order of methods: First approach This approach has a proud history andv has been used by Runge, Heun, Kutta, Nyström and Huta to obtain methods up to order 6. We start with the differential equation dy y(x0 ) = y0 dx = f (x, y),
Trees and numerical methods for ordinary differential equations – p. 10/41
Order of methods: First approach This approach has a proud history andv has been used by Runge, Heun, Kutta, Nyström and Huta to obtain methods up to order 6. We start with the differential equation dy y(x0 ) = y0 dx = f (x, y), We want the first few terms in the formal Taylor series about x0 : so we calculate the next few derivatives y ′′ = fx + f fy , ′′′
2
y = fxx + 2f fxy + f fyy +
2 f fy
Trees and numerical methods for ordinary differential equations – p. 10/41
Order of methods: First approach This approach has a proud history andv has been used by Runge, Heun, Kutta, Nyström and Huta to obtain methods up to order 6. We start with the differential equation dy y(x0 ) = y0 dx = f (x, y), We want the first few terms in the formal Taylor series about x0 : so we calculate the next few derivatives y ′′ = fx + f fy , ′′′
2
y = fxx + 2f fxy + f fyy +
2 f fy
Once we have the Taylor series for y(x0 + h) we find also the series for a numerical approximation and we get a number of “order conditions”. Trees and numerical methods for ordinary differential equations – p. 10/41
Order of methods: First approach This approach has a proud history andv has been used by Runge, Heun, Kutta, Nyström and Huta to obtain methods up to order 6. We start with the differential equation dy y(x0 ) = y0 dx = f (x, y), We want the first few terms in the formal Taylor series about x0 : so we calculate the next few derivatives y ′′ = fx + f fy , ′′′
2
y = fxx + 2f fxy + f fyy +
2 f fy
Once we have the Taylor series for y(x0 + h) we find also the series for a numerical approximation and we get a number of “order conditions”. For order p call the number of conditions Cp . Trees and numerical methods for ordinary differential equations – p. 10/41
The number of parameters in an explicit Runge–Kutta method with s stages is s(s + 1)/2. It might be expected that s should be chosen so that there are more parameters than conditions, as in the table p 1 2 3 4
Cp 1 2 4 8
s 1 2 3 4
s(s+1) 2
5
16
6
21
6
31
8
36
1 3 6 10
Trees and numerical methods for ordinary differential equations – p. 11/41
The number of parameters in an explicit Runge–Kutta method with s stages is s(s + 1)/2. It might be expected that s should be chosen so that there are more parameters than conditions, as in the table p 1 2 3 4
Cp 1 2 4 8
s 1 2 3 4
s(s+1) 2
5 6
16 31
6 7 8
21 28 36
1 3 6 10
Surprisingly, order 6 can be achieved with s = 7 Trees and numerical methods for ordinary differential equations – p. 11/41
Order of methods: Second approach We make two changes; these are 1. Remove x from f (x, y) — in other words make the problem autonomous
Trees and numerical methods for ordinary differential equations – p. 12/41
Order of methods: Second approach We make two changes; these are 1. Remove x from f (x, y) — in other words make the problem autonomous 2. Regard y as a vector-valued function
Trees and numerical methods for ordinary differential equations – p. 12/41
Order of methods: Second approach We make two changes; these are 1. Remove x from f (x, y) — in other words make the problem autonomous 2. Regard y as a vector-valued function The first change seems to make everything simpler because all terms involving fx , fxy etc just disappear.
Trees and numerical methods for ordinary differential equations – p. 12/41
Order of methods: Second approach We make two changes; these are 1. Remove x from f (x, y) — in other words make the problem autonomous 2. Regard y as a vector-valued function The first change seems to make everything simpler because all terms involving fx , fxy etc just disappear. The second change seems to make everything more complicated, because terms like f 2 fy fyy , which are identical in one dimension, have to be distinguished from each other in N dimensions.
Trees and numerical methods for ordinary differential equations – p. 12/41
How are we going to write these complicated terms involving compositions of what will be linear and multilinear operators?
Trees and numerical methods for ordinary differential equations – p. 13/41
How are we going to write these complicated terms involving compositions of what will be linear and multilinear operators? It is possible to work in terms of tensors but I prefer to use Frechet derivatives.
Trees and numerical methods for ordinary differential equations – p. 13/41
How are we going to write these complicated terms involving compositions of what will be linear and multilinear operators? It is possible to work in terms of tensors but I prefer to use Frechet derivatives. I will now write the first, second and third derivatives in this way with the one-dimensional formulae written beside them for comparison. y ′ = f,
y′ = f
y ′′ = fx + f fy ,
y ′′ = f ′ f
y ′′′ = fxx + 2f fxy + f 2 fyy + f fy2 , y ′′′ = f ′′ (f, f) + f ′ f ′ f where f = f (y(x)), f ′ = f ′ (y(x)) etc. Trees and numerical methods for ordinary differential equations – p. 13/41
If we count the number of order conditions in this second formulation — call this number Dp for the moment — and include Cp for comparison, we get this table
Trees and numerical methods for ordinary differential equations – p. 14/41
If we count the number of order conditions in this second formulation — call this number Dp for the moment — and include Cp for comparison, we get this table p Cp D p 1 2 3 4 5 6 7 8
1 2 4 8 16 31
1 2 4 8 17 37 85 200 Trees and numerical methods for ordinary differential equations – p. 14/41
If we count the number of order conditions in this second formulation — call this number Dp for the moment — and include Cp for comparison, we get this table p Cp D p 1 1 1 2 2 2 3 4 4 4 8 8 5 16 17 6 31 37 7 85 8 200 I don’t know if C7 , C8 , . . . are known Trees and numerical methods for ordinary differential equations – p. 14/41
If we count the number of order conditions in this second formulation — call this number Dp for the moment — and include Cp for comparison, we get this table p Cp D p 1 1 1 2 2 2 3 4 4 4 8 8 5 16 17 6 31 37 7 85 8 200 I don’t know if C7 , C8 , . . . are known but I don’t think we should really care what their values are. Trees and numerical methods for ordinary differential equations – p. 14/41
In the second approach, we again list the formulae for the derivatives; but this time go as far as order 4. Note the tree-like structures:
Trees and numerical methods for ordinary differential equations – p. 15/41
In the second approach, we again list the formulae for the derivatives; but this time go as far as order 4. Note the tree-like structures: y ′ = f, f
Trees and numerical methods for ordinary differential equations – p. 15/41
In the second approach, we again list the formulae for the derivatives; but this time go as far as order 4. Note the tree-like structures: y ′ = f, f y ′′ = f ′ f,
f′ f
Trees and numerical methods for ordinary differential equations – p. 15/41
In the second approach, we again list the formulae for the derivatives; but this time go as far as order 4. Note the tree-like structures: y ′ = f, f y ′′ = f ′ f, y ′′′ = f ′′ (f, f) + f ′ f ′ f,
f′ f f f′′ f
f′ f′ f
Trees and numerical methods for ordinary differential equations – p. 15/41
In the second approach, we again list the formulae for the derivatives; but this time go as far as order 4. Note the tree-like structures: y ′ = f, f f′ f f f′′ f
y ′′ = f ′ f, y ′′′ = f ′′ (f, f)
f′ f′ f
+ f ′ f ′ f, y
(4)
f f f f ′′′
′′′
= f (f, f, f) + 3f ′′ (f, f ′ f)
f f
+ f ′ f ′′ (f, f) ′ ′ ′
+f f f f
f′ f′′
f
f′′
f′ f
f′ f′ f′ f
Trees and numerical methods for ordinary differential equations – p. 15/41
The plan now is to formulate Runge–Kutta methods in a systematic way and to explore the order conditions.
Trees and numerical methods for ordinary differential equations – p. 16/41
The plan now is to formulate Runge–Kutta methods in a systematic way and to explore the order conditions. This will all be done using what I am calling the second approach.
Trees and numerical methods for ordinary differential equations – p. 16/41
The plan now is to formulate Runge–Kutta methods in a systematic way and to explore the order conditions. This will all be done using what I am calling the second approach. Later, right at the end, I plan to come back to the first approach and show why I don’t think it is completely satisfactory.
Trees and numerical methods for ordinary differential equations – p. 16/41
The plan now is to formulate Runge–Kutta methods in a systematic way and to explore the order conditions. This will all be done using what I am calling the second approach. Later, right at the end, I plan to come back to the first approach and show why I don’t think it is completely satisfactory. Before we go on, note that the numbers Dp , is just the number of rooted trees with no more than p vertices.
Trees and numerical methods for ordinary differential equations – p. 16/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives.
Trees and numerical methods for ordinary differential equations – p. 17/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives. y ′ (x) = f (y(x))
Trees and numerical methods for ordinary differential equations – p. 17/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives. y ′ (x) = f (y(x)) y ′′ (x) = f ′ (y(x))y ′ (x) = f ′ (y(x))f (y(x)))
Trees and numerical methods for ordinary differential equations – p. 17/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives. y ′ (x) = f (y(x)) y ′′ (x) = f ′ (y(x))y ′ (x) = f ′ (y(x))f (y(x))) ′′′
′′
′
′
′
′
y (x) = f (y(x))(f (y(x)), y (x)) + f (y(x))f (y(x))y (x) =f ′′ (y(x))(f (y(x)), f (y(x)))+f ′ (y(x))f ′ (y(x))f (y(x))
Trees and numerical methods for ordinary differential equations – p. 17/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives. y ′ (x) = f (y(x)) y ′′ (x) = f ′ (y(x))y ′ (x) = f ′ (y(x))f (y(x))) ′′′
′′
′
′
′
′
y (x) = f (y(x))(f (y(x)), y (x)) + f (y(x))f (y(x))y (x) =f ′′ (y(x))(f (y(x)), f (y(x)))+f ′ (y(x))f ′ (y(x))f (y(x)) As we have found out, this becomes increasingly complicated as we evaluate higher derivatives.
Trees and numerical methods for ordinary differential equations – p. 17/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives. y ′ (x) = f (y(x)) y ′′ (x) = f ′ (y(x))y ′ (x) = f ′ (y(x))f (y(x))) ′′′
′′
′
′
′
′
y (x) = f (y(x))(f (y(x)), y (x)) + f (y(x))f (y(x))y (x) =f ′′ (y(x))(f (y(x)), f (y(x)))+f ′ (y(x))f ′ (y(x))f (y(x)) As we have found out, this becomes increasingly complicated as we evaluate higher derivatives. Hence we return to the known systematic pattern:
Trees and numerical methods for ordinary differential equations – p. 17/41
Taylor expansion of exact solution Recalculate formulae for the second, third, . . . , derivatives. y ′ (x) = f (y(x)) y ′′ (x) = f ′ (y(x))y ′ (x) = f ′ (y(x))f (y(x))) ′′′
′′
′
′
′
′
y (x) = f (y(x))(f (y(x)), y (x)) + f (y(x))f (y(x))y (x) =f ′′ (y(x))(f (y(x)), f (y(x)))+f ′ (y(x))f ′ (y(x))f (y(x)) As we have found out, this becomes increasingly complicated as we evaluate higher derivatives. Hence we return to the known systematic pattern: Recall the notation f = f (y(x)), f′ = f ′ (y(x)), f′′ = f ′′ (y(x)), . . . . Trees and numerical methods for ordinary differential equations – p. 17/41
′
y (x) = f
f
′′
′
f f′
′′′
′′
y (x) = f f y (x) = f (f, f) + f′ f′ f
f
f
f′′ f f′ f′
Trees and numerical methods for ordinary differential equations – p. 18/41
′
y (x) = f
f
′′
′
f f′
′′′
′′
y (x) = f f y (x) = f (f, f) + f′ f′ f
f
f
f′′ f f′ f′
The various terms have a structure related to rooted-trees.
Trees and numerical methods for ordinary differential equations – p. 18/41
′
y (x) = f
f
′′
′
f f′
′′′
′′
y (x) = f f y (x) = f (f, f) + f′ f′ f
f
f
f′′ f f′ f′
The various terms have a structure related to rooted-trees. Hence, we introduce the set of all rooted trees and some functions on this set. Trees and numerical methods for ordinary differential equations – p. 18/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T .
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices σ(t) symmetry of t = order of automorphism group
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices σ(t) symmetry of t = order of automorphism group γ(t) density of t
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices σ(t) symmetry of t = order of automorphism group γ(t) density of t α(t) number of ways of labelling with an ordered set
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices σ(t) symmetry of t = order of automorphism group γ(t) density of t α(t) number of ways of labelling with an ordered set β(t) number of ways of labelling with an unordered set
Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices σ(t) symmetry of t = order of automorphism group γ(t) density of t α(t) number of ways of labelling with an ordered set β(t) number of ways of labelling with an unordered set F (t)(y0 ) elementary differential Trees and numerical methods for ordinary differential equations – p. 19/41
Let T denote the set of rooted trees: n T =
,
,
,
,
,
,
,
,
...
o
We identify the following functions on T . In this table, t will denote a typical tree r(t) order of t = number of vertices σ(t) symmetry of t = order of automorphism group γ(t) density of t α(t) number of ways of labelling with an ordered set β(t) number of ways of labelling with an unordered set F (t)(y0 ) elementary differential We will give examples of these functions based on t = Trees and numerical methods for ordinary differential equations – p. 19/41
t =
Trees and numerical methods for ordinary differential equations – p. 20/41
t = 1 23 4
r(t) = 7
5
6 7
Trees and numerical methods for ordinary differential equations – p. 20/41
t = 1 23 4
r(t) = 7
5
6 7
σ(t) = 8
Trees and numerical methods for ordinary differential equations – p. 20/41
t = 1 23 4
r(t) = 7
5
6 7
σ(t) = 8 1 11 1
γ(t) = 63
3
3 7
Trees and numerical methods for ordinary differential equations – p. 20/41
t = 1 23 4 5
r(t) = 7
6 7
σ(t) = 8 1 11 1 3
γ(t) = 63 α(t) =
r(t)! σ(t)γ(t)
3 7
= 10
Trees and numerical methods for ordinary differential equations – p. 20/41
t = 1 23 4 5
r(t) = 7
6 7
σ(t) = 8 1 11 1 3
γ(t) = 63
3 7
α(t) =
r(t)! σ(t)γ(t)
= 10
β(t) =
r(t)! σ(t)
= 630
Trees and numerical methods for ordinary differential equations – p. 20/41
t = 1 23 4 5
r(t) = 7
6 7
σ(t) = 8 1 11 1 3
γ(t) = 63
3 7
α(t) =
r(t)! σ(t)γ(t)
= 10
β(t) =
r(t)! σ(t)
= 630 f f f f
′′
′′
′′
F (t) = f f (f, f), f (f, f)
f′′
f′′ f′′
Trees and numerical methods for ordinary differential equations – p. 20/41
These functions are easy to compute up to order 4 trees: t r(t) 1 2
3
3
4
4
4
4
σ(t) 1 1
2
1
6
1
2
1
γ(t) 1 2
3
6
4
8
12
24
α(t) 1 1
1
1
1
3
1
1
β(t) 1 2
3
6
4
24
12
24
′
′′
′ ′
′′′
′′
′
′ ′′
′ ′ ′
F (t) f f f f (f, f) f f f f (f, f, f) f (f, f f) f f (f, f) f f f f Trees and numerical methods for ordinary differential equations – p. 21/41
The formal Taylor expansion of the solution at x0 + h is y(x0 + h) = y0 +
X α(t)hr(t) t∈T
r(t)!
F (t)(y0 )
Trees and numerical methods for ordinary differential equations – p. 22/41
The formal Taylor expansion of the solution at x0 + h is y(x0 + h) = y0 +
X α(t)hr(t) t∈T
r(t)!
F (t)(y0 )
Using the known formula for α(t), we can write this as y(x0 + h) = y0 +
X t∈T
hr(t) F (t)(y0 ) σ(t)γ(t)
Trees and numerical methods for ordinary differential equations – p. 22/41
The formal Taylor expansion of the solution at x0 + h is y(x0 + h) = y0 +
X α(t)hr(t) t∈T
r(t)!
F (t)(y0 )
Using the known formula for α(t), we can write this as y(x0 + h) = y0 +
X t∈T
hr(t) F (t)(y0 ) σ(t)γ(t)
Our aim will now be to find a corresponding formula for the result computed by one step of a Runge-Kutta method.
Trees and numerical methods for ordinary differential equations – p. 22/41
The formal Taylor expansion of the solution at x0 + h is y(x0 + h) = y0 +
X α(t)hr(t) t∈T
r(t)!
F (t)(y0 )
Using the known formula for α(t), we can write this as y(x0 + h) = y0 +
X t∈T
hr(t) F (t)(y0 ) σ(t)γ(t)
Our aim will now be to find a corresponding formula for the result computed by one step of a Runge-Kutta method. By comparing these formulae term by term, we will obtain conditions for a specific order of accuracy. Trees and numerical methods for ordinary differential equations – p. 22/41
Taylor expansion for numerical approximation We need to evaluate various expressions which depend on the tableau for a particular method.
Trees and numerical methods for ordinary differential equations – p. 23/41
Taylor expansion for numerical approximation We need to evaluate various expressions which depend on the tableau for a particular method. These are known as “elementary weights”.
Trees and numerical methods for ordinary differential equations – p. 23/41
Taylor expansion for numerical approximation We need to evaluate various expressions which depend on the tableau for a particular method. These are known as “elementary weights”. We use the example tree we have already considered to illustrate the construction of the elementary weight Φ(t). l
t=
m n
j
o
k i
Trees and numerical methods for ordinary differential equations – p. 23/41
Taylor expansion for numerical approximation We need to evaluate various expressions which depend on the tableau for a particular method. These are known as “elementary weights”. We use the example tree we have already considered to illustrate the construction of the elementary weight Φ(t). l
t=
Φ(t) =
s X
m n
j
o
k i
bi aij ajl ajmaik aknako
i,j,k,l,m,n,o=1
Trees and numerical methods for ordinary differential equations – p. 23/41
Taylor expansion for numerical approximation We need to evaluate various expressions which depend on the tableau for a particular method. These are known as “elementary weights”. We use the example tree we have already considered to illustrate the construction of the elementary weight Φ(t). l
t=
Φ(t) =
m n
j
s X
o
k i
bi aij ajl ajmaik aknako
i,j,k,l,m,n,o=1
Simplify by summing over l, m, n, o:
Φ(t) =
s X
2 2 biaij cj aik ck
i,j,k=1 Trees and numerical methods for ordinary differential equations – p. 23/41
Now add Φ(t) to the table of functions: t r(t) α(t) β(t) Φ(t)
1 1 1 P
bi
2 1 2 P bi ci
3 1 3 P 2 bi ci
3 1 6 P bi aij cj
t r(t) 4 4 4 4 1 3 1 1 α(t) β(t) 4 24 12 24 P P P 3 P 2 Φ(t) bi aij cj bi aij ajk ck bi ci bi ci aij cj
Trees and numerical methods for ordinary differential equations – p. 24/41
The formal Taylor expansion of the computed solution at x0 + h is y1 = y0 +
X β(t)hr(t) t∈T
r(t)!
Φ(t)F (t)(y0 )
Trees and numerical methods for ordinary differential equations – p. 25/41
The formal Taylor expansion of the computed solution at x0 + h is y1 = y0 +
X β(t)hr(t) t∈T
r(t)!
Φ(t)F (t)(y0 )
Using the known formula for β(t), we can write this as y1 = y0 +
X hr(t) t∈T
σ(t)
Φ(t)F (t)(y0 )
Trees and numerical methods for ordinary differential equations – p. 25/41
Order conditions To match the Taylor series y(x0 + h) = y0 +
X t∈T
y1 = y0 +
hr(t) F (t)(y0 ) σ(t)γ(t)
X hr(t) t∈T
σ(t)
Φ(t)F (t)(y0 )
up to hp terms we need to ensure that 1 Φ(t) = , γ(t)
Trees and numerical methods for ordinary differential equations – p. 26/41
Order conditions To match the Taylor series y(x0 + h) = y0 +
X t∈T
y1 = y0 +
hr(t) F (t)(y0 ) σ(t)γ(t)
X hr(t) t∈T
σ(t)
Φ(t)F (t)(y0 )
up to hp terms we need to ensure that
for all trees such that
1 Φ(t) = , γ(t) r(t) ≤ p. Trees and numerical methods for ordinary differential equations – p. 26/41
Order conditions To match the Taylor series y(x0 + h) = y0 +
X t∈T
y1 = y0 +
hr(t) F (t)(y0 ) σ(t)γ(t)
X hr(t) t∈T
σ(t)
Φ(t)F (t)(y0 )
up to hp terms we need to ensure that
for all trees such that
1 Φ(t) = , γ(t)
r(t) ≤ p. These are the “order conditions”. Trees and numerical methods for ordinary differential equations – p. 26/41
Fourth order methods The definitive work on fourth order methods is Kutta’s 1901 paper.
Trees and numerical methods for ordinary differential equations – p. 27/41
Fourth order methods The definitive work on fourth order methods is Kutta’s 1901 paper. Kutta found several families of methods; today I will review only methods based on Simpson’s rule: 0 1 2 1 2
1 2
1 2
− a32 1 1 − a42 − a43 1 6
a32 a42 a43 2 3 − b3 b3
1 6
Trees and numerical methods for ordinary differential equations – p. 27/41
Fourth order methods The definitive work on fourth order methods is Kutta’s 1901 paper. Kutta found several families of methods; today I will review only methods based on Simpson’s rule: 0 1 2 1 2
1 2
1 2
− a32 1 1 − a42 − a43
a32 a42 a43 1 2 1 − b b 3 3 6 6 3 Because the underlying quadrature formula has order 4, some order conditions are automatically satisfied:
Trees and numerical methods for ordinary differential equations – p. 27/41
It is necessary in fourth order methods with 4 stages that P −1 a4j = b4 (bj (1 − cj ) − i