Thread: Continuity of Primes View Single Post 2011-08-04, 02:58   #19
LaurV
Romulan Interpreter

Jun 2011
Thailand

874110 Posts Quote:
 Originally Posted by LiquidNitrogen And now I actually know how to do the Lucas-Lehmer test, although those s(k) numbers grow too big for Excel after s(4). At least Excel can prove 2^5 - 1 is prime using Lucas-Lehmer in fact, using 32bit excel you can prove m=2^p-1 is prime for p=31 (and all p smaller, of course), using some tricks, like taking the MOD function each time, after each step (yes, there is a MOD function, you don't need to do division as said in another reply above) and using the fact that x^2=(m-x)^2 mod m (that is, testing after each step and taking the smallest one for squaring), and if you use VBA in excel and declare them as "variants", then you can go to 2^43-1 (that is proved composite). For 64bit excel you can go to prove m=2^p-1 is prime for p=61 (and all other primes p smaller then 61, leading to primes or composite m's) by declaring them as Longlong in VBA (this type is missing in Excel32).

This just for fun :D (no computational value).

Last fiddled with by LaurV on 2011-08-04 at 02:59  