Author: Dann Corbit
Date: 16:34:06 11/08/99
Go up one level in this thread
On November 07, 1999 at 15:37:36, Ratko V Tomic wrote: >Dann, Blass Uri mentioned some high precdision floating point math you used in >the conversion of his position counting code: > >> I used C and my first program did not get so many significant digits. >> Dan Corbit translated my program to C++ and got these many significant digits. > >>>It found the number >>>3.7010630121207222927827147741452119115968e46 >>>when you ignore the side to move right to castle and the 50 move rule >>> > >Normally standard C++ by itself wouldn't have this fp precision (this looks like >16 byte mantissa). What did you use? I was thinking of writing up to perhaps 256 >byte variable precision fp & integer math functions for C/C++, at least the 4 >basic operations (may come handy for other than chess position counting). Do you >know of any such C linkable library? I have something called MIRACL which I use. I have a commercial license for it (which is $500). You can use it for your own purposes without paying anything if it is not for commercial gain. (I got the license free for bug reporting and things like that, but I only use it for playtime anyway). Anyway, there is both a C and C++ interface. It comes with full source code. It does arbitrary precision for both integers and rational numbers. It is very nice and has some really neat stuff for factoring: http://indigo.ie/~mscott/ Really cool. Worth a look. I also use a specially modified version of QFLOAT by Stephen L. Moshier. C and C++ interfaces available. Comes with source. Get it from NETLIB. APFLOAT and HFLOAT by Mikko Tommilla or Jorge Arndt are really good if you only use GCC (they don't work with any other compilers). Also, they are C++ only -- no C interface. Doubledouble by Keith Briggs is easy to use C++ code that is pretty fast for most operations and gives about 30 digits of precision.
This page took 0 seconds to execute
Last modified: Thu, 15 Apr 21 08:11:13 -0700
Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.