[Math] Contour integral with a logarithm squared

branch-cutscontour-integrationresidue-calculus

The integral I'd like to evaluate is $\int_0^\infty \frac{\log^2 x \, dx}{(1+x)^2}$. I consider the function $f(z) = \frac{\text{Log}^2 z}{(1+z)^2}$, which has a pole of order 2 at $z=-1$ and has a branch point at $z=0$. I set up the integral $\oint_C f(z) dz$ along the contour $C = C_1 + C_2 + C_3 + C_4 + C_5 + C_6$, which consists of $C_1$ going just above the branch cut from $0$ to infinity, $C_2$, which is a big half-circle, $C_3$, which is a piece along the real axis from infinity to a point infinitesimally close to $z=-1$, $C_4$, which is a small half-circle going around $z=-1$ clockwise, $C_5$, which is another small piece on the real axis, and, finally, $C_6$, which is a quarter-circle around the origin to close the contour.

Now, I take the branch with $\text{Log}(z) = \log(r) + i \theta$, $0 \le\theta<2\pi$. Then the piece along $C_1$ is the integral $I$ I want to calculate. The pieces along $C_2$ and $C_6$ are zero when we take appropriate limits, but I'm not sure what to do with all the other pieces, since we can't really (can we?) write them in a way "$\text{something} \cdot I$", because of the singularity at $z=-1$. I know what I would do in the case of $1+z^2$ in the denominator, but not in this one. Suggestions?

Best Answer

We have $$\int_1^{\infty} \dfrac{\log^2(x)}{(1+x)^2}dx = \int_1^0 \dfrac{\log^2(1/x)}{(1+1/x)^2} \left(-\dfrac{dx}{x^2}\right) = \int_0^1 \dfrac{\log^2(x)}{(1+x)^2}dx$$ Hence, our integral becomes \begin{align} I & = \int_0^{\infty}\dfrac{\log^2(x)}{(1+x)^2}dx = 2\int_0^1\dfrac{\log^2(x)}{(1+x)^2}dx = 2\int_0^1 \sum_{k=0}^{\infty}(-1)^k (k+1)x^k \log^2(x)dx\\ & = 2\sum_{k=0}^{\infty}(-1)^k(k+1) \int_0^1 x^k\log^2(x)dx = 2\sum_{k=0}^{\infty}(-1)^k(k+1) \cdot \dfrac2{(k+1)^3}\\ & = 4 \sum_{k=0}^{\infty} \dfrac{(-1)^k}{(k+1)^2} = 4\left(\dfrac1{1^2} - \dfrac1{2^2} + \dfrac1{3^2} - \dfrac1{4^2} \pm \cdots\right) = \dfrac{\pi^2}3 \end{align}

Related Question