Share on Facebook Share on Twitter Email
Answers.com

Round-off error

 
Wikipedia: Round-off error
For the acrobatic movement, roundoff, see Roundoff.

A round-off error, also called rounding error, is the difference between the calculated approximation of a number and its exact mathematical value. Numerical analysis specifically tries to estimate this error when using approximation equations and/or algorithms, especially when using finite digits to represent real numbers (which in theory have infinite digits). This is a form of quantization error.

Contents

Representation error

The error introduced by attempting to represent a number on the computer is called representation error. Some examples:

Notation Represent Approximate Error
1/7 0.142 857 0.142 857 0.000 000 142 857
ln 2 0.693 147 180 559 945 309 41...   0.693 147 0.000 000 180 559 945 309 41...
log10 2 0.301 029 995 663 981 195 21...   0.3010 0.000 029 995 663 981 195 21...
 2  1.259 921 049 894 873 164 76...   1.25992 0.000 001 049 894 873 164 76...
 2  1.414 213 562 373 095 048 80...   1.41421 0.000 003 562 373 095 048 80...
e 2.718 281 828 459 045 235 36...   2.718 281 828 459 045   0.000 000 000 000 000 235 36...
π 3.141 592 653 589 793 238 46...   3.141 592 653 589 793 0.000 000 000 000 000 238 46...

Increasing the number of digits allowed in a representation reduces the magnitude of possible roundoff errors, but any representation limited to finitely many digits will still cause some degree of roundoff error for uncountably many real numbers. This kind of error is unavoidable for conventional representations of numbers, but can be reduced by the use of guard digits.

Double-rounding can increase the round-off error. For example, if the numeral 9.945309 is rounded to two decimal places (9.95) for data entry purposes, and then rounded again to one decimal place (10.0) for display purposes, the apparent round-off error is 0.054691. If the original number was rounded to one decimal place in one step (9.9), the round-off error is only 0.045309.

There are five standard ways of performing the rounding in IEEE standard arithmetic:

  • truncation: simply chop off the remaining digits; also called rounding to zero.
0.142857 ≈ 0.142 (dropping all significant digits after 3rd)
  • round to nearest: round to the nearest value, with ties broken in one of two ways. The result may round up or round down.
0.142857 ≈ 0.143 (rounding the 4th significant digit. This is rounded up because 8\ge5)
0.142857 ≈ 0.14 (rounding the 3rd significant digit. This is rounded down because 2 < 5 \!\ )
  • round to -∞: always round to the left on the number line
  • round to ∞: always round to the right on the number line

Examples

  • in January 25, 1990 during the First Gulf War, a Patriot missile defense system in Al-Dhahran, Saudi Arabia, was rendered ineffective due to a round-off error. The system's computer only had 24-bit precision, so it chopped 0.0001% of timing values, while the accuracy threshold is 20 hours. After the system had been running for 100 hours, an error of 0.3422 seconds had accumulated. This discrepancy caused the Patriot system to continuously recycle itself instead of targeting properly. As a result, an Iraqi Scud missile could not be targeted and was allowed to detonate on a barracks, killing 28 people.[1] [2]
  • In the 37th second of flight of the Ariane rocket (launched on June 4, 1996), the inertial reference system attempted to convert a 64-bit floating-point number to a 16-bit number, but instead triggered an overflow error which was interpreted by the guidance system as flight data, causing the rocket to veer off course and be destroyed.[1]
  • The Vancouver stock exchange devised a short-lived index. At its inception in 1982, the index was given a value of 1000.000. After 22 months of recomputing the index and truncating to three decimal places at each change in market value, the index stood at 524.881, despite the fact that its "true" value should have been 1009.811.[1]

See also

External links

Notes and references



Search unanswered questions...
Enter a question here...
Search: All sources Community Q&A Reference topics
Best of the Web: Round-off error
Top

Some good "Round-off error" pages on the web:


Math
mathworld.wolfram.com
 
 
 

 

Copyrights:

Wikipedia. This article is licensed under the Creative Commons Attribution/Share-Alike License. It uses material from the Wikipedia article "Round-off error" Read more