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 43 results. Next

A237658 Positive integers m with pi(m) and pi(m^2) both prime, where pi(.) is given by A000720.

Original entry on oeis.org

6, 17, 33, 34, 41, 59, 60, 69, 109, 110, 111, 127, 157, 161, 246, 287, 335, 353, 367, 368, 404, 600, 709, 711, 713, 718, 740, 779, 804, 1153, 1162, 1175, 1437, 1472, 1500, 1526, 1527, 1679, 1729, 1742, 1787, 1826, 2028, 2082, 2104, 2223, 2422, 2616, 2649, 2651
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 10 2014

Keywords

Comments

The conjecture in A237657 implies that this sequence has infinitely many terms.
For primes in this sequence, see A237659.

Examples

			a(1) = 6 since pi(6) = 3 and pi(6^2) = 11 are both prime, but none of pi(1) = 0, pi(2) = 1, pi(3^2) = 4, pi(4^2) = 6 and pi(5^2) = 9 is prime.
		

Crossrefs

Programs

  • Mathematica
    p[m_]:=PrimeQ[PrimePi[m]]&&PrimeQ[PrimePi[m^2]]
    n=0;Do[If[p[m],n=n+1;Print[n," ",m]],{m,1,1000}]
  • PARI
    isok(n) = isprime(primepi(n)) && isprime(primepi(n^2)); \\ Michel Marcus, Apr 28 2018

A262976 Number of ordered ways to write n as 2^x + y^2 + pi(z^2) with x >= 0, y >= 0 and z > 0, where pi(m) denotes the number of primes not exceeding m.

Original entry on oeis.org

1, 2, 2, 3, 4, 4, 4, 6, 4, 6, 6, 7, 6, 7, 5, 6, 10, 5, 9, 10, 7, 7, 9, 9, 4, 12, 10, 9, 8, 7, 10, 9, 10, 7, 15, 10, 6, 13, 10, 9, 10, 16, 10, 10, 9, 8, 15, 9, 8, 15, 12, 12, 7, 12, 11, 14, 12, 8, 16, 6, 10, 11, 14, 8, 11, 17, 10, 16, 9, 13, 16, 15, 8, 18, 13, 10, 14, 10, 12, 16, 12, 13, 18, 11, 9, 17, 17, 9, 15, 16, 15, 9, 12, 12, 17, 12, 9, 21, 10, 11
Offset: 1

Views

Author

Zhi-Wei Sun, Oct 05 2015

Keywords

Comments

Conjecture: (i) a(n) > 0 for all n > 0.
(ii) Each positive integer can be written as 2^x + pi(y^2) + pi(z^2) with x >= 0, y > 0 and z > 0.

Examples

			a(1) = 1 since 1 = 2^0 + 0^2 + pi(1^2).
a(2) = 2 since 2 = 2^0 + 1^2 + pi(1^2) = 2 + 0^2 + pi(1^2).
a(3) = 2 since 3 = 2^0 + 0^2 + pi(2^2) = 2 + 1^2 + pi(1^2).
		

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
    SQ[n_]:=IntegerQ[Sqrt[n]]
    f[n_]:=PrimePi[n^2]
    Do[r=0;Do[If[f[x]>=n,Goto[aa]];Do[If[2^y>n-f[x],Goto[bb]];If[SQ[n-f[x]-2^y],r=r+1],{y,0,Log[2,n-f[x]]}];Label[bb];Continue,{x,1,n}];Label[aa];Print[n," ",r];Continue,{n,1,100}]

A263319 a(n) = pi(n^2)*phi(n)/2, where pi(x) denotes the number of primes not exceeding x, and phi(.) is Euler's totient function given by A000010.

Original entry on oeis.org

0, 1, 4, 6, 18, 11, 45, 36, 66, 50, 150, 68, 234, 132, 192, 216, 488, 198, 648, 312, 510, 460, 1089, 420, 1140, 732, 1161, 822, 2044, 616, 2430, 1376, 1810, 1528, 2400, 1260, 3942, 2052, 2880, 2008, 5260, 1644, 5943, 2950, 3672, 3509, 7567, 2736, 7497, 3670
Offset: 1

Views

Author

Zhi-Wei Sun, Oct 14 2015

Keywords

Comments

Conjecture: (i) All the terms of this sequence are pairwise distinct.
(ii) All the numbers phi(n)*pi(n*(n-1)) (n = 1,2,3,...) are pairwise distinct.
(iii) All the numbers phi(n^2)*pi(n^2) = n*phi(n)*pi(n^2) (n = 1,2,3,...) are pairwise distinct.
We have checked this conjecture via Mathematica. For example, we have verified that a(n) (n = 1..4*10^5) are indeed pairwise distinct.
See also A263325 for a similar conjecture.

Examples

			a(1) = 0 since pi(1^2)*phi(1)/2 = 0*1/2 = 0.
a(2) = 1 since pi(2^2)*phi(2)/2 = 2*1/2 = 1.
a(3) = 4 since pi(3^2)*phi(3)/2 = 4*2/2 = 4.
		

