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 17 results. Next

A065584 Smallest prime beginning with exactly n 1's.

Original entry on oeis.org

2, 13, 11, 1117, 11113, 111119, 11111101, 11111117, 111111113, 11111111129, 11111111113, 1111111111139, 11111111111123, 1111111111111013, 1111111111111123, 11111111111111101, 11111111111111119
Offset: 0

Views

Author

Robert G. Wilson v, Nov 28 2001

Keywords

Comments

Largest terms are only probable primes. Some terms of the sequence are also in A004022 (repunit primes) or A056710 (all digits same except last digit). All terms of A004022 are in the current sequence.
According to the Magma Calculator (at http://magma.maths.usyd.edu.au/calc/), all 201 terms in the table (and thus all 17 terms listed above) are, in fact, prime. - Jon E. Schoenfield, Aug 24 2009

Crossrefs

Cf. A004022 (repunit primes), A056710 (near-repdigit primes).

Extensions

Corrected by Don Reble, Jan 17 2007
Offset corrected by Sean A. Irvine, Sep 06 2023

A099656 a(n) is the least prime following A002276(n) repdigits.

Original entry on oeis.org

2, 3, 23, 223, 2237, 22229, 222247, 2222239, 22222223, 222222227, 2222222243, 22222222223, 222222222301, 2222222222243, 22222222222229, 222222222222227, 2222222222222281, 22222222222222301, 222222222222222281
Offset: 0

Views

Author

Labos Elemer, Nov 17 2004

Keywords

Examples

			n=2: 22 is followed by 23.
		

Crossrefs

Programs

  • Maple
    seq(nextprime(2*(10^i-1)/9), i=0..20); # Robert Israel, Aug 25 2017
  • Mathematica
    Table[NextPrime[2*(10^n-1)/9], {n, 0, 35}]
    Table[ NextPrime[2*(10^n - 1)/9], {n, 0, 18}] (* Robert G. Wilson v, Nov 20 2004 *)
    Table[NextPrime[FromDigits[PadRight[{},n,2]]],{n,0,20}] (* Harvey P. Dale, Dec 15 2021 *)

A099668 a(n) is the largest prime before A002282(n) repdigits.

Original entry on oeis.org

7, 83, 887, 8887, 88883, 888887, 8888861, 88888883, 888888887, 8888888837, 88888888859, 888888888887, 8888888888857, 88888888888873, 888888888888883, 8888888888888753, 88888888888888801, 888888888888888859, 8888888888888888881, 88888888888888888879, 888888888888888888857
Offset: 1

Views

Author

Labos Elemer, Nov 17 2004

Keywords

Examples

			n=2: 83 is before 88.
		

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[8*(10^n-1)/9, -1], {n, 1, 35}]
    Table[NextPrime[FromDigits[PadRight[{},n,8]],-1],{n,20}] (* Harvey P. Dale, Jul 12 2014 *)

Formula

a(n) = A007917(A002282(n)). - Amiram Eldar, Jun 29 2025

A068103 Smallest prime starting with at least n 2s.

Original entry on oeis.org

2, 2, 223, 2221, 22229, 2222203, 22222223, 22222223, 222222227, 22222222223, 22222222223, 2222222222243, 22222222222201, 22222222222229, 222222222222227, 222222222222222043, 222222222222222221
Offset: 0

Views

Author

Amarnath Murthy, Feb 20 2002

Keywords

Crossrefs

Programs

  • PARI
    A068103(n)={n=10^n\9*2;n>2&for(d=1,9e9,n*=10;for(t=1,10^d-1,ispseudoprime(n+t)&return(n+t)));2} \\ - M. F. Hasler, Oct 17 2012

Extensions

More terms from Sascha Kurz, Mar 19 2002
Corrected by Don Reble, Jan 17 2007

A068105 Smallest prime starting with n 5s.

Original entry on oeis.org

2, 5, 557, 5557, 555521, 555557, 55555517, 55555553, 5555555501, 5555555557, 555555555551, 555555555551, 5555555555551, 555555555555529, 555555555555557, 55555555555555519, 555555555555555559, 555555555555555559, 55555555555555555567, 5555555555555555555087
Offset: 0

Views

Author

Amarnath Murthy, Feb 20 2002

Keywords

Crossrefs

Programs

  • Python
    from sympy import isprime
    def a(n):
      if n < 2: return list([2, 5])[n]
      n5s, i, pow10 = int('5'*n), 1, 1
      while True:
        i = 1
        while i < pow10:
          t = n5s * pow10 + i
          if isprime(t): return t
          i += 2
        pow10 *= 10
    print([a(n) for n in range(20)]) # Michael S. Branicky, Feb 05 2021

Formula

a(n) <= A065588(n). - Michael S. Branicky, Feb 05 2021

Extensions

Edited and extended by Robert G. Wilson v, Feb 21 2002
Corrected by Don Reble, Jan 17 2007

