Euler’s Method: Truncation Error
Contents
Euler’s Method: Truncation Error#
Like all numerical methods, Euler’s method has systemic error. This is introduced when we discard the higher order terms in the Taylor expansion. The local truncation error is thus:
If you are unfamiliar with the notation for \(O(h^3)\) (big O notation), in this case it means the dominant terms are proportional to \(h^3\) (higher order terms of \(h\) will be less dominant for \(0 < h < 1\)).
The local truncation error is associated with a single integration step. It is far more useful, however, to consider the global truncation error, which is the error accumulated over multiple integration steps. The global truncation error is \(O(h)\) [EulerErr1]. The derivation for the bounds of the error are beyond the scope of the course. As this error approximately scales linearly with \(h\), reducing the size of \(h\) will generally reduce the global error:
We can illustrate the relationship between the global error and \(h\) directly by looking at the magnitude of error at the same final \(x\) value for different \(h\) values:
There is a limit to how much reducing \(h\) will help you. If \(h\) is too small you could introduce floating point errors, that is when operations require more precision than afforded by the float data type. Reducing the size of \(h\) also means that you will have more steps to integrate to a final \(x\), which increases the computational time.
References#
- EulerErr1
James F. Epperson. An Introduction to Numerical Methods and Analysis. John Wiley & Sons, Inc., Hoboken, New Jersey, second edition edition, 2013.