Reciprocal primes in a fixed arithmetic progression (source code)

= Reciprocal primes in a fixed arithmetic progression
{title2=$\sum_{p\le x,\ p\equiv a\pmod q}1/p\sim\varphi(q)^{-1}\log\log x$}

For fixed coprime integers $a,q$, the <Prime number theorem> in the <arithmetic progression> gives $\pi(x;q,a)\sim x/(\varphi(q)\log x)$. <Partial summation> expresses the reciprocal-prime sum as $\pi(x;q,a)/x+\int_2^x\pi(t;q,a)t^{-2}\,dt$. The integral of the relative error is $o(\log\log x)$: fix a threshold beyond which that error is at most $\varepsilon$, bound its remaining integral by $\varepsilon\log\log x$, and then let $\varepsilon$ decrease to zero. The modulus is fixed in this statement.