Section 4.4.7.1: Demonstration that Improved and Modified Euler are Second Order methods

Second order means:
the method matches the exact solution if the exact solution is a quadratic:
x(t) = x(n) + a1 (t - tn) + a2 (t - tn)2.
For such a function,
$ \frac{dx}{dt} = f(t) = a_1 + 2 a_2 (t - t_n) $.

See how the proposed methods work on $\frac{dx}{dt} = f(t)$.

1.
f(n) = f(tn) = a1
2.
Take a first order step for a fraction p of the full step (p = 1 or $\frac{1}{2}$ for Improved or Modified Euler)
x(I) = x(n) + p h f(n) = x(n) + a1 p h;
t(I) = tn + p h.
3.
Stage I derivative estimate at fraction p across step
f(I) = f(t(I)) = a1 + 2 a2 (t(I) - tn) = a1 + 2 a2 p h.
4.
For Stage II derivative take a weighted average of f(I) (assuming weight q) and f(n) (weight (1-q)):
$f(II) = q f(I) + (1-q) f(n) = q(a_1 + 2 a_2 p h) + (1-q) a_1 , \\
f(II) = a_1 + 2 a_2 p q h $
5.
Full step using Stage II derivative f(II)
x(n+1) = x(n) + h f(II) = x(n) + a1 h + 2 a2 p q h2.

Compare this with the exact solution

x(tn+1) = x(n) + a1 (tn+1 - tn) + a2 (tn+1 - tn)2


x(tn+1) = x(n) + a1 h + a2 h2

For an exact match a second order method must have

2 p q = 1

Thus if p=1 (Improved Euler with full first order step),
we need $q=\frac{1}{2}$ (average of start and end of step derivative estimates).
If $p=\frac{1}{2}$ (Modified Euler with half first order step),
we need q=1 (use the mid point derivative for the full step).

These values of q are what we assumed before, so the methods are indeed second order.

Performance of Second Order Explicit Methods on a Linear ODE

Apply the general second order explicit method (with parameters p and $q = \frac{1}{2p}$) to the linear ODE

\begin{displaymath}\frac{dx}{dt} = - k x\end{displaymath}

1.
f(n) = f(x(n)) = - k x(n)
2.
First order step to fraction p of the full step
x(I) = x(n) + p h f(n) = x(n) - p h k x(n)
3.
Stage I derivative estimate
f(I) = f(x(I)) = - k x(I) = - k x(n) + p h k2 x(n)
4.
Stage II derivative (weighted average):
$f(II) = q f(I) + (1-q) f(n) = \frac{1}{2p} f(I) + (1- \frac{1}{2p}) f(n) , \\
...
...II) = - k x(n) + \frac{1}{2p} p h k^2 x(n) = - k x(n) + \frac{1}{2} h k^2 x(n) $
5.
Full step:
$ x(n+1) = x(n) + h f(II) = x(n) - h k x(n) + \frac{1}{2} (h k)^2 x(n) $.

Thus

\begin{displaymath}\frac{x(n+1)}{x(n)} = 1 - h k + \frac{1}{2} (h k)^2 \end{displaymath}

Local error

\begin{displaymath}e_n = x(n+1) - x(n) exp(- h k) = [ 1 - h k + \frac{1}{2} (h k...
... h k + \frac{1}{2!} (h k)^2 - \frac{1}{3!} (h k)^3 ...) ] x(n) \end{displaymath}


\begin{displaymath}\vert e_n \vert \approx \frac{1}{6} (h k)^3 x(n) \end{displaymath}

In general

\begin{displaymath}\vert e_n \vert \approx \frac{1}{6} h^3 \vert\frac{d^3x}{dt^3}\vert \end{displaymath}



Return to Section 4.4.7 Index

Return to Section 4.4 Index

Course Organiser
Last modified: Wed Aug 5 14:47:00 BST