Approximation and Errors in Computing
Approximation and Errors in Computing
Computing
Mr. Sunanda Das
Assistant Professor, CSE, KUET
Intro
• Errors come in a variety of forms. Some are avoidable and some are
not.
• Data conversion and roundoff errors can not be avoided but human
error can be eliminated.
• By careful analysis and proper design and implementation of
algorithms, we can restrict their effect quite significantly.
Taxonomy of errors
Total Error
Missing Human
Information Imperfection
Measuring
Method Computing Numerical
Machine Method
Significant Digits
• All computers operate with fixed length of numbers.
• 3.141592653589... … can be represented as 3.14, 3.14159 etc.
• The concept of significant digits has been introduced primarily to
indicate the accuracy of numerical value.
• There are different situations when a problem can have a large condition
number.
Minimizing the total error
• The total numerical errors mainly consists of two component,
truncation error and roundoff error.
Pitfalls and Precautions
THE TAYLOR SERIES and Truncation Error
• The theorem states that any smooth function can be approximated as a polynomial
• A useful way to gain insight into the Taylor series is to build it term by term. For example, the first term
in the series is
• This relationship, called the zero-order approximation, indicates that the value of f at the
new point is the same as its value at the old point.
• Equation provides a perfect estimate if the function being approximated is, in
• fact, a constant.