You are on page 1of 26

/lr|can v|rrua| un|vers|r, 9

IX. Teaching and learning activities


9.1 Pre-assessment
1. If x is an exact measurement of a certain quantity and x
0
is its approximation,
the concept of error in the approximation is defned by

(a)
(b)
(c)
(d)

x
0
x
x x
0
x x
0
x x
0
2. The absolute error in approximating the exact quantity x = 104 by the approxi-
mate value x
0
= 107 is given by

(a)
(b)
(c)
(d)

4
3
7
104

The relative error in the approximation x
0
given in Question 1 is

(a)
(b)
(c)
(d)

0.028846
0.299462
0.002885
0.038462
3. One valid reason why the function
f (x) =
1 if x > 0
0 if x = 0


/lr|can v|rrua| un|vers|r, '0
is not continuous at x = 0 is

(a)
(b)
(c)
(d)

lim
x 0
lim
x 0
lim
x 0
lim
x 0
f (x) = f (0)
f (x) = 0
f (x) = 1
f (x) f (0)

4. The continuous function x
3
3x 3 must have a zero (root) at some point in
the
interval 2 < x < 3 because
(a)
(b)
(c)
(d)

f (2) f (3) = 0
f (2) f (3) < 0
f (2) > 0
f (2) = 0
f (3) < 0
f (3) = 0
5. The frst derivative of the function y = x
x
is
(a)
(b)
(c)
(d)

1+ ln(x) ( ) x
x
x
x
x
x
ln(x)
(1 ln(x))x
x
6. The truncated cubic Maclaurin series expansion of the function f (x) = 1+ x is

(a) :1
x
2
+
x
2
4

3x
3
8
(b) :1+
x
2

x
2
4
+
3x
3
8
(c) :1
x
2
+
x
2
8

x
3
16
(d) :1+
x
2

x
2
8
+
x
3
16

/lr|can v|rrua| un|vers|r, ''
7. The general anti-derivative of the function f (x) = ln(x) is given by

(a)
(b)
(c)
(d)

xln(x) + C
ln(x) x + C
xln(x) x + C
xln(x) + x + C

8. The value of the integral
1+ x
x
2
+ 2x + 5
3 1
2

dx is
(a)
(b)
(c)
(d)

1.146581
1.145681
1.146185
1.164581
9. Working throughout with six decimal places accuracy, the approximate
value of
1+ x
x
2
+ 2x + 5
3 1
2

dx using the Trapezoidal rule with h = 0.25 is


(a)
(b)
(c)
(d)

1.146850
1.416560
1.146038
1.146580
10. Working under the same conditions, the approximate value of the integral given
in Question 8 using Simpsons rule is found to be
(a) :
(b) :
(c) :
(d) :

1.416039
1.146083
1.146038
1.146580
/lr|can v|rrua| un|vers|r, '2
11. If the 3
rd
and 13
th
terms of an arithmetic sequence of numbers are 7 and 27 ,
respectively, then the 52
nd
element of the sequence is

(a)
(b)
(c)
(d)

103
105
107
106
12. Starting with x
0
= 2, the value of x
4
using the iteration formula x
n+1
=
3(1+ x
n
)
x
n

is
(a) :
(b) :
(c) :
(d) :

2.104255
2.103731
2.130731
2.103713
13. Given two points P(x
0
, y
0
) andQ(x
1
, y
1
) , the x-coordinate of the point where the
secant line AB cuts the x - axis is
(a)
x
1
y
0
x
0
y
1
y
1
y
0
(b)
y
1
y
0
x
1
y
0
x
0
y
1
(c)
x
0
y
1
x
1
y
0
y
1
y
0
(d)
y
1
y
0
x
0
y
1
x
1
y
0

/lr|can v|rrua| un|vers|r, 'J


14. The curve of a function y = f (x) passes through two points whose coordinates
are (0.2,1.183) and(0.4,1.342) . By using the straight line which joins the
two points to approximate the curve of the function in the given interval, the
approximate value of y at x = 0.3 is found to be

(a)
(b)
(c)
(d)

y = 1.2265
y = 1.6225
y = 1.5262
y = 1.2625
15. Given a point P(x
0
, f (x
0
)) on the curve of a differentiable function y = f (x) ,
the x coordinate of the point where the tangent at P cuts the x - axis is

(a) : x
0

f (x
0
)
f
'
(x
0
)
(b) : x
0
+
f (x
0
)
f
'
(x
0
)
(c) : x
0

