AP CALCULUS BC • DIFFERENTIATION: DEFINITION AND FUNDAMENTAL PROPERTIES

Finding the Derivatives of Tangent, Cotangent, Secant, and/or Cosecant Functions

Extend the quotient rule to derive and apply the derivatives of the four remaining trigonometric functions.

Historical Context & Motivation

The story of differentiating trigonometric functions is inseparable from the broader development of calculus itself. While sine and cosine were the first trigonometric functions whose derivatives were rigorously established, mathematicians quickly recognized that the tangent, cotangent, secant, and cosecant functions—defined as ratios and reciprocals of sine and cosine—demanded their own derivative formulas. These secondary derivatives became essential tools in navigation, optics, and the study of periodic phenomena, where slope and rate-of-change information about more complex waveforms was needed.

1614
Napier's Trigonometric Tables
John Napier published extensive tables of tangent, secant, and other trigonometric values to aid astronomical computation, establishing these functions as independent objects of study.
1665–1676
Newton & Leibniz Develop Calculus
Newton's method of fluxions and Leibniz's differential calculus provided the formal machinery—particularly the quotient rule—needed to differentiate rational combinations of sine and cosine.
1748
Euler's Introductio in Analysin Infinitorum
Euler systematized all six trigonometric functions as analytic objects, deriving their series expansions and differentiation formulas in the modern notation we use today.
1800s
Standardized Calculus Curricula
Textbooks by Cauchy, Weierstrass, and others codified the derivatives of all six trigonometric functions as foundational results, embedding them permanently in the calculus canon.

With the derivatives of sin x and cos x already in hand, the central question becomes: how can we systematically derive the derivatives of tan x, cot x, sec x, and csc x using only the quotient rule and the known derivatives of sine and cosine? This lesson answers that question and builds fluency with these four formulas so that you can apply them confidently under exam conditions.

Core Principles & Definitions

Before deriving any formulas, it is essential to recall the definitions of the four functions in terms of sine and cosine, as well as the two prerequisite derivative facts. The quotient rule serves as the single unifying technique: because tan x = sin x / cos x, cot x = cos x / sin x, sec x = 1 / cos x, and csc x = 1 / sin x, every derivative in this lesson reduces to a quotient-rule application followed by a Pythagorean-identity simplification.

1

Prerequisite: d/dx [sin x] = cos x

The derivative of sine is cosine. This fact, proved via the limit definition, is a building block for every result in this lesson.
2

Prerequisite: d/dx [cos x] = −sin x

The derivative of cosine is the negative of sine. The negative sign propagates into the derivative formulas for sec x and tan x.
3

Quotient Rule

If h(x) = f(x)/g(x), then h′(x) = [f′(x)g(x) − f(x)g′(x)] / [g(x)]². This rule is applied four times to obtain the four derivatives.
4

Pythagorean Identities

sin²x + cos²x = 1, 1 + tan²x = sec²x, and 1 + cot²x = csc²x. These identities simplify the quotient-rule results into the compact final formulas.
5

Domain Awareness

Each derivative formula is valid only where the original function is defined. Tan x and sec x exclude odd multiples of π/2; cot x and csc x exclude integer multiples of π.
KEY TAKEAWAY
Think of the quotient rule as a universal adapter: just as a single adapter lets you plug any foreign device into a wall outlet, the quotient rule lets you convert any ratio of sine and cosine into its derivative. You only need two facts (the derivatives of sin x and cos x) and one tool (the quotient rule) to unlock four new formulas.

Visual Explanation — Graphs and Their Derivatives

A powerful way to internalize these derivatives is to see the original function alongside its derivative on the same axes. The diagram below plots y = tan x and its derivative y = sec²x over the interval (−π/2, π/2). Notice that wherever tan x has a horizontal tangent (at x = 0), sec²x equals 1—its minimum value. As tan x steepens near its vertical asymptotes, sec²x grows without bound, reflecting the increasingly rapid rate of change.

The cyan curve is y = tan x and the pink curve is y = sec²x. At x = 0, tan x = 0 and sec²x = 1, confirming that the slope of tan x at the origin is 1. As x → ±π/2, both functions diverge to infinity.

This visual reinforces a critical observation: the derivative sec²x is always positive on its domain, which is consistent with the fact that tan x is strictly increasing on each interval between consecutive vertical asymptotes. By contrast, the derivative of cot x turns out to be −csc²x, which is always negative, reflecting the strictly decreasing behavior of cotangent on each of its intervals.

Mathematical Framework — Deriving the Four Formulas

