program to find largest double...
Robert G. Brown
rgb at phy.duke.edu
Fri Apr 20 07:28:31 PDT 2001
Just for the heck of it, I wrote a little program to evaluate the
largest double precision number that isn't "infinite" on a box. It uses
ISOC99 calls to test for "infinity" (I tried using signals on an FPE but
it is too painful and not easy to understand anyway).
It seems to work, and tells me that the largest float on my PIII is:
Biggest double that isn't infinite: 8.9884656743115795e+307
I require 1079 loop passes in a binary search that could probably be
shortened considerably with a little log-scale forethought.
I attach the source tarball (it's small) for the person who (long ago)
Robert G. Brown http://www.phy.duke.edu/~rgb/
Duke University Dept. of Physics, Box 90305
Durham, N.C. 27708-0305
Phone: 1-919-660-2567 Fax: 919-660-2525 email:rgb at phy.duke.edu
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 40948 bytes
Desc: Maxsize program
Url : http://www.scyld.com/pipermail/beowulf/attachments/20010420/ec15f6cf/maxsize-0.1.1-0003.obj
More information about the Beowulf