EMATH 311 Introduction Ee
EMATH 311 Introduction Ee
EMATH 311 Introduction Ee
The error in this approximation is due to truncating the series and has
nothing to do with the computer or calculator. Many numerical methods
are iterative and we would reach the exact answer only if we apply the
method infinitely many times. But life is finite and computer time is
costly. Thus we must be satisfied with an approximation to the exact
analytic answer. The error in this approximation is a truncation error.
Round-off error
The error that is produced when a calculator or
computer is used to perform real-number calculations
is called round-off error. It occurs because the
arithmetic performed in a machine involves numbers
with only a finite number of digits, with the result that
calculations are performed with only approximate
representations of the actual numbers.
Blunders
Since humans are involved in programming, operation,
input preparation, and output interpretation, blunders
or gross errors do occur more frequently than we like
to admit. The solution here is care coupled with a
careful examination of the results for reasonableness.
Sometimes a test run with known results is
worthwhile, but it is no guarantee of freedom from
foolish error.
Propagated error
By propagated error we mean an error in the succeeding steps of a
process due to an occurrence of an earlier error-such error is in
addition to the local errors. It is somewhat analogous to errors in the
initial conditions. Propagated error is of critical importance. If errors
are magnified continuously as the method continues, eventually they
will overshadow the true value, destroying its validity; we call such a
method unstable. For stable method, the desirable kind, errors made
at early points die out as the method continue.
Remark. Each of these types of error, while interacting to a degree,
may occur even in the absence of the other kinds.
Floating-point arithmetic
In order to examine round-off error in detail we need to
understand how numeric quantities are represented in
computer. An unfortunate fact of life is that any digital
computer can only store finitely many quantities. Thus, a
computer can not represent the infinity set of integers, the
set rational numbers, set of real numbers, or the set
complex numbers. So the decision of how to deal with
more general numbers using only the finitely many that the
computer can store becomes an important issue.
Overflow and underflow
Numbers occurring in calculations that have too small
a magnitude to be represented result in underflow, and
are generally set to 0 with computations continuing.
However, numbers occurring in calculations that have
too large a magnitude to be represented result in
overflow and typically cause the computations to stop
(unless the program has been designed to detect this
occurrence)
Accuracy and Precision
Absolute and relative errors
Source: http://site.iugaza.edu.ps/asakka
Suppose that you have the task of measuring the lengths of a bridge and a rivet and come up
with 9999 and 9 cm, respectively. If the true values are 10,000 and 10 cm, respectively,
compute (a) the true error and (b) the true percent relative error for each case.