A074990 Number of primes in the interval (n,3n].
2, 2, 2, 3, 3, 4, 4, 5, 5, 6, 6, 6, 6, 7, 8, 9, 8, 9, 8, 9, 10, 10, 10, 11, 12, 12, 13, 14, 13, 14, 13, 13, 14, 15, 16, 17, 17, 18, 18, 18, 17, 17, 17, 18, 18, 19, 19, 19, 19, 20, 21, 21, 21, 21, 22, 23, 23, 24, 23, 24, 24, 24, 24, 25, 26, 27, 27, 27, 27, 27, 27, 27, 26, 26, 27, 28
Offset: 1
Keywords
Examples
a(4) = 3 because between 4 and 12 there are 3 primes: 5, 7, 11; a(7) = 4 because between 7 and 21 there are 4 primes: 11, 13, 17, 19.
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..10000
- M. Das, G. Paul, Generalization of Bertrand's Postulate and Upper Bounds on the Number of Primes in Certain Intervals, arXiv:1710.09891 [math.NT], 2017.
Programs
-
Maple
A074990 := proc(n) numtheory[pi](3*n)-numtheory[pi](n) ; end proc: # R. J. Mathar, Nov 03 2017
-
Mathematica
s=3; a[n_] := PrimePi[s*n]-PrimePi[n]
Comments