2007 fun
Rainer Rosenthal
r.rosenthal at web.de
Wed Jan 3 21:50:40 CET 2007
Nick Hobson schrieb:
>Ed Pegg wrote:
>>20071 is prime
>>200713 is prime
>>2007133 is prime
>>20071333 is prime
>>200713333 is prime
>>2007133333 is prime
>>20071333333 is prime
> The simple PARI/GP script below found ...
> 2007333...333 prime for n = number of 3s =
>
> 1, 2, 3, 4, 5, 6, 26, 73, 87, 220, 248, ...
>
> ... before I cancelled it after about 10 minutes.
>
> for(n=1, 500, x=20071*(10^n) + (10^n)\3; if(isprime(x), print1(n, ", ")))
Ten minutes is quite a long time. Why didn't you use
assembler :-)
Maple is said to be slow but good old Maple 6 with a
comparable simple loop came up with two more terms in
less than a minute:
1, 2, 3, 4, 5, 6, 26, 73, 87, 220, 248, 349, 410
Maple program:
for n to 1000 do
x := ((3*20071+1)*10^n-1)/3;
if isprime(x) then
print(n)
fi
od;
Using Alpertrons's new batch feature I tested up to n=1070 without
finding a new fun2007 prime. Formula ((3*20071+1)*10^n-1)/3 is well
suited for that because you have to vary n only once.
Best regards,
Rainer Rosenthal
r.rosenthal at web.de
More information about the SeqFan
mailing list