login
A126911
Numbers k such that 1 + k^2 + k^4 + k^6 + k^8 + k^10 + k^12 + k^13 is prime.
1
10, 24, 60, 148, 174, 180, 268, 274, 280, 294, 346, 472, 484, 516, 522, 598, 654, 804, 834, 856, 858, 898, 994, 1012, 1036, 1054, 1066, 1102, 1168, 1272, 1294, 1338, 1342, 1368, 1420, 1462, 1500, 1536, 1564, 1588, 1608, 1624, 1710, 1746, 1786, 1792, 1822, 1992
OFFSET
1,1
LINKS
MATHEMATICA
a = {}; Do[If[PrimeQ[1 + n^2 + n^4 + n^6 + n^8 + n^10 + n^12 + n^13], AppendTo[a, n]], {n, 1, 1400}]; a
PROG
(PARI) is(n)=isprime(1+n^2+n^4+n^6+n^8+n^10+n^12+n^13) \\ Charles R Greathouse IV, Jun 13 2017
(Python)
from sympy import isprime
def ok(k): return isprime(1+sum(k**i for i in [2, 4, 6, 8, 10, 12, 13]))
print([k for k in range(2000) if ok(k)]) # Michael S. Branicky, Oct 24 2021
KEYWORD
nonn,easy
AUTHOR
Artur Jasinski, Dec 31 2006
STATUS
approved