Talk:Lucas-Lehmer test: Difference between revisions

New section: Java precision
m (M23,209 36 hours ≡ 1979)
 
(New section: Java precision)
Line 320:
| [[Great Internet Mersenne Prime Search|GIMPS]] / [[Curtis Cooper (mathematician)|Curtis Cooper]] & [[Steven Boone]] [http://www.mersenne.org/32582657.htm]
|}
 
== Java precision ==
 
The Java version is still limited by types. Integer.parseInt(args[0]) limits p to 2147483647. Also the fact that isMersennePrime takes an int limits it there too. For full arbitrary precision every int needs to be a BigInteger or BigDecimal and a square root method will need to be created for them. The limitation is OK I think (I don't think we'll be getting up to 2<sup>2147483647</sup> - 1 anytime soon), but the claim "any arbitrary prime" is false because of the use of ints. --[[User:Mwn3d|Mwn3d]] 07:45, 21 February 2008 (MST)
Anonymous user