OFFSET
2,1
COMMENTS
a(11) > 379749833583227. Conjecture: No entry is zero.
a(23) is 150 digits long and too long to include. - Alec Mihailovs (Alec(AT)Mihailovs.com), Jun 16 2003
If n-1 is a prime then a(n)=n-1. - Farideh Firoozbakht, Aug 09 2014
LINKS
Michel Marcus, Table of n, a(n) for n = 2..35
FORMULA
EXAMPLE
a(7) = 47 = 7^2 - 2.
MAPLE
a := proc(n) local k; k := 1; while not isprime(n^k-k) do k := k+1 od; n^k-k end: seq(a(n), n=2..35);
MATHEMATICA
sp[n_]:=Module[{k=1}, While[!PrimeQ[n^k-k], k++]; n^k-k]; Array[sp, 21, 2] (* Harvey P. Dale, Jul 22 2021 *)
PROG
(PARI) a(n)=my(k=1); while(!ispseudoprime(n^k-k), k++); return(n^k-k)
vector(20, n, a(n+1)) \\ Derek Orr, Aug 08 2014
CROSSREFS
KEYWORD
nonn
AUTHOR
Amarnath Murthy and Meenakshi Srikanth (menakan_s(AT)yahoo.com), Jun 15 2003
EXTENSIONS
More terms from Alec Mihailovs (Alec(AT)Mihailovs.com), Jun 16 2003
STATUS
approved