login
Smallest a(n) > n such that concatenation of numbers from n to a(n) is a prime or 0 if no such number exists.
6

%I #44 Mar 05 2021 04:24:44

%S 3,19,7,17,7,13,9,187

%N Smallest a(n) > n such that concatenation of numbers from n to a(n) is a prime or 0 if no such number exists.

%C Terms a(1) and a(10) (and many other terms) are currently unknown.

%C a(11) = 309, a(12) = 13.

%C a(1) > 344869 (see A007908). - _Sean A. Irvine_, Jun 17 2019

%C More terms: a(14..17) = (17, 19, 43, 39), a(20) = 23, a(23) = 41, a(25) = 49, a(26) = 147, a(28) = 73, a(33..39) = (103, 37, 603, 37, 43, 57, 43), a(42) = 43, a(44) = 51, a(49) = 241, a(50) = 51, a(n) > 1000 for 12 < n < 50 not mentioned here. - _M. F. Hasler_, Feb 22 2021

%C a(10) > 10010, a(18) = 3607, a(66) = 1003, a(275) = 1089. If n == 2 (mod 3), then a(n) == 3 or 5 (mod 6). If n == 0 or 1 (mod 3), then a(n) == 1 (mod 6) (see A341716). - _Chai Wah Wu_, Feb 22 2021

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/ConsecutiveNumberSequences.html">Consecutive Number Sequences</a>.

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/SmarandachePrime.html">Smarandache Prime</a>

%e a(4) = 7 because 4567 is a prime.

%o (PARI) A084559(n,N=n,T=10^logint(n,10))=while(T*=10,for(m=n+1,n=T-1,ispseudoprime(N=N*T+m)&&return(m))) \\ _M. F. Hasler_, Feb 22 2021

%Y Cf. A007908, A030458, A030471, A052087, A052088, A052089.

%Y Cf. also A341715, A341716, A341717 (similar but a(n) = n when n is prime).

%K nonn,base,hard,more

%O 2,1

%A _Zak Seidov_, Jun 27 2003

%E Edited by _Max Alekseyev_, Jan 28 2012

%E a(4) corrected by _Daniel Suteu_, Jun 16 2019

%E Escape clause added to definition by _Chai Wah Wu_, Feb 22 2021