[erlang-questions] Erlang Numbers

Jesper Louis Andersen <>
Tue Jun 17 18:42:49 CEST 2014


On Tue, Jun 17, 2014 at 6:21 PM, Camille Troillard <> wrote:

> Is it because of some rounding behaviour?


It is due to the representation. A floating point number is really a
rational number, which has been constructed in a way to make most numbers
readily representable in the notation. This means some numbers can be
represented in an exact way, whereas other numbers can't. As Bob suggests,
there are also rounding, which will sometimes make a number being slightly
off seem to be correct.






-- 
J.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20140617/fc3d4d94/attachment.html>


More information about the erlang-questions mailing list