f
'
(x
0
)
f (x
0
)
(d) : x
0
+
f
'
(x
0
)
f (x
0
)
16. The Bisection method is based on the principle that a continuous function which
is positive at one point x = a and negative at another point x = b has a root
(zero) at some point x = c in the interval a < c < b and that the point x =
a + b
2
, which bisects the interval [a, b], is a reasonable approximation of c . Starting
with the two points a = 2, b = 3, application of the bisection method on
the function x
3
3x 3 gives the value
(a)
(b)
(c)
(d)

x
3
=
x
3
=
x
3
=
x
3
=
2.215
2.115
2.125
2.225
after the third
bisection process.
/lr|can v|rrua| un|vers|r, '4
17. The Newton Raphson method for approximating a root of a function f (x) uses
the iteration formula

x
n+1
= x
n

f (x
n
)
f
'
(x
n
)

n = 0,1, 2,...
If x
0
= 2 is an approximation of one of the roots of the function f (x) = x
3
3x 3,
then application of the Newton-Raphson method on the function gives the value of
x
2
as:

(a)
(b)
(c)
(d)

x
2
=
x
2
=
x
2
=
x
2
=
2.130836
2.103386
2.301836
2.103836

18. The coordinates of the point where the curves representing the functions
x
2
+ y
2
= 4 ; x
2
y
2
= 1 intersect each other and which lies in the frst qua-
drant are

(a)
(b)
(c)
(d)

x = 1.224745,
x = 1.581139,
x = 1.511839,
x = 1, 242745,
y = 1.561139
y = 1.224745
y = 1.227445
y = 1.561139
19. Starting with x
0
= 1.5 , y
0
= 1.2 , the values x
3
and y
3
obtained using the pair
formulae x
n+1
= 4 y
n
2
, y
n+1
= x
n
2
1 n = 0,1, 2,... are
(a)
(b)
(c)
(d)

