login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A082622 a(1) = 3, a(n) = smallest palindromic prime obtained by inserting two paired digits anywhere in a(n-1). 6

%I #53 Sep 21 2019 05:45:33

%S 3,131,10301,1003001,100030001,10070307001,1000703070001,

%T 100075030570001,10006750305760001,1000167503057610001,

%U 100015675030576510001,10001056750305765010001,1000105367503057635010001,100001053675030576350100001,10000105360750305706350100001

%N a(1) = 3, a(n) = smallest palindromic prime obtained by inserting two paired digits anywhere in a(n-1).

%C With the exception of 11, all decimal palindromic numbers with an even number of digits are composite (they are divisible by 11). This leaves only odd-digit-length palindromes, therefore (at least) a pair of digits needs to be inserted at every iteration.

%C The sequence terminates at a(19) = 1000010025136075033305706315200100001, which cannot be extended to another palindromic prime by inserting two paired digits. - _Giovanni Resta_, Sep 20 2019

%H Giovanni Resta, <a href="/A082622/b082622.txt">Table of n, a(n) for n = 1..19</a>

%o (PARI) \\ Warning: program gives incorrect results; _Michel Marcus_, Sep 21 2019

%o {w=[];print(1" "3);

%o for(i=2,58,w=concat(0,w);for(pos=1,i,if(pos>1,w[pos-1]=w[pos]);

%o for(d=0,9,w[pos]=d;

%o if(isprime(n=fromdigits(concat(Vecrev(w),concat(3,w)))),

%o print(i" "n);break(2)))))} \\ _Serge Batalov_, Dec 18 2015

%Y Cf. A082620, A082621.

%K nonn,base,fini,full

%O 1,1

%A _Amarnath Murthy_, Apr 29 2003

%E a(6)-a(56) from _Serge Batalov_, Dec 18 2015

%E Terms following a(6) corrected by _Giovanni Resta_, Sep 20 2019

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified July 24 05:58 EDT 2024. Contains 374575 sequences. (Running on oeis4.)