Calculus 2Techniques of Integration

Trigonometric Integrals

Use identities for powers of sine, cosine, tangent and secant.

Not started Jump to practice

Integrals like $\int \sin^{3}x\cos^{2}x\,dx$ or $\int \sin^{2}x\,dx$ come up in physics, in Fourier series and inside trigonometric substitution. Two tools handle almost all of them: substitution with $u = \sin x$ or $u = \cos x$, and the power-reducing identities.

Why it works

Substitution needs a spare factor to be $du$. If $\sin x$ has an odd power, peel off one $\sin x$ to go with $dx$ (since $d(\cos x) = -\sin x\,dx$), and the remaining even power becomes a polynomial in $\cos x$ through $\sin^{2}x = 1 - \cos^{2}x$. Then $u = \cos x$ leaves a polynomial in $u$. If both powers are even, there is no factor to spare. Instead lower the powers with $$\sin^{2}x = \frac{1 - \cos 2x}{2},$$ $$\cos^{2}x = \frac{1 + \cos 2x}{2},$$ which trade a square for a single cosine of a double angle.

Key idea

For $\int \sin^{m}x\cos^{n}x\,dx$: if $m$ is odd, save one $\sin x$ and let $u = \cos x$; if $n$ is odd, save one $\cos x$ and let $u = \sin x$; if both are even, use the power-reducing identities.
Which factor to save, and why: it becomes $du$.
IntegrandSaveConvert the rest withSubstitute
$\sin^{m}x\cos^{n}x$, $m$ odd$\sin x\,dx$$\sin^{2}x = 1 - \cos^{2}x$$u = \cos x$
$\sin^{m}x\cos^{n}x$, $n$ odd$\cos x\,dx$$\cos^{2}x = 1 - \sin^{2}x$$u = \sin x$
$\sin^{m}x\cos^{n}x$, both even—$\sin^{2}x = \frac{1 - \cos 2x}{2}$, $\cos^{2}x = \frac{1 + \cos 2x}{2}$—
$\tan^{m}x\sec^{n}x$, $n$ even$\sec^{2}x\,dx$$\sec^{2}x = 1 + \tan^{2}x$$u = \tan x$
$\tan^{m}x\sec^{n}x$, $m$ odd$\sec x\tan x\,dx$$\tan^{2}x = \sec^{2}x - 1$$u = \sec x$

Worked example: An odd power of sine

Find $\int \sin^{3}x\cos^{2}x\,dx$.
  1. Save one $\sin x$: $\sin^{3}x = (1 - \cos^{2}x)\sin x$.
  2. Let $u = \cos x$, $du = -\sin x\,dx$: the integral becomes $-\int (1 - u^{2})u^{2}\,du = -\int (u^{2} - u^{4})\,du$.
  3. $$\begin{aligned} &= -\frac{u^{3}}{3} + \frac{u^{5}}{5} + C \\ &= -\frac{\cos^{3}x}{3} + \frac{\cos^{5}x}{5} + C. \end{aligned}$$

Answer: $-\frac{\cos^{3}x}{3} + \frac{\cos^{5}x}{5} + C$

Worked example: An even power

Find $\int \sin^{2}x\,dx$, then $\int_0^{\pi}\sin^{2}x\,dx$.
  1. $\int \frac{1 - \cos 2x}{2}\,dx = \frac{x}{2} - \frac{\sin 2x}{4} + C$.
  2. From 0 to $\pi$: $\frac{\pi}{2} - 0 - (0 - 0) = \frac{\pi}{2}$.

Answer: $\frac{x}{2} - \frac{\sin 2x}{4} + C$; the definite integral is $\frac{\pi}{2}$.

$\sin^{2}x$ swings between 0 and 1 around the line $y = \frac{1}{2}$, and the parts above and below that line balance. So over $[0, \pi]$ the area is $\frac{1}{2}\cdot\pi$, matching the identity $\sin^{2}x = \frac{1}{2} - \frac{\cos 2x}{2}$.

Worked example: Tangent and secant

Find $\int \tan^{3}x\sec x\,dx$.
  1. The power of $\tan x$ is odd: save $\sec x\tan x\,dx$, which is $d(\sec x)$.
  2. What is left is $\tan^{2}x = \sec^{2}x - 1$. With $u = \sec x$: $\int (u^{2} - 1)\,du = \frac{u^{3}}{3} - u + C$.
  3. $= \frac{\sec^{3}x}{3} - \sec x + C$.

Answer: $\frac{\sec^{3}x}{3} - \sec x + C$

Common mistake

Substituting $u = \cos x$ when no spare $\sin x$ is available, as in $\int \cos^{2}x\,dx$. Then $du = -\sin x\,dx$ has nothing to match, and you end up with leftover $x$'s next to $u$'s. Check after substituting: if any $x$ is left in the integrand, the substitution did not work. For even powers, reduce the power first.
Products with different angles, like $\int \sin 3x\cos x\,dx$, use the product-to-sum identity $$\begin{aligned} \sin A\cos B &= \tfrac{1}{2}\sin(A + B) \\ &\quad + \tfrac{1}{2}\sin(A - B), \end{aligned}$$ which turns the product into two easy terms.

Practice

Pass with 3 right answers, the last 2 in a row. Each right answer earns 3 XP.

Loading practice…

Builds on

Leads to

Sources and further reading

  • OpenStax Calculus Volume 2, Section 3.2: Trigonometric Integrals
  • Paul’s Online Math Notes (Lamar University), Calculus II: Integrals Involving Trig Functions
@teddyrookbook GitHub