Catalan constant to 300000 digits computed on September 29, 1996
by using a Sun UltraSparc in 1 day 8 hour 15 min 15 sec 55 hsec.
The algorithm used is the standard series for Catalan, accelerated
by an Euler transform. The algorithm was implemented using the LiDIA
library for computational number theory and it is part of the
multiprecision floatingpoint arithmetic of the package.
LiDIA is available from
ftp://crypt1.cs.unisb.de/pub/systems/LiDIA/LiDIA1.2.1.tgz
http://wwwjb.cs.unisb.de/LiDIA/linkhtml/lidia/lidia.html
The implementation of the algorithm is:
inline void
const_catalan (bigfloat & y)
{
bigfloat p;
bigfloat t;
int i = 1, j = 3; // j = 2*i+1
// y = t = p = 1/2
divide (y, 1, 2);
t.assign (y);
p.assign (y);
// while t is greater than the desired accuracy
while (!t.is_approx_zero ())
