login
A192609
Numbers k such that the concatenation of k^4 k^3 k^2 k^1 k^0 is prime.
3
12, 16, 25, 29, 55, 62, 63, 68, 76, 87, 93, 96, 119, 120, 166, 203, 218, 236, 268, 272, 280, 291, 308, 340, 361, 364, 368, 369, 410, 417, 424, 452, 459, 476, 482, 494, 499, 527, 554, 569, 585, 599, 612, 616, 635, 659, 663, 672, 723, 724, 730, 732, 739, 745
OFFSET
1,1
LINKS
EXAMPLE
12 is a term because the concatenation of 12^4 12^3 12^2 12^1 12^0 is 207361728144121 and this number is prime.
MATHEMATICA
Select[Range[750], PrimeQ[FromDigits[Flatten[IntegerDigits/@(#^Range[4, 0, -1])]]]&] (* Harvey P. Dale, Jan 14 2022 *)
PROG
(PARI) isok(n) = {s = ""; for(i=0, 4, s = concat(Str(n^i), s)); isprime(eval(s)); } \\ Michel Marcus, Feb 04 2014
(Python)
from sympy import isprime
def aupto(N): return [k for k in range(N+1) if isprime(int("".join(str(k**i) for i in [4, 3, 2, 1, 0])))]
print(aupto(745)) # Michael S. Branicky, Dec 16 2021
CROSSREFS
Sequence in context: A189763 A077617 A182074 * A157678 A334560 A357631
KEYWORD
nonn,base
AUTHOR
Claudio Meller, Jul 05 2011
EXTENSIONS
More terms from Michel Marcus, Feb 04 2014
STATUS
approved