Solution of an integral Can somebody help me solving this integral?
$$\int_0^a 2(1+x^2)\sin^2(x)dx$$
Thank you guys.

First do the substitution $2x=t$, so
$$
\sin^2x=\sin^2\frac{t}{2}=\frac{1-\cos t}{2}
$$
Thus the integral becomes
$$
\int_{0}^{2a}2\left(1+\frac{t^2}{4}\right)\frac{1-\cos t}{2}\frac{1}{2}\,dt
$$
An integral of the form
$$
\int t^2\cos t\,dt
$$
can be done by parts (twice).
