# Real integral using complex methods

Evaluate $\displaystyle\int_0^\infty \frac {x^\frac{1}{2}}{1+x^4}dx$ using complex methods.

I'm totally locked up on this one and have thrown in the towel. My strategy was to integrate around a "keyhole" in the complex plane, branching the $x^{1/2}$ across the positive real line, then to take limits. The solution I keep getting for the sum of the residues for $R$ (the radius of my "keyhole contour") sufficiently large is $$\frac{1}{4} (e^{\pi i/8}+e^{5\pi i/8}-e^{3\pi i/8}-e^{7\pi i/8})=2\int_0^\infty \frac {x^\frac{1}{2}}{1+x^4}dx$$ which yields that $$\displaystyle\int_0^\infty \frac {x^\frac{1}{2}}{1+x^4}dx=\frac{1}{8}\left(\sqrt{\sqrt{2}+2}-\sqrt{2-\sqrt{2}}\right).$$

A quick look-see on Wolfram, however, yields $\frac{\pi}{4\cos{\frac{\pi}{8}}}=\frac{\pi}{2\sqrt{\sqrt{2}+2}}$ as the solution. So it seems like I've missed something trivial, but I'm not sure what.

• Looks to me as if you have made a careless error like $e^{\pi i/8}=e^{1/8}e^{\pi i}$. Suggest you check carefully! – David Mar 13 '14 at 4:38
• David, you're correct. I'll edit my post - the result still seems incorrect without the careless error here – Darrin Mar 13 '14 at 4:56

$$\oint_C dz \frac{z^{1/2}}{1+z^4}$$
where $C$ is a quarter-circle of radius $R$ in the first quadrant (upper-right quarter plane), with a small quarter-circle about the origin of radius $\epsilon$ cut out. As $R\to\infty$ and $\epsilon \to 0$, you can show that the integrals over the circular arcs vanish. Thus the contour integral is, in this limit,
$$\int_0^{\infty} dx \frac{x^{1/2}}{1+x^4} + i \int_{\infty}^0 dy \frac{(i y)^{1/2}}{1+(i y)^4} = \left ( 1-e^{i \pi/2} e^{i \pi/4}\right )\int_0^{\infty} dx \frac{x^{1/2}}{1+x^4}$$
By the residue theorem, the contour integral is also equal to $i 2 \pi$ times the residue at the pole $z=e^{i \pi/4}$. Thus,
\begin{align}\int_0^{\infty} dx \frac{x^{1/2}}{1+x^4} &= i 2 \pi\frac{e^{i \pi/8}}{4 e^{i 3 \pi/4}} \frac1{1-e^{i 3 \pi/4}}\\ &= \frac{\pi}{4 \cos{(\pi/8)}}\\ &= \frac{\pi}{2} \sqrt{1-\frac{\sqrt{2}}{2}}\end{align}