<s>[INST] Elegant proof of $\int_{-\infty}^{\infty} \frac{dx}{x^4 + a x^2 + b ^2} =\frac {\pi} {b \sqrt{2b+a}}$? Let $a, b > 0$ satisfy $a^2-4b^2 \geq 0$. Then:
$$\int_{-\infty}^{\infty} \frac{dx}{x^4 + a x^2 + b ^2} =\frac {\pi} {b \sqrt{2b+a}}$$
One way to calculate this is by computing the residues at the poles in the upper half-plane and integrating around the standard semicircle. However, the sum of the two residues becomes a complicated expression involving nested square roots, which magically simplifies to the concise expression above.
Sometimes such 'magical' cancellations indicate that there is a faster, more elegant method to reach the same result. 
Is there a faster or more insightful way to compute the above integral?
 [/INST] Let $b=\frac{a}{2}\sin2\theta$ ($0<\theta<\frac{\pi}{2}$), then
\begin{eqnarray}
\int_{-\infty}^{\infty} \frac{dx}{x^4 + a x^2 + \frac14a^2\sin^22\theta}&=&\int_{-\infty}^{\infty}\frac{dx}{(x^2+a\sin^2\theta)(x^2+a\cos^2\theta)}\\
&=&\frac{1}{a(\cos^2\theta-\sin^2\theta)}\int_{-\infty}^{\infty}\left(\frac{1}{x^2+a\sin^2\theta}-\frac{1}{x^2+a\cos^2\theta}\right)dx\\
&=&\frac{1}{a(\cos^2\theta-\sin^2\theta)}\left(\frac{1}{\sqrt{a}\sin\theta}\arctan\frac{1}{\sqrt{a}\sin\theta}x\right.\\
&&-\left.\frac{1}{\sqrt{a}\cos\theta}\arctan\frac{1}{\sqrt{a}\cos\theta}x\right)\bigg|_{-\infty}^\infty\\
&=&\frac{1}{a(\cos^2\theta-\sin^2\theta)}\left(\frac{1}{\sqrt{a}\sin\theta}-\frac{1}{\sqrt{a}\cos\theta}\right)\pi\\
&=&\frac{\pi}{a\sqrt{a}(\cos\theta+\sin\theta)\sin\theta\cos\theta}\\
&=&\frac{\pi}{b\sqrt{2b+a}}.
\end{eqnarray}
</s>