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

A217658 In A217564, prime(i), where i is the index of the start of the first exactly-n terms between successive zeros.

Original entry on oeis.org

13, 19, 3, 73, 523, 6581, 10753, 231643, 387679, 43103, 255259, 55457, 28751773, 328934789, 278689963, 784284211, 4440915607, 8340839629, 30651695947
Offset: 1

Views

Author

Hans Havermann, Oct 09 2012

Keywords

Examples

			The first exactly-4 terms between successive zeros in A217564 are '1,1,1,1' beginning at index 21, so a(4) = prime(21) = 73.
The first exactly-5 terms between successive zeros in A217564 are '2,1,1,1,1' beginning at index 99, so a(5) = prime(99) = 523.
		

Crossrefs

Cf. A217564.

A102820 Number of primes between 2*prime(n) and 2*prime(n+1), where prime(n) is the n-th prime.

Original entry on oeis.org

1, 1, 2, 2, 1, 2, 1, 2, 2, 2, 3, 1, 1, 1, 3, 3, 0, 2, 2, 0, 3, 1, 2, 4, 2, 0, 1, 0, 1, 6, 1, 3, 1, 3, 0, 3, 1, 1, 1, 3, 1, 3, 1, 1, 1, 4, 4, 1, 1, 2, 1, 1, 3, 2, 2, 0, 1, 1, 1, 1, 3, 6, 2, 0, 1, 6, 1, 3, 0, 1, 1, 3, 2, 2, 1, 2, 1, 1, 2, 4, 1, 3, 1, 1, 2, 1, 2, 1, 0, 1, 4, 2, 1, 3, 0, 2, 5, 0, 5, 3, 3, 2, 1, 0, 2
Offset: 1

Views

Author

Ali A. Tanara (tanara(AT)khayam.ut.ac.ir), Feb 27 2005

Keywords

Comments

Number of primes between successive even semiprimes. [Juri-Stepan Gerasimov, May 01 2010]
From Peter Munn, Jun 01 2023: (Start)
First differences of A020900.
A080192 lists prime(n) corresponding to the zero terms.
A104380(k) is prime(n) corresponding to the first occurrence of k as a term.
If a(n) is nonzero, A059786(n) is the smallest and A059788(n+1) the largest of the a(n) enumerated primes. In the tree of primes described in A290183, these primes label the child nodes of prime(n).
Conjecture: the asymptotic proportions of 0's, 1's, ... , k's, ... are 1/3, 2/9, ... , 2^k/3^(k+1), ... .
(End)

Examples

			a(15)=3 because there are 3 primes between the doubles of the 15th and 16th primes, that is between 2*47 and 2*53.
		

Crossrefs

Sequences with related analysis: A020900, A059786, A059788, A080192, A104380, A290183.
Cf. A104272, A080359. [Vladimir Shevelev, Aug 24 2009]
Sequences with similar definitions: A104289, A217564.

Programs

  • Haskell
    a102820 n = a102820_list !! (n-1)
    a102820_list =  map (sum . (map a010051)) $
       zipWith enumFromTo a100484_list (tail a100484_list)
    -- Reinhard Zumkeller, Apr 29 2012
    
  • Mathematica
    Table[PrimePi[2 Prime[n+1]]-PrimePi[2 Prime[n]], {n, 150}] (* Zak Seidov *)
    Differences[PrimePi[2 Prime[Range[110]]]] (* Harvey P. Dale, Oct 29 2022 *)
  • PARI
    a(n) = primepi(2*prime(n+1)) - primepi(2*prime(n)); \\ Michel Marcus, Sep 22 2017

Formula

a(n) = A020900(n+1) - A020900(n). - Peter Munn, Jun 01 2023

Extensions

More terms from Zak Seidov, Feb 28 2005

A079952 Number of primes less than prime(n)/2.

Original entry on oeis.org

0, 0, 1, 2, 3, 3, 4, 4, 5, 6, 6, 7, 8, 8, 9, 9, 10, 10, 11, 11, 11, 12, 13, 14, 15, 15, 15, 16, 16, 16, 18, 18, 19, 19, 21, 21, 21, 22, 23, 23, 24, 24, 24, 24, 25, 25, 27, 29, 30, 30, 30, 30, 30, 30, 31, 32, 32, 32, 33, 34, 34, 34, 36, 36, 36, 37, 38, 39, 40
Offset: 1

Views

Author

Reinhard Zumkeller, Jan 19 2003

Keywords

Comments

Previous name: Number of primes p such that prime(n) mod 2*p < prime(n).
Same as A055930, except for a(2). [Noticed by R. J. Mathar, Dec 15 2008, proved by Andrey Zabolotskiy, Oct 26 2017]

Examples

			n = 6: prime(6) = 13 and 2, 3, 5 are less than 13/2, therefore a(6) = 3.
		

Crossrefs

Programs

Formula

A079950(n, a(n) + 1) = prime(n).
Where defined, that is for n > 2, prime(a(n)) = A055377(prime(n)). - Peter Munn, Sep 18 2017
0 with partial sums of A217564. - David A. Corneth, Oct 26 2017 (found earlier by Peter Munn).

Extensions

New name from Peter Munn, Sep 18 2017

A215237 Least number k for which primepi(prime(k+1)/2) - primepi(prime(k)/2) = n.

Original entry on oeis.org

1, 2, 30, 259, 429, 4612, 26466, 88110, 31545, 104071, 2775456, 14614604, 15793779, 164082567, 476853784, 495207013, 3613011290, 9032608100, 69827848342
Offset: 0

Views

Author

T. D. Noe, Oct 09 2012

Keywords

Comments

See A215238 and A215239 for prime(a(n)) and the next prime.
Equivalently stated, a(n) is least k such that there are exactly n primes between prime(k)/2 and prime(k+1)/2. - Peter Munn, May 20 2019

Examples

			For n = 2, the consecutive primes are 113 and 127; there are two primes between 56.5 and 63.5.  For n = 3, the consecutive primes are 1637 and 1657; there are three primes between 818.5 and 828.5.
		

Crossrefs

Programs

  • Mathematica
    t = Table[PrimePi[Prime[n+1]/2] - PrimePi[Prime[n]/2], {n, 100000}]; Flatten[Table[Position[t, n, 1, 1], {n, 0, 8}]]

Extensions

a(14)-a(18) from Donovan Johnson, Oct 13 2012

A217864 Number of prime numbers between floor(n*log(n)) and (n + 1)*log(n + 1).

Original entry on oeis.org

0, 2, 2, 2, 0, 2, 1, 2, 2, 1, 1, 2, 0, 1, 2, 1, 0, 1, 1, 2, 1, 1, 1, 1, 1, 0, 1, 1, 2, 1, 2, 1, 0, 0, 1, 1, 1, 1, 0, 2, 0, 1, 1, 1, 1, 1, 1, 0, 2, 2, 0, 0, 1, 0, 1, 2, 1, 1, 1, 0, 1, 1, 1, 2, 1, 2, 2, 0, 1, 0, 1, 3, 2, 0, 0, 1, 1, 0, 2, 1, 1, 0, 1, 1, 2, 1, 1
Offset: 1

Views

Author

Jon Perry, Oct 13 2012

Keywords

Comments

Conjecture: a(n) is unbounded.
If Riemann Hypothesis is true, this is probably true as the PNT is generally a lower bound for Pi(n).
Conjecture: a(n)=0 infinitely often.
The first conjecture follows from Dickson's conjecture. The second conjecture follows from a theorem of Brauer & Zeitz on prime gaps. - Charles R Greathouse IV, Oct 15 2012

Examples

			log(1)=0 and 2*log(2) ~ 1.38629436112. Hence, a(1)=0.
Floor(2*log(2)) = 1 and 3*log(3) ~ 3.295836866. Hence, a(2)=2.
		

References

  • A. Brauer and H. Zeitz, Über eine zahlentheoretische Behauptung von Legendre, Sitz. Berliner Math. Gee. 29 (1930), pp. 116-125; cited in Erdos 1935.

Crossrefs

An alternate version of A166712.

Programs

  • JavaScript
    function isprime(i) {
    if (i==1) return false;
    if (i==2) return true;
    if (i%2==0) return false;
    for (j=3;j<=Math.floor(Math.sqrt(i));j+=2)
    if (i%j==0) return false;
    return true;
    }
    for (i=1;i<88;i++) {
    c=0;
    for (k=Math.floor(i*Math.log(i));k<=(i+1)*Math.log(i+1);k++) if (isprime(k)) c++;
    document.write(c+", ");
    }
    
  • Mathematica
    Table[s = Floor[n*Log[n]]; PrimePi[(n+1) Log[n+1]] - PrimePi[s] + Boole[PrimeQ[s]], {n, 100}] (* T. D. Noe, Oct 15 2012 *)
  • PARI
    a(n)=sum(k=n*log(n)\1,(n+1)*log(n+1),isprime(k)) \\ Charles R Greathouse IV, Oct 15 2012
Showing 1-5 of 5 results.