# Simple integration question.

integrate

$$\int \sin(x) \cos(x)\; dx$$

using $u$-substitution.

If i take $u = \sin(x)$ I get final answer to be $\sin^2(x) / 2 + c$

But If i take $u = \cos(x)$ I get final answer to be $-\cos^2(x) / 2 + c$

Are they equal? They should be, otherwise it does not make sense. But how are they equal?

-
Do they differ by a constant? – David Mitra Dec 16 '12 at 3:08
Note that the $c$ in the first answer need not be the same as the $c$ in the second answer. – asmeurer Dec 16 '12 at 6:39

The symbol $\int f(x) dx$ does not denote a function, but rather the set of all functions $F(x)$ that satisfy $F'(x)=f(x)$. Hence, any two functions in this set may differ by a constant. In your particular example, note that $\sin^2(x)/2 -(-\cos^2(x)/2)=1/2$.

-

Remember that for two derivable functions $\,f(x)\,,\,g(x)\,$ on some open interval $\,I\,$, we have that

$$\forall\,x\in I\;\;,\;f'(x)=g'(x)\Longleftrightarrow f(x)=g(x)+C\,\,,\,C=\,\text{ a constant}$$

Now apply the above to your problem...

-