OFFSET
1,1
COMMENTS
Conjecture: a(243)=34613 is the last term.
LINKS
Joerg Arndt, Table of n, a(n) for n = 1..243
EXAMPLE
17 doesn't occur in the sequence, because there is D=6: 17-12, 17-6, 17+6 and 17+12 are all primes: 5, 11, 23, 29.
MATHEMATICA
fQ[p_] := Module[{d = 1}, While[4d < p && !(PrimeQ[p-4d] && PrimeQ[p-2d] && PrimeQ[p+2d] && PrimeQ[p+4d]), d++]; 4d > p]; Select[Prime[Range[4000]], fQ] (* T. D. Noe, Aug 20 2012 *)
PROG
(PARI)
N=10^9;
default(primelimit, N);
print1(2, ", ");
{ forprime (p=3, N,
D=2; D2 = D << 1;
t = 1;
while ( p > D2,
if ( isprime(p+D) & isprime(p-D) &
isprime(p+D2) & isprime(p-D2)
, /* then */
t=0; break()
);
D += 2; D2 += 4;
);
if ( t==1, print1(p, ", ") );
); }
/* Joerg Arndt, Aug 20 2012 */
CROSSREFS
KEYWORD
nonn
AUTHOR
Alex Ratushnyak, Aug 18 2012
STATUS
approved
