Evaluate the integral: $\int_{0}^{1} \frac{\ln(x+1)}{x^2+1} \mathrm dx$

Solution 1:

Put $x = \tan\theta$, then your integral transforms to $$I= \int_{0}^{\pi/4} \log(1+\tan\theta) \ d\theta. \tag{1}$$

Now using the property that $$\int_{0}^{a} f(x) \ dx = \int_{0}^{a} f(a-x) \ dx,$$ we have $$I = \int_{0}^{\pi/4} \log\biggl(1+\tan\Bigl(\frac{\pi}{4}-\theta\Bigr)\biggr) \ d\theta = \int_{0}^{\pi/4} \log\biggl(\frac{2}{1+\tan\theta} \biggr) \ d\theta.\tag{2}$$

Adding $(1)$ and $(2)$ we get $$2I = \int_{0}^{\pi/4} \log(2) \ d\theta\Rightarrow I= \log(2) \cdot \frac{\pi}{8}.$$

Solution 2:

Consider: $$I(a) = \int_0^1 \frac{\ln (1+ax)}{1+x^2} \, dx$$ than, the derivative $I'$ is equal: $$I'(a) = \int_0^1 \frac{x}{(1+ax)(1+x^2)} \, dx = \frac{2 a \arctan x - 2\ln (1+a x) + \ln (1+x^2)}{2(1+a^2)} \Big|_0^1\\ = \frac{\pi a + 2 \ln 2}{4(1+a^2)} - \frac{\ln (1+a)}{1+a^2}$$ Hence: $$I(1) = \int_0^1 \left( \frac{\pi a + 2 \ln 2}{4(1+a^2)} - \frac{\ln (1+a)}{1+a^2} \right) \, da \\ 2 I(1) = \int_0^1 \frac{\pi a + 2 \ln 2}{4(1+a^2)} \, da = \frac{\pi}{4} \ln 2$$ Divide both sides by $2$ and you're done.