Comparison of multiple-precision floating-point software

Maple Mathematica Sage GMP MPF MPFR PARI NTL CLN
commercial commercial free (GPL) free (LGPL) free (LGPL) free (GPL) free (GPL) free (GPL)
12.00 6.0.1 3.2.3 4.2.2 2.4.0 2.4.2.alpha 5.4.2 1.2.2
interactive interactive interactive library library library library library

The following tables give the cpu time in milliseconds spent by several systems or libraries for different operations, at different precisions (in digits). Those timings were obtained on a 24-core Intel Xeon X7460 at 2.66GHz (sage.math.washington.edu) with 717GB of swap and 132GB of RAM under Linux 2.6.24-19-server. The version of GCC is 4.2.4 (Ubuntu 4.2.4-1ubuntu3).

GMP has been built with Gaudry's AMD64 patch. MPFR was built with --with-gmp-build, and make tune. PARI was built with GMP support. NTL was built with native support. CLN has been built with GMP support and with the following patch.

An entry "na" means a function not available in the corresponding software tool. The boldface entries are the fastest in each row.

100 digits Maple Mathematica Sage MPF MPFR Pari NTL CLN
mult 0.0020 0.0006 0.00045 0.00016 0.00014 0.00012 0.000362 0.000223
div 0.0029 0.0017 0.00074 0.00051 0.00039 0.00040 0.00072 0.000567
sqrt 0.032 0.0018 0.00124 0.00072 0.00055 0.00059 0.00450 0.00079
exp 0.070 0.019 0.0103 na 0.0079 0.0126 0.070 0.0232
log 0.100 0.028 0.0155 na 0.0124 0.0134 0.388 0.0305
sin 0.131 0.017 0.0118 na 0.0087 0.0121 0.075 0.0283
cos 0.119 0.018 0.0081 na 0.0067 0.0105 0.081 0.0249
acos 0.450 0.053 0.065 na 0.061 0.034 na 0.036
atan 0.280 0.048 0.057 na 0.053 0.032 na 0.031
1000 digits Maple Mathematica Sage MPF MPFR Pari NTL CLN
mult 0.0200 0.007 0.0040 0.0049 0.0035 0.0048 0.0136 0.0053
div 0.0200 0.015 0.0082 0.0080 0.0079 0.0077 0.0198 0.0085
sqrt 0.160 0.011 0.0072 0.0066 0.0061 0.0061 0.184 0.0067
exp 0.90 0.63 0.251 na 0.243 0.469 5.92 0.449
log 0.300 0.67 0.211 na 0.203 0.266 47.74 0.469
sin 1.89 0.41 0.260 na 0.254 0.398 6.67 0.381
cos 1.91 0.40 0.246 na 0.247 0.383 6.94 0.349
acos 2.50 0.82 0.95 na 0.94 0.94 na 0.59
atan 2.10 0.80 0.86 na 0.84 0.89 na 0.56
10000 digits Maple Mathematica Sage MPF MPFR Pari NTL CLN
mult 0.80 0.28 0.155 0.172 0.151 0.175 0.513 0.222
div 0.80 0.56 0.373 0.369 0.364 0.369 1.662 0.547
sqrt 3.70 0.36 0.236 0.236 0.233 0.233 20.48 0.339
exp 50.0 17.6 14.7 na 14.3 17.6 1550 18.1
log 20.0 15.9 10.4 na 10.0 11.3 16060 21.1
sin 93.0 44.4 25.7 na 24.8 33.2 1670 31.6
cos 92.0 44.4 25.2 na 24.4 32.9 7570 30.2
acos 87.0 91.2 45.9 na 43.9 44.8 na 39.7
atan 82.0 87.2 41.8 na 40.6 44.2 na 38.1

The source file of these tests is available for Maple, Mathematica, Sage, MPF, MPFR, Pari, NTL, CLN.

Please acknowledge "National Science Foundation Grant No. DMS-0821725" in any published work that uses this computer.

Back to the MPFR 2.4.0 page.

Back to the MPFR 2.4.1 page.

Back to the MPFR 2.4.2 page.