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.

Showing 1-3 of 3 results.

A261881 Minimal nested palindromic primes with seed 0.

Original entry on oeis.org

0, 101, 31013, 3310133, 933101339, 1093310133901, 30109331013390103, 333010933101339010333, 33330109331013390103333, 993333010933101339010333399, 104993333010933101339010333399401, 7810499333301093310133901033339940187
Offset: 1

Views

Author

Clark Kimberling, Sep 23 2015

Keywords

Comments

Let s be a palindrome and put a(1) = s. Let a(2) be the least palindromic prime having s in the middle; for n > 2, let a(n) be the least palindromic prime having a(n-1) in the middle. Then (a(n)) is the sequence of minimal nested palindromic primes with seed s.
Guide to related sequences:
seed sequence

Examples

			As a triangle:
........0
.......101
......31013
.....3310133
....933101339
..1093310133901
30109331013390103
		

Crossrefs

Cf. A261818.

Programs

  • Mathematica
    s = {0}; Do[NestWhile[# + 1 &, 1, ! PrimeQ[tmp = FromDigits[Join[#, IntegerDigits[Last[s]], Reverse[#]] &[IntegerDigits[#]]]] &]; AppendTo[s, tmp], {15}]; s
    (* Peter J. C. Moses, Sep 01 2015 *)

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.

Original entry on oeis.org

3, 10301, 101030101, 1210103010121, 12121010301012121, 111212101030101212111, 3111121210103010121211113, 17311112121010301012121111371, 961731111212101030101212111137169, 3196173111121210103010121211113716913, 95319617311112121010301012121111371691359, 109531961731111212101030101212111137169135901, 1410953196173111121210103010121211113716913590141, 13141095319617311112121010301012121111371691359014131
Offset: 1

Views

Author

Shyam Sunder Gupta, Aug 24 2024

Keywords

Comments

This is a finite sequence since at a(14) there is no way to add 2 more digits and reach a palindromic prime.

Examples

			As a triangle:
          3
        10301
      101030101
    1210103010121
  12121010301012121
		

Crossrefs

Programs

  • Python
    from sympy import isprime
    from itertools import product
    def agen(): # generator of terms
        an, s = 3, "3"
        while an > 0:
            yield an
            an = -1
            for f, r in product("1379", "0123456789"):
                sn = f+r+s+r+f
                if isprime(t:=int(sn)):
                    an, s = t, sn
                    break
    print(list(agen())) # Michael S. Branicky, Aug 25 2024

A376103 a(1) = 5; 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.

Original entry on oeis.org

5, 10501, 111050111, 1211105011121, 39121110501112193, 393912111050111219393, 7239391211105011121939327, 79723939121110501112193932797, 157972393912111050111219393279751, 7415797239391211105011121939327975147
Offset: 1

Views

Author

Shyam Sunder Gupta, Sep 10 2024

Keywords

Comments

This is a finite sequence since at a(10) there is no way to add 2 more digits and reach a palindromic prime.

Examples

			As a triangle:
          5
        10501
      111050111
    1211105011121
  39121110501112193
		

Crossrefs

Showing 1-3 of 3 results.