martes, 27 de julio de 2010

ROUNDING ERROR

Rounding error Often, computers cut decimal numbers between e17 and 12th decimal thus introducing a rounding error, for example, the value of "e" is called infinitely 2.718281828 .... If we cut the number 2.71828182 ( 8 significant digits after the decimal point) we are getting or error = E = 2.718281828 -2.71828182 0.000000008 ... However, as we do not consider the number that was cut was greater than 5, then we should have let the number as 2.71828183, in which case the error would only = E = 2.118281828 -2.11828183 -0.000000002 .., that in absolute terms is much smaller than the last. In general, the cutting error of the computers will be much lower than the error introduced by a user, usually cut to a smaller number of significant figures. Example: Depending on the magnitude of the numbers with which you work, the rounding error can have a big impact very small in the final calculation. For example, if we have a product of 502.23 m and a dollar price of U.S. $ 7.52, the total price of U.S. $ 3,776.7696 give us (in Chilean pesos to $ 1 = $ 500 gives us $ 1,888,384 , 8). Now, if we introduce a variation of 0.1% in meters of the product and calculate the total, we get 502.23 * 0.1% = 507, 54, in U.S. $ equivalent of U.S. $ 3,816.7008 (ie, $ 1,908 350.4 Chilean pesos, a difference of $ 19,965.6), which is no less important as a variation of 0.1% in the footage gives a product greater than 1.5% error in the final price.

Rounding error. Almost all real numbers require for its decimal representation of an infinite number of digits. In practice, for management should be considered only a finite number of digits in its representation, we proceed to determination by an appropriate rounding. A typical case as presented by computers, in its report, stored only finite representations of real numbers. In this case we speak of inherent rounding.

0 comentarios:

Publicar un comentario