Karim BELABAS on Sun, 30 Nov 2003 21:15:19 +0100

[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Version 2.1.5 vs Version 2.2.6

On Mon, 17 Nov 2003, Dirk Laurie wrote:
> I have a calculation that needs to evaluate the psi function to 10000
> digits.  In Pari-GP 2.1.5 there is no problem.  In Pari-GP 2.2.6 I get
> a stack overflow, even with allocatemem(200*2^20), which is the biggest
> my computer can comfortably do.  I have good reason to believe that the
> reason is that 2.2.6 caches the Bernoulli numbers on the heap whereas
> 2.1.5 does not.

Actually, both versions cache (floating point approximations to) Bernoulli
numbers on the heap.

> Is there a way of controlling the decision, to cache or not to cache,
> from a user program, or is it hard-wired into the two implementations?

It is hardwired, but the psi (and Bernoulli) functions were faulty in 2.2.6:
the implementations changed and intermediate garbage collection mostly

I have fixed this in CVS. You migh want to try a CVS snapshot.

Karim Belabas                     Tel: (+33) (0)1 69 15 57 48
Dép. de Mathématiques, Bât. 425   Fax: (+33) (0)1 69 15 60 19
Université Paris-Sud              http://www.math.u-psud.fr/~belabas/
F-91405 Orsay (France)            http://pari.math.u-bordeaux.fr/  [PARI/GP]