OFFSET
1,1
LINKS
Chai Wah Wu, Table of n, a(n) for n = 1..10000
EXAMPLE
121 = 11 * 11 = 37 + 41 +43
1207 = 17 * 71 = 397 + 401 + 409
117907 = 157 * 751 = 39293 + 39301 + 39313
MATHEMATICA
PrevPrim[n_] := Block[{k = n - 1}, While[ !PrimeQ[k], k-- ]; k]; NextPrim[n_] := Block[{k = n + 1}, While[ !PrimeQ[k], k++ ]; k]; pal[n_] := FromDigits@ Reverse@ IntegerDigits@n; fQ[n_] := Block[{pn = pal@n, p, q, r, s}, q = PrevPrim[ Ceiling[n*pn/3]]; p = PrevPrim@q; r = NextPrim[ Floor[n*pn/3]]; s = NextPrim@r; n*pn == p + q + r || n*pn == q + r + s]; pd = 6; lst = {}; Do[ pd = NextPrim@pd; If[ PrimeQ@pd && fQ@pd, Print[pd*pal@pd]; AppendTo[lst, pd*pal@pd]], {n, 1000}]; lst = Union@lst (* Robert G. Wilson v, Jun 19 2007 *)
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Paolo P. Lava and Giorgio Balzarotti, Jun 15 2007
EXTENSIONS
Corrected and extended by Robert G. Wilson v, Jun 19 2007
Corrected and extended and definition clarified by Chai Wah Wu, Feb 25 2018
STATUS
approved