|
|
A175687
|
|
a(0)=113, then a(n) = smallest prime p not already used such that the first three digits of p = the last three digits of a(n-1).
|
|
1
|
|
|
113, 11311, 311, 3119, 1193, 193, 1931, 9311, 31121, 1213, 2131, 131, 1319, 3191, 191, 1913, 9133, 13309, 30911, 911, 91121, 1217, 2179, 179, 17903, 90313, 313, 3137, 137, 1373, 373, 3733, 733, 7331, 331, 3313, 31307, 307, 30703, 70309, 30931, 9319
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
Second-to-last (= third from right) digit of p is not allowed to be zero: e.g., after a(37)=307 we do not use 3079 because then next term must start with 079 which is not possible, hence a(38)=30703.
|
|
LINKS
|
|
|
MATHEMATICA
|
s={113}; id2={1, 1, 3}; Do[Do[p=Prime[k]; If[FreeQ[s, p], idp=IntegerDigits[p];
If[id2==Take[idp, 3]&&idp[[ -3]]>0, AppendTo[s, p]; id2=Take[idp, -3]; Break[]]], {k, 31, 10^7}], {1000}]; s
|
|
CROSSREFS
|
|
|
KEYWORD
|
base,nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|