OFFSET
0,2
COMMENTS
If the reversal of p is another prime, p+reversal(p) and reversal(p)+p are both counted.
a(n) is the first number that occurs exactly n times in A061227.
LINKS
Robert Israel, Table of n, a(n) for n = 0..92
EXAMPLE
a(4) = 1090 because 1090 = 149+941 = 347+743 = 743+347 = 941+149, and this is the least number with exactly four such representations.
MAPLE
revdigs:= proc(n) local L, t;
L:= convert(n, base, 10);
add(L[-t]*10^(t-1), t=1..nops(L));
end proc:
V:= Vector(10^6):
p:= 1:
do
p:= nextprime(p);
if p > 9*10^5 then break fi;
r:= p+revdigs(p);
if r <= 10^6 then V[r]:= V[r]+1 fi
od:
A:= Array(0..64):
for i from 1 to 10^6 do
if V[i] <= 64 and A[V[i]] = 0 then A[V[i]]:= i fi
od:
convert(A, list);
CROSSREFS
KEYWORD
nonn,base
AUTHOR
J. M. Bergot and Robert Israel, May 31 2021
STATUS
approved