|
|
A329242
|
|
a(n) = Pi(8,3)(n) + Pi(8,5)(n) + Pi(8,7)(n) - 3*Pi(8,1)(n), where Pi(a,b)(x) denotes the number of primes in the arithmetic progression a*k + b less than or equal to x.
|
|
2
|
|
|
0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 4, 4, 5, 5, 5, 5, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 7, 7, 7, 7, 7, 7, 8, 8, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 11, 11, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 10
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,5
|
|
COMMENTS
|
In general, assuming the strong form of the Riemann Hypothesis, if 0 < a, b < k are integers, gcd(a, k) = gcd(b, k) = 1, a is a quadratic residue and b is a quadratic nonresidue mod k, then Pi(k,b)(n) > Pi(k,a)(n) occurs more often than not. This phenomenon is called "Chebyshev's bias". (See Wikipedia link and especially the links in A007350.) [Edited by Peter Munn, Nov 19 2023]
Define the "Chebyshev's bias sequence mod k" to be sequence q(n), where q(n) = Sum_{b is a quadratic nonresidue mod k, gcd(b, k) = 1} Pi(k,b)(n) - (r-1)*(Sum_{a is a quadratic residue mod k, gcd(a, k) = 1} Pi(k,a)(n)), r is the number of solutions to x^2 == 1 (mod n), then this sequence is the "Chebyshev's bias sequence mod 8". Also the initial terms are nonnegative integers, a(n) is negative for some n ~ 10^28.127. See page 21 of the paper in Journal of Number Theory in the Links section below.
|
|
LINKS
|
Andrew Granville and Greg Martin, Prime number races, Amer. Math. Monthly, 113 (No. 1, 2006), 1-33.
|
|
EXAMPLE
|
Below 2000000, there are 37116 primes congruent to 1 mod 8, 37261 primes congruent to 3 mod 8, 37300 primes congruent to 5 mod 8 and 37255 primes congruent to 7 mod 8, so a(2000000) = 37261 + 37300 + 37255 - 3*37116 = 468.
|
|
PROG
|
(PARI) a(n) = my(k=0); for(p=1, n, if(isprime(p)&&p>2, if(p%8==1, k-=3, k++))); k
|
|
CROSSREFS
|
|
|
KEYWORD
|
sign
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|