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.

Previous Showing 21-30 of 30 results.

A260197 Least prime p such that pi(p*n) = prime(q*n) for some prime q, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

5, 277, 29, 17, 43, 103, 53, 31, 1571, 3089, 37, 593, 881, 3023, 277, 9257, 47, 1949, 9137, 311, 17011, 1039, 53, 59, 2153, 15331, 3617, 631, 44867, 61, 17351, 661, 821, 2339, 683, 1201, 34759, 62687, 20327, 59369, 71, 883, 40189, 9187, 1879, 7669, 2767, 3931, 8867, 8081, 79, 12401, 139, 4787, 6367, 277, 2903, 23671, 32839, 3659
Offset: 1

Views

Author

Zhi-Wei Sun, Jul 19 2015

Keywords

Comments

Conjecture: a(n) exists for any n > 0. Also, for any n > 0, there are primes p and q such that pi(p*n) = q*n.

Examples

			 a(1) = 5 since pi(5*1) = 3 = prime(2*1) with 2 and 5 both prime.
a(2) = 277 since pi(277*2) = 101 = prime(13*2) with 13 and 277 both prime.
a(10) = 3089 since pi(3089*10) = 3331 = prime(47*10) with 47 and 3089 both prime.
		

References

  • Zhi-Wei Sun, Problems on combinatorial properties of primes, in: M. Kaneko, S. Kanemitsu and J. Liu (eds.), Number Theory: Plowing and Starring through High Wave Forms, Proc. 7th China-Japan Seminar (Fukuoka, Oct. 28 - Nov. 1, 2013), Ser. Number Theory Appl., Vol. 11, World Sci., Singapore, 2015, pp. 169-187.

Crossrefs

Programs

  • Mathematica
    PQ[n_,p_]:=PrimeQ[p]&&PrimeQ[PrimePi[p]/n]
    Do[k=0;Label[aa];k=k+1;If[PQ[n,PrimePi[Prime[k]*n]],Goto[bb],Goto[aa]];Label[bb];Print[n, " ", Prime[k]];Continue,{n,1,60}]

A237838 a(n) = |{0 < k <= n: the number of Sophie Germain primes among 1, ..., k*n is a Sophie Germain prime}|.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Feb 14 2014

Keywords

Comments

Conjecture: a(n) > 0 for all n > 1.
See also A237839 for a similar conjecture involving twin primes.

Examples

			a(20) = 1 since 11 is a Sophie Germain prime, and there are exactly 11 Sophie Germain primes among 1, ..., 6*20 (namely, they are 2, 3, 5, 11, 23, 29, 41, 53, 83, 89, 113).
		

Crossrefs

Programs

  • Mathematica
    SG[n_]:=PrimeQ[n]&&PrimeQ[2n+1]
    sg[n_]:=Sum[If[PrimeQ[2*Prime[k]+1],1,0],{k,1,PrimePi[n]}]
    a[n_]:=Sum[If[SG[sg[k*n]],1,0],{k,1,n}]
    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}]

A238504 Number of primes p <= n with pi(pi((p-1)*n)) prime, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Mar 06 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 2.
(ii) If n > 92, then pi(p*n) is prime for some prime p <= n. If n > 39, then pi(pi(p*n)) is prime for some p <= n.
See also A238902 for another conjecture involving pi(pi(x)).

Examples

			a(3) = 1 since 3 and pi(pi((3-1)*3)) = pi(pi(6)) = pi(3) = 2 are both prime.
a(20) = 1 since 3 and pi(pi((3-1)*20)) = pi(pi(40)) = pi(12) = 5 are both prime.
a(48) = 1 since 29 and pi(pi((29-1)*48)) = pi(pi(1344)) = pi(217) = 47 are both prime.
		

Crossrefs

Programs

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

A238568 a(n) = |{0 < k < n: n^2 - pi(k*n) is prime}|, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Feb 28 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 1, and a(n) = 1 only for n = 2, 3, 4, 8, 10, 24, 41.
(ii) For any integer n > 6, there is a positive integer k < n with n^2 + pi(k*n) - 1 prime.
(iii) If n > 2, then pi(n^2) - pi(k*n) is prime for some 0 < k < n. If n > 1, then pi(n^2) + pi(k*n) - 1 is prime for some 0 < k < n.

Examples

			a(2) = 1 since 2^2 - pi(1*2) = 4 - 1 = 3 is prime.
a(3) = 1 since 3^2 - pi(1*3) = 9 - 2 = 7 is prime.
a(4) = 1 since 4^2 - pi(3*4) = 16 - 5 = 11 is prime.
a(8) = 1 since 8^2 - pi(4*8) = 64 - 11 = 53 is prime.
a(10) = 1 since 10^2 - pi(6*10) = 100 - 17 = 83 is prime.
a(24) = 1 since 24^2 - pi(14*24) = 576 - 67 = 509 is prime.
a(41) = 1 since 41^2 - pi(10*41) = 1681 - 80 = 1601 is prime.
		

Crossrefs

