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}]

A237656 Least positive integer m such that {A000720(k^2): k = 1, ..., m} contains a complete system of residues modulo n, or 0 if such a number m does not exist.

Original entry on oeis.org

1, 5, 3, 6, 8, 10, 18, 17, 30, 41, 28, 43, 29, 33, 43, 27, 66, 47, 98, 105, 155, 114, 113, 100, 49, 62, 118, 146, 85, 125, 80, 117, 74, 101, 167, 137, 168, 282, 176, 287, 129, 178, 151, 140, 163, 139, 262, 267, 277, 234, 285, 188, 203, 163, 192, 239, 188, 241, 252, 252
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 10 2014

Keywords

Comments

Conjecture: a(n) is always positive. Moreover, a(n) < 2*prime(n+1) - 2 for all n > 0.
Note that a(21) = 155 = 2*prime(22) - 3.

Examples

			a(5) = 8 since {A000720(k^2): k = 1, ..., 8} = {0, 2, 4, 6, 9, 11, 15, 18} contains a complete system of residues modulo 5, but {A000720(k^2): k = 1, ..., 7} contains no integer congruent to 3 modulo 5.
		

Crossrefs

Programs

  • Mathematica
    q[m_,n_]:=Length[Union[Table[Mod[PrimePi[k^2],n],{k,1,m}]]]
    Do[Do[If[q[m,n]==n,Print[n," ",m];Goto[aa]],{m,n,2*Prime[n+1]-3}];
    Print[n," ",0];Label[aa];Continue,{n,1,60}]

A237657 a(n) = |{n < m < 2*n: pi(m) and pi(m^2) are both prime}|, where pi(.) is given by A000720.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Feb 10 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 8.
(ii) For any integer n > 1 there is a prime p <= n such that n + pi(p) is prime. Also, for n > 5 there is a prime p with n < p < 2*n such that pi(p) is prime.
(iii) For each n > 20, there is a prime p with n < p < 2*n such that pi(p^2) is prime.

Examples

			a(4) = 1 since pi(6) = 3 and pi(6^2) = 11 are both prime.
a(10) = 1 since pi(17) = 7 and pi(17^2) = 61 are both prime.
a(17) = 1 since pi(33) = 11 and pi(33^2) = 181 are both prime.
		

Crossrefs

Programs

  • Mathematica
    q[n_]:=PrimeQ[PrimePi[n]]&&PrimeQ[PrimePi[n^2]]
    a[n_]:=Sum[If[q[m],1,0],{m,n+1,2n-1}]
    Table[a[n],{n,1,70}]
Showing 1-3 of 3 results.