Unit 3.2 Approximation
Unit 3.2 Approximation
Specific Objectives:
3. To apply Taylor’s series expansion to approximate functions and estimate the resulting errors.
Detailed Content Time Ratio Notes on Teaching
15.1 Treatment of Errors: their 6 Analysis of the error in a numerical result is basic to any computation, whether done
Estimation and Algebraic manually, with a calculator or a computer. Input values are seldom exact since they are
Manipulation often based on experiments or estimates, and the numerical processes themselves
introduce errors of various types. In order to know how well the numerical results are,
students are expected to be able to carry out simple error analysis in a calculation.
109
(a) Three basic types of Students are expected to know that there are three basic types of errors in a
errors numerical computation: inherent error, truncation error and round-off error.
(i) Inherent error Inherent errors are errors in the values of data caused by uncertainty in
measurement or by the necessarily approximating nature of representing in some finite
number of digits a number that cannot be represented exactly in the number of digits
available.
(ii) Truncation error Truncation errors and round-off errors both refer to errors that are introduced by
numerical procedures when the data are operated upon. The error introduced by
truncating an infinite mathematical process is called truncation error. In numerical
methods in this course, many of the procedures studied are infinite (in the sense that to
obtain an exact solution would require an infinite number of iterations), so the subject of
truncation error assumes major importance.
(iii) Round-off error When a calculator or computer is used to perform real number calculations,
round-off error occurs. This arises because the arithmetic performed in a machine
involves numbers with only a finite number of digits, with the result that many
calculations are performed with approximate representation of the actual numbers.
To illustrate the idea of rounding, teachers can use decimal machine numbers,
represented in the normalized form
±0.d1d 2d3 … dk × 10n , 1 ≤ d1 ≤ 9 , 0 ≤ d i ≤ 9
for i = 2, 3, 4, ……, k. The idea of rounding up and rounding down should also be
clearly explained.
(b) Absolute and relative It is preferable at this stage to revise with students the concept of absolute and
error relative error, which they have learned in S.3. Teachers should point out that each of the
three types of errors in (a) can be expressed in absolute or relative form.
(c) Estimation of errors A physical measurement may be given to a number of digits with the limits on
inherent errors given such as in 2.3 ± 0.1 cm or 2.3 cm (2 sig. fig.) or without any
qualification on the significance of the digits such as in 2.3 cm. In the latter case, it is
often assumed that it is accurate to within half a unit in the last place i.e. 0.05 cm.
As regards truncation errors, teachers should introduce them in the context of the
110
(d) Combining errors The major concern here is the question of how an error at one point propagates,
that is, whether its effect becomes greater or smaller as subsequent operations are
carried out. Students are expected to be familiar with the following facts.
1. Addition and subtraction
If S = a + b then max ∆S = ∆a + ∆b .
If K = a − b then max ∆K = ∆a + ∆b .
3. Exponentiation
∆F ∆a
=k
k
If F = a then max . The following examples are relevant.
F a
Example 1
Two masses are measured to be (100.0 ± 0.4) g and (94.0 ± 0.3) g. Calculate the
maximum absolute error in the sum and difference in the masses.
Example 2
15.2 Approximation of 6
Functional Values using
Taylor’s Expansion
(a) Taylor’s series Students may be motivated to find a polynomial p(x) which has, for a single
expansion of a function argument x0, the values of the polynomial and its derivatives matching those of a function
f(x)
i.e. p( i ) ( x0 ) = f ( i ) ( x0 ) , i = 0, 1, 2, ..., n.
Then teachers may ask them to substitute x = 0 and 3 into the expansion and then lead
them to discover that they are not convergent.
Afterwards, students may be asked to evaluate some functions at some arguments
within the region of convergence. It is preferable to ask students to expand a function in
Taylor’s series up to the fourth derivative only and do the evaluation correspondingly.
Functions such as y = (1 + x )2 ln(1 + x ) are typical examples.
(b) Error estimation Students are expected to recall the term truncation error as occurs in approximating
a function using Lagrange Interpolating Polynomial. The remainder, Rn in Lagrangian
form, could be shown or derived (for abler students only) to be
( x − x0 )n
Rn = f ( n ) (ε ) where ε lies between x0 and x.
n!
Detailed Content Time Ratio Notes on Teaching
Students should have no difficulty in seeing that the maximum error by truncating a
series is given by
( x − x0 )n
Rn ≤ M
n!
where M = max f ( n ) (ε) for every ε between x0 and x.
Given this error term, students may be asked to do examples like estimating the
maximum error committed if 3 terms in the series expansion of
x2 x4 x6
cos x = 1 − + − + ……
2! 4! 6!
π
are used to evaluate cos , and finding the number of terms of the Taylor’s series
3
expansion of
x x2 x3 x 4
ex = 1+ + + + + ……
113
1! 2! 3! 4!
to evaluate e so that the maximum error is less than 0.0001.
12