Odd powers of trig integrands such as in $\int \sin^7 \theta\cos^5\theta\, d\theta$ I am doing as many trig integrals exercices as I can to develop the skills and thought patterns. I have a rather simple question about the result I get when computing integrals such as $\int \sin^7 \theta\cos^5\theta\, d\theta$, I use the basic substitution technique 
$$\int \sin^7 \theta\cos^5\theta\, d\theta\,=\,\int u^7\theta\left(1-u^2\theta\right)^2\, du\,:\,u=\sin\theta \quad du=\cos\theta\, d\theta$$
wich gives me 
$$\frac 18 \sin^8\theta - \frac 15 \sin^{10}\theta + \frac 1{12} \sin^{12}\theta +C$$
I check my answers with $Mathematica$ which gives,
$$\frac {-5\cos{2\theta}}{1024}+\frac {5\cos{4\theta}}{8192}+\frac {5\cos{6\theta}}{6144} - \frac {\cos{8\theta}}{4096} - \frac {\cos{10\theta}}{10240}+\frac {\cos{12\theta}}{24 576}$$
this is far from the result I got by substitution so I thought I was doing something wrong and I tried to achieve the same result but it is a bit painful, so I tried a definite integral as a quicker way to convince myself. Sure enough, I get the same answer as $Mathematica$ when I compute definite integrals. For example,
$$\int_0^\frac \pi 2 \sin^7 \theta\cos^5\theta\, d\theta\,=\,\frac1{120}$$
$$\frac 18 \sin^8\frac \pi 2- \frac 15 \sin^{10}\frac \pi2+ \frac 1{12} \sin^{12}\frac \pi2\,=\,\frac 1{120}$$
Does this have to do with the way $Mathematica$ does computations or am I doing something wrong? Also, is it useful to get it down to the same form as does $Mathematica$ or is the simple u-substitution result always reliable and correct?
 A: Actually, both of your solutions are correct. They are just of a different form.
Using the following identities:
$$\cos(2\theta)\equiv \cos^2 \theta-\sin^2 \theta \tag{1}$$
$$\sin(2\theta)\equiv 2\sin \theta \cos \theta \tag{2}$$
$$\sin^2 \theta+\cos^2 \theta\equiv 1 \tag{3}$$
We can obtain the result you've obtained from Mathematica:
$$\frac 18 \sin^8\theta - \frac 15 \sin^{10}\theta + \frac 1{12} \sin^{12}\theta +C$$
To do so, replace each of the $\cos$ terms on the result you've obtained from Mathematica with powers of $\sin \theta$.
$$\frac {-5\cos(2\theta)}{1024}+\frac {5\cos(4\theta)}{8192}+\frac {5\cos(6\theta)}{6144} - \frac {\cos(8\theta)}{4096} - \frac {\cos(10\theta)}{10240}+\frac {\cos(12\theta)}{24 576}$$
For the $\cos(4\theta), \cos(6\theta),\cdots ,\cos(12\theta)$ terms apply all the 3 above identities:

This is an example for $\cos(4\theta)$:
$$\cos(4\theta)=\cos^2(2\theta)-\sin^2(2\theta)=(\cos^2 \theta-\sin^2\theta)^2-(2\sin \theta\cos\theta)^2$$
$$\therefore \cos(4\theta)=\sin^4\theta+\cos^4\theta-6\sin^2 \theta\cos^2 \theta $$
$$\therefore \cos(4\theta)=\sin^4\theta+(1-\sin^2\theta)^2-6\sin^2\theta\cdot (1-\sin^2\theta)$$
$$\therefore \cos(4\theta)=8\sin^4\theta-8\sin^2 \theta+1$$
Now apply this process to the other $\cos$ terms.

If you would not like to do this method by hand (since it is extremely tedious), you can check this using Wolfram|Alpha. Do not be alarmed that it suggests that no solutions exist on this specific input. That is because the arbitrary constant of integration $C$ was not considered (It was assumed that $C=0$). If you let $C=-\frac{462}{122880}$, you will see that they are identical and apply for all $\theta \in \mathbb{R}$.
