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-10 of 12 results. Next

A052092 Lengths of the palindromic primes from Honaker's sequence A053600.

Original entry on oeis.org

1, 3, 5, 9, 11, 15, 19, 23, 25, 31, 35, 41, 45, 49, 55, 59, 63, 69, 75, 81, 87, 93, 99, 105, 109, 113, 119, 125, 129, 133, 139, 145, 151, 157, 161, 167, 173, 179, 185, 191, 195, 201, 207, 213, 219, 225, 231, 237, 243, 249, 255, 261, 267, 273, 279, 285, 291, 297
Offset: 0

Views

Author

Patrick De Geest, Jan 15 2000

Keywords

Comments

Since the terms from a(34) onward are currently only probable primes, the lengths given in this sequence beyond that point are only provisional.
For n > 0, a(n) = a(n-1)+2*m where m is the number of digits of A052091(n). - Chai Wah Wu, Dec 03 2015

Crossrefs

Programs

  • Python
    from sympy import isprime
    A052092_list, l, p = [1], 1, 2
    for _ in range(100):
        m, ps = 1, str(p)
        s = int('1'+ps+'1')
        while not isprime(s):
            m += 1
            ms = str(m)
            if ms[0] in '268':
                ms = str(int(ms[0])+1) + '0'*(len(ms)-1)
                m = int(ms)
            if ms[0] in '45':
                ms = '7' + '0'*(len(ms)-1)
                m = int(ms)
            s = int(ms+ps+ms[::-1])
        p = s
        l += 2*len(ms)
        A052092_list.append(l) # Chai Wah Wu, Dec 02 2015

Extensions

Comments from G. L. Honaker, Jr., Mar 30 2000
Edited by T. D. Noe, Oct 30 2008

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 *)

A047076 a(n+1) is the smallest palindromic prime containing exactly 2 more digits on each end than the previous term, with a(n) as a central substring.

Original entry on oeis.org

2, 30203, 133020331, 1713302033171, 12171330203317121, 151217133020331712151, 1815121713302033171215181, 16181512171330203317121518161, 331618151217133020331712151816133, 9333161815121713302033171215181613339, 11933316181512171330203317121518161333911
Offset: 1

Views

Author

G. L. Honaker, Jr., Jan 26 2000

Keywords

References

  • Pickover, Clifford A., A Passion for Mathematics: Numbers, Puzzles, Madness, Religion and the Quest for Reality, John Wiley & Sons, Inc., Hoboken, New Jersey (2005) p. 108.

Crossrefs

Cf. A053600.

