Convergence, consistency and order
Local and global truncation errors, the definition of convergence and consistency, theoretical orders of the one-step methods and how to estimate the order numerically, with or without an exact solution.
Errors in the numerical solution
When an infinite process (the full Taylor expansion, the exact integral) is replaced by a finite one, each step commits a local truncation error . The global truncation error accumulates the local errors:
To this error one adds the round-off error of finite arithmetic. If the exact solution is known, the total error at each node is .
Convergence and consistency
Consistency looks at a single step; convergence, at the whole process. For a consistent method to converge, stability is also needed: errors must not be amplified as they propagate, which can fail with large steps even for consistent methods, as the Euler stability exercise shows.
Theoretical orders
| Method | Local error | Global error (order) |
|---|---|---|
| Euler | ||
| Euler implícito | ||
| Heun | ||
| RK4 |
Numerical estimation of the order
If the exact solution is known, compute the maximum error for several values of , doubling each time. The order appears as the limit of the logarithmic ratio:
If the exact solution is unknown, compare two consecutive discrete solutions: the one with subintervals against the one with evaluated at the same nodes, , and apply the same logarithmic ratio to the . The order estimation exercise applies both techniques to Euler, Heun and RK4.