In
numerical analysis
Numerical analysis is the study of algorithms that use numerical approximation (as opposed to symbolic manipulations) for the problems of mathematical analysis (as distinguished from discrete mathematics). It is the study of numerical methods t ...
and
scientific computing, truncation error is an error caused by approximating a mathematical process.
Examples
Infinite series
A summation series for
is given by an infinite series such as
In reality, we can only use a finite number of these terms as it would take an infinite amount of computational time to make use of all of them. So let's suppose we use only three terms of the series, then
In this case, the truncation error is
Example A:
Given the following infinite series, find the truncation error for if only the first three terms of the series are used.
Solution
Using only first three terms of the series gives
The sum of an infinite geometrical series
is given by
For our series, and , to give
The truncation error hence is
Differentiation
The definition of the exact first derivative of the function is given by
However, if we are calculating the derivative numerically,
has to be finite. The error caused by choosing
to be finite is a truncation error in the mathematical process of differentiation.
Example A:
Find the truncation in calculating the first derivative of
at
using a step size of
Solution:
The first derivative of
is
and at
,
The approximate value is given by
The truncation error hence is
Integration
The definition of the exact integral of a function
from
to
is given as follows.
Let
be a function defined on a
closed interval
In mathematics, a (real) interval is a set of real numbers that contains all real numbers lying between any two numbers of the set. For example, the set of numbers satisfying is an interval which contains , , and all numbers in between. Othe ...