I think the asymptotics aren't going to go our way if we use pari. It takes 11s for 10^5 and I've been sitting here for quite a few minutes and didn't get 10^6 yet.
I think pari uses the zeta function to compute bernoulli numbers. If I'm reading the code right it first computes 1/zeta(n) using the Euler product, then computes the numerator of the bernoulli number to the required precision using this value, then divides by the required denominator, which is just a product of primes. Bill. On 2 May, 20:11, "William Stein" <[EMAIL PROTECTED]> wrote: > On Fri, May 2, 2008 at 11:34 AM, Fredrik Johansson > > <[EMAIL PROTECTED]> wrote: > > > Oleksandr Pavlyk reports on the Wolfram Blog that he has computed the > > 10 millionth Bernoulli number using Mathematica: > > http://blog.wolfram.com/2008/04/29/today-we-broke-the-bernoulli-recor... > > > How does sage's Bernoulli number implementation compare? I'd like to > > see bernoulli(10^7) in sage beating Mathematica's time. And then > > computing the 20 millionth Bernoulli number... > > Sage's Bernoulli number is *just* PARI/GP's bernoulli number implementation. > > Last time I tried timing Sage versus Mathematica's Bernoulli number command > (which was 2 years ago), Sage was twice as fast. > > William --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---