login
A240623
Prime numbers n such that replacing each digit d in the decimal expansion of n with d^d produces a prime. Zeros are allowed with the convention 0^0 = 1.
1
11, 13, 17, 31, 53, 61, 71, 79, 151, 167, 229, 233, 251, 263, 311, 313, 331, 337, 349, 367, 389, 409, 419, 443, 673, 751, 947, 971, 991, 1433, 1531, 1699, 1733, 1993, 2011, 2027, 2053, 2063, 2081, 2111, 2141, 2153, 2221, 2333, 2393, 2503, 2521, 2833, 2963
OFFSET
1,1
EXAMPLE
263 is in the sequence because 263 becomes 44665627 which is also prime, where 44665627 is the concatenation of the numbers (2^2, 6^6, 3^3) = (4, 46656, 27).
2503 is in the sequence because 2503 becomes 43125127 which is also prime, where 43125127 is the concatenation of the numbers (2^2, 5^5, 0^0, 3^3) = (4, 3125, 1, 27).
MAPLE
with(numtheory):T:=array(1..10):L:=array(1..10):
for n from 1 to 1000 do:
p:=ithprime(n):k:=0:s:=0:j:=0:
x:=convert(p, base, 10):n1:=nops(x):
for m from n1 by -1 to 1 do:
k:=k+1:T[k]:=x[k]^x[k]:L[k]:=length(T[k]):
od:
n2:=sum('L[j]', 'j'=1..n1):s2:=0:
for u from n1 by -1 to 1 do:
s2:=s2+T[u]*10^(n2-L[u]):n2:=n2-L[u]:
od:
if type(s2, prime)=true
then
printf(`%d, `, p):
else
fi:
od:
CROSSREFS
Sequence in context: A162237 A325870 A090236 * A240624 A375091 A032502
KEYWORD
nonn,base
AUTHOR
Michel Lagneau, Apr 09 2014
STATUS
approved