I'm asked to find:
$$\int_{-\infty}^\infty \frac{\ln(x^2+1)}{1+x^2} dx $$
Attempt
Considering $$ \oint \frac{\ln(z^2+1)}{(z+i)(z-i)} dz $$
So first I find the branch points of the function.
This function has a simple pole at $z=i$ and an essential singularity at $z=-i$.
Using this contour:
By residue theorem,
$$\int_\gamma + \int_AB + \int_BC = 2\pi i \times \text{Residue} $$
$$ \text{Residue} = \frac{\ln(2i)}{2i} = \frac{\pi}{4} - \frac{i}{2}\ln(2) $$
Taking the semi-circle to infinity, $\int_\gamma \rightarrow 0$ by Jordan's Lemma.
$$\int_{-\infty}^0 \frac{\ln(-|x| + i)}{1+x^2} dx + \int_0^{\infty} \frac{\ln(x+i)}{1+x^2} dx = 2\pi i \left[ \frac{\pi}{4} - \frac{i}{2}\ln(2) \right] $$
$$ \int_{-\infty}^0 \frac{\ln (i - |x|) + i\pi}{1+x^2} dx + \int_0^{\infty} \frac{\ln(x+i)}{1+x^2} dx = 2\pi i \left[ \frac{\pi}{4} - \frac{i}{2}\ln(2) \right] $$
$$ \int_{\infty}^0 \frac{\ln (i - x) + i\pi}{1+x^2} dx + \int_0^{\infty} \frac{\ln(x+i)}{1+x^2} dx = 2\pi i \left[ \frac{\pi}{4} - \frac{i}{2}\ln(2) \right] $$
I have a hunch that the first integral must become $+\int_0^{\infty}$ for it to combine with the second integral to give $\int_0^\infty \frac{\ln(1+x^2)}{1+x^2}\,dx$ then we take the real part on the right. But I can't seem to show this..
$\int_{C_-} dz \frac{\log{(1+z^2)}}{1+z^2} = i\int_R^{\epsilon} dy \frac{\log{[-y (2+y)]}+ i 2 \pi}{-y (2+y)}$, why is there an additional factor of $2\pi i$?
How did the user get this result: $-2 \pi \int_{\epsilon}^R \frac{dy}{y (2+y)} = -\pi \left [ \log{R} - \log{(2 + R)} - \log{\epsilon} + \log{(2 + \epsilon)}\right]$?
– user44840 Jun 10 '14 at 21:50