OFFSET
1,1
COMMENTS
There are no such with an even number of digits.
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
EXAMPLE
a(12)=272=2^4*17 is palindromic number and its middle digit 7 is prime, a(13)=323=17*19 is palindromic number and its middle digit 2 is prime, a(14)=333=3^2*37 is palindromic number and its middle digit 3 is prime.
MAPLE
ts_numprapal := proc(n) local ad, adr, midigit; ad := convert(n, base, 10): adr := ListTools[Reverse](ad): if nops(ad) mod 2 = 0 then return 1; fi; midigit := op( (nops(ad)+1)/2, ad ): if (isprime( midigit )='true' and adr=ad) then return 0; else return 1; fi end: ts_num_pal := proc(i) if ts_numprapal(i) = 0 then return (i) fi end: anumpal := [seq(ts_num_pal(i), i=1..50000)]: anumpal;
MATHEMATICA
pnpmdQ[n_]:=Module[{idn=IntegerDigits[n], len=IntegerLength[n]}, OddQ[len] && PalindromeQ[n]&&PrimeQ[idn[[(len+1)/2]]]]; Select[Range[15000], pnpmdQ] (* Requires Mathematica version 10 or later *) (* Harvey P. Dale, Jun 08 2017 *)
CROSSREFS
KEYWORD
easy,nonn,base
AUTHOR
Jani Melik, Oct 21 2002
STATUS
approved