cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A375690 a(1) = 3; for n > 1, a(n) is the smallest palindromic prime containing exactly 2 more digits on each end than a(n-1), with a(n-1) as the central substring.

This page as a plain text file.
%I A375690 #13 Sep 01 2024 09:37:48
%S A375690 3,10301,101030101,1210103010121,12121010301012121,
%T A375690 111212101030101212111,3111121210103010121211113,
%U A375690 17311112121010301012121111371,961731111212101030101212111137169,3196173111121210103010121211113716913,95319617311112121010301012121111371691359,109531961731111212101030101212111137169135901,1410953196173111121210103010121211113716913590141,13141095319617311112121010301012121111371691359014131
%N A375690 a(1) = 3; for n > 1, a(n) is the smallest palindromic prime containing exactly 2 more digits on each end than a(n-1), with a(n-1) as the central substring.
%C A375690 This is a finite sequence since at a(14) there is no way to add 2 more digits and reach a palindromic prime.
%e A375690 As a triangle:
%e A375690           3
%e A375690         10301
%e A375690       101030101
%e A375690     1210103010121
%e A375690   12121010301012121
%o A375690 (Python)
%o A375690 from sympy import isprime
%o A375690 from itertools import product
%o A375690 def agen(): # generator of terms
%o A375690     an, s = 3, "3"
%o A375690     while an > 0:
%o A375690         yield an
%o A375690         an = -1
%o A375690         for f, r in product("1379", "0123456789"):
%o A375690             sn = f+r+s+r+f
%o A375690             if isprime(t:=int(sn)):
%o A375690                 an, s = t, sn
%o A375690                 break
%o A375690 print(list(agen())) # _Michael S. Branicky_, Aug 25 2024
%Y A375690 Cf. A047076, A053600, A082563.
%K A375690 nonn,base,fini,full
%O A375690 1,1
%A A375690 _Shyam Sunder Gupta_, Aug 24 2024