apfloat
A Java version is also available.
Apfloat could be compiled in general with most C++ compilers, however gcc is recommended. It has assembler optimizations for x86, Alpha and MIPS processors.
A sample program for calculating pi is included in the package. Calculating one million digits of pi takes less than half a minute with an Athlon XP computer. This makes it one of the fastest programs for calculating pi (faster than the Japanese super_pi program).
Compiled executables for calculating pi are available for download. The fastest versions of the program can calculate up to 226 million decimal digits of pi. A machine with at least 256 MB of RAM would be needed for such a calculation. A version, which can calculate up to 1.9 billion digits (if you have at least two gigabytes of memory) is also provided, but it is somewhat slower.
Zipped executable | Processor | Operating system | Maximum number of digits |
---|---|---|---|
aptestg5.zip | Pentium | Microsoft Windows (GUI) | 226 million |
aptestc5.zip | Pentium | Microsoft Windows (console) | 226 million |
aptestc6.zip | Pentium | Microsoft Windows (console) | 1.9 billion (slower!) |
aptestm.zip | Pentium Multiprocessor | Microsoft Windows | 226 million |
aptestm6.zip | Pentium Multiprocessor | Microsoft Windows | 1.9 billion (slower!) |
aptest25.zip | Pentium | MS-DOS (requires DPMI) | 226 million |
aptest26.zip | Pentium | MS-DOS (requires DPMI) | 1.9 billion (slower!) |
aptest24.zip | 486 | MS-DOS (requires DPMI) | 226 million |
aptest5.zip | Pentium | MS-DOS | 226 million |
aptest4.zip | 486 | MS-DOS | 226 million |
aptestlx.zip | Athlon 64 | Linux x86-64 | 61 billion (faster!) |
aptestl5.zip | Pentium | Linux | 226 million |
aptestl6.zip | Pentium | Linux | 1.9 billion (slower!) |
aptestl4.zip | 486 | Linux | 226 million |
aptestlm.zip | Pentium Multiprocessor | Linux | 226 million |
aptestll.zip | Pentium Multiprocessor | Linux | 1.9 billion (slower!) |
Compiled executables for printing Mersenne numbers and associated perfect numbers are also available for download:
Zipped executable | Processor | Operating system |
---|---|---|
mprintc5.zip | Pentium | Microsoft Windows |
mprint5.zip | Pentium | MS-DOS |
mprint4.zip | 486 | MS-DOS |
All corrections, comments and bug reports should be sent to the author.
Last updated: February 28th, 2005
If you have problems, you can try the older versions: 2.40, 2.35, 2.34, 2.33, 2.32, 2.31, 2.30, 2.21, 2.20, 2.10, 2.00, 1.51, 1.50, 1.40, 1.33, 1.32, 1.31, 1.30, 1.20, 1.10 or 1.02.
The apfloat Frequently Asked Questions (FAQ). Actually, they are not very frequently asked. I don't get a lot of questions from apfloat users.
If you have some other compiler than gcc, djgpp, Borland C++ or Microsoft Visual C++, you may want to look at instructions on creating your own makefile.
You might also want to try other freeware arbitrary precision arithmetic packages, like the hfloat package by Jörg Arndt, or the CLN package by Bruno Haible, which seems to be superior.
People who have contributed to apfloat.