# How I Impressed My Wife: Part 5h

Earlier in this series, I gave three different methods of showing that

$Q = \displaystyle \int_0^{2\pi} \frac{dx}{\cos^2 x + 2 a \sin x \cos x + (a^2 + b^2) \sin^2 x} = \displaystyle \frac{2\pi}{|b|}.$

Using the fact that $Q$ is independent of $a$, I’ll now give a fourth method.
Since $Q$ is independent of $a$, I can substitute any convenient value of $a$ that I want without changing the value of $Q$. As shown in previous posts, substituting $a =0$ yields the following simplification:

$Q = \displaystyle \int_0^{2\pi} \frac{dx}{\cos^2 x + 2 a \sin x \cos x + (a^2 + b^2) \sin^2 x}$

$= \displaystyle \int_{0}^{2\pi} \frac{dx}{\cos^2 x + 2 \cdot 0 \cdot \sin x \cos x + (0^2 + b^2) \sin^2 x}$

$= \displaystyle \int_{0}^{2\pi} \frac{dx}{\cos^2 x + b^2 \sin^2 x}$

$= \displaystyle \int_{-\pi}^{\pi} \frac{dx}{\cos^2 x + b^2 \sin^2 x}$

$= \displaystyle \int_{-\infty}^{\infty} \frac{ 2(1+u^2) du}{u^4 + (4 b^2 - 2) u^2 + 1}$

The four roots of the denominator satisfy

$u^2 = \displaystyle 1 - 2b^2 \pm 2|b| \sqrt{b^2 - 1}$

So far, I’ve handled the cases $|b| = 1$ and $|b| > 1$. In today’s post, I’ll start considering the case $|b| < 1$.

Factoring the denominator is a bit more complicated if $|b| < 1$. Using the quadratic equation, we obtain

$u^2 = \displaystyle 1 - 2b^2 \pm 2|b| i \sqrt{1-b^2}$

However, unlike the cases $|b| \ge 1$, the right-hand side is now a complex number. So, To solve for $u$, I’ll use DeMoivre’s Theorem and some surprisingly convenient trig identities. Notice that

$(1-2b^2)^2 + (2|b| \sqrt{1-b^2})^2 = 1 - 4b^2 + b^4 + 4b^2 (1 - b^2) = 1 - 4b^2 + b^4 + 4b^2 - b^4 = 1$.

Therefore, the four complex roots of the denominator satisfy $|u^2| = 1$, or $|u| = 1$. This means that all four roots can be written in trigonometric form so that

$u^2 = \cos 2\phi + i \sin 2\phi$,

where $2\phi$ is some angle. (I chose the angle to be $2\phi$ instead of $\phi$ for reasons that will become clear shortly.)

I’ll begin with solving

$u^2 = \displaystyle 1 - 2b^2 + 2|b| i \sqrt{1-b^2}$.

Matching the real and imaginary parts, we see that

$\cos 2\phi = 1-2b^2$,

$\sin 2\phi = 2|b| \sqrt{1-b^2}$

This completely matches the form of the double-angle trig identities

$\cos 2\phi = 1 - 2\sin^2 \phi$,

$\sin 2 \phi = 2 \sin\phi \cos \phi$,

and so the problem reduces to solving

$u^2 = \cos 2\phi + i \sin 2\phi$,

where $\sin \phi = |b|$ and $\cos \phi = \sqrt{1-b^2}$. By De Moivre’s Theorem, I can conclude that the two solutions of this equation are

$u = \pm(\cos \phi + i \sin \phi)$,

or

$u = \pm( \sqrt{1-b^2} + i |b|)$.

I could re-run this argument to solve $u^2 = \displaystyle 1 - 2b^2 - 2|b| i \sqrt{1-b^2}$ and get the other two complex roots. However, by the Conjugate Root Theorem, I know that the four complex roots of the denominator $u^4 + (4 b^2 - 2) u^2 + 1$ must come in conjugate pairs. Therefore, the four complex roots are

$u = \pm \sqrt{1-b^2} \pm i |b|$.

Therefore, I can factor the denominator as follows:

$u^4 + (4 b^2 - 2) u^2 + 1 = (u - [\sqrt{1-b^2} + i|b|])(u - [\sqrt{1-b^2} - i|b|])$

$\qquad \times (u - [-\sqrt{1-b^2} + i|b|])(u - [-\sqrt{1-b^2} + i|b|])$

$= (u - \sqrt{1-b^2} - i|b|)(u - \sqrt{1-b^2} + i|b])$

$\qquad \times (u +\sqrt{1-b^2} + i|b|)(u +\sqrt{1-b^2} + i|b|)$

$= ([u - \sqrt{1-b^2}]^2 +b^2)([u + \sqrt{1-b^2}]^2 +b^2)$

To double-check my work, I can directly multiply this product:

$([u - \sqrt{1-b^2}]^2 +b^2)([u + \sqrt{1-b^2}]^2 +b^2)$

$= (u^2 - 2u \sqrt{1-b^2} + 1 - b^2 + b^2) (u^2 + 2u \sqrt{1-b^2} + 1 - b^2 + b^2)$

$= ([u^2 +1] - 2u\sqrt{1-b^2})([u^2+1] + 2u\sqrt{1-b^2})$

$= [u^2+1]^2 - [2u\sqrt{1-b^2}]^2$

$= u^4 + 2u^2 + 1 - 4u^2 (1-b^2)$

$= u^4 + u^2 (2 - 4[1-b^2]) + 1$

$= u^4 + u^2 (4b^2 - 2) + 1$.

So, at last, I can rewrite the integral $Q$ as

$Q = \displaystyle \int_{-\infty}^{\infty} \frac{ 2(1+u^2) du}{ ([u - \sqrt{1-b^2}]^2 +b^2)([u + \sqrt{1-b^2}]^2 +b^2)}$

I’ll continue with this fourth evaluation of the integral, continuing the case $|b| < 1$, in tomorrow’s post.