AP Calculus AB and BC

Integral of sin(x)cos^2(x): Answer and Proof

The integral of sin(x)cos^2(x) is -cos^3(x)/3 + C. Substituting u = cos x gives du = -sin x dx, so the integral becomes the negative of the integral of u^2 du, which is -u^3/3. Differentiating -cos^3(x)/3 returns sin(x)cos^2(x).

sinxcos2xdx=cos3x3+C\int \sin x\cos^2 x\,dx = -\frac{\cos^3 x}{3} + C

Substituting u = cos x

One factor of sinx\sin x sits beside a power of cosx\cos x, and sinx\sin x is what the derivative of cosx\cos x produces up to sign. Let the cosine be the new variable.

u=cosx,du=sinxdx,sinxdx=duu = \cos x, \qquad du = -\sin x\,dx, \qquad \sin x\,dx = -du

The minus sign travels with the substitution and stays in the final answer.

sinxcos2xdx=u2du=u33+C=cos3x3+C\int \sin x\cos^2 x\,dx = -\int u^2\,du = -\frac{u^3}{3} + C = -\frac{\cos^3 x}{3} + C

Track the sign at the substitution step

Writing sinxdx=du\sin x\,dx = -du once, in a line of its own, is what keeps the minus sign from disappearing later.

Checking by differentiating

Differentiate with the chain rule. Two negatives appear and cancel.

ddx(cos3x3)=133cos2x(sinx)=sinxcos2x\frac{d}{dx}\left(-\frac{\cos^3 x}{3}\right) = -\frac{1}{3}\cdot 3\cos^2 x\cdot(-\sin x) = \sin x\cos^2 x

One minus sign comes from the antiderivative and the other from ddxcosx=sinx\frac{d}{dx}\cos x = -\sin x, so the integrand comes back positive.

The mistakes students make

  • Dropping the minus sign and answering cos3x3\frac{\cos^3 x}{3}. Differentiating that gives sinxcos2x-\sin x\cos^2 x, the negative of the integrand.
  • Choosing u=sinxu = \sin x. Then du=cosxdxdu = \cos x\,dx consumes only one cosine and leaves a stray cosx\cos x that cannot be written in terms of uu.
  • Answering sin2x2cos3x3\frac{\sin^2 x}{2}\cdot\frac{\cos^3 x}{3} by splitting the product and then applying the power rule to each trig factor. Two rules break at once: fg\int fg is not (f)(g)\left(\int f\right)\left(\int g\right), and the reverse power rule needs the variable itself raised to a power, so sinxdx=cosx\int\sin x\,dx = -\cos x, not sin2x2\frac{\sin^2 x}{2}.
  • Using the identity cos2x=1+cos2x2\cos^2 x = \frac{1+\cos 2x}{2} first. It is legal but creates extra work that substitution avoids.

Every answer on this page is machine checked

An automated test differentiates the antiderivative above and confirms it returns the integrand. A wrong sign or a missing factor fails the build, so it cannot reach you.

Frequently asked questions

Why is u = cos x the right choice and not u = sin x?

Because sine appears to an odd power. Peeling off one sinx\sin x for dudu leaves only even powers of cosine, and every remaining factor becomes uu. With u=sinxu = \sin x an unmatched cosx\cos x survives.

What is the integral of sin(x)cos^2(x) from 0 to pi/2?

0π/2sinxcos2xdx=[cos3x3]0π/2=0(13)=13\int_0^{\pi/2}\sin x\cos^2 x\,dx = \left[-\frac{\cos^3 x}{3}\right]_0^{\pi/2} = 0 - \left(-\frac{1}{3}\right) = \frac{1}{3}.

How does this extend to other powers of sine and cosine?

When sine has an odd power, save one sinx\sin x for dudu and set u=cosxu = \cos x. When cosine has an odd power, save one cosx\cos x and set u=sinxu = \sin x. When both powers are even, use the half-angle identities.