A238378 Numbers k such that (k+1)^(k-1) + k is prime.
1, 2, 3, 5, 7, 8, 158, 536, 4670, 9795
Offset: 1
Examples
3 is in the sequence since (3+1)^(3-1) + 3 = 4^2 + 3 = 19 is prime.
Crossrefs
Cf. A187602 (corresponding primes).
Programs
-
Mathematica
Select[Range[600],PrimeQ[(#+1)^(#-1)+#]&] (* The program generates the first eight terms of the sequence. *) (* Harvey P. Dale, Feb 07 2024 *)
-
PARI
is(n)=isprime((n+1)^(n-1)+n) \\ Charles R Greathouse IV, Jun 06 2017
Comments