AP Calculus AB and BC

Derivative of sec x tan x: Proof and Common Mistakes

sec x tan x differentiates to sec x (2 sec^2 x - 1). This is a product of two functions, so the product rule decides the method: it gives sec x tan^2 x + sec^3 x, and replacing tan^2 x with sec^2 x - 1 collapses that into the single factored form.

ddx[secxtanx]=secx(2sec2x1)\frac{d}{dx}\left[\sec x \tan x\right] = \sec x\left(2\sec^{2}x - 1\right)

Product rule, then the identity

Both factors differentiate into something built from secx\sec x and tanx\tan x, which is why the raw answer looks bigger than it needs to. Take u=secxu = \sec x with u=secxtanxu' = \sec x\tan x, and v=tanxv = \tan x with v=sec2xv' = \sec^{2}x.

ddx(secxtanx)=secxtanxtanx+secxsec2x=secxtan2x+sec3x\frac{d}{dx}\left(\sec x\tan x\right) = \sec x\tan x\cdot\tan x + \sec x\cdot\sec^{2}x = \sec x\tan^{2}x + \sec^{3}x

Now use the Pythagorean identity tan2x=sec2x1\tan^{2}x = \sec^{2}x - 1 on the first term. Everything becomes powers of secx\sec x, and a common factor of secx\sec x falls out.

secx(sec2x1)+sec3x=2sec3xsecx=secx(2sec2x1)\sec x\left(\sec^{2}x-1\right)+\sec^{3}x = 2\sec^{3}x-\sec x = \sec x\left(2\sec^{2}x-1\right)

Both secxtanx\sec x\tan x and its derivative are undefined at the odd multiples of π2\frac{\pi}{2}, where cosx=0\cos x = 0, so function and derivative share the same domain. Everything below, including the antiderivative statement, holds on each interval between consecutive asymptotes.

The derivative and the integral look nothing alike

secxtanx\sec x\tan x is one of the few expressions students meet far more often as an integrand than as a function to differentiate, because it is exactly the derivative of secx\sec x. Read backwards, that fact gives a one line antiderivative.

secxtanxdx=secx+Cbutddx(secxtanx)=secx(2sec2x1)\int \sec x\tan x\,dx = \sec x + C \qquad\text{but}\qquad \frac{d}{dx}\left(\sec x\tan x\right) = \sec x\left(2\sec^{2}x-1\right)

Going one step up in complexity and one step down are not mirror images here. The antiderivative is shorter than the input, the derivative is longer, and confusing the two directions is the most common way this expression goes wrong on a free response question.

The mistakes students make

Almost every wrong answer here comes from one of two places: the product rule itself, or the direction the Pythagorean identity is applied in.

  • Stopping at secxtan2x\sec x\tan^{2}x. That is only the first product rule term; the second, secxsec2x=sec3x\sec x\cdot\sec^{2}x = \sec^{3}x, is the one that gets dropped.
  • Using the identity backwards as tan2x=1sec2x\tan^{2}x = 1-\sec^{2}x. That turns the sum into secxsec3x+sec3x=secx\sec x - \sec^{3}x + \sec^{3}x = \sec x, which is the antiderivative, not the derivative.
  • Multiplying the two derivatives to get secxtanxsec2x=sec3xtanx\sec x\tan x\cdot\sec^{2}x = \sec^{3}x\tan x. The product rule adds two terms; it never multiplies the derivatives together.

Check yourself, not just the answer

Type derivatives and get graded on mathematical equivalence, with rule-level hints when you miss, in the Derivative Practice Checker.

Frequently asked questions

What is the derivative of sec x tan x?

It is secx(2sec2x1)\sec x\left(2\sec^{2}x-1\right), equivalently 2sec3xsecx2\sec^{3}x-\sec x or secxtan2x+sec3x\sec x\tan^{2}x+\sec^{3}x before simplifying.

Why does the answer have no tangent in it?

Because tan2x\tan^{2}x is rewritten as sec2x1\sec^{2}x-1. Once that substitution is made, every term is a power of secx\sec x, so the tangent disappears from the tidy form.

Is the derivative of sec x tan x the same as the integral?

No. secxtanxdx=secx+C\int\sec x\tan x\,dx = \sec x + C, while the derivative is secx(2sec2x1)\sec x\left(2\sec^{2}x-1\right). The two directions give completely different expressions.