Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #70766

Re: Bug in Decimal??

From Gregory Ewing <greg.ewing@canterbury.ac.nz>
Newsgroups comp.lang.python
Subject Re: Bug in Decimal??
Date 2014-04-30 19:59 +1200
Message-ID <bsborkFdqjjU1@mid.individual.net> (permalink)
References <973d2677-03c6-464a-8c88-f07282806468@googlegroups.com>

Show all headers | View raw


pleasedontspam@isp.com wrote:
> I compared the results with wolfram Alpha, and
> also with an open source arbitrary precision calculator, which matches Alpha
> results.

Decimal is *not* an arbitrary precision data type, so you
can't expect exact results from it. You can set the precision
to be very large, but it's still essentially a floating point
type, and as such you can expect the last few digits to
depend heavily on the details of the algorithm used.

-- 
Greg

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Bug in Decimal?? pleasedontspam@isp.com - 2014-04-29 19:37 -0700
  Re: Bug in Decimal?? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-04-30 03:39 +0000
    Re: Bug in Decimal?? pleasedontspam@isp.com - 2014-04-30 05:01 -0700
    Re: Bug in Decimal?? pleasedontspam@isp.com - 2014-04-30 05:13 -0700
  Re: Bug in Decimal?? Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2014-04-30 19:59 +1200
  Re: Bug in Decimal?? Mark Dickinson <mdickinson@enthought.com> - 2014-05-04 10:53 +0000
    Re: Bug in Decimal?? pleasedontspam@isp.com - 2014-05-15 13:45 -0700
      Re: Bug in Decimal?? Mark H Harris <harrismh777@gmail.com> - 2014-05-15 16:26 -0500
      Re: Bug in Decimal?? Mark Dickinson <mdickinson@enthought.com> - 2014-05-19 16:10 +0000

csiph-web