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-6 of 6 results.

A005042 Primes formed by the initial digits of the decimal expansion of Pi.

Original entry on oeis.org

3, 31, 314159, 31415926535897932384626433832795028841
Offset: 1

Views

Author

Keywords

Comments

The next term consists of the first 16208 digits of Pi and is too large to show here (see A060421). Ed T. Prothro found this probable prime in 2001.
A naive probabilistic argument suggests that the sequence is infinite. - Michael Kleber, Jun 23 2004

References

  • M. Gardner, personal communication.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

See A060421 for further terms.

Programs

  • Maple
    Digits := 130; n0 := evalf(Pi); for i from 1 to 120 do t1 := trunc(10^i*n0); if isprime(t1) then print(t1); fi; od:
  • Mathematica
    a = {}; Do[k = Floor[Pi 10^n]; If[PrimeQ[k], AppendTo[a, k]], {n, 0, 160}]; a (* Artur Jasinski, Mar 26 2008 *)
    nn=1000;With[{pidigs=RealDigits[Pi,10,nn][[1]]},Select[Table[FromDigits[ Take[pidigs,n]],{n,nn}],PrimeQ]] (* Harvey P. Dale, Sep 26 2012 *)
  • PARI
    c=Pi;for(k=0,precision(c),isprime(c\.1^k) & print1(c\.1^k,",")) \\ - M. F. Hasler, Sep 01 2013

Formula

a(n) = floor(10^(A060421(n)-1)*A000796), where A000796 is the constant Pi = 3.14159... . - M. F. Hasler, Sep 02 2013

A047777 Primes seen in the decimal expansion of Pi (disregarding the decimal point) that are contiguous, smallest and distinct.

Original entry on oeis.org

3, 14159, 2, 653, 5, 89, 7, 9323
Offset: 1

Views

Author

Keywords

Comments

Sequence A121267 gives the number of digits of a(n) [but see also A229181 for a variant, cf. below]. The terms a(9)-a(11) had been found by Chris Nash in October 1999, and primality of the 3057-digit term a(9) has been proved in September 2002 by J. K. Andersen, who also found the next 5 terms a(12)-a(16) and the bound a(17) > 10^32000, cf. Rivera's web page "Problem 18". - M. F. Hasler, Aug 31 2013
There is a natural variant of the present sequence, using the same definition except for not requiring that all primes have to be distinct. That variant would have the same 3057-digit prime as next term a(9), and therefore have the same displayed terms and not justify a separate entry in the OEIS. However, terms beyond a(9) would be different: instead of a(10) = 73, a(11) = 467 and the 14650-digit PRP a(11), it would be followed by a'(10) = 7, a'(11) = 3 (which cuts a(10) = 73 in two pieces), a'(12) = 467, a'(13) = a'(14) = 2, and a'(15) equal to a 748-digit prime, see the a-file from J.-F. Alcover. Sequence A229181 lists the size of these terms. - M. F. Hasler, Sep 15 2013, updated Jan 18 2019

Examples

			The first digit of Pi = 3.14159... is the prime 3, therefore a(1) = 3.
We discard this digit 3, and look for the first time a chunk of subsequent digits (always starting with the 1 coming right after the previously used 3) would be prime: 1, 14, 141, 1415 are not, but 14159 is. (The single-digit prime '5' was not considered, because we require the primes made from the whole contiguous chunk of digits starting after the previously found prime.) Thus, a(2) = 14159.
Thereafter, we have the single-digit prime a(3) = 2, and then a(4) = 653 (since neither 6 nor 65 is prime). - _M. F. Hasler_, Jan 18 2019
		

Crossrefs

Programs

Extensions

The next term is the 3057-digit prime formed from digits 19 through 3075. It is 846264338327950...708303906979207. - Mark R. Diamond, Feb 22 2000
The two terms after that are 73 and 467. - Jason Earls, Apr 05 2001

A198019 Primes occurring in the decimal expansion of Pi (A000796), ordered by position of last digit, then by size.

Original entry on oeis.org

3, 31, 41, 5, 59, 4159, 14159, 314159, 2, 53, 653, 1592653, 89, 141592653589, 7, 97, 5897, 35897, 6535897, 5926535897, 415926535897, 79, 58979, 358979, 589793, 23, 9323, 9265358979323, 43, 643, 462643, 93238462643, 433, 83, 383, 2643383, 38462643383, 89793238462643383, 41592653589793238462643383
Offset: 1

Views

Author

M. F. Hasler, Oct 20 2011

Keywords

Comments

Cf. A198018; the only difference is that here we list the "new primes" by increasing size (for a given subsequence of A000796).
Considering the first 1, 2, 3, 4,.... digits of the decimal expansion 3.14159... of Pi, record the primes that have not occurred earlier.
Sequence A198187 lists "duplicate" primes multiple times, each time they occur anew ending in another decimal place. - M. F. Hasler, Sep 01 2013

Examples

			In Pi = 3... we have the prime a(1)=3.
In Pi = 3.1.... we have the prime a(2)=31.
In Pi = 3.14... we have no new prime.
In Pi = 3.141.... we have the prime a(3)=41.
In Pi = 3.1415.... we have the new prime a(5)=5.
In Pi = 3.14159.... we have the new primes (listed in increasing order) a(6)=59, a(7)=4159, a(8)=14159 and a(9)=314159. [_M. F. Hasler_, Sep 01 2013]
		

