Bug in floating-point addition: is anyone else seeing this?

Matthieu Brucher matthieu.brucher at gmail.com
Wed May 21 17:17:12 EDT 2008


2008/5/21 Dave Parker <daveparker at flamingthunder.com>:

> On May 21, 2:44 pm, "Jerry Hill" <malaclyp... at gmail.com> wrote:
>
> > My understand is no, not if you're using IEEE floating point.
>
> Yes, that would explain it.  I assumed that Python automatically
> switched from hardware floating point to multi-precision floating
> point so that the user is guaranteed to always get correctly rounded
> results for +, -, *, and /, like Flaming Thunder gives.  Correct
> rounding and accurate results are fairly crucial to mathematical and
> scientific programming, in my opinion.
> --
> http://mail.python.org/mailman/listinfo/python-list
>

That's why there is the Decimal module.
That's why the IEEE standard exists as well, because it is not possible to
always use what you call multi-precision floating point with decent speed.
That's why numerical analysis exists.

Matthieu
-- 
French PhD student
Website : http://matthieu-brucher.developpez.com/
Blogs : http://matt.eifelle.com and http://blog.developpez.com/?blog=92
LinkedIn : http://www.linkedin.com/in/matthieubrucher
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20080521/d1e7e6ea/attachment-0001.html>


More information about the Python-list mailing list