Right solution to an integration problem One more from me.
Please help me understand the following. How do you get from here:
$\frac{1}{8}\int{1dx}-\frac{1}{8}\int{\cos(2x)dx}-\frac{1}{8}\int{\cos^2(2x)dx}+\frac{1}{8}\int{\cos^3(2x)dx}$
to here:
$=\frac{1}{16}x-\frac{1}{64}\sin(4x)-\frac{1}{48}\sin^3(2x)+C$
Is the above even correct? I found this in a textbook but found another solution online and I am not sure which one to believe anymore. The one i found online is this:
$=\frac{1}{16}x-\frac{1}{64}\sin(2x)-\frac{1}{64}\sin(4x)+\frac{1}{192}\sin(6x)+C$
The starting point was for both the following:
$\int{\sin^4(x)\cos^2(x)dx}$
Thank you.

We know that $$\cos^2(x) = \frac {1 + \cos(2x)}{2}$$ and $$\sin^2(x) = \frac {1 - \cos(2x)}{2}$$. So let us convert the integrand into something we can integrate:
$$\sin^4(x)\cos^2(x) = (\sin^2(x))^2\cos^2(x)$$ $$=\frac {1-\cos(2x)}{4}^2 \times \frac {1+\cos(2x)}{2}$$ $$=\frac {1 - 2\cos(2x) + \cos^2(2x)}{4} \times \frac {1 + \cos(2x)}{2}$$ $$=\frac {1 - 2\cos(2x) + \cos^2(2x) + \cos(2x) - 2\cos^2(2x) + cos^3(2x)}{8}$$ $$=\frac {1 - \cos(2x) - \cos^2(2x) + \cos^3(2x)}{8}$$ This was all the side work.
Now we can integrate it :
$$\int \sin^4(x)\cos^2(x) = \int \frac {1 - \cos(2x) - \cos^2(2x) + \cos^3(2x)}{8} dx$$
$$=\frac{1}{8}  \left[x - \frac {1}{2}\sin(2x) - \left(\frac {x}{2} + \frac{\sin(2x)}{4} + C_1\right) + \left(\frac{1}{2}\sin(2x) - \frac{1}{6}\sin^3(2x) + C_2\right)\right]$$
$$=\frac{1}{8} \left[\frac{x}{2} - \frac{\sin(2x)}{4} - \frac{1}{6}\sin^3(2x)\right] + C\tag{C = C_1 + C_2}$$
