L-series: Which logarithm will split this product into a sum? For a project, I am analyzing a proof of Dirichlet's theorem. It is my first introduction to the concept of an $L$-series, which is defined by
\begin{align*}
L(s,\chi) = \sum_{n\geq 1} \frac{\chi(n)}{n^s},
\end{align*}
for a character $\chi$ and a real number $s>1$. Using Euler's product representation, we see
\begin{align*}
L(s,\chi) = \prod_p \frac{1}{1-(\chi(p) \text{/} p^s)}.
\end{align*}
(The product is taken over primes.) In the proof I am reading, the author goes on to say that we may take a logarithm here, giving
\begin{align*}
\log L(s,\chi) = -\sum_p \log\bigg(1-\frac{\chi(p)}{  p^s}\bigg).
\end{align*}
However, I am struggling to understand which logarithm they are using, as we are dealing with complex numbers, and the log of an infinite product will not split into a sum under specific circumstances (this depends on which branch of the complex logarithm we decide to use.) My question is: are there properties of characters that allow us to choose a specific log here? (which one?) Otherwise, is there another way of getting around this issue?
 A: I came across the same issue in the book "Analytic number theory" by De Koninck and Luca (Eq. (14.6) on p.241).
Given the general style of the book and the preceding arguments of the proof, I highly doubt that the authors had
@KCd's argument (see comments) in mind. I can think of two ways to resolve the issue:
(1) Instead of looking at $\log L(s,\chi)$ directly, consider
$$\exp\Bigl(\sum_{p}\sum_{k=1}^\infty\frac{\chi(p^k)}{kp^{ks}}\Bigr)=\prod_{p}\exp\Bigl(\log\Bigl(\frac{1}{1-\chi(p)p^{-s}}\Bigr)\Bigr)=\prod_{p}\frac{1}{1-\chi(p)p^{-s}}=L(s,\chi).$$
The arguments apply to this equation similarly.
(2) To show that the original equation really holds for the principal branch of the complex logarithm (which I don't know at the moment), one must show that the imaginary part of $$\sum_p\log(1-\chi(p)p^{-s})$$ lies between $-\pi$ and $\pi$. Hence, we nee to compute the argument $\phi$ of $1-\chi(p)p^{-s}$. We may assume that $\chi(p)\ne 0$ (otherwise $\phi=0$). Then $\chi(p)$ is a root of unity, in particular $|\chi(p)|=1$. The number $1-\chi(p)p^{-s}$ lies on the circle described by $f(x)=\sqrt{p^{-2s}-(x-1)^2}$. Now $\phi$ is maximized for the point on the tangent crossing the origin. If $x$ denotes the real part of that point and $a$ denotes the slope of the tangent, we get the equations
$$ax=f(x),\qquad a=f'(x)=\frac{1-x}{f(x)}.$$
If I'm not mistaken, this yields $x=1-p^{-2s}$ and $\phi=\arctan(a)=\arctan(f(x)/x)=\mathrm{arccot}\sqrt{p^{2s}-1}$.
I don't know how to simplify this further, but I did some numerical experiments. It might indeed be the case that the claim holds. I have to admit that I'm a novice in analysis. Perhaps someone else can finish the computation.