x
3
= 1.562050,
x
3
= 1.322875,
x
3
= 1.526050,
x
3
= 1.233875,
y
3
= 1.322875
y
3
= 1.562050
y
3
= 1.322875
y
3
= 1.562050
/lr|can v|rrua| un|vers|r, '5
Solutions
1. (c) 11. (b)
2. (b) 12. (b)
3. (d) 13. (c)
4. (b) 14. (d)
5. (a) 15. (a)
6. (d) 16. (c)
7. (d) 17. (d)
8. (c) 18. (b)
9. (c) 19. (c)
10. (d)
Pedagogical Comment For Learners
The learners confdence to embark on this module will greatly be enhanced by
solving these preassessment questions.
Questions 1,2 are on errors and 3 is on continuity. If you have problems in solving
them you are advised to look up the defnitions given in the Module Glosary.
Questions 4,5,6 and 7 are on the concepts of limits, continuity, differentiation and
the anti-derivative. If you fail to solve any of them then work through the relevant
Sections of the pre-requisite Module (Mathematics Module 3). The same tip holds if
you experience diffculties in solving Questions 8,9,10 and 11 on integration.
Questions 12,13,16,17,18 and 19 relate to the concept of iterations and simula-
tneous equations. Here, simply study carefully the given formulae and apply them
faithfully.
Questions 15, 16 and 17 are on linear approximation of a function. In case one faces
some problems in solving any of these, one should work through the relevant section
in your Higher Level Mathmatics books.
Each correct solution has 5 marks, giving a maximum score of 90 marks. A score in
the range 41 60 is average. A below average score (0 40) probably implies that
you need a thorough go at the relevant prerequisite material before starting the mo-
dule. An average score may mean you can start the module but with frequent cross
reference to some prerequisite materials. With an above average score (61 90) the
learner should confdently embark on the module in the knowledge that he/she has
the required background knowledge to start and successfully complete it.
/lr|can v|rrua| un|vers|r, '6
X. learning activities
LEARNING ACTIVITY # 1
Types and Sources of Errors
Summary
In this learning activity we discuss three important introductory topics. We begin by
making a distinction between analytic and numerical solutions. This is followed by
discussion of some typical mathematical problems specifcally selected to convince
the learner why numerical methods are needed. We conclude the activity by defning
the concept of errors in computational mathematics, pointing out their main causes,
types and presenting practical ways of eliminating or reducing their effect on nume-
rical solutions.
Specific Learning objectives
At the end of this learning activity the learner will be able to:
Defne the concept of errors in computational mathematics
Distinguish between absolute and relative errors and appropriately relate
them to the concepts of accuracy and precision
List the chief sources of computational errors and the practical steps to be taken
to eliminate or reduce their cumulative effect on the numerical solution
Appreciate the difference between the size (accuracy) and the seriousness
(precision) of an error.
Understand and apply linear interpolation on a given table of function va-
lues
Estimate the error in linear interpolation for a known smooth function
List of required readings
Wikipedia: Numerical Methods/Errors Introduction
List of relevant useful links
Wolfram MathWorld (visited 03.04.07)
http://mathworld.wolfram.com
Students should search for the entry covering the unit title. Also, search for
any key words in the text. Mathworld gives a detailed reference in all cases.
/lr|can v|rrua| un|vers|r, '7
Wikipedia (visited 03.04.07)
http://en.wikipedia.org/wiki
As with mathworld, students should search for the entry covering the unit title.
Also, search for any key words in the text. Wikipedia generally gives shorter
and less complete entries. However, they can be easier to read.
MacTutor History of Mathematics (visited 03.03.07)
http://www-history.mcs.standrews.ac.uk/Indexes
The MacTutor Archive is the most comprehensive history of mathematics on
the internet. Students should search for their unit title and read the history of
the subject. This gives a helpful overview of the importance and context of
the topic being studied.
Key Words
[Full defntions are given in the text]
Error in an approximation: The difference between the exact and the approximate
value.
Absolute error: The error without consideration of the sign (positive or negative).
Relative error: The ratio between the absolute error and the exact quantity.
Initial, discretization, truncation and rounding errors: Different types of errors
caused by different sources of error.
/lr|can v|rrua| un|vers|r, '8
Learning Activity 1: Types and Sources of Errors
Introduction
This frst learning activity of the module is intended to provide the learner with
answers to the following important questions; questions raised by many students
taking a numerical methods course for the frst time.
(1) What is a numerical solution and how does such a solution differ from an exact
(true) or analytical solution?
(2) Why should one learn numerical methods? Are numerical methods needed?
(3) What are errors in the context of mathematics? What are the main sources of
computational errors? How can one eliminate errors or reduce their effect on
numerical solutions?
We begin the activity by explaining the difference between an analytic and a numerical
solution. In order to establish the need for numerical methods we discuss a number of
mathematical problems specifcally selected with a view to convince the learner that
there is a real need for learning numerical methods either because analytical solutions
cannot be found or they are too complex to be of any practical use.
To answer the questions on errors we defne the concept of an error and list a number
of sources of errors. In the sequel we also suggest for each type and source of error
practical steps to be taken to reduce the error and hence its impact on numerical
solution.
Analytic Methods, Numerical Methods and Errors.
(a) Analytic versus numerical methods
What is a numerical solution and how does such a solution differ from an exact (true)
or analytical solution?
An analytic method for solving a given mathematical problem is any method based
on rigorous mathematical analysis and whose application leads to the true (exact)
solution, also known as analytic solution.
A numerical method for solving a given mathematical problem is any method based
on rigorous mathematical analysis whose application, in most cases, can only lead
to an approximate (non-exact) solution, also known as numerical solution. In some
very rare cases, a numerical method may result in an exact solution.

/lr|can v|rrua| un|vers|r, '9
Example 1.1
The exact solutions of the nonlinear equation x
2
5x + 3 = 0 can be obtained using
the well known quadratic formula (analytic method)

x
1, 2
=
b b
2
4ac
2a
.
This gives the analytic solutions x
1, 2
=
5 13
2
.
On the other hand, the iteration formula (numerical method)