Crossrefs

Programs

  • Magma
    [#PrimesUpTo(n^2)*EulerPhi(n)/2: n in [1..80]]; // Vincenzo Librandi, Oct 15 2015
  • Mathematica
    a[n_]:=a[n]=PrimePi[n^2]*EulerPhi[n]/2
    Do[Print[n," ",a[n]],{n,1,50}]
  • PARI
    a(n) = primepi(n^2)*eulerphi(n)/2; \\ Michel Marcus, Oct 15 2015
    

A194189 Number of primes between the n-th triangular number and the n-th square.

Original entry on oeis.org

0, 0, 1, 2, 3, 3, 6, 7, 8, 9, 12, 13, 15, 17, 18, 22, 25, 27, 30, 32, 35, 38, 41, 43, 48, 52, 55, 58, 62, 64, 68, 73, 79, 83, 86, 89, 93, 97, 103, 110, 114, 120, 123, 129, 132, 139, 141, 149, 157, 162, 162, 173, 183, 186, 192, 195, 198, 207, 213, 222, 229
Offset: 1

Views

Author

Reinhard Zumkeller, Nov 01 2011

Keywords

Comments

a(n) = A038107(n) - A111208(n).

Examples

			a(10) = #{59,61,67,71,73,79,83,89,97} = 9;
a(11) = #{67,71,73,79,83,89,97,101,103,107,109,113} = 12;
a(12) = #{79,83,89,97,101,103,107,109,113,127,131,137,139} = 13.
		

Crossrefs

Programs

  • Haskell
    a194189 n = sum $ map a010051 [n*(n+1) `div` 2 + 1 .. n^2 - 1]
  • Mathematica
    Table[PrimePi[n^2] - PrimePi[n*(n+1)/2], {n, 100}] (* T. D. Noe, Nov 01 2011 *)
    PrimePi[#[[2]]]-PrimePi[#[[1]]]&/@Module[{nn=70},Thread[{Accumulate[ Range[ nn]],Range[nn]^2}]] (* Harvey P. Dale, Aug 21 2019 *)

A237659 Primes p with pi(p) and pi(p^2) both prime, where pi(.) is given by A000720.

Original entry on oeis.org

17, 41, 59, 109, 127, 157, 353, 367, 709, 1153, 1787, 3319, 3407, 3911, 5851, 6037, 6217, 6469, 8389, 9103, 9319, 10663, 13709, 14107, 14591, 15683, 18433, 19463, 19577, 20107, 21727, 23209, 27809, 29383, 32797, 35023, 36251, 36599, 38351, 39239
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 11 2014

Keywords

Comments

This is a subsequence of A237658.
Conjecture: The sequence has infinitely many terms.

Examples

			a(1) = 17 with pi(17) = 7 and pi(17^2) = 61 both prime.
a(2) = 41 with pi(41) = 13 and pi(41^2) = 263 both prime.
		

Crossrefs

Programs

  • Mathematica
    p[m_]:=PrimeQ[PrimePi[m^2]]
    n=0;Do[If[p[Prime[Prime[k]]],n=n+1;Print[n," ",Prime[Prime[k]]]],{k,1,1000}]
    Select[Prime[Range[4500]],AllTrue[{PrimePi[#],PrimePi[#^2]},PrimeQ]&] (* Harvey P. Dale, May 10 2025 *)

A263325 a(n) = sigma(n)*pi(n^2), where sigma(n) is the sum of all (positive) divisors of n, and pi(x) is the number of primes not exceeding x.

Original entry on oeis.org

0, 6, 16, 42, 54, 132, 120, 270, 286, 450, 360, 952, 546, 1056, 1152, 1674, 1098, 2574, 1440, 3276, 2720, 3312, 2376, 6300, 3534, 5124, 5160, 7672, 4380, 11088, 5184, 10836, 8688, 10314, 9600, 19110, 8322, 13680, 13440, 22590, 11046, 26304, 12452, 24780, 23868, 22968, 15792, 42408, 20349, 34131
Offset: 1

Views

Author

Zhi-Wei Sun, Oct 14 2015

Keywords

Comments

Conjecture: (i) All the terms of this sequence are pairwise distinct.
(ii) All the numbers sigma(n)*pi(n*(n+1)) (n = 1,2,3,...) are pairwise distinct.
(iii) All the numbers n*sigma(n)*pi(n^2) (n = 1,2,3,...) are pairwise distinct, and all the numbers sigma(n^2)*pi(n^2) (n = 1,2,3,...) are also pairwise distinct.
(iv) All the numbers n*phi(n)*sigma(n^2) = phi(n^2)*sigma(n^2) (n = 1,2,3,...) are pairwise distinct, where phi(.) is Euler's totient function.
We have verified that the terms a(n) (n = 1..4*10^5) are indeed pairwise distinct.
See also A263319 for a similar conjecture.

Examples

			a(1) = 0 since sigma(1)*pi(1^2) = 1*0 = 0.
a(2) = 6 since sigma(2)*pi(2^2) = 3*2 = 6.
		

Crossrefs

Programs

  • Magma
    [#PrimesUpTo(n^2)*SumOfDivisors(n): n in [1..80]]; // Vincenzo Librandi, Oct 15 2015
  • Mathematica
    a[n_]:=a[n]=DivisorSigma[1,n]*PrimePi[n^2]
    Do[Print[n," ",a[n]],{n,1,50}]
  • PARI
    a(n) = sigma(n)*primepi(n^2); \\ Michel Marcus, Oct 15 2015
    

A139328 Sums of rows of the triangle in A139325.

Original entry on oeis.org

0, 3, 6, 10, 14, 19, 24, 30, 36, 45, 52, 60, 67, 76, 86, 96, 105, 117, 127, 138, 151, 162, 176, 189, 203, 216, 230, 246, 262, 277, 292, 308, 325, 343, 362, 376, 398, 417, 435, 451, 473, 491, 515, 535, 557, 579, 599, 622, 646, 668, 691, 712, 737, 764, 788, 815
Offset: 1

Views

Author

Reinhard Zumkeller, Apr 14 2008

Keywords

Comments

a(n) = Sum_{k=1..n} A139325(n,k).

Examples

			a(4) = #{3,5,7}+#{11,13}+#{17,19,23}+#{29,31} = 3+2+3+2 = 10:
..1 ...3 ...5 ...7 ... primes in first row = {3,5,7},
..9 ..11 ..13 ..15 ... primes in 2nd row = {11,13},
.17 ..19 ..21 ..23 ... primes in 3rd row = {17,19,23},
.25 ..27 ..29 ..31 ... primes in 4th row = {29,31}.
		

Crossrefs

Formula

a(n) = A000720(2*n^2 - 1) - 1.

A161182 Successive differences between positions of squares in list of nonprimes.

Original entry on oeis.org

1, 1, 3, 5, 6, 9, 9, 12, 13, 16, 16, 19, 20, 22, 25, 25, 26, 30, 31, 33, 34, 36, 38, 41, 40, 43, 46, 47, 48, 51, 53, 53, 56, 57, 60, 61, 64, 66, 65, 68, 69, 72, 76, 75, 78, 78, 83, 82, 82, 89, 90, 88, 89, 95, 96, 100, 101, 98, 104, 103, 105, 110, 108, 112, 115, 115, 118, 120
Offset: 1

Views

Author

Daniel Tisdale, Jun 05 2009

Keywords

Crossrefs

Cf. A078435, sequence of positions of squares in sequence of nonprimes.

Programs

Formula

a(n) = A078435(n) - A078435(n-1). - R. J. Mathar, Jun 22 2009

Extensions

Corrected and extended by R. J. Mathar, Jun 22 2009

A220506 Number of primes <= n-th quarter-square.

Original entry on oeis.org

0, 0, 1, 2, 3, 4, 5, 6, 8, 9, 10, 11, 13, 15, 16, 18, 20, 22, 24, 25, 29, 30, 32, 34, 36, 39, 42, 44, 46, 48, 52, 54, 58, 61, 62, 66, 68, 72, 75, 78, 81, 85, 89, 92, 96, 99, 101, 105, 109, 114, 118, 122, 126, 129, 133, 137, 141, 146, 150, 154, 158, 162, 167, 172, 177, 181, 187, 191, 195, 200
Offset: 1

Views

Author

Omar E. Pol, Feb 05 2013

Keywords

Crossrefs

Partial sums of A220492. A bisection is A038107, n >= 1.

Programs

  • Mathematica
    Table[PrimePi[n^2/4], {n, 75}] (* Alonso del Arte, Feb 05 2013 *)

Formula

a(n) = A000720(A002620(n)), n >= 1.

A237687 Primes p with pi(p), pi(pi(p)) and pi(p^2) all prime, where pi(.) is given by A000720.

Original entry on oeis.org

59, 127, 709, 1153, 1787, 9319, 13709, 19577, 32797, 35023, 39239, 40819, 53353, 62921, 75269, 90023, 161159, 191551, 218233, 228451, 235891, 238339, 239087, 272999, 289213, 291619, 339601, 439357, 500741, 513683
Offset: 1

Views

Author

Zhi-Wei Sun, Feb 11 2014

Keywords

Comments

This is a subsequence of A237659.
Conjecture: The sequence has infinitely many terms.

Examples

			a(1) = 59 with 59, pi(59) = 17, pi(pi(59)) = pi(17) = 7 and pi(59^2) = 487 all prime.
		

Crossrefs

Programs

  • Mathematica
    p[m_]:=PrimeQ[PrimePi[m^2]]
    n=0;Do[If[p[Prime[Prime[Prime[k]]]],n=n+1;Print[n," ",Prime[Prime[Prime[k]]]]],{k,1,1000}]
Previous Showing 21-30 of 43 results. Next