login
A100955
Consider all (2n+1)-digit palindromic primes of the form 30...0M0...03 (so that M is a palindrome with <= 2n-1 digits); a(n) = smallest such M.
3
1, 1, 1, 2, 5, 2, 2, 8, 5, 434, 5, 313, 272, 838, 5, 272, 8, 505, 1, 7, 212, 7, 151, 686, 2, 242, 656, 656, 323, 929, 121, 242, 262, 12521, 454, 949, 353, 2, 16361, 707, 10301, 515, 29092, 454, 13331, 686, 848, 20602, 1, 484, 737, 101, 242, 121, 15551, 656, 232
OFFSET
1,4
LINKS
MATHEMATICA
f[n_] := Block[{k = 0, t = Flatten[ Join[{3}, Table[0, {n - 1}]]]}, While[s = Drop[t, Min[ -Floor[ Log[10, k]/2], 0]]; k != FromDigits[ Reverse[ IntegerDigits[k]]] || !PrimeQ[ FromDigits[ Join[s, IntegerDigits[k], Reverse[s]]]], k++ ]; k]; Table[ f[n], {n, 57}]
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Robert G. Wilson v, Nov 23 2004
STATUS
approved