login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A141139
a(n) = f(f(f(f(f(n))))), where f(n) is prime(n)-1.
2
1, 2, 150, 862, 4210, 6688, 12496, 15496, 24420, 40086, 43206, 67138, 83046, 88426, 102646, 133998, 161092, 169986, 202966, 235288, 243262, 279816, 305068, 346168, 394812, 438568, 454500, 481020, 498936, 521860, 633160, 670728, 715698, 741400
OFFSET
1,2
MAPLE
p:=ithprime: seq(p(p(p(p(p(n)-1)-1)-1)-1)-1, n=1..35); # Emeric Deutsch, Aug 06 2008
MATHEMATICA
Table[Prime[Prime[Prime[Prime[Prime[n - 1] - 1] - 1] - 1] - 1] - 1, {n, 2, 50}] (* Vincenzo Librandi, Apr 05 2015 *)
PROG
(PARI) vector(50, n, prime(prime(prime(prime(prime(n)-1)-1)-1)-1)-1) \\ Michel Marcus, Apr 09 2015
CROSSREFS
KEYWORD
nonn
AUTHOR
EXTENSIONS
More terms from Emeric Deutsch, Aug 06 2008
STATUS
approved