# Trigonometric Substitution in $\int _0^{\pi/2}{\frac{ x\cos x}{ 1+\sin^2 x} dx }$

Evaluate $$\int _{ 0 }^{ \pi /2 }{ \frac { x\cos { (x) } }{ 1+\sin ^{ 2 }{ x } } \ \mathrm{d}x }$$  The solution was suggested like this: SOLUTION: First of all its, quite obvious to have substitution $\sin(x) \rightarrow x$ $$I = \int_{0}^{1} \frac{\arcsin(x)}{1+x^2} \ \mathrm{d}x$$ Now using integration by parts, $$I = \frac{\pi^2}{8} - \int_{0}^{1} \frac{\arctan(x)}{\sqrt{1-x^2}} \ \mathrm{d}x$$ Could someone please explain these two steps to me? For example, how do we get $\arcsin(x)$ in the numerator? Thanks a lot!

• if you write out things correctly, this is the sub x=arcsin(y) – tired May 19 '15 at 11:31

Since setting $\sin x=u$ gives you $$x=\arcsin u,\ \ \ \mathrm{d}u=\cos x \ \mathrm{d}x,$$ you have \begin{align}\int_{0}^{\pi/2}\frac{x\cos x}{1+\sin^2x}\ \mathrm{d}x&=\int_{0}^{1}\frac{\arcsin u}{1+u^2}\ \mathrm{d}u\\&=\int_{0}^{1}(\arctan u)'\arcsin u\ \ \mathrm{d}u\\&=[\arctan u\arcsin u]_{0}^{1}-\int_{0}^{1}\frac{\arctan u}{\sqrt{1-u^2}}\ \mathrm{d}u\\&=\frac{\pi^2}{8}-\int_{0}^{1}\frac{\arctan u}{\sqrt{1-u^2}}\ \mathrm{d}u\end{align}

• Alright Sir, thanks very much! Sir, I just wanted to know how to realise what substitution to make when. For example, I never thought of this substitution in you answer. – Ishan May 19 '15 at 11:40
• Done Sir. Could you please answer the last doubt in my comment? – Ishan May 19 '15 at 18:23
• @BetterWorld: "what substitution to make when" well, it depends. Try and error. You can google it to get useful information (see, for example, wiki). – mathlove May 19 '15 at 18:30
• Sir, please could you help me with this problem? – Ishan May 19 '15 at 18:42

It's a change of variables. If $y=\sin(x)$, $x=\arcsin(y)$ and $dy=\cos(x)dx$, so $x\cos(x)dx=\arcsin(y)dy$. Then you also have to change the bounds of the integral.

Knowing that :

• the derivative of $x\mapsto \arcsin(x)$ is $x\mapsto\frac{1}{1-\sqrt{x^2}}$

• the derivative of $x\mapsto \arctan(x)$ is $x\mapsto\frac{1}{1+x^2}$

the second part is simple if you know how to integrate by parts.

You may obtain

$$\int_0^{\pi/2} \frac{x\cos x}{1+\sin^2 x}\:dx=\frac12 \log^2 (1+\sqrt{2}) . \tag1$$

Proof. First observe that \begin{align} \int_0^\pi \frac{x\cos x}{1+\sin^2 x}\:dx &= \int_0^{\pi/2} \frac{x\cos x}{1+\sin^2 x}\:dx + \int_{\pi/2}^{\pi} \frac{x\cos x}{1+\sin^2 x}\:dx \\ & = \int_0^{\pi/2} \frac{x\cos x}{1+\sin^2 x}\:dx - \int_0^{\pi/2} \frac{(x+\pi/2)\sin x}{1+\cos^2 x}\:dx \\ &= 2\int_0^{\pi/2} \frac{x\cos x}{1+\sin^2 x}\:dx - \pi\int_0^{\pi/2} \frac{\cos x}{1+\sin^2 x}\:dx \\ &= 2\int_0^{\pi/2} \frac{x\cos x}{1+\sin^2 x}\:dx - \pi \left[\arctan u\right]_0^1\\ &= 2\int_0^{\pi/2} \frac{x\cos x}{1+\sin^2 x}\:dx - \frac{\pi^2}{4}. \end{align} Then evaluate $$\int_0^{\pi}\frac{x \cos{x}}{1+\sin^2{x}} {\rm d}x$$ using for example this approach.