[math-fun] Fwd: about bugs in mathematica and pari-gp
On 2019-05-27 05:42, Hans Havermann wrote:
SP: "type Prime[8200000000] or Prime[93000000000]"
note the eight zeros after 82, nine zeros after 93
OOPS! See below.
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"
:)
In[456]:= Prime[93 10^9] // tim During evaluation of In[456]:= 36292.726051,0 (ten hrs +. Clearly unintended. Yet correct.) Out[456]= 2560462462787 —rwg
Hello , the 2 values are 8 200 000 000 and 93 billions, they clearly hangs, but it depends what previous values were computed, if you start with 8 199 999 999 then it goes well for the evaluation, the same with 93 000 000 000, the maximum reached for Prime[n] is 7700 billions. and the known values are still the references in seq. A006988, unless someone has a greater value than 10^24 ? it would be useful. Best regards, Simon Plouffe Le jeu. 30 mai 2019 à 23:13, Bill Gosper <billgosper@gmail.com> a écrit :
On 2019-05-27 05:42, Hans Havermann wrote:
SP: "type Prime[8200000000] or Prime[93000000000]"
note the eight zeros after 82, nine zeros after 93
OOPS! See below.
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"
:)
In[456]:= Prime[93 10^9] // tim
During evaluation of In[456]:= 36292.726051,0 (ten hrs +. Clearly unintended. Yet correct.)
Out[456]= 2560462462787 —rwg _______________________________________________ math-fun mailing list math-fun@mailman.xmission.com https://mailman.xmission.com/cgi-bin/mailman/listinfo/math-fun
SP: "the known values are still the references in seq. A006988, unless someone has a greater value than 10^24 ?" I think A006988(25), the (10^25)-th prime, should be a little more than 6*10^26 and someone has calculated the number of primes < 10^27 (see A006880) so it certainly seems do-able with today's hardware/software. Using Kim Walisch's program, Tom Rokicki needed 6 hours to do the number of primes < 10^23. On my 6-core 2018 Mac mini it took 14 hours. I think the time required scales by four or five for each power of ten. So by the time Tom is doing the number of primes < 6*10^26, he's looking at a couple of months or so. I'm looking at half a year. Also, while Walisch's program does the n-th prime directly, there appears to be a built-in limit: ./primecount 1e18 -n primecount: nth_prime(n): n must be <= 216289611853439384 So while A006988 states that the (10^23)-th and (10^24)-th primes were calculated using Walisch's program (in 2015), I assume they used a version without the limit. Otherwise one is manually playing high-low with the reverse procedure.
participants (3)
-
Bill Gosper -
Hans Havermann -
Simon Plouffe