# Harish Karakoti's question on Facebook

#### ZaidAlyafey

##### Well-known member
MHB Math Helper
Harish Karakoti asked how to find the integral

$$I = \int^{\pi}_{-\pi} \frac{x^4\cos(x)}{1-\sin(x)+\sqrt{1+\sin^2(x)}}dx$$

#### ZaidAlyafey

##### Well-known member
MHB Math Helper
$$I = \int^{\pi}_{-\pi} \frac{x^4\cos(x)}{1-\sin(x)+\sqrt{1+\sin^2(x)}}dx$$

Separate the intervals

$$= \int^{\pi}_{0} \frac{x^4\cos(x)}{1-\sin(x)+\sqrt{1+\sin^2(x)}}dx-\int^{-\pi}_{-0} \frac{x^4\cos(x)}{1-\sin(x)+\sqrt{1+\sin^2(x)}}dx$$

use change of variable in the second one
$$I= \int^{\pi}_{0} \frac{x^4\cos(x)}{1-\sin(x)+\sqrt{1+\sin^2(x)}}dx+\int^{\pi}_{0} \frac{x^4\cos(x)}{1+\sin(x)+\sqrt{1+\sin^2(x)}}dx$$

By combining the two integrals, and noticing that

$$\frac{1}{1-\sin(x)+\sqrt{1+\sin^2(x)}}+ \frac{1}{1+\sin(x)+\sqrt{1+\sin^2(x)}} =1$$

We get

$$I=\int^{\pi}_{0} x^4\cos(x)\,dx$$

Use integration by parts to conclude that
$$I=\int^{\pi}_{0} x^4\cos(x)\,dx =24\pi -4\pi^3$$