|
|
A080437
|
|
For n < 5, a(n) = n-th prime. For n >= 5, let m = n-th prime. If m is a k-digit prime then a(n) = smallest prime obtained by inserting at least one digit between every pair of digits of m. There are (k-1) places where digit insertion takes place and a(n) contains at least 2k-1 digits.
|
|
2
|
|
|
2, 3, 5, 7, 101, 103, 107, 109, 223, 229, 311, 307, 401, 433, 457, 503, 509, 601, 607, 701, 733, 709, 823, 809, 907, 10061, 10093, 10007, 10009, 10103, 10247, 10301, 10337, 10369, 10429, 10501, 10567, 10613, 10607, 10723, 10709, 10831, 11941
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
At least up to n = 10^5, one inserted digit per position suffices. - Robert Israel, Feb 12 2016
|
|
LINKS
|
|
|
MAPLE
|
f:= proc(n) local p, Lp, q0, x, Lx, k, i, q;
# This function attempts to insert one digit in each position.
p:= ithprime(n);
if p < 10 then return p fi;
Lp:= convert(p, base, 10);
k:= nops(Lp);
q0:= add(100^(i-1)*Lp[i], i=1..k);
for x from 0 to 10^k-1 do
Lx:= convert(10^k+x, base, 10);
q:= q0 + 10*add(100^(i-1)*Lx[i], i=1..k-1);
if isprime(q) then return q fi
od:
error("Need more than one digit");
end proc:
|
|
CROSSREFS
|
|
|
KEYWORD
|
base,nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|