[tahoe-dev] Estimating reliability

Shawn Willden shawn-tahoe at willden.org
Tue Jan 13 07:49:04 UTC 2009


On Tuesday 13 January 2009 12:33:48 am Brian Warner wrote:
> I may throw together a program to try this, although I'm not convinced that
> the numerical accuracy of regular floats will cut it. A lot of these
> numbers will be very close to 1.0. Hm, maybe I'll see what the 'decimal'
> module can do for me..

I'll read and reply to the rest of your post when I'm more fully awake, but as 
I suggested earlier, it's better to simply avoid dealing with numbers that 
are close to 1.  Restate the problem so that you're looking at numbers close 
to 0, because then your calculations can use the full width of the mantissa.  
When the numbers are close to 1 you use up most -- or all! -- of the mantissa 
bits just holding that big sequence of 9s (actually 1s, but you get my 
meaning).

I have access to a copy of Mathematica (technically, it's my daughter's; I 
paid $75 to get her a student license for her K-12 years) so I tend to do 
this stuff there.  If you enter everything symbolically and in fractions 
rather than decimals, Mathematica will maintain infinite precision (barring 
the introduction of irrational-valued functions, of course).  I did a bunch 
of tests in Mathematica, comparing my results to the machine precision values 
from a Python program, and I'm very confident that my floating point 
calculations are plenty accurate.

	Shawn.



More information about the tahoe-dev mailing list