# Integrate $\int \sin (2x) \cos (2x) dx$

I have

$\int \sin(2x) \cos (2x) = 1/2 \int \sin(4x) dx = -\cos(4x)/8$

But I also have

$\int \sin(2x) \cos (2x) = 1/2 \int \sin 2x \cdot 2 \cos 2x \; dx = (1/4) \sin^2(2x)$

which is correct, and why is the other method wrong?

-
They're both correct. Why assume otherwise? With trigonometric functions things that look different are often the same. For example, $\sin^2x$ is the same as $1-\cos^2 x$. (In this case, the two differ from each other by a constant, and that's what you expect of two antiderivatives of the same function.) – Michael Hardy Sep 27 '11 at 0:17
They are both wrong. The constant of integration has been omitted in each case. – André Nicolas Sep 27 '11 at 1:11

They are differing by an integration constant, because of $\cos(2 y) = \cos^2(y) - \sin^2(y) = 1 - 2 \sin^2(y)$, and hence are the same as indefinite integration produces an anti-derivative up to a constant
To illustrate the phenomena in your calculation, I've chosen the number $\pi/8$ as the lower boundary.