An -order ordinary differential equation given in explicit form
(1) |
is a statement of equality between the action of two operators. On the left hand side the linear differential operator
acts upon a sufficiently smooth function, , . On the right hand side, a nonlinear operator acts upon the independent variable and the first derivatives
An associated function has values given by
The numerical solution of (1) seeks to find an approximant of through:
Approximation of the differentiation operator ;
Approximation of the nonlinear operator
Approximation of the equality between the effect of the two operators
These approximation problems shall be considered one-by-one, starting with approximation of assuming that the action of is exactly represented through knowledge of .
Note that an -order differential equation can be restated as a system of first-order equations
(2) |
by introducing
Approximation of the differentiation operator for the problem
(3) |
can readily be extended to the individual equations of system (2).
Construction of approximants to (3) is first considered for the initial value problem (IVP)
(4) |
The two procedures are:
Approximation of the differentiation operator;
Differentiation of an approximation of .
Often the two approaches leads to the same algorithm. The problem (4) has a unique solution over some rectangle in the -plane if is Lipschitz-continuous, stated as the existence of such that
Note that Lipschitz continuity is a stronger condition than standard continuity in that it states . Differentiability implies Lipschitz continuity.
Consider approximation of through forward finite differences
(5) |
and denote by the approximation of , at the equidistant sample points . Evaluation of (2) with a order truncation of (5) then gives
For , the resulting scheme is
where , and is known as the Euler forward scheme. New values are obtained from previous values. Such methods are said to be explicit schemes. As to be expected from the truncation of (5) to the first term in the series, the scheme is first-order accurate. This can be formally established by evaluation of the error at step
At the next step, , and subtraction of the two errors gives upon Taylor-series expansion
Since , the one-step error is given by
After steps,
Assuming (exact representation of the initial condition),
Numerical solution of the initial value problem is carried out over some finite interval , with , hence
(6) |
indeed with first-order convergence.
Alternatively, one could use the backward or centered finite difference approximations of the derivative
(7) |
Truncation of the backward operator at first order gives
Note now that the unknown value appears as an argument to , with , the approximation of the exact slope . Some procedure to solve the equation
must be introduced in order to advance the solution from to . Such methods are said to be implicit schemes. The same type of error analysis as in the forward Euler case again leads to the conclusion that the one-step error is , while the overall error over a finite interval satisfies (6), and is first-order.
Truncation of the centered operator at first order gives
The higher-order accuracy of the centered finite differences leads to a more accurate numerical solution of the problem (4). The one-step error is third-order accurate,
and the overall error over interval is second-order accurate