MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Re: Accuracy and Precision

  • To: mathgroup at
  • Subject: [mg37009] Re: [mg36983] Re: Accuracy and Precision
  • From: David Withoff <withoff at>
  • Date: Sun, 6 Oct 2002 05:32:55 -0400 (EDT)
  • Sender: owner-wri-mathgroup at

> The more I play with the example the more depressing it gets. Start
> with floating point numbers but explicitely arbitrary-precision ones.
> In[1]:=
> a=77617.00000000000000000000000000000;
> b=33095.00000000000000000000000000000;
> In[3]:=
> \!\(333.7500000000000000000000000000000\ b\^6 + a\^2\ \((11\ a\^2\
> b\^2 - \
> b\^6 - 121\ b\^4 - 2)\) + 5.500000000000000000000000000000\ b\^8 +
> a\/\(2\
>             b\)\)
> Out[3]=
> \!\(\(-4.78339168666055402578083604864320577443814`26.6715*^32\)\)
> In[4]:=
> Accuracy[%]
> Out[4]=
> -6
> Due to the manual section 3.1.6:
> "When you do calculations with arbitrary-precision numbers, as
> discussed in the previous section, Mathematica always keeps track of
> the precision of your results, and gives only those digits which are
> known to be correct, given the precision of your input. When you do
> calculations with machine-precision numbers, however, Mathematica
> always gives you a machine?precision result, whether or not all the
> digits in the result can, in fact, be determined to be correct on the
> basis of your input. "
> Because I started with arbitrary-precision numbers Mathematica should display
> only those digits that are correct, that is none.

An accuracy of -6 means that the least significant correct digit is 6
digits to the left of the decimal point.  The result Out[3] in the
example above has 26 significant digits to the left of that (the most
sigificant digit is 26+6=32 digits to the left of the decimal point),
so there are 26 correct digits to display.

Was there some other result you were referring to as a result in
which the number of correct digits is "none"?

Dave Withoff
Wolfram Research

  • Prev by Date: Rounding numbers
  • Next by Date: Re: RE: RE: Accuracy and Precision
  • Previous by thread: Re: Re: Accuracy and Precision
  • Next by thread: Re: RE: RE: Accuracy and Precision