login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Numbers n such that concatenation of first n primes, separated by zeros, is prime.
3

%I #11 Feb 28 2020 19:57:00

%S 1,9,15,25,59,444

%N Numbers n such that concatenation of first n primes, separated by zeros, is prime.

%C w_n= (p_1)0(p_2)0(p_3)...0(p_n) w_1=2 is prime(a_1=1), w_2, ..., w_8 are not prime and w_9 is prime (a_2=9),... a_n is the n-th term of w_n which is prime.

%C a(7) > 2615. - _Derek Orr_, Aug 12 2014

%e a(2)=9 because 2030507011013017019023, which is the concatenation of first 9 primes separated by zeros is prime.

%t Select[Range[450],PrimeQ[FromDigits[Flatten[IntegerDigits/@Riffle[ Prime[ Range[ #]],0]]]]&] (* _Harvey P. Dale_, Feb 28 2020 *)

%o (PARI)

%o p="";for(n=1,5000,p=concat(p,"0");p=concat(p,Str(prime(n)));if(ispseudoprime(eval(p)),print1(n,", "))) \\ _Derek Orr_, Aug 12 2014

%K base,hard,more,nonn

%O 1,2

%A _Farideh Firoozbakht_, May 03 2003