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

A079648 Number of primes between n^2 and n^3.

Original entry on oeis.org

0, 0, 2, 5, 12, 21, 36, 53, 79, 107, 143, 187, 235, 288, 356, 428, 510, 595, 699, 810, 929, 1062, 1206, 1358, 1528, 1707, 1898, 2098, 2323, 2561, 2807, 3066, 3340, 3636, 3946, 4283, 4611, 4975, 5351, 5755, 6162, 6587, 7034, 7506, 7998, 8504, 9042, 9587, 10157
Offset: 0

Views

Author

Cino Hilliard, Jan 22 2003, Aug 23 2007

Keywords

Comments

There is always a prime between n^2 and n^3 for n > 1. For n = 2, primes 5 and 7 are between 4 and 8. For n > 2, we have the number of primes between n^2 and n^3 ~ n^3/log(n^3) - n^2/log(n^2) = n^2*(2n-3)/(6*log(n)) -> infinity as n -> infinity. A corollary to this is that the number of primes is infinite.
Number of primes in row n of the triangle in A214084;
a(n) = Sum_{m=n^2..n^3} A010051(m). - Reinhard Zumkeller, Jul 07 2012

Examples

			For n = 4 4^2 = 16, 4^3 = 64. there are 12 primes between 16 and 64 namely, 17,19,23,29,31,37,41,43,47,53,59,61.
		

Programs

  • Haskell
    a079648 = sum . map a010051 . a214084_row  -- Reinhard Zumkeller, Jul 07 2012
  • PARI
    /* Count primes between x^2 and x^3. */ primex2x3(m,n) = { local(x,y,c); for(x=m,n, c=0; for(y=x^2,x^3, if(ispseudoprime(y),c++) ); print(c) ) }
    

Extensions

Edited by N. J. A. Sloane, Aug 22 2009 at the suggestion of Richard Stanley

A214085 n^2 * (n^4 - n^2 + n + 1) / 2.

Original entry on oeis.org

0, 1, 30, 342, 1960, 7575, 22806, 57820, 129312, 262845, 495550, 879186, 1483560, 2400307, 3747030, 5671800, 8358016, 12029625, 16956702, 23461390, 31924200, 42790671, 56578390, 73884372, 95392800, 121883125, 154238526, 193454730, 240649192, 297070635
Offset: 0

Views

Author

Reinhard Zumkeller, Jul 07 2012

Keywords

Comments

Row sums of the triangle in A214084.

Programs

  • Haskell
    a214085 n = n^2 * (n^4 - n^2 + n + 1) `div` 2
    
  • Magma
    [n^2*(n^4-n^2+n+1)/2: n in [0..29]]; // Bruno Berselli, Jul 09 2012
  • Mathematica
    Table[n^2 (n^4 - n^2 + n + 1)/2, {n, 0, 29}] (* Bruno Berselli, Jul 09 2012 *)
    LinearRecurrence[{7,-21,35,-35,21,-7,1},{0,1,30,342,1960,7575,22806},40] (* Harvey P. Dale, Dec 12 2012 *)

Formula

a(n) = n * A000217(n) * A100104(n).
a(n) = A000217(A000578(n)) - A000217(A000290(n) - 1).
G.f.: x*(1+23*x+153*x^2+161*x^3+22*x^4)/(1-x)^7. - Bruno Berselli, Jul 09 2012
a(0)=0, a(1)=1, a(2)=30, a(3)=342, a(4)=1960, a(5)=7575, a(6)=22806, a(n)=7*a(n-1)-21*a(n-2)+35*a(n-3)-35*a(n-4)+21*a(n-5)-7*a(n-6)+a(n-7). - Harvey P. Dale, Dec 12 2012
Showing 1-2 of 2 results.