<s>[INST] integrate sin(x)cos(x) using trig identity. Book tells me the answer is:
$$ \int \sin(x)\cos(x) dx = \frac{1}{2} \sin^{2}(x) + C $$
however, I get the result:
$$
\sin(A)\cos(B) = \frac{1}{2} \sin(A-B)+\frac{1}{2}\sin(A+B)
$$
$$ 
\begin{split}
\int \sin(x)\cos(x) dx 
 &= \int \left(\frac{1}{2}\sin(x-x) + \frac{1}{2}\sin(x+x)\right) dx \\
 &= \int \left(\frac{1}{2}\sin(0) + \frac{1}{2}\sin(2x)\right) dx \\
 &= \int \left(\frac{1}{2}\sin(2x)\right) dx \\
 &= -\frac{1}{2} \frac{1}{2}\cos(2x) +C\\
 &= -\frac{1}{4} \cos(2x) +C
\end{split}
$$
How did the book arrive at the answer $\frac{1}{2}\sin^2(x)$?
 [/INST] HINT
The answers are equivalent. Recall that
$$
\cos (2x) = \cos^2 x - \sin^2 x = \left(1-\sin^2 x\right) - \sin^2 x = 1 - 2 \sin^2x
$$
</s>