# Trigonometric function integration: $\int_0^{\pi/2}\frac{dx}{(a^2\cos^2x+b^2 \sin^2x)^2}$

How to integrate $$\int_0^{\pi/2}\dfrac{dx}{(a^2\cos^2x+b^2 \sin^2x)^2}$$

What's the approach to it?

Being a high school student , I don't know things like counter integration.(Atleast not taught in India in high school education ).I just know simple elementary results of definite and indefinite integration. Substitutions and all those works good. :)

• To get the best possible answers, you should explain what your thoughts on the problem are so far. That way, people won't tell you things you already know, and they can write answers at an appropriate level; also, people tend to be more willing to help you if you show that you've tried the problem yourself. – Zev Chonoles May 25 '13 at 17:27
• Do you know anything about contour integration? The Weierstrass substitution? – Potato May 25 '13 at 17:29
• @Potato: I am a high school student . I don't know these .I'll add something in question too. – ABC May 25 '13 at 17:30
• @user007 There's probably a faster way, but you can handle most trigonometric integrals with this: en.wikipedia.org/wiki/Weierstrass_substitution – Potato May 25 '13 at 17:33

In this case, the following trick also works: Dividing both the numerator and the denominator by $\cos^4 x$, we can use the substitution $t = \tan x$ to obtain

\begin{align*} \int_{0}^{\frac{\pi}{2}} \frac{dx}{(a^2 \cos^2 x + b^2 \sin^2 x)^2} &= \int_{0}^{\frac{\pi}{2}} \frac{1 + \tan^2 x}{(a^2 + b^2 \tan^2 x)^2} \sec^2 x \, dx \\ &= \int_{0}^{\infty} \frac{1 + t^2}{(a^2 + b^2 t^2)^2} \, dt \\ &= \frac{1}{a^2}\int_{0}^{\infty} \left( \frac{1}{a^2 + b^2 t^2} + \frac{(a^2 - b^2) t^2}{(a^2 + b^2 t^2)^2} \right) \, dt. \end{align*}

The first one can be evaluated as follows: Let $bt = a \tan\varphi$. Then

$$\int_{0}^{\infty} \frac{dt}{a^2 + b^2 t^2} = \frac{1}{ab} \int_{0}^{\frac{\pi}{2}} d\varphi = \frac{\pi}{2ab}.$$

For the second one, we perform the integration by parts:

\begin{align*} \int_{0}^{\infty} \frac{t^2}{(a^2 + b^2 t^2)^2} \, dt &= \left[ - \frac{1}{b^2}\frac{1}{a^2 + b^2 t^2} \cdot \frac{t}{2} \right]_{0}^{\infty} + \int_{0}^{\infty} \frac{1}{2b^2}\frac{dt}{a^2 + b^2 t^2} \\ &= \frac{1}{2b^2} \int_{0}^{\infty} \frac{dt}{a^2 + b^2 t^2} \\ &= \frac{\pi}{4ab^3}. \end{align*}

$$\frac{(a^2 + b^2)\pi}{4(ab)^3}.$$
You want to integrate $$J = \int_0^{\pi/2} \dfrac{dx}{\left(a^2 +(b^2-a^2) \sin^2(x) \right)^2} = \dfrac1{a^4}\int_0^{\pi/2} \dfrac{dx}{\left(1 +c \sin^2(x) \right)^2}$$ where $c = \dfrac{b^2-a^2}{a^2}$. We now want to integrate $I = \displaystyle \int_0^{\pi/2} \dfrac{dx}{\left(1 +c \sin^2(x) \right)^2}$. From Taylor series, we have $$\dfrac1{(1+cy^2)^2} = \sum_{k=0}^{\infty}(-1)^k (k+1)c^k y^{2k}$$ Hence (swapping integral and infinite summation), we get that $$\int_0^{\pi/2}\dfrac{dx}{(1+c\sin^2(x))^2} = \sum_{k=0}^{\infty}(-1)^k (k+1)c^k \int_0^{\pi/2}\sin^{2k}(x)dx$$ From here, we have $$\int_0^{\pi/2} \sin^{2k}(x) dx = \dbinom{2k}k \dfrac{\pi}{2^{2k+1}}$$ Hence, $$I = \sum_{k=0}^{\infty}(-1)^k (k+1)c^k \dbinom{2k}k \dfrac{\pi}{2^{2k+1}} = \dfrac{\pi}2 \sum_{k=0}^{\infty} (k+1) \dbinom{2k}k \left(-\dfrac{c}4\right)^k$$ Now from Taylor series, we have $$\sum_{k=0}^{\infty} (k+1) \dbinom{2k}k x^k = \dfrac{1+4x\sqrt{1-4x}-2x-\sqrt{1-4x}}{(1-4x)^{3/2}}$$ Hence, $$J = \dfrac{\pi}2 \left(\dfrac{1-c\sqrt{1+c}+c/2-\sqrt{1+c}}{a^4(1+c)^{3/2}} \right)$$ Now plug in the value of $c$ and get the value of the original integral $J$.
Put $t=\tan x\implies dt=\sec^2x.dx$ \begin{align} &\int_0^{\pi/2}\frac{dx}{(a^2\cos^2x+b^2\sin^2x)^2}=\int_0^{\pi/2}\frac{\sec^4x.dx}{(a^2+b^2\tan^2x)^2}\\ &=\int_0^\infty\frac{1+t^2}{(a^2+b^2t^2)^2}dt=\frac{1}{b^2}\int_0^\infty\frac{dt}{a^2+b^2t^2}+\frac{b^2-a^2}{b^2}\int^\infty_0\frac{dt}{(a^2+b^2t^2)^2}=I_1+I_2 \end{align} $$I_1=\frac{1}{b^2}\int_0^\infty\frac{dt}{a^2+b^2t^2}=\bigg[\frac{1}{b^2}.\frac{1}{ab}.\tan^{-1}\frac{bt}{a}\bigg]_0^\infty=\frac{\pi}{2ab^3}$$ Put $t=\frac{a}{b}\tan\theta\implies dt=\frac{a}{b}\sec^2\theta.d\theta$ \begin{align} I_2&=\frac{b^2-a^2}{b^2}\int^\infty_0\frac{dt}{(a^2+b^2t^2)^2}=\frac{b^2-a^2}{b^2}\int_0^{\pi/2}\frac{\frac{a}{b}\sec^2\theta.d\theta}{(a^2+a^2\tan^2\theta)^2}\\ &=\frac{b^2-a^2}{b^2}\frac{a}{b.a^4}\int_0^{\pi/2}\frac{\sec^2\theta}{\sec^4\theta}d\theta=\frac{b^2-a^2}{a^3b^3}\int_0^{\pi/2}\cos^2\theta.d\theta\\ &=\frac{b^2-a^2}{a^3b^3}\int_0^{\pi/2}\bigg(\frac{1+\cos2\theta}{2}\bigg)d\theta=\frac{b^2-a^2}{2a^3b^3}\bigg[\theta+\frac{\sin2\theta}{2}\bigg]_0^{\pi/2}=\frac{\pi}{4}\frac{b^2-a^2}{a^3b^3} \end{align} \begin{align} \int_0^{\pi/2}\frac{dx}{(a^2\cos^2x+b^2\sin^2x)^2}&=I_1+I_2=\frac{\pi}{2ab^3}+\frac{\pi}{4}\frac{(b^2-a^2)}{a^3b^3}\\ &=\frac{2\pi.a^2+\pi.b^2-\pi.a^2}{4a^3b^3}=\frac{\pi}{4}.\frac{a^2+b^2}{a^3b^3} \end{align}