|
|
A283145
|
|
a(1)=5; for n > 1, and a(n) is the least prime p > a(n-1) such that both q = p + 2n and r = q + 2n + 2 are prime.
|
|
3
|
|
|
5, 7, 17, 23, 31, 41, 53, 67, 71, 89, 127, 149, 173, 199, 251, 281, 283, 347, 383, 409, 461, 479, 523, 593, 641, 691, 719, 773, 823, 887, 971, 1033, 1097, 1163, 1231, 1301, 1373, 1447, 1619, 1709, 1741, 1823, 1907
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
Note that p,q,r are not required to be consecutive primes.
|
|
LINKS
|
|
|
EXAMPLE
|
a(1)=5 because both 5 + 2 = 7 and 7 + 4 = 11 are prime;
n=2: d=4, p=7 because both p + d = 11 and 11 + 6 = 17 are prime;
n=3: d=6: primes 11,13 are not qualified while 17 + 6 = 23 and 23 + 8 = 31 are prime hence a(3)=17.
|
|
MATHEMATICA
|
m=0; p=3; s={}; Do[p = NextPrime[p]; m=m+2; While[!PrimeQ[p+m]||!PrimeQ[p+2*m+2], p=NextPrime[p]]; AppendTo[s, p], {50}]; s
|
|
PROG
|
(PARI) first(n)=my(v=vector(n), k=4); v[1]=5; forprime(p=5, , if(isprime(p+k) && isprime(p+2*k+2), v[k/2]=p; if(k==2*n, return(v)); k+=2)) \\ Charles R Greathouse IV, Mar 01 2017
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|