We now carry out the four derivations in full. Each one follows the same three-step pattern: express the function as a quotient of sine and cosine, apply the quotient rule, and simplify using the Pythagorean identity sin²x + cos²x = 1.

Derivative of tan x

Write tan x = sin x / cos x. Let f(x) = sin x and g(x) = cos x. The quotient rule gives d/dx [tan x] = [cos x · cos x − sin x · (−sin x)] / cos²x = [cos²x + sin²x] / cos²x = 1 / cos²x = sec²x.

DERIVATIVE OF TANGENT
d/dx [tan x] = sec²x
Valid for all x where cos x ≠ 0, i.e., x ≠ π/2 + nπ for any integer n.

Derivative of cot x

Write cot x = cos x / sin x. Applying the quotient rule with f(x) = cos x and g(x) = sin x yields d/dx [cot x] = [−sin x · sin x − cos x · cos x] / sin²x = −[sin²x + cos²x] / sin²x = −1 / sin²x = −csc²x.

DERIVATIVE OF COTANGENT
d/dx [cot x] = −csc²x
Valid for all x where sin x ≠ 0, i.e., x ≠ nπ for any integer n.

Derivative of sec x

Write sec x = 1 / cos x. Applying the quotient rule with f(x) = 1 and g(x) = cos x gives d/dx [sec x] = [0 · cos x − 1 · (−sin x)] / cos²x = sin x / cos²x. Rewriting this as (1/cos x)(sin x/cos x) yields sec x tan x.

DERIVATIVE OF SECANT
d/dx [sec x] = sec x · tan x
Valid for all x where cos x ≠ 0. The product form sec x tan x is the standard representation.

Derivative of csc x

Write csc x = 1 / sin x. The quotient rule with f(x) = 1 and g(x) = sin x gives d/dx [csc x] = [0 · sin x − 1 · cos x] / sin²x = −cos x / sin²x. Factoring as −(1/sin x)(cos x/sin x) produces −csc x cot x.

DERIVATIVE OF COSECANT
d/dx [csc x] = −csc x · cot x
Valid for all x where sin x ≠ 0. Note the negative sign—csc x mirrors sec x but with an extra factor of −1.

Patterns & Memory Aids

Memorizing four separate formulas becomes far easier when you recognize the structural symmetry between the "co" pairs. The derivative of each co-function (cotangent, cosecant) mirrors the derivative of its companion function (tangent, secant) but carries an extra negative sign. This pattern originates in the fact that d/dx [cos x] = −sin x carries a negative sign while d/dx [sin x] = cos x does not.

Co-function derivative pairs — the co-version always picks up a negative sign.
FunctionDerivativeCo-functionDerivative of Co-function
tan xsec²xcot xcsc²x
sec xsec x tan xcsc xcsc x cot x
Every co-function derivative mirrors its partner but with a negative sign. This pattern holds across all three pairs: sin/cos, tan/cot, sec/csc.
💡 Memory Tip
If a trig function starts with "co" (cosine, cotangent, cosecant), its derivative carries a negative sign. Functions without the "co" prefix (sine, tangent, secant) yield positive derivatives. This single mnemonic eliminates half the sign confusion on exam day.

Worked Example — Differentiating a Composite Expression

Let us work through a representative problem that combines the chain rule with the derivative formulas developed in Section 4. Problems of this type appear routinely on the AP Calculus BC exam.

Find dy/dx for y = 3 sec(2x) + tan²(x)
1
Step 1 — Identify the component functionsThe expression has two additive terms. The first term, 3 sec(2x), is a constant multiple of the secant of a linear inner function u = 2x. The second term, tan²(x), is [tan x]² — a power of a trigonometric function.
2
Step 2 — Differentiate the first term using the chain ruled/dx [3 sec(2x)] = 3 · sec(2x) tan(2x) · d/dx [2x] = 3 · sec(2x) tan(2x) · 2 = 6 sec(2x) tan(2x). We applied d/du [sec u] = sec u tan u and multiplied by the inner derivative du/dx = 2.
6 sec(2x) tan(2x)
3
Step 3 — Differentiate the second term using the chain ruleWrite tan²(x) = [tan x]². Applying the general power rule: d/dx [tan x]² = 2 tan x · d/dx [tan x] = 2 tan x · sec²x.
2 tan x sec²x
4
Step 4 — Combine the resultsAdding the derivatives of both terms gives the final answer.
dy/dx = 6 sec(2x) tan(2x) + 2 tan x sec²x
⚠️ Common Pitfall
Students frequently forget to multiply by the inner derivative when applying the chain rule to expressions like sec(2x). On the AP exam, always write out the inner function explicitly and multiply by its derivative as a separate factor. Omitting this step is one of the most heavily penalized errors on FRQ scoring.

Strengths, Limitations & Common Errors

Understanding where each formula excels and where students commonly stumble is just as important as knowing the formulas themselves. The table below contrasts the properties of each derivative formula, highlighting domain restrictions and typical error patterns.

Derivative properties and frequent mistakes
FormulaAlways Positive/Negative?Common Student Errors
d/dx [tan x] = sec²xAlways positive (sec²x ≥ 1)Writing sec x instead of sec²x; forgetting the square
d/dx [cot x] = −csc²xAlways negative (−csc²x ≤ −1)Dropping the negative sign; confusing with sec²x
d/dx [sec x] = sec x tan xSign matches sign of tan xWriting sec²x tan x instead of sec x tan x
d/dx [csc x] = −csc x cot xSign opposite to cot xOmitting the negative sign; mixing up csc and sec
KEY TAKEAWAY
Think of the sign of the derivative as a quality-control check. After computing any trigonometric derivative, ask: does the sign make geometric sense? If you know cot x is strictly decreasing on (0, π), then its derivative must be negative everywhere on that interval. A positive answer would be an immediate red flag, much like an engineer noticing a bridge stress calculation that predicts a negative force where tension should exist.

Connection to Advanced Topics

The four derivative formulas derived in this lesson serve as essential building blocks for several advanced calculus topics that appear later on the AP Calculus BC exam. Integration of trigonometric functions, in particular, frequently relies on recognizing these derivatives in reverse. For example, knowing that d/dx [tan x] = sec²x immediately tells you that ∫ sec²x dx = tan x + C. Similarly, the integral ∫ sec x tan x dx = sec x + C follows directly from the derivative of sec x.

How today's derivatives feed into advanced BC topics
This Lesson's ResultAdvanced Application (BC Exam)
d/dx [tan x] = sec²xAntiderivative: ∫ sec²x dx = tan x + C; integral of tan x via substitution
d/dx [sec x] = sec x tan xTrigonometric substitution in integrals (e.g., x = a sec θ); integration of sec x
d/dx [cot x] = −csc²xAntiderivative: ∫ csc²x dx = −cot x + C; appears in partial fraction integrals
d/dx [csc x] = −csc x cot xReduction formulas for ∫ cscⁿx dx; arc-length computations involving csc x
Chain rule + trig derivativesImplicit differentiation, related rates, parametric and polar derivatives

Beyond the AP exam, these derivatives play central roles in Fourier analysis, where trigonometric functions form the basis for representing periodic signals, and in differential equations, where solutions often involve combinations of all six trigonometric functions and their derivatives. Mastering these formulas now establishes a foundation that extends well beyond a single exam.

Practice Problems

1
Which of the following correctly explains why the derivative of cot x carries a negative sign while the derivative of tan x does not?
2
Find d/dx [5 csc x − 2 tan x].
3
Let f(x) = sec(3x²). What is f ′(x)?
PROBLEM 4APPLIED
A spotlight mounted on the ground is located 20 meters from a vertical wall. The light rotates at a constant rate of dθ/dt = 0.5 rad/s, where θ is the angle between the beam and the line perpendicular to the wall. Let y be the vertical distance from the point on the wall closest to the light to the point where the beam hits the wall. (a) Express y as a function of θ. (1 point) (b) Find dy/dθ. (1 point) (c) Find dy/dt in terms of θ. (1 point) (d) Evaluate dy/dt when θ = π/3. (1 point) (e) Explain in the context of this problem why dy/dt increases without bound as θ → π/2⁻. (1 point)
PROBLEM 5CRITICAL THINKING
Prove, using only the quotient rule and the Pythagorean identity, that d/dx [csc x] = −csc x cot x. Then explain why csc x has exactly one critical point on the interval (0, π).

Lesson Summary

This lesson established the derivatives of the four remaining trigonometric functions by applying the quotient rule to ratios and reciprocals of sine and cosine. The central results are: d/dx [tan x] = sec²x, d/dx [cot x] = −csc²x, d/dx [sec x] = sec x tan x, and d/dx [csc x] = −csc x cot x. Each derivation relied on the Pythagorean identity sin²x + cos²x = 1 for simplification.

A powerful mnemonic connects all six trigonometric derivatives: co-function derivatives always carry a negative sign. When combined with the chain rule, these four formulas enable differentiation of composite, product, and quotient expressions involving any trigonometric function—skills that are tested extensively in both the multiple-choice and free-response sections of the AP Calculus BC exam.

Varsity Tutors • AP Calculus BC • Finding the Derivatives of Tangent, Cotangent, Secant, and/or Cosecant Functions