Ma · Mathematics

Reduction Formula for ∫ cos(nx)/cos(x) dx

Updated 13 October 2026

At a glance

  1. 1. Set the notation

    Interpret cos nx as cos(n x), and define I_n as the integral of cos(n x) divided by cos x.

  2. 2. Apply a cosine identity

    Use the sum of cos((n−1)x) and cos((n+1)x) to replace the quotient with a lower-index pair.

  3. 3. Integrate and rearrange

    Integrate the identity and isolate I_n to get the reduction recurrence.

  4. 4. Use the base cases

    Start with I_0 equal to the integral of sec x and I_1 equal to x.

The notation in this integral can be read in two ways: cos(nx), where n multiplies the angle, or cos^n(x), where n is an exponent. The reduction formula below uses the first, common reading: I_n = ∫ cos(nx)/cos(x) dx, with n a nonnegative integer. The exponent interpretation is covered separately at the end.

The recurrence lowers the index by 2, so you need two starting integrals. It applies on any interval where cos(x) is nonzero; the integrand is undefined at the zeros of cos(x).

Derive the reduction formula

Use the cosine addition identity in the form

cos⁡((n−1)x)+cos⁡((n+1)x)=2cos⁡(nx)cos⁡x.\cos((n-1)x)+\cos((n+1)x)=2\cos(nx)\cos x.

Divide by cos(x), on an interval where it is nonzero, and integrate with respect to x:

∫cos⁡((n−1)x)cos⁡x dx+∫cos⁡((n+1)x)cos⁡x dx=2∫cos⁡(nx) dx.\int\frac{\cos((n-1)x)}{\cos x}\,dx+ \int\frac{\cos((n+1)x)}{\cos x}\,dx =2\int\cos(nx)\,dx.

The left side is I_(n−1) + I_(n+1). For n ≠ 0, the right side is 2 sin(nx)/n. Thus

In+1+In−1=2nsin⁡(nx).I_{n+1}+I_{n-1}=\frac{2}{n}\sin(nx).

Shift the index down by one to obtain the reduction formula:

In=2n−1sin⁡((n−1)x)−In−2,n≥2 an integer.\boxed{I_n=\frac{2}{n-1}\sin((n-1)x)-I_{n-2}},\qquad n\ge 2 \text{ an integer}.

The base cases are

I0=∫sec⁡x dx=ln⁡∣sec⁡x+tan⁡x∣,I1=∫1 dx=x.I_0=\int\sec x\,dx=\ln|\sec x+\tan x|, \qquad I_1=\int 1\,dx=x.

These are antiderivatives, so each may also include an arbitrary additive constant. The displayed recurrence gives a consistent choice of antiderivatives when the base cases are used as written.

Worked example: find I_4

Apply the recurrence first at n = 2:

I2=2sin⁡x−I0=2sin⁡x−ln⁡∣sec⁡x+tan⁡x∣.I_2=2\sin x-I_0 =2\sin x-\ln|\sec x+\tan x|.

Then use it at n = 4:

I4=23sin⁡(3x)−I2=23sin⁡(3x)−2sin⁡x+ln⁡∣sec⁡x+tan⁡x∣.\begin{aligned} I_4&=\frac{2}{3}\sin(3x)-I_2\\ &=\frac{2}{3}\sin(3x)-2\sin x+\ln|\sec x+\tan x|. \end{aligned}

You can check by differentiating. The derivative is 2 cos(3x) − 2 cos(x) + sec(x). Since cos(3x) = 4 cos^3(x) − 3 cos(x), this becomes 8 cos^3(x) − 8 cos(x) + sec(x), which equals cos(4x)/cos(x).

If n is an exponent

If the intended integrand is cos^n(x)/cos(x), with n an integer, simplify it first:

cos⁡nxcos⁡x=cos⁡n−1x.\frac{\cos^n x}{\cos x}=\cos^{n-1}x.

Let J_m = ∫ cos^m(x) dx. Integration by parts gives the standard cosine-power recurrence, for integer m ≥ 2:

Jm=sin⁡xcos⁡m−1xm+m−1mJm−2,m≥2.J_m=\frac{\sin x\cos^{m-1}x}{m}+\frac{m-1}{m}J_{m-2},\qquad m\ge 2.

Consequently, if I_n denotes the integral of cos^n(x)/cos(x), then for integer n ≥ 3,

In=sin⁡xcos⁡n−2xn−1+n−2n−1In−2,I_n=\frac{\sin x\cos^{n-2}x}{n-1}+\frac{n-2}{n-1}I_{n-2},

with I_1 = x and I_2 = sin(x). For example, I_3 = sin(x)cos(x)/2 + x/2. This recurrence is different from the one for cos(nx)/cos(x), so writing the exponent clearly matters.

Common mistakes

  • Confusing an exponent with an angle. cos(nx) means the cosine of the multiplied angle; cos^n(x) means a power of cosine.
  • Starting the recurrence without base cases. The recurrence steps down by two, so even indices use I_0 and odd indices use I_1.
  • Using the formula at a singularity. The quotient has denominator cos(x), so work on intervals that do not contain its zeros.
  • Dropping the absolute value. The standard real antiderivative of sec(x) is ln|sec(x) + tan(x)| on intervals where it is defined.

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.