[math-fun] Fwd: Re: Fwd: about bugs in mathematica and pari-gp
Subject: Re: [math-fun] Fwd: about bugs in mathematica and pari-gp Date: 2019-05-26 07:21 From: Victor Miller <victorsmiller@gmail.com> To: math-fun <math-fun@mailman.xmission.com> Reply-To: math-fun <math-fun@mailman.xmission.com> I think that macsyma is wrong about 93 * 10^9: time ./primecount -n 93000000000 2560462462787 real 0m0.143s user 0m0.106s sys 0m0.004s time ./primecount 2560462462787 93000000000 real 0m0.106s user 0m0.101s sys 0m0.004s time ./primecount 2560462462786 92999999999 real 0m0.106s user 0m0.101s sys 0m0.004s rwg> ? It agrees with (somewhat cajoled) Mathematica: In[159]:= NextPrime@Prime[9299999999] // tim During evaluation of In[159]:= 0.56919,0 Out[159]= 233746743437 The system you are quoting invites confusion of a function with its inverse. I now recall (in the mid 80s) Macsyma computing prime(10^13). Took most of a weekend. I gave the printout (including a garbage collection message) to a class clown type and he surprised me by taking it to school and getting extra credit. —rwg On Sun, May 26, 2019 at 3:54 AM Bill Gosper <billgosper@gmail.com> wrote:
My old Macsyma gets
(c71) PRIME(8200000000);
(d71) 205021987301
(c72) PRIME(9300000000);
(d72) 233746743437
SPlouffe>Hello,
here is a strange bug,
type Prime[8200000000] or Prime[93000000000] in mathematica and your machine will hang forever....
rwg> No, mine is powered by PG&E.
and by a bizarre coincidence, the same thing happens with pari-gp with the value prime(8200000000), I could not test 93 000 000 000 because it is out of reach for pari-gp (I think).
Does anybody has any idea why the programs are bugging on these particular values ?
rwg>NSA back door.
In[156]:= Prime[8200000001] // tim
During evaluation of In[156]:= 0.539572 (secs)
Out[156]= 205021987381 Macsyma took minutes.
Best regards and have a nice day. Simon Plouffe
SP: "type Prime[8200000000] or Prime[93000000000]" note the eight zeros after 82, nine zeros after 93 RWG: "My old Macsyma gets (c71) PRIME(8200000000); (d71) 205021987301 (c72) PRIME(9300000000); (d72) 233746743437" note only eight zeros after 93 VM: "I think that macsyma is wrong about 93*10^9: ./primecount -n 93000000000 2560462462787 ./primecount 2560462462786 92999999999" RWG: "? It agrees with (somewhat cajoled) Mathematica: In[159]:= NextPrime@Prime[9299999999] Out[159]= 233746743437" :)
participants (2)
-
Bill Gosper -
Hans Havermann