Crossrefs

Programs

  • PARI
    {t=Pi; u=[]; for(i=0,precision(t), for(k=1,i+1, ispseudoprime(p=t\.1^i%10^k)& !setsearch(u,p)& (u=setunion(u,Set(p)))&print1(p",")))}

A121267 Number of decimal digits in A047777(n).

Original entry on oeis.org

1, 5, 1, 3, 1, 2, 1, 4, 3057, 2, 3, 14650, 4, 2, 46, 4
Offset: 1

Views

Author

Robert G. Wilson v, Aug 23 2006

Keywords

Comments

Not equal to the first differences of A053013 (which is based on a different variant of A047777).
"A new visitor to an old problem! Jens Kruse Andersen confirmed the primality of Nash's 3057-digit prime using PRIMO." - Carlos Rivera, Sep 2002
If it exists, then a(17) > 50000. - Lucas A. Brown, Jul 04 2024

Crossrefs

Programs

  • PARI
    default(realprecision,5000);c=Pi/10;u=[];for(k=1,9e9,ispseudoprime(c\.1^k) & !setsearch(u,c\.1^k) & (u=setunion(u,Set(c\.1^k))) & !print1(k,",") & k=0*c=frac(c*10^k)) \\ M. F. Hasler, Sep 15 2013

Extensions

The old values a(10) onwards were incorrect, as discovered by M. F. Hasler, Aug 31 2013. The old values, the b-file and the Mathematica program have been deleted. - N. J. A. Sloane, Sep 01 2013

A198187 Primes from the decimal expansion of Pi, sorted first by the final digit index and then by length.

Original entry on oeis.org

3, 31, 41, 5, 59, 4159, 14159, 314159, 2, 5, 3, 53, 653, 1592653, 5, 89, 141592653589, 7, 97, 5897, 35897, 6535897, 5926535897, 415926535897, 79, 58979, 358979, 3, 589793, 2, 3, 23, 9323, 9265358979323, 2, 3, 43, 643, 462643, 93238462643, 3, 433, 3, 83, 383
Offset: 1

Views

Author

Keywords

Comments

In this sequence, primes are listed each time they occur (again) with a new ending position, in contrast to A198019 where only the first occurrence of each prime is listed. - M. F. Hasler, Sep 02 2013

Examples

			The first digit is 3, which is prime, so a(1) = 3.
The second digit is 1, which is no prime, but 31 is prime, so a(2) = 31.
The third digit is 4, which does not end any prime.
The fourth digit is 1, not prime, but 41 is prime, so a(3) = 41.
		

Crossrefs

Programs

  • PARI
    v=[3, 1, 4, 1, 5, 9, 2, 6, 5, 3, 5, 8, 9, 7, 9, 3, 2, 3, 8, 4, 6, 2, 6, 4, 3, 3, 8, 3]
    for(n=1,#v,x=0;p=1;forstep(k=n,1,-1,x+=p*v[k];p*=10;if(v[k]&&isprime(x),print1(x", "))))

A229181 Number of decimal digits in the variant of A047777(n) (decimal expansion of Pi cut in "prime chunks") without the restriction that all primes must be different.

Original entry on oeis.org

1, 5, 1, 3, 1, 2, 1, 4, 3057, 1, 1, 3, 1, 1, 748, 2, 2, 1, 2, 83, 5, 1, 2, 71, 10, 1, 1, 2, 2, 2, 1, 1, 3, 1, 14, 2, 5, 51, 1, 6, 1, 6, 3, 2, 9, 1, 16, 2, 3, 43, 1, 6, 19, 1, 5, 3, 1999, 1, 1, 2, 22, 1, 3, 1, 2, 2, 1, 2, 2, 5, 1, 1, 1, 1, 4, 1, 1, 3, 7, 5, 1, 6, 4, 3, 1, 10, 7, 1, 2, 11, 2, 5, 1, 13, 1, 20, 16, 1, 9, 16
Offset: 1

Views

Author

M. F. Hasler, Sep 15 2013

Keywords

Comments

A variant of A121267. First differences of A053013. See these two sequences for further details.

Crossrefs

Programs

  • Mathematica
    A229181 = {1}; digits = Join[{{1}}, RealDigits[Pi, 10, 10^4] // First // Rest]; digits //. {a:({A229181,%20lg%5D;%20%7B%7B1%7D,%20c%7D)%20;%20A229181%20(*%20_Jean-Fran%C3%A7ois%20Alcover">Integer..}..), b__Integer /; PrimeQ[FromDigits[{b}]], c___Integer} :> (Print[lg = {b} // Length]; AppendTo[A229181, lg]; {{1}, c}) ; A229181 (* _Jean-François Alcover, Oct 17 2013 *)
  • PARI
    default(realprecision,5000);c=Pi/10;u=[];for(k=1,9e9,ispseudoprime(c\.1^k) & !print1(k,",") & k=0*c=frac(c*10^k))

Extensions

More terms from Jean-François Alcover, Oct 17 2013
Showing 1-6 of 6 results.