A099667 a(n) is the largest prime before A002281(n); repdigits repeating 7.

Original entry on oeis.org

5, 73, 773, 7759, 77773, 777769, 7777769, 77777761, 777777773, 7777777741, 77777777767, 777777777773, 7777777777771, 77777777777753, 777777777777773, 7777777777777753, 77777777777777747, 777777777777777743
Offset: 1

Views

Author

Labos Elemer, Nov 17 2004

Keywords

Examples

			n=2: 73 is before 77.
		

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[7 (10^n - 1)/9, -1], {n, 35}]
    (* Second program: *)
    Rest[NextPrime[#,-1]&/@LinearRecurrence[{11,-10},{0,7},25]] (* Harvey P. Dale, May 24 2015 *)

Extensions

Name changed by David A. Corneth, Sep 01 2017

A123568 Prime numbers of the form (10^n - 7)/3.

Original entry on oeis.org

31, 331, 3331, 33331, 333331, 3333331, 33333331, 333333333333333331, 3333333333333333333333333333333333333331, 33333333333333333333333333333333333333333333333331
Offset: 1

Views

Author

Artur Jasinski, Nov 12 2006

Keywords

Comments

The number of initial 3s is n - 1.
Note that each n from 2 to 8 gives primes, but after that the n that correspond to primes are progressively further apart. Singh (1997) gives this as an example of why mathematicians don't trust a preponderance of evidence as proof: in the 17th century, when factoring numbers with as few as eight digits wasn't as easy as it is today, the pattern suggested that all numbers of this form are prime. - Alonso del Arte, Nov 11 2012

Examples

			a(7) = 33333331 because that is the seventh number of the specified form to be prime.
333333331 is not in the sequence because it is composite, being the product of 17 and 19607843.
		

References

  • Simon Singh, Fermat's Enigma. New York: Walker & Company (1997) p. 159.

Crossrefs

Programs

  • Mathematica
    Do[If[PrimeQ[(10^n - 7)/3], Print[(10^n - 7)/3]], {n, 1, 100}] (* Jasinski *)
    Select[(10^Range[50] - 7)/3, PrimeQ[#] &] (* Alonso del Arte, Nov 11 2012 *)
    Select[Table[FromDigits[PadLeft[{1},n,3]],{n,50}],PrimeQ] (* Harvey P. Dale, Dec 05 2018 *)
  • PARI
    select(ispseudoprime, vector(20, n, (10^n-7)/3)) \\ Charles R Greathouse IV, Nov 12 2012

A099658 a(n) is the smallest prime greater than 4(10^n - 1)/9.

Original entry on oeis.org

2, 5, 47, 449, 4447, 44449, 444449, 4444469, 44444453, 444444457, 4444444447, 44444444497, 444444444461, 4444444444493, 44444444444459, 444444444444461, 4444444444444463, 44444444444444461, 444444444444444469, 4444444444444444537, 44444444444444444447
Offset: 0

Views

Author

Labos Elemer, Nov 17 2004

Keywords

Comments

a(n) = smallest prime > A002278(n).

Examples

			n=4: 44 is followed by 47.
		

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[4*(10^n-1)/9], {n, 0, 35}]

Extensions

Checked by N. J. A. Sloane, Jan 27 2007
Mathematica program edited by Harvey P. Dale, Jul 16 2024

A099659 a(n) is the least prime following A002279(n) repdigits.

Original entry on oeis.org

7, 59, 557, 5557, 55579, 555557, 5555567, 55555559, 555555587, 5555555557, 55555555619, 555555555559, 5555555555593, 55555555555573, 555555555555557, 5555555555555573, 55555555555555639, 555555555555555559, 5555555555555555621, 55555555555555555567, 555555555555555555619
Offset: 1

Views

Author

Labos Elemer, Nov 17 2004

Keywords

Examples

			n=2: 55 is followed by 59.
		

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[5*(10^n-1)/9], {n, 1, 35}]

Extensions

Offset corrected by Georg Fischer, Mar 12 2024

A099660 a(n) is the least prime following A002280[n] repdigits.

Original entry on oeis.org

2, 7, 67, 673, 6673, 66683, 666667, 6666679, 66666667, 666666667, 6666666757, 66666666667, 666666666671, 6666666666683, 66666666666737, 666666666666719, 6666666666666719, 66666666666666713, 666666666666666773
Offset: 0

Views

Author

Labos Elemer, Nov 17 2004

Keywords

Examples

			n=6: 66 is followed by 67.
		

Crossrefs

Programs

  • Mathematica
    Table[NextPrime[6*(10^n-1)/9], {n, 0, 35}]
    NextPrime/@Table[FromDigits[PadRight[{},n,6]],{n,0,20}] (* Harvey P. Dale, Feb 25 2015 *)

Extensions

First Mathematica program corrected by Harvey P. Dale, Feb 25 2015
Showing 1-10 of 17 results. Next