Programs

  • Mathematica
    cc=If[EvenQ[First[#]],Reverse[#],#]&/@Tuples[{Range[0,9],Range[1,9,2]}]; nxt[n_]:=First[Select[Sort[FromDigits[Flatten[Join[{#,IntegerDigits[ n], Reverse[#]}]]]&/@cc],PrimeQ]]; NestList[nxt,2,10] (* Harvey P. Dale, Dec 24 2012 *)

A052205 a(n+1) is smallest palindromic prime containing exactly 3 more digits on each end than the previous term, with a(n) as a central substring.

Original entry on oeis.org

2, 1022201, 1051022201501, 1241051022201501421, 1071241051022201501421701, 1051071241051022201501421701501, 1091051071241051022201501421701501901, 1351091051071241051022201501421701501901531
Offset: 1

Views

Author

G. L. Honaker, Jr., Jan 28 2000

Keywords

Crossrefs

Extensions

Shown to be finite by Felice Russo

A052091 Left parts needed for the construction of the palindromic prime pyramid starting with 2.

Original entry on oeis.org

2, 7, 3, 33, 9, 30, 18, 92, 3, 133, 18, 117, 17, 15, 346, 93, 33, 180, 120, 194, 126, 336, 331, 330, 95, 12, 118, 369, 39, 32, 165, 313, 165, 134, 13, 149, 195, 145, 158, 720, 18, 396, 193, 102, 737, 964, 722, 156, 106, 395, 945, 303, 310, 113, 150, 303, 715, 123
Offset: 0

Views

Author

Patrick De Geest, Jan 15 2000

Keywords

Comments

Each term is the smallest to have the previous term as a centered substring, beginning with the smallest palindromic prime 2. The right parts are the reversals of the above terms leading zeros included. The terms from a(34) onward currently correspond only to strong pseudoprimes.
For n > 0, the leftmost (most significant) digit of a(n) is either 1, 3, 7 or 9. - Chai Wah Wu, Dec 02 2015

Examples

			Start with 2; add 7 gives 727; add 3 gives 37273; add 33 gives 333727333; etc.
		

Crossrefs

Programs

  • Python
    from sympy import isprime
    A052091_list, p = [2], 2
    for _ in range(30):
        m, ps = 1, str(p)
        s = int('1'+ps+'1')
        while not isprime(s):
            m += 1
            ms = str(m)
            if ms[0] in '268':
                ms = str(int(ms[0])+1) + '0'*(len(ms)-1)
                m = int(ms)
            if ms[0] in '45':
                ms = '7' + '0'*(len(ms)-1)
                m = int(ms)
            s = int(ms+ps+ms[::-1])
        p = s
        A052091_list.append(m) # Chai Wah Wu, Dec 02 2015

Extensions

Comments from G. L. Honaker, Jr., Mar 30 2000

A082563 a(1) = 3; for n>=1, a(n+1) is the smallest palindromic prime with a(n) as a central substring.

Original entry on oeis.org

3, 131, 11311, 121131121, 1212113112121, 36121211311212163, 303612121131121216303, 7230361212113112121630327, 30723036121211311212163032703, 723072303612121131121216303270327, 1472307230361212113112121630327032741, 114723072303612121131121216303270327411
Offset: 1

Views

Author

Benoit Cloitre, May 04 2003

Keywords

Comments

The minimal nested palindromic primes with seed 3; see A261881 for a guide to related sequences.

Examples

			As a triangle:
........3
.......131
......11311
....121131121
..1212113112121
36121211311212163
		

Crossrefs

Programs

  • Mathematica
    s = {3}; 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 *)

Extensions

Name changed by Arkadiusz Wesolowski, Sep 15 2011
More terms from Clark Kimberling, Sep 23 2015

A256957 Smallest palindromic prime that generates a palindromic prime pyramid of height n.

Original entry on oeis.org

11, 131, 2, 5, 10301, 16361, 10281118201, 35605550653, 7159123219517, 17401539893510471, 3205657651567565023, 14736384418081448363741
Offset: 1

Views

Author

Felice Russo, Jan 25 2000

Keywords

Comments

Start with a palindromic prime p; look for smallest palindromic prime that has previous term as a centered substring and has 2 more digits (i.e., one more digit at each end); repeat until no such palindromic prime can be found; then height(p) = number of rows in pyramid. Each row of pyramid must be the smallest prime that can be used. Then a(n) = smallest value of p that generates a pyramid of height n.

Examples

			a(1) = 11.
a(4) = 5:
5
151
31513
3315133, stop;
height(5)=4.
a(6)=16362:
16361
1163611
311636113
33116361133
3331163611333
333311636113333, stop;
height(16361)=6.
		

Crossrefs

Extensions

Added a(10)-a(11) and corrected a(4) - Chai Wah Wu, Apr 09 2015
Entry revised by N. J. A. Sloane, Apr 13 2015
a(12) from Michael S. Branicky, Oct 28 2024

A034276 Smallest prime that generates a prime pyramid of height n.

Original entry on oeis.org

11, 29, 2, 5, 41, 251, 43, 145577, 51941, 4372877, 26901631, 366636187, 15387286403, 218761753811, 3313980408469
Offset: 1

Views

Author

Felice Russo, Jan 25 2000

Keywords

Comments

Let p be prime; look for the smallest prime in {1|p|1, 3|p|3, 7|p|7, 9|p|9}, where '|' stands for concatenation; repeat until no such prime can be found; then height(p) = number of rows in pyramid.
a(13) > 10^10. - Donovan Johnson, Aug 13 2010

Examples

			Example for p=43: 43 3433 334333 93343339 3933433393 939334333939 39393343339393, stop; height(43)=7.
		

Crossrefs

Extensions

More terms from Naohiro Nomoto, Jul 14 2001
a(11)-a(12) from Donovan Johnson, Aug 13 2010
a(13) from Chai Wah Wu, Apr 10 2015
a(14)-a(15) from Giovanni Resta, May 15 2020

A247483 a(1)=4; for n>=1, a(n+1) is the smallest palindromic semiprime with a(n) as a central substring.

Original entry on oeis.org

4, 141, 41414, 1414141, 314141413, 33141414133, 3331414141333, 14333141414133341, 121433314141413334121, 1012143331414141333412101, 17101214333141414133341210171, 3171012143331414141333412101713, 19317101214333141414133341210171391
Offset: 1

Views

Author

Michel Lagneau, Dec 01 2014

Keywords

Examples

			a(1) = 4 = 2*2;
a(2) = 141 = 3*47;
a(3) = 41414 = 2*20707;
a(4) = 1414141 = 43*32887.
		

Crossrefs

Programs

  • Mathematica
    d[n_] := IntegerDigits[n]; t = {x = 4}; Do[i = 1; While[!PrimeOmega[y = FromDigits[Flatten[{z = d[i], d[x], Reverse[z]}]]]==2, i++]; AppendTo[t, x = y], {n, 12}]; t
    nxt[n_]:=Module[{k=1},While[PrimeOmega[FromDigits[Join[IntegerDigits[k],IntegerDigits[n],Reverse[IntegerDigits[k]]]]]!=2,k++]; FromDigits[ Join[IntegerDigits[k],IntegerDigits[n],Reverse[IntegerDigits[k]]]]]; NestList[nxt,4,15] (* Harvey P. Dale, Oct 30 2024 *)

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
Showing 1-10 of 12 results. Next