|
|
A112786
|
|
Starting from P0=3, the sequence list the minimum prime P1>P0 for which the expression P=P1+P0+1 is also a prime. The search then restarts from P1.
|
|
2
|
|
|
3, 7, 11, 17, 19, 23, 29, 31, 41, 47, 53, 59, 67, 71, 79, 83, 89, 101, 109, 113, 127, 149, 157, 173, 179, 193, 227, 229, 233, 257, 263, 277, 293, 307, 311, 331, 359, 367, 383, 389, 397, 431, 449, 457, 461, 467, 479, 487, 503, 509, 521, 541, 587, 593, 599, 601
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
LINKS
|
|
|
EXAMPLE
|
3+5+1=9 is not a prime.
3+7+1=11 is a prime: 7 is in the sequence.
7+11+1=19 is a prime: 11 is in the sequence.
11+13+1=25 is not a prime.
11+17+1=29 is a prime: 17 is in the sequence.
|
|
MAPLE
|
P:=proc(n) local i, w; w:=3; for i from 3 by 1 to n do if isprime(w+ithprime(i)+1) then print(ithprime(i)); w:=ithprime(i); fi; od; end: P(500);
|
|
MATHEMATICA
|
f[n_]:=Module[{p=NextPrime[n]}, While[!PrimeQ[n+p+1], p=NextPrime[p]]; p]; Join[{p=3}, Table[p=f[p], {n, 60}]] (* Vladimir Joseph Stephan Orlovsky, Feb 07 2012 *)
nxt[p_]:=Module[{np=NextPrime[p]}, While[!PrimeQ[p+np+1], np=NextPrime[np]]; np]; NestList[nxt, 3, 60] (* Harvey P. Dale, Jun 05 2023 *)
|
|
CROSSREFS
|
|
|
KEYWORD
|
easy,nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|