x
n+1
= 5x
n
3, n = 0,1, 2,... ; x
0
= 4.5
may also be applied to approximate one of the two solutions of the given quadratic
equation. This method can only give an approximate numerical solution.
DO THIS
Given the numerical integration formulas
Trapezoidal rule: [ ]
0 1 1 0
; ) ( ) (
2
) (
1
0
x x h x f x f
h
dx x f
x
x
= + =

Simpsons rule:
[ ]
0 1 1 2 2 1 0
; ) ( ) ( 4 ) (
3
) (
2
0
x x x x h x f x f x f
h
dx x f
x
x
= = + + =


Verify that:
(i) The trapezoidal rule gives exact values of the integral

1
0
) (
x
x
dx x f for any linear
function b ax x f + = ) ( .
(ii) Simpsons rule gives exact values of the integral

2
0
) (
x
x
dx x f for any cubic
function :
d cx bx ax x f + + + =
2 3
) (
.
In general, the difference between analytical and numerical solutions can be summed
up by the statement: Analytical solutions are exact while numerical methods are
only approximate.
/lr|can v|rrua| un|vers|r, 20
(b) Need for numerical methods
Why should one learn numerical methods? Are numerical methods needed?
Because of the above distinction between analytic and numerical solutions one can
easily be tempted to conclude that one should only use analytic methods in solving
mathematical problems. In other words, there is no need to learn numerical methods
because they can only give approximate solutions. Such a conclusion is misguided.
We need to learn numerical methods for the following three main reasons.
1. For some problems the analytical solution may not be known. A typical examples
is given by the following cases.
x 1.0 1.25 1.5 1.75
2.0
) (x f
0000 . 1 1180 . 1 1180 . 1 3229 . 1 4142 . 1
2. An integral, such as

1
0
2
dx e
x
, is perfectly defned but the antiderivative of the in-
tegrand
2
) (
x
e x f = cannot be expressed using known mathematical functions.
3. In some cases, it may be possible to fnd a mathematical expression for the
analytical solution of a given problem. However, the expression may be com-
putationally too complicated to handle numerically. A typical problem is that of
fnding an antiderivative of the function
3
8
1
) (
x
x f

= .
After some tedious manipulations involving factorization of the denominator fol-
lowed by application of the method of partial fractions, one fnds the general anti
derivative
C
x x
x x x
x F +


+ +
+

+
=

4 4
4 2
ln
24
1
3
1
tan
12
3
) (
2
2
1
where C is an arbitrary constant of integration. This complicated result makes the
evaluation of a typical associated defnite integral


2
1
3
8 x
dx
almost impossible to
carry out with any meaningful degree of accuracy.
/lr|can v|rrua| un|vers|r, 2'
DO THIS
(i) Verify that ) ( x f
dx
dF
= (using the function F in example 3 above).
(ii) By factorizing
3
8 x = ) 4 2 )( 2 (
2
+ + x x x and applying the method of
partial fractions derive the expression for ) (x F as an anti-derivative of ) (x f .
(c) Errors
What are errors in the context of mathematics? What are the main sources of com-
putational errors? How can one eliminate errors or reduce their effect on numerical
solutions?
In the key words section you can fnd defnitions of the key concepts and stated the key
theorems and principles relevant to the topic of numerical methods. This includes the
defnitions of errors, absolute errors, relative errors, initial errors, discretization errors,
truncation errors and rounding errors. For ease of reference we list them here.
Assumption
Let
*
X be an approximation to an exact (true) quantity X . Then,
The absolute error in
*
X is defned by
*
X X .
The error in
*
X is defned by
*
X X
The percentage error in
*
X is defned by
X
X X
*
100

%
Since the exact (true) value X is normally not known, one replaces it with the
approximate value
*
X in the denominator of the expression for the relative and
percentage errors.
Precision and Accuracy
Measurements and calculations can be characterized with regard to their accuracy
and precision.
/lr|can v|rrua| un|vers|r, 22
Precision refers to how big or how small the absolute error
*
X X is. The absolute
error is therefore a measure of the precision of an approximation.
Accuracy refers to how closely the approximation
*
X agrees with the true value X
. Here, what counts is not only the magnitude of the deviation
*
X X

but its size


relative to the true value X . Accuracy is therefore measured by the relative error
X
X X
*

.

(d) Types and Sources of Errors
We now list the sources and types of errors and briefy discuss methods of eliminating
or reducing such errors so that the numerical solution we get is not seriously affected
by them to the extent of rendering it meaningless.
(i) Initial errors
Any mathematical problem meriting to be solved numerically involves some initial
data. Such data may be in the form of coeffcients in a mathematical expression or
entries in a matrix. If this initial data is not exact, then the deviations from their respec-
tive true values are called initial errors. In some problems, uncertainties in the initial
data can have devastating effect on the fnal numerical solution to the problem.
(ii) Discretization error
Most of the literature on the subject of computational errors does not make a distinc-
tion between discretization and truncation errors, the reason being that the two types
of errors are almost inseparable. In this presentation we separate the two because
truncation errors are special types of discretization errors.
The true (exact) solutions of some mathematical problems are continuous functions
) (x f y = of their respective independent variables. In almost all cases, numerical
methods for solving such problems approximate the unknown continuous solution
) (x f by a sequence { } ) (
n
x f of approximate values of the solution at a discrete set of
points { }
n
x in the domain of the solution function ) (x f . For example, the continuous
function
x
e x x f

+ = ) ( is the solution of the initial value problem x y y + = + 1
/
,
1 ) 0 ( = y
/lr|can v|rrua| un|vers|r, 2J
A typical numerical method for solving this problem is given by the recurrence
relation
, 1 , 0
0 0
= = y x

, ) 1 ( ) 1 (
1 1
h x y h y
n n n
+ + = ,... 3 , 2 , 1 = n , h being a
constant distance between two consecutive discrete values of the variable x . The
error resulting from such a discretization process is called discretization error.
(iii) Truncation error
Truncation errors are special types of discretization errors. The term truncation error
refers to the error in a method, which occurs because some infnite process is stopped
prematurely (truncated) to a fewer number of terms or iterations in the process.
Such errors are essentially algorithmic errors and one can predict the extent of the
error that will occur in the method.
Specifcally, the solution obtained using some numerical methods may involve infnite
processes. For instance, this is the case with all convergent iteration methods and
convergent infnite series. Since such infnite processes cannot be carried out indef-
nitely, one is forced to stop (truncate) the process and hence accept an approximate
solution. The error caused though this unavoidable termination of an infnite process
is called a truncation error.
(iv) Rounding error
Rounding errors are errors introduced during numerical calculations due to the ina-
bility of calculating devices to perform exact arithmetic. For example, if we multiply
two numbers, each with six decimal digits, the product will have twelve decimal digits.
Unfortunately some calculating devices may not be able to display all twelve decimal
digits. In such cases one is forced to work with fewer digits thereby necessitating
dropping some of the (less signifcant) digits on the right of the product. The error
so introduced is called a rounding error.
(e) Methods of reducing errors
In the spirit of prevention is better than cure we shall attempt in this section to
give practical suggestions of ways to eliminate or reduce the impact of various types
of computational errors that are encountered in resorting to numerical methods.
(i) How to reduce initial error
Initial errors can have a devastating effect on numerical solutions.
We illustrate a typical case involving an example taken from Francis Sheid, Nume-
rical Analysis, Shaum Outline Series, 1968 page 342 involving the solution of the
following two simultaneous linear equations.
x
-
y
=
1
x
-
y 00001 . 1
=
0
/lr|can v|rrua| un|vers|r, 24
The true (analytical) solution is 001 , 100 = x , 000 , 100 = y . In this example, the
set of initial data consists of the elements of the coeffcient matrix
and the right hand side vector .

However, if the entry 00001 . 1 in the matrix A

is changed
to 99999 . 0 while all other data items remain unchanged, the resulting system of
equations
x
-
y
=
1
x
-
y 99999 . 0
=
0
has the drastically changed exact (analytical) solution 999 , 99 = x , 000 , 100 = y
This somewhat startling result demonstrates how a small change in the initial data
can cause disproportionately large changes in the solution of some problems.
Thus, the only way to reducing or if possible, to eliminate initial errors is by ensuring
that all data given with or computed for use in solving a problem is as accurate
as is humanly possible.
(ii) How to reduce discretization errors
Different numerical methods for approximating the solution of a given mathematical
problem can result in numerical solutions with very different degrees of accuracy
due to the magnitudes of their respective discretization errors. Consider the problem
of evaluating the defnite integral:

+
1
0
2
1 x
dx
. The exact (analytical) value of the integral, correct to six decimal places
is

785398 . 0 ) 1 ( tan
1
=

.
Let us apply the trapezoidal method and Simpsons rule using an interval length
25 . 0 = h . First we evaluate the integrand
2
1
1
) (
x
x f
+
= at the relevant points and
get

=
00001 . 1 1
1 1
A

=
0
1
b
/lr|can v|rrua| un|vers|r, 25
i 0 1 2 3 4
i
x
0 25 . 0 5 . 0 75 . 0 1
) (
i
x f
000000 . 1 941176 . 0 800000 . 0 640000 . 0
500000 , 0
The trapezoidal rule [ ]

+ + + + ) ( ) ( ) ( ) ( 2 ) (
2
4 3 2 1 0
x f x f x f x f x f
h

gives the numerical solution 782794 . 0 .
Simpsons rule [ ] { } ) ( ) ( 2 ) ( ) ( 4 ) (
3
4 2 3 1 0
x f x f x f x f x f
h
+ + + + leads to

the numerical solution 0.785392.
One observes that, while the solution obtained using the trapezoidal rule is correct
to only two decimal places, the solution obtained using Simpsons rule is correct to
four decimal places. This signifcant difference in the accuracy of the two numerical
solutions is caused by the differences in the discretization errors of the two nume-
rical methods. Simpsons rule has a smaller discretization error than the trapezoidal
rule.
In general, discretization errors cannot be avoided. However, one can reduce them
substantially by being careful in selecting a numerical method whose discretization
error is known a priori to be relatively small.
(iii) How to reduce truncation errors
Truncation errors are caused by the unavoidable need to stop a convergent infnite
process in efforts to get a solution. The size of the truncation error will therefore
depend on the particular infnite process (numerical method) being used an on how
far we are prepared to carry on with the infnite process.
The truncation error can be reduced either by
(a) Choosing a numerical method with a small truncation error or
(b) Carrying out the infnite process suffciently far.
/lr|can v|rrua| un|vers|r, 26
Example 1.2
The continuous function 1 3 ) (
2
+ = x x x f has a root which lies in the interval
1 0 < < x (Why?). Using the quadratic formula, the exact value of the root correct
to six decimal places is 381966 . 0 = . A number of iterative methods exist for
approximating such a root. Here we consider two such methods:
The bisection method
x
n+1
=
x
n
x
n1
2
, provided
f (x
n
) f (x
n1
) < 0
.
The Newton-Raphson method
x = x
f (x
n
)
f
/
(x
n
)
, provided f
/
(x
n
) 0.
If one performs only three iterations (truncation after three iterations) with each
method using the starting values 0
0
= x and 1
1
= x for the bisection method and
0
1
= x for the Newton-Raphson method, one gets the following sequence of ap-
proximations for each method.
Method Initial Values
2
x
3
x
4
x
Bisection
0
0
= x
1
1
= x
500000 . 0 250000 . 0 375000 . 0
Newton
Raphson
0
1
= x
333333 . 0 380952 . 0 381966 . 0
These results demonstrate that in stopping the infnite process (iteration) after the
third iteration, the truncation error of the Newton Raphson method is much smaller
than that of the bisection method.
/lr|can v|rrua| un|vers|r, 27
DO THIS
Continue applying the bisect method on the above example until the solution is correct
to three decimal places. How many more iterations did this require?
(iv) How to Reduce Rounding Errors
Before we discuss this important last task in our learning activity we shall frst intro-
duce a few terms that will frequently be mentioned and used in the process.
What are Figures or Digits
In computational mathematics, the words fgure and digit are synonyms. They
are used interchangeably to mean any one of the ten numerals in the set {0, 1, 2, 3,
4, 5, 6, 7, 8, 9}.
In the decimal system of real numbers, a number N is a string or an ordered se-
quence of fgures or digits A typical example is the number
0 0000450700 . 0365 0007392060 = N
A number can be viewed as a measure of the size or magnitude of some real or ima-
ginary quantity. The position of each digit in the string of digits has direct bearing
on the importance or signifcance of that digit (fgure) in the overall measure of the
size or magnitude of the quantity the number represents.
Intuitively we know that the leftmost digit 7 in the number N above is more signi-
fcant than the rightmost digit 7.
Which digits in a number are Signifcant?
The following rules apply in deciding which digits or fgures in a given number are
signifcant.
1. Nonzero integers are always signifcant fgures.
2. Any zeros on the leftmost part of a number are not signifcant.
3. All zero digits positioned between nonzero digits are signifcant.
4. Zeros at the rightmost end of a number are counted as signifcant only if the
number contains a decimal point.
How many Signifcant Figures are in a given Number
The number of signifcant fgures in a given number is found using the following
rule:
Rule 1: The number of signifcant fgures in a purely integer number (with no decimal
digits) is obtained by counting, starting with the leftmost nonzero digit and ending
with the rightmost nonzero digit.
/lr|can v|rrua| un|vers|r, 28
Example 1.3
The number 541500409 has 9 signifcant fgures.
The number 002507030 has 6 signifcant fgures
Rule 2: The number of signifcant fgures in a number having a decimal part is ob-
tained by counting all the digits, starting with the leftmost nonzero digit.
Example 1.4
The number 6.00213 has 6 signifcant fgures.
The number 6.00213000 has 9 signifcant fgures
NOTE: All zero digits at the end of a decimal number are signifcant.
(iv) How to Reduce Rounding Errors
Armed with the concepts of digits/fgures and signifcant fgures in a number we can
now comfortably discuss ways of reducing rounding errors.
One obvious method of dealing with the problem of rounding errors is to work with
the maximum allowable accuracy on our calculating device at each stage in our
calculations.
Example 1.5
Find the sum of the numbers 2.35, 1.48, 4.24 using a calculating device that can only
handle numbers with two signifcant fgures.
The exact sum is 07 . 8 24 . 4 48 . 1 35 . 2 = + + = S
If we neglect the second decimal digit from each term and form their sum we fnd
the approximate sum
9 . 7 2 . 4 4 . 1 3 . 2
1
= + + = S
The absolute error in
1
S is: 17 . 0
1
= S S
A better approximation of S under the same limitations is
1 . 8 2 . 4 5 . 1 4 . 2
2
= + + = S
/lr|can v|rrua| un|vers|r, 29
The absolute error in
2
S is: 03 . 0
2
= S S
This error is signifcantly smaller than that in
1
S .
The immediate question expected to be raised by the learner is How did one arrive
at the two digit terms in the sum
2
S ?
The answer to the above question is simple. Each term has been obtained from its
corresponding three-digit term by rounding.
The learner will soon know how to round numbers
What it means to round a number
To round a number to a fxed number of fgures or digits simply means leaving out
(dropping) all digits on the right hand side of the number beyond a certain posi-
tion.
If a number is rounded simply by dropping all digits beyond a certain position on the
right hand side of the number without making any adjustments to the last retained
digit, then one speaks of rounding off or chopping the number.
Example 1.6
The sum
1
S has been calculated using terms obtained from the original numbers by
rounding off (chopping) the third decimal digit from each term. The term 2.35 was
rounded to 2.3, the term 1.48 was rounded to 1.4 and the term 4.24 was rounded to
4.2. In each case, the last retained digit (the frst decimal place) has not been adjusted
in the process of rounding.
Note
The sum
2
S has also been obtained through rounding. However, the rounding this
time is different. Here, not all the three terms have been rounded off!
The term 2.35 has been rounded to 2.4
The term 1.48 has been rounded to 1.5
The term 4.24 has been rounded to 4.2
We observe that in rounding each of the frst two terms 2.35 and 1.48, the digit occu-
pying the second decimal position has been dropped but the digit occupying the frst
decimal position has been adjusted by increasing it by one (unity). The third digit
4.24 has simply been rounded off.
This practice (or as yet unknown rule for rounding numbers) seems to have some
signifcant advantage over rounding off manifested by the above example in which
2
S is more accurate than
1
S .
/lr|can v|rrua| un|vers|r, J0
Rules for Rounding Numbers
In order to reduce the error in rounding numbers, the rejection of digits beyond some
predetermined position ( n ) is accompanied by making adjustments to the digit re-
tained in position (n-1). The adjustment involves either leaving the digit in position
( n ) unchanged or increasing it by one (unity). The decision to retain or increase by
1 the digit occupying position (n-1) is governed by the following rules.
(a) If the digit in position ( 1 + n ) is greater than 5 then the digit in position ( n )
is increased by 1.
(b) If the digit in position ( 1 + n ) is 5 and at least one other digit to its right is non
zero then the digit in position ( n ) is increased by 1.
(c) If the digit in position ( 1 + n ) is less than 5 then the digit in position ( n ) is
left unchanged.
(d) If the digit in position ( 1 + n ) is 5 and all other digits to the right of position
( 1 + n ) zero, then
(i) The digit in position ( n ) is increased by 1 if it is an odd number ) 9 , 7 , 5 , 3 , 1 ( ;
(ii) The digit in position ( n ) is retained unchanged if it is an even number
) 8 , 6 , 4 , 2 , 0 ( .
Example1.7
Rounding a given number correct to two signifcant fgures
S/N Number Rounded to 2 Signifcant
fgures
Rule Used
1 8.361 8.4 (a)
2 8.351 8.4 (b)
3 8.350 8.4 (d) (i)
4 8.450 8.4 (d) (ii)
5 8.050 8.0 (d) (ii)
6 8.349 8.3 (c)
7 2.55 2.6 (d) (i)
8 2.65 2.6 (d) (ii)
9 0.0557 0.056 (a)
10 0.0554 0.055 (b)
/lr|can v|rrua| un|vers|r, J'
Formative Evaluation: Students should work through this exercise carefully writing
full solutions for each problem. They should check their work thoroughly using the
solutions provided.
Questions
1. (a) Using the method of substitution fnd the exact solution of the linear system
of equations

905 . 16 10 7
075 . 12 7 5
= +
= +
y x
y x
(b) Round the values on the right hand side of each equation to two signifcant fgures
and then fnd the exact solution of the resulting system of linear equation.
(c) Use the solutions obtained from the two systems of equations to explain why
initial errors need to be avoided as much as possible.
2. (a) How many signifcant fgures are in each of the following numbers:
(i) 00001000020000
(ii) 10000200003004
(iii) 000123.0004500
(b) Round each of the following numbers correct to fve signifcant fgures.
(i) 0123.395
(ii) 0123.205
(iii) 0123.206
3. Given the quantity

20
3
11
3
3
1

+ = X , perform the following calculations:


(a) Find the exact value of X correct to fve signifcant fgures.
(b) Approximate value of X using three digit chopping arithmetic (rounding
without making any adjustments).
(c) Approximate value of X using three digit rounding arithmetic.
(d) Calculate the absolute errors and percentage errors in the approximations
obtained in parts (b) and (c).
/lr|can v|rrua| un|vers|r, J2
4. The truncation error ) (x E in linearly interpolating a function ) (x f between two
points
0
x and
1
x , with h x x + =
0 1
, is given by ) ( ) )( (
2
1
) (
//
1 0
f x x x x x E =

where is some point in the interval ) , ( :


1 0
x x I = .
(a) Using the second derivative test, show that

M
h
x E Max
I x
8
) (
2
=

, where

M = Max
x I
f
/ /
(x)
.
(b) If ) sin( ) ( x x f = determine the value of h for which the truncation error
will always be less than 01 . 0 .
5. Assuming that the function ) (x f has a single root lying inside the closed
interval, b x a the bisection method for approximating uses the iteration
formula
2
1 2
+
=
i i
i
x x
x , ,.... 3 , 2 , 1 = i a x =
1
, b x =
0
, 0 ) ( ) (
1 2
<
i i
x f x f
(a) Prove by mathematical induction that the error in the
th
i iterate
i
x is given by
i
i
a b
E
2

= .
(b) If 0 = a and 1 = b , how many bisection iterations will be needed to obtain
an approximation with an error not greater than
3
10

?
Solutions
1. (a) 415 . 2 = x , 0 = y .
(b) 1 = x , 1 = y .
(c) Initial errors must be avoided because the solutions of some problems may
be very sensitive to relatively small initial errors.
2. (a) (i) 6 (b) (i) 123.40
(ii) 14 (ii) 123.20
(iii) 10 (iii) 123.21
/lr|can v|rrua| un|vers|r, JJ
3. (a) Exact value 45606 . 0 = X
(b) Approximate value 455 . 0 =
b
X
(c) Approximate value 456 . 0 =
c
X
(d) Absolute error 00106 . 0 =
b
X X
Absolute error 00006 . 0 =
c
X X
Percentage errors % 23 . 0 100 =


X
X X
b
Percentage errors % 013 . 0 100 =


X
X X
c

4. (a) Consider the function ) )( ( ) (
1 0
x x x x x g = whose frst and second deri-
vatives are: ) ( 2 ) (
1 0
/
x x x x g + = and 2 ) (
//
= x g , respectively. ) (x g has a
single critical point at
2
1 0
x x +
= , and since 0 ) (
//
> g , we conclude that
) ( g = ) )( (
1 0
x x
=

+
1 1 0 0 1 0
2
1
2
1
2
1
2
1
x x x x x x
= ( ) ( )
1 0 0 1
2
1
2
1
x x x x
=
4
2
h


We therefore conclude that and hence the result that
Max E x
h
M | ( ) |=
2
4
.
Max g x
h
| ( ) |=
2
4
/lr|can v|rrua| un|vers|r, J4
(b) With ) sin( ) ( x x f = , we have 1 = M and therefore we need to fnd h such
that 01 . 0
8
2

h
. This leads to the value 3 . 0 08 . 0 < h .
5. (a)Mathematical induction
i
i
a b
E
2

=
Test : Formula is true for 1 = i because the error in the frst bisection is

2
a b
.
Assumption: Let the formula hold for 1 > = k i (fxed). This means

k
k
a b
E
2

= .
Induction: Error in
k k k
E E x
2
1
1 1
= =
+ +

1
2 2 2
1
+


k k
a b a b
= . Q.e.d
(b) If 0 = a and 1 = b , then
i
i
E
2
1
= . This will not exceed
3
10

if .
10
) 2 ln(
) 1000 ln(
= i

You might also like