Programs

  • Mathematica
    p[k_,n_]:=PrimeQ[n^2-PrimePi[k*n]]
    a[n_]:=Sum[If[p[k,n],1,0],{k,1,n-1}]
    Table[a[n],{n,1,80}]

A238890 a(n) = |{0 < k <= n: prime(k*n) - pi(k*n) is prime}|, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Mar 06 2014

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 0, and a(n) = 1 for no n > 28.
(ii) If n > 7 is not equal to 34, then prime(k*n) + pi(k*n) is prime for some k = 1, ..., n.
The conjecture implies that there are infinitely many primes p with p - pi(pi(p)) (or p + pi(pi(p))) prime.

Examples

			a(5) = 1 since prime(3*5) - pi(3*5) = 47 - 6 = 41 is prime.
a(28) = 1 since prime(18*28) - pi(18*28) = prime(504) - pi(504) = 3607 - 96 = 3511 is prime.
		

Crossrefs

Programs

  • Mathematica
    p[k_]:=PrimeQ[Prime[k]-PrimePi[k]]
    a[n_]:=Sum[If[p[k*n],1,0],{k,1,n}]
    Table[a[n],{n,1,80}]

A239328 Number of primes p < n with pi(p*n) - pi((p-1)n) prime, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Mar 16 2014

Keywords

Comments

Conjecture: a(n) > 0 for all n > 3. Also, for any integer n > 4, there is a prime p < n with pi((p+1)*n) - pi(p*n) prime.
We have verified that a(n) > 0 for all n = 4, ..., 7*10^5.

Examples

			a(4) = 1 since 2 and pi(2*4) - pi(1*4) = 4 - 2 = 2 are both prime.
a(5) = 1 since 3 and pi(3*5) - pi(2*5) = 6 - 4 = 2 are both prime.
a(17) = 1 since 11 and pi(11*17) - pi(10*17) = 42 - 39 = 3 are both prime.
a(47) = 1 since 37 ad pi(37*47) - pi(36*47) = 270 - 263 = 7 are both prime.
		

Crossrefs

Programs

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

A239330 Number of odd primes p <= n with pi(n*(p+1)/2) - pi(n*(p-1)/2) prime, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Mar 16 2014

Keywords

Comments

Conjecture: a(n) > 0 for all n > 3, and a(n) = 1 only for n = 4, 5, 17.
We have verified this for n up to 3*10^5.

Examples

			a(4) = 1 since 3 and pi(4*(3+1)/2) - pi(4*(3-1)/2) = pi(8) - pi(4) = 4 - 2 = 2 are both prime.
a(5) = 1 since 5 and pi(5*(5+1)/2) - pi(5*(5-1)/2) = pi(15) - pi(10) = 6 - 4 = 2 are both prime.
a(17) = 1 since 11 and pi(17*(11+1)/2) - pi(17*(11-1)/2) = pi(102) - pi(85) = 26 - 23 = 3 are both prime.
		

Crossrefs

Programs

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

A238703 a(n) = |{0 < k < n: floor(k*n/3) is prime}|.

Original entry on oeis.org

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

Views

Author

Zhi-Wei Sun, Mar 03 2014

Keywords

Comments

Conjecture: If n > m > 0 with n not divisible by m, then floor(k*n/m) is prime for some 0 < k < n.

Examples

			a(4) = 1 since floor(2*4/3) = 2 is prime.
If p is a prime, then a(3*p) = 1 since floor(k*3p/3) = k*p is prime only for k = 1. If m > 1 is composite, then a(3*m) = 0 since floor(k*3m/3) = k*m is composite for all k > 0.
		

Crossrefs

Programs

  • Mathematica
    p[n_,k_]:=PrimeQ[Floor[k*n/3]]
    a[n_]:=Sum[If[p[n,k],1,0],{k,1,n-1}]
    Table[a[n],{n,1,80}]

A240604 Primes p with pi(p), pi(2*p), pi(3*p) and pi(4*p) all prime, where pi(x) denotes the number of primes not exceeding x.

Original entry on oeis.org

10909, 67247, 185869, 408379, 511111, 1297061, 1730461, 1732333, 2135347, 2266079, 2316203, 2978917, 3477737, 4337257, 4495739, 4691849, 6108461, 6407971, 6591163, 7462589, 7909507, 8165039, 8298337, 8948509, 11144083, 11961373, 15019049, 16074059, 16732561, 19316263
Offset: 1

Views

Author

Zhi-Wei Sun, Apr 09 2014

Keywords

Comments

Conjecture: For any positive integer n, there are infinitely many primes p with pi(k*p) (k = 1,...,n) all prime.

Examples

			a(1) = 10909 with 10909, pi(10909) = 1327, pi(2*10909) = 2447, pi(3*10909) = 3511 and pi(4*10909) = 4547 all prime.
		

Crossrefs

Programs

  • Mathematica
    p[j_,k_]:=p[j,k]=PrimeQ[PrimePi[j*Prime[Prime[k]]]]
    p[k_]:=p[k]=p[2,k]&&p[3,k]&&p[4,k]
    m=0;Do[If[p[k],m=m+1;Print[m," ",Prime[Prime[k]]]],{k,1,95041}]
Previous Showing 21-30 of 30 results.