login
a(n) is the least prime beginning with prime(n) such that the concatenation a(1)a(2)...a(n) is a prime.
2

%I #11 Aug 07 2020 02:15:14

%S 2,3,509,79,1163,13033,1721,19,233,29569,3119,37057,410171,43003,

%T 47111,5323,59219,61291,670223,710911,73331,795793,83399,894709,

%U 975581,101383,1033079,1071937,109073,1130257,1276397,1313911,1378673,1395469,1491233

%N a(n) is the least prime beginning with prime(n) such that the concatenation a(1)a(2)...a(n) is a prime.

%H Robert Israel, <a href="/A090510/b090510.txt">Table of n, a(n) for n = 1..461</a>

%p dcat:= proc(a,b) 10^(1+ilog10(b))*a+b end proc:

%p S:= 2: R:= 2:

%p for n from 2 to 35 do

%p found:= false;

%p for d from 0 while not found do

%p cand:= 10^d*ithprime(n)-1;

%p do

%p cand:= nextprime(cand);

%p if cand >= 10^d*(ithprime(n)+1) then break fi;

%p Sc:= dcat(S,cand);

%p if isprime(Sc) then found:= true; break fi

%p od od;

%p R:= R, cand;

%p S:= Sc;

%p od:

%p R; # _Robert Israel_, Aug 06 2020

%Y Cf. A090511.

%K base,nonn

%O 1,1

%A _Amarnath Murthy_, Dec 06 2003

%E More terms from _Max Alekseyev_, Feb 08 2010