01 / 20

Derivatives of \(\tan\)
& Other Trig

Master the derivatives of tangent, cotangent, secant, and cosecant: the rules, the proofs, and the patterns that tie them together.

AP Calculus

Why These Derivatives Matter

You already know \(\frac{d}{dx}[\sin x] = \cos x\) and \(\frac{d}{dx}[\cos x] = -\sin x\). But real-world models, from pendulum motion to signal processing, often involve \(\tan x\), \(\sec x\), \(\csc x\), and \(\cot x\). To differentiate expressions containing them, you need their derivative formulas.

Quick Recap: Quotient Rule

Since \(\tan x = \frac{\sin x}{\cos x}\), the quotient rule is the key tool. For any functions \(u\) and \(v\):

We will apply this rule to each of the four remaining trig functions, using only the known derivatives of \(\sin x\) and \(\cos x\).

The Six Trig Functions

\(\sin x\) & \(\cos x\)
The two base functions. Derivatives already known.
\(\tan x\) & \(\cot x\)
Ratio functions: \(\frac{\sin}{\cos}\) and \(\frac{\cos}{\sin}\).
\(\sec x\) & \(\csc x\)
Reciprocal functions: \(\frac{1}{\cos}\) and \(\frac{1}{\sin}\).

Deriving \(\frac{d}{dx}[\,\)\(\tan x\)\(\,]\)

1
Rewrite: \(\tan x = \dfrac{\sin x}{\cos x}\)
2
Apply quotient rule: \(\dfrac{\cos x \cdot \cos x - \sin x \cdot (-\sin x)}{\cos^2 x}\)
3
Simplify numerator: \(\cos^2 x + \sin^2 x = 1\)
4
Result: \(\dfrac{1}{\cos^2 x} = \sec^2 x\)

The Other Three Formulas

Using the same quotient rule technique on the remaining functions gives:

\(\cot x\)
$$\frac{d}{dx}[\cot x] = -\csc^2 x$$
\(\sec x\)
$$\frac{d}{dx}[\sec x] = \sec x \tan x$$
\(\csc x\)
$$\frac{d}{dx}[\csc x] = -\csc x \cot x$$

The Sign-Flip Pattern

Notice that the "co-" partner always introduces a negative sign. This is the single most useful memorization trick:

Function Derivative Co-partner Derivative
\(\tan x\) \(+\sec^2 x\) \(-\csc^2 x\) for \(\cot x\)
\(\sec x\) \(+\sec x\tan x\) \(-\csc x\cot x\) for \(\csc x\)
\(\sin x\) \(+\cos x\) \(-\sin x\) for \(\cos x\)

Visualizing \(\tan x\) and \(\sec^2 x\)

How to Apply These Rules

1
Identify which trig function appears and whether the chain rule is needed (is the argument something other than plain \(x\)?).
2
Write the base derivative from the table: e.g. \(\frac{d}{du}[\sec u] = \sec u \tan u\).
3
Multiply by the inner derivative if the argument is \(u(x)\): chain rule gives an extra factor of \(u'(x)\).
4
Simplify using trig identities if possible (e.g. \(\sin^2 x + \cos^2 x = 1\)).

Example 1: Basic Derivative

Find \(\frac{d}{dx}[3\tan x + 5\sec x]\).

1
Differentiate term by term using linearity.
2
\(\frac{d}{dx}[3\tan x] = 3\sec^2 x\)
3
\(\frac{d}{dx}[5\sec x] = 5\sec x\tan x\)

Example 2: Chain Rule

Find \(\frac{d}{dx}[\tan(3x^2)]\).

1
Outer function: \(\tan(u)\) where \(u = 3x^2\).
2
Outer derivative: \(\sec^2(u) = \sec^2(3x^2)\).
3
Inner derivative: \(\frac{d}{dx}[3x^2] = 6x\).
4
Multiply: chain rule result.

Example 3: Product Rule

Find \(\frac{d}{dx}[x^2 \csc x]\).

1
Product rule: \(u = x^2\), \(v = \csc x\).
2
\(u' = 2x\), \(v' = -\csc x \cot x\).
3
Combine: \(u'v + uv'\).

Example 4: Combining Rules

Find \(\frac{d}{dx}\!\left[\frac{\sec x}{x}\right]\).

1
Quotient rule: \(u = \sec x\), \(v = x\).
2
\(u' = \sec x \tan x\), \(v' = 1\).
3
\(\frac{x \cdot \sec x \tan x - \sec x \cdot 1}{x^2}\).

Common Mistakes

✕ Forgetting the Negative
Writing \(\frac{d}{dx}[\cot x] = \csc^2 x\) instead of \(-\csc^2 x\). The "co-" functions always carry a minus sign.
✕ Dropping the Chain Rule
Writing \(\frac{d}{dx}[\sec(5x)] = \sec(5x)\tan(5x)\) and forgetting to multiply by \(5\).
✕ Confusing Squared Notation
Thinking \(\sec^2 x\) means \(\sec(x^2)\). It means \((\sec x)^2\).

Complete Derivative Table

\(f(x)\) \(f'(x)\)
\(\sin x\) \(\cos x\)
\(\cos x\) \(-\sin x\)
\(\tan x\) \(\sec^2 x\)
\(\cot x\) \(-\csc^2 x\)
\(\sec x\) \(\sec x \tan x\)
\(\csc x\) \(-\csc x \cot x\)

Question 1 of 5

What is \(\frac{d}{dx}[\tan x]\)?

Question 2 of 5

What is \(\frac{d}{dx}[\csc x]\)?

Question 3 of 5

Find \(\frac{d}{dx}[\tan(4x)]\).

Question 4 of 5

Find \(\frac{d}{dx}[x \cdot \sec x]\).

Question 5 of 5

Which statement about the sign-flip pattern is correct?