I've been thinking about integration lately, and I've come up with a question that I'm not sure how to address. Consider $$ \int \sin x\cos x \, \mathrm dx = - \int -\sin x \cos x \, \mathrm dx $$ I started with the integral on the left hand side, which suggests a typical $u$-substitution. Let $u=\sin x$ then $\, \mathrm du=\cos x \, \mathrm dx$. So the integral evaluates to $$ \int \sin x\cos x \, \mathrm dx = \frac{\sin^2(x)}{2} $$ But the original integral also suggests an alternate substitution. Let $u=\cos x$ and then $du=-\sin x \, dx$. So now $$ \int \sin x\cos x \, \mathrm dx =- \int -\sin x \cos x \, \mathrm dx= -\frac{\cos^2(x)}{2} $$ So now I have that the integral evaluates to two different functions. I've tried playing with some different trigonometric identities, but I haven't been able to show that this is true and I'm fairly certain I haven't had any success because the statement itself isn't true. What am I doing wrong? How do you evaluate $\int \sin x\cos x \, \mathrm dx$?
Asked
Active
Viewed 2,382 times
11
-
A similar older question: https://math.stackexchange.com/questions/33187/trig-integral-int-cosx-sinx-cosx-dx – Hans Lundmark Apr 01 '21 at 14:25
-
Relevant https://math.stackexchange.com/a/4262231/686284 – Quanto May 20 '23 at 17:33
1 Answers
31
The only thing that you’re doing wrong is forgetting the constant of integration: your two antiderivatives differ by a constant, so of course they are antiderivatives of the same function.
$$\frac12\sin^2x=-\frac12\cos^2x+\frac12$$
Brian M. Scott
- 616,228