A159804 Number of primes q with (2n-1)^2+1 <= q < (2n)^2-(2n-1).
1, 1, 1, 1, 2, 2, 3, 4, 1, 3, 4, 2, 4, 4, 4, 5, 6, 5, 3, 6, 5, 7, 6, 6, 6, 5, 7, 6, 7, 8, 7, 8, 11, 8, 8, 8, 7, 11, 4, 11, 9, 10, 9, 11, 8, 10, 13, 9, 14, 12, 11, 12, 12, 11, 15, 12, 9, 13, 15, 8, 14, 13, 16, 12, 14, 11, 11, 15, 9, 16, 16, 11, 14, 14, 13, 13, 13
Offset: 1
Keywords
Examples
n=1: 2 <= q < 3 => prime 2: a(1)=1; n=5: 82 <= q < 91 => primes 83,89: a(5)=2; n=9: 290 <= q < 307 => prime 293: a(9)=1; n=30: 3482 <= q < 3541 => prime 3491,3499,3511,3517,3527,3529,3533,3539: a(30)=8.
References
- L. E. Dickson, History of the Theory of Numbers, Vol, I: Divisibility and Primality, AMS Chelsea Publ., 1999
- R. K. Guy, Unsolved Problems in Number Theory (2nd ed.) New York: Springer-Verlag, 1994
- P. Ribenboim, The New Book of Prime Number Records. Springer. 1996
Programs
-
PARI
a(n) = if (n==1, 1, primepi((2*n)^2-(2*n-1)-1) - primepi((2*n-1)^2+1)); \\ Michel Marcus, May 18 2020
Extensions
More terms from Michel Marcus, May 18 2020
Comments