OFFSET
1,1
COMMENTS
Conjecture: a(k) < prime(k) for k > 2.
a(n)=3 if and only if prime(n) is in A023238. - Robert Israel, Dec 27 2017
LINKS
Robert Israel, Table of n, a(n) for n = 1..20000 (n=1..1000 from Harry J. Smith)
EXAMPLE
MAPLE
N:= 100: # to get a(1)..a(N)
P:= Vector(N, ithprime):
A:= Vector(N):
q:= 2:
Agenda:= {$1..N}:
while Agenda <> {} do
q:= nextprime(q);
m:= 10^(ilog10(q)+1);
L, Agenda:= selectremove(t -> isprime(P[t]*m+q), Agenda);
A[convert(L, list)]:= q;
od:
convert(A, list); # Robert Israel, Dec 27 2017
PROG
(PARI) digitsIn(x)= { local(d); if (x==0, return(1)); d=1 + log(x)\log(10); if (10^d == x, d++, if (10^(d-1) > x, d--)); return(d) }
Concat(a, b)= { return(a*10^digitsIn(b) + b) }
{ for (n = 1, 1000, p=prime(n); q=2; while(!isprime(Concat(p, q)), q=nextprime(q + 1)); write("b066065.txt", n, " ", q) ) } \\ Harry J. Smith, Nov 09 2009
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Reinhard Zumkeller, Dec 01 2001
STATUS
approved