login
A255730
Numbers k such that k^k - (k-1)^k + k is prime.
0
1, 2, 4, 16, 52, 80
OFFSET
1,2
COMMENTS
a(6) corresponds to a prime having 153 digits.
If it exists, a(7) > 5000.
k does not have the form 20m+2 (which leads to a multiple of 5) or 42m+26 (which leads to a multiple of 7).
If it exists, a(7) > 20000. - Michael S. Branicky, Oct 09 2024
EXAMPLE
4 is in the sequence because 4^4 - 3^4 + 4 = 179 is prime.
MATHEMATICA
Select[Range[1000], PrimeQ[#^# - (# - 1)^# + #] &]
PROG
(Magma) [n: n in [0..500] |IsPrime(n^n - (n-1)^n + n)];
(PARI) is(n)=ispseudoprime(n^n-(n-1)^n+n) \\ Charles R Greathouse IV, Jun 13 2017
CROSSREFS
Cf. A085682.
Sequence in context: A104354 A153948 A284730 * A363441 A087972 A010362
KEYWORD
nonn,more
AUTHOR
Vincenzo Librandi, Mar 13 2015
STATUS
approved