Complex Analysis – Contour for Evaluating $\int_0^\infty \frac{\sqrt{t}}{1+t^2} dt$

complex-analysiscontour-integrationintegration

Could anyone help me decide what contour to use to evaluate this integral?

$$\int_0^\infty \frac{\sqrt{t}}{1+t^2} dt$$

So we have simple poles at $i$,$-i$. Why does using a quarter of a circle in the upper right quadrant not work -is it a problem having $i$ on the contour of integration?

My second idea was to let
$$\sqrt{t}=e^{\frac{1}{2}\operatorname{log}t}$$

And defining the branch of the logarithm to be the negative imaginary axis. Then using an upper semi-circular contour. With a hole at 0, which will tend to the point 0 as the radius of the semi circle tends to infinity. Then we'll divide by two to get the integral from $0$ to $\infty$. Does this work, as this does not seem to be an even function we're integrating.

I apolygise for the poor explanation of my contours, it's quite difficult without pen and paper!

EDIT: Ok, so using an upper semi circle, with a semicircular hole about $0$. let us call the contour $\gamma$, we have:

$$\int_\gamma \frac{e^{\frac{1}{2}\operatorname{log}t}}{1+t^2}dt =2\pi i\Big(\frac{e^{\frac{1}{2}\operatorname{log}t}}{t+i}\Big)\Big|_{t=i}=\frac{e^{\pi/4}}{2i}$$

But by letting on the positive real axis $z=x+iy$ implies $log(z)=log(x)+0$ and on the negative axis $log(z)=log(x)+\pi$ Therefore if we tend the large arc's radius to infinity and the small arc about the origin's radius to zero we find the integral along the arc tends to zero. So

$$\int_\gamma \frac{e^{\frac{1}{2}\operatorname{log}t}}{1+t^2}dt=\int_0^\infty \frac{\sqrt{x}}{1+x^2} dx+\int_0^\infty \frac{\sqrt{x}e^{\pi/2}}{1+x^2} dx=(1+e^{\pi/2})\int_0^\infty \frac{\sqrt{x}}{1+x^2} dx$$

$$\Rightarrow \int_0^\infty \frac{\sqrt{x}}{1+x^2} =\frac{e^{\pi/4}}{2i(1+e^{\pi/2})}$$

This is wrong but can anyone point out what mistake I have made here?

Best Answer

Call $\displaystyle K=\int_0^\infty \frac{\sqrt{t}}{1+t^2} \mathrm dt$ and $\displaystyle J_\gamma=\int_\gamma\frac{\sqrt{t}}{1+t^2} \mathrm dt$. Basically, you made the same mistake twice.

(1) Evaluating $J_\gamma$ thanks to the residue theorem yields $$ J_\gamma=2\pi\mathrm i\cdot\left.\left(\frac{\mathrm e^{(\log t)/2}}{t+\mathrm i}\right)\right|_{t=\mathrm i}=\pi\mathrm e^{(\log \mathrm i)/2}=\pi\mathrm e^{\mathrm i\pi/4}=\pi(1+\mathrm i)/\sqrt2. $$ Here the mistake is to believe that (the principal value of) $\log\mathrm i$ is $\pi/2$ instead of $\mathrm i\pi/2$: consider that $\mathrm e^{\mathrm i\pi/2}=\cos(\pi/2)+\mathrm i\sin(\pi/2)=\mathrm i$ and that $\mathrm e^{\pi/2}$ is... well, a real number close to $4.81$.

(2) Evaluating $J_\gamma$ through an integral on the real line yields $$ \int_{-\infty}^\infty \frac{\sqrt{t}}{1+t^2} \mathrm dt=K+\int_{-\infty}^0 \frac{\sqrt{t}}{1+t^2} \mathrm dt=K+\int_0^{+\infty} \frac{\mathrm i\sqrt{t}}{1+t^2} \mathrm dt=(1+\mathrm i)\,K. $$ Here, the mistake is to believe that, for every positive real number $t$, $\sqrt{-t}$ is $\mathrm e^{\pi/2}\sqrt{t}$ instead of $\mathrm e^{\mathrm i\pi/2}\sqrt{t}=\mathrm i\sqrt{t}$.

Correcting steps (1) and (2), your reasoning yields the relation $$ (1+\mathrm i)K=\lim\limits_{R\to+\infty}J_{\gamma}=\pi(1+\mathrm i)/\sqrt2, $$ hence the (exact) value $K=\pi/\sqrt2$.

Note: A "purely real" road is available to compute $K$. To do that, first use in succession the changes of variables $u=\sqrt{t}$, $v=\pm u$, and $w=1/v$ to get $$ K=\int_0^\infty\frac{2u^2}{1+u^4}\mathrm du=\int_{-\infty}^\infty\frac{v^2}{1+v^4}\mathrm dv=\int_{-\infty}^\infty\frac{\mathrm dw}{1+w^4}. $$ Thus, $$ K=\frac12\int_{-\infty}^\infty\frac{x^2+1}{x^4+1}\mathrm dx. $$ The factorisation $x^4+1=(x^2+\sqrt2x+1)(x^2-\sqrt2x+1)$ implies that $$ \frac{x^2+1}{x^4+1}=\frac1{(\sqrt2x+1)^2+1}+\frac1{(\sqrt2x-1)^2+1}, $$ hence $K=\frac12(L_1+L_{-1})$ where, for every real number $a$, $$ L_a=\int_{-\infty}^\infty\frac{\mathrm dx}{(\sqrt2x+a)^2+1}. $$ Using the change of variable $u=\sqrt2x+a$, one sees that, for every real number $a$, $$ L_a=\frac1{\sqrt2}\int_{-\infty}^\infty\frac{\mathrm du}{u^2+1}=\frac{\pi}{\sqrt2}, $$ where the last equality is direct if one recognizes the density of a standard Cauchy distribution. This proves finally that $K=\pi/\sqrt2$.