TITLE: Is there a von Koch-type theorem for the generalized Riemann hypothesis?
QUESTION [5 upvotes]: Helge von Koch proved in 1901  that the Riemann hypothesis is equivalent to the error term in the prime number theorem having the bound 
$$
\mid\pi(x)-\textrm{li}(x)\mid=O(\sqrt{x} \log x).
$$

Q1: Is von Koch's result (and proof) also valid for the generalized Riemann hypothesis (GRH)?

That is, if a and d are coprime, and $\pi(x,a,d)$ denotes the number of primes in the arithmetic progression $a, a+d, a+2d, \dots$, is GRH equivalent to 
$$
\left|\pi(x,a,d)-\frac{1}{\varphi(d)}\textrm{li}(x)\right|=O(\sqrt{x} \log x)?
$$
The Wikipedia page for GRH states that GRH implies this error term, but is short on references and says nothing about whether the given error term implies GRH.  

Q2: Does anyone know if von Koch's paper has been translated to English; alternatively a reference to the best modern version of proving his result; or perhaps both?

REPLY [13 votes]: As GH from MO and Felipe Voloch have already indicated it is standard to show that $\psi(x;q,a) = x/\phi(q) +O(x^{\frac 12+\epsilon})$ for all reduced residue classes $a\pmod q$ is equivalent to GRH for the characters $\pmod q$.  I want to make the following small (but amusing) refinement:  it is enough to know that $\psi(x;q,1) = x/\phi(q) + O(x^{\frac12+\epsilon})$ and $\psi(x) =x+ O(x^{\frac 12+\epsilon})$ and from these two pieces of information (rather than all $\phi(q)$ residue classes) we can get GRH for all the characters $\pmod q$.   
To see this, note that (starting with Re$(s)>1$) 
$$ 
 -\frac{1}{\phi(q)} 
\sum_{\chi\neq \chi_0} \frac{L^{\prime}}{L}(s,\chi) = \int_1^{\infty} \frac{s}{x^{s+1}} \Big( \psi(x;q,1) - \frac{\psi(x,\chi_0)}{\phi(q)} \Big) dx, 
$$ 
and so by hypothesis, the RHS extends analytically to Re$(s)>1/2$.  Therefore $L(s,\chi) \neq 0$ for all $\chi \neq \chi_0$ and Re$(s)>1/2$.  Finally $\psi(x)=x+O(x^{\frac 12+\epsilon})$ implies RH; thus GRH follows for all the characters $\pmod q$.
Put differently, this shows that the asymptotic $\psi(x;q,1) = \psi(x)/\phi(q) + O(x^{\frac 12+\epsilon})$ implies $\psi(x;q,a) =\psi(x)/\phi(q)+ O(x^{\frac 12+\epsilon})$ for all $(a,q)=1$.

REPLY [8 votes]: The bound you state follows from GRH, see Corollary 13.8 in Montgomery-Vaughan: Multiplicative number theory I. Conversely, the bound you state implies GRH. I provide the proof below. 
Assume that for all coprime pairs $a$ and $d$ we have
$$ E(x,a,d):=\pi(x,a,d)-\frac{\mathrm{li}(x)}{\varphi(d)} = O(\sqrt{x}\log x). $$
Let us introduce
$$ \theta(x,a,d):=\sum_{\substack{p\leq x\\p\equiv a\pmod{d}}} \log p \qquad\text{and}\qquad\psi(x,a,d):=\sum_{\substack{n\leq x\\n\equiv a\pmod{d}}} \Lambda(n). $$
Then
$$\theta(x,a,d) - \frac{x-2}{\varphi(d)} = \int_{2-}^x \log t\ d E(t,a,d) = E(x,a,d)\log x-\int_2^x\frac{E(t,a,d)}{t}dt,$$
whence
$$\psi(x,a,d)=\theta(x,a,d)+O(\sqrt{x}\log x) = \frac{x}{\varphi(d)}+O(\sqrt{x}\log^2 x).$$
As a result, for any nontrivial Dirichlet character $\chi$ modulo $d>1$ we have
$$\psi(x,\chi):=\sum_{n\leq x}\chi(n)\Lambda(n)=\sum_{\substack{1\leq a\leq d\\(a,d)=1}}\chi(a)\psi(x,a,d)=O(\sqrt{x}\log^2 x).$$
This implies that the Dirichlet $L$-function $L(s,\chi)$ has no zero in the half-plane $\Re(s)>1/2$, because its logarithmic derivative is analytic there:
$$ -\frac{L'(s,\chi)}{L(s,\chi)}=\sum_{n=1}^\infty \frac{\chi(n)\Lambda(n)}{n^s}=\int_{2-}^\infty t^{-s}\ d\psi(t,\chi)=s\int_2^\infty \frac{\psi(t,\chi)}{t^{s+1}}\,dt.$$
Analycity follows from the local uniform convergence of the last integral in the half-plane $\Re(s)>1/2$.