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.

A238278 a(n) = |{0 < k < n: the number of primes in the interval ((k-1)*n, k*n] and the number of primes in the interval (k*n, (k+1)*n] are both prime}|.

Original entry on oeis.org

0, 0, 0, 1, 1, 3, 3, 2, 7, 6, 8, 4, 9, 4, 9, 8, 1, 1, 3, 5, 4, 6, 3, 4, 4, 6, 3, 11, 8, 8, 7, 7, 12, 9, 4, 8, 9, 12, 8, 12, 8, 7, 6, 7, 7, 9, 4, 8, 9, 11, 5, 6, 3, 11, 2, 5, 14, 8, 8, 11, 2, 1, 11, 4, 6, 4, 5, 4, 1, 9, 5, 2, 10, 5, 4, 9, 10, 11, 6, 7
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 22 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 3.
(ii) For any integer n > 3, there is a prime p < n such that the number of primes in the interval ((p-1)*n, p*n) is a prime.
We have verified part (i) for n up to 150000.
See also A238277 and A238281 for related conjectures.

Examples

			a(17) = 1 since the interval (9*17, 10*17] contains exactly 3 primes with 3 prime, and the interval (10*17, 11*17] contains exactly 3 primes with 3 prime.
		

Crossrefs

Programs

  • Mathematica
    d[k_,n_]:=PrimePi[k*n]-PrimePi[(k-1)n]
    a[n_]:=Sum[If[PrimeQ[d[k,n]]&&PrimeQ[d[k+1,n]],1,0],{k,1,n-1}]
    Table[a[n],{n,1,80}]

A238281 a(n) = |{0 < k < n: the two intervals (k*n, (k+1)*n) and ((k+1)*n, (k+2)*n) contain the same number of primes}|.

Original entry on oeis.org

0, 1, 2, 1, 2, 3, 3, 1, 5, 2, 4, 4, 8, 3, 7, 4, 4, 4, 2, 3, 7, 3, 10, 4, 12, 7, 7, 15, 7, 9, 8, 5, 8, 9, 11, 8, 8, 10, 8, 4, 10, 10, 10, 11, 7, 10, 8, 11, 8, 8, 9, 9, 8, 11, 7, 8, 13, 10, 8, 14, 13, 4, 14, 8, 11, 12, 14, 12, 8, 10, 16, 12, 16, 12, 14, 19, 11, 14, 8, 9
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 22 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1. Moreover, if n > 1 is not equal to 8, then there is a positive integer k < n with 2*k + 1 prime such that the two intervals ((k-1)*n, k*n) and (k*n, (k+1)*n) contain the same number of primes.
(ii) For any integer n > 4, there is a positive integer k < prime(n) such that all the three intervals (k*n, (k+1)*n), ((k+1)*n, (k+2)*n), ((k+2)*n, (k+3)*n) contain the same number of primes, i.e., pi(k*n), pi((k+1)*n), pi((k+2)*n), pi((k+3)*n) form a 4-term arithmetic progression.

Examples

			a(8) = 1 since each of the two intervals (7*8, 8*8) and (8*8, 9*8) contains exactly two primes.
		

Crossrefs

Programs

  • Mathematica
    d[k_,n_]:=PrimePi[(k+1)*n]-PrimePi[k*n]
    a[n_]:=Sum[If[d[k,n]==d[k+1,n],1,0],{k,1,n-1}]
    Table[a[n],{n,1,80}]

A238165 Number of pairs {j, k} with 0 < j < k <= n such that pi(j*n) divides pi(k*n), where pi(.) is given by A000720.

Original entry on oeis.org

0, 1, 1, 2, 3, 2, 1, 5, 5, 5, 3, 5, 12, 5, 5, 7, 3, 2, 12, 7, 8, 9, 9, 6, 6, 11, 9, 12, 9, 15, 12, 12, 13, 7, 16, 12, 18, 15, 16, 11, 8, 8, 13, 15, 20, 13, 7, 15, 13, 7, 18, 7, 18, 15, 11, 15, 15, 12, 15, 17, 6, 18, 17, 16, 11, 15, 9, 18, 15, 13
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 19 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1.
(ii) For any integer n > 4, the sequence pi(k*n)^(1/k) (k = 1, ..., n) is strictly decreasing.
See also A238224 for a refinement of part (i) of this conjecture.

Examples

			a(5) = 3 since pi(1*5) = 3 divides both pi(3*5) = 6 and pi(5*5) = 9, and pi(2*5) = 4 divides pi(4*5) = 8.
a(7) = 1 since pi(1*7) = 4 divides pi(3*7) = 8.
		

Crossrefs

Programs

  • Mathematica
    m[k_,j_]:=Mod[PrimePi[k],PrimePi[j]]==0
    a[n_]:=Sum[If[m[k*n,j*n],1,0],{k,2,n},{j,1,k-1}]
    Do[Print[n," ",a[n]],{n,1,70}]
Showing 1-3 of 3 results.