Evaluate $\int_{0}^{\infty} \frac{x^{1/2}}{1 + x^2}\,\mathrm dx$ using the Residue Theorem.
I have been given a formula to compute integrals of this type:
$I = \int_{0}^{\infty} R(x) x^{\alpha}\,\mathrm dx = \frac{2\pi i}{1 - e^{2\pi i \alpha}} \sum_{a\in\mathbb{C}}\operatorname{Res}(R(z)z^{\alpha}, a) $ for $0 < \alpha < 1$,
however when I use this formula to compute the above integral I am finding that the answer is $\frac{i\pi}{\sqrt{2}}$. I know that the answer should not be complex so either I am doing the math wrong or this formula is incorrect.