Tutorials › AP Calculus › Using the Second Derivative Test

Monotonicity and Local Extrema · Tutorial 360 of 999

Using the Second Derivative Test

Use the second derivative at a stationary point to identify a local maximum or minimum, and check the conditions that make the conclusion valid.

Intermediate 9 min read

What You'll Learn

  • Identify when a stationary point satisfies the hypotheses of the second derivative test
  • Classify a point with a negative second derivative as a local maximum
  • Classify a point with a positive second derivative as a local minimum
  • Use the test to classify multiple stationary points of a function
  • Explain why the second-derivative sign determines the local behavior
  • Recognize why checking the function's domain and differentiability matters

From a Stationary Point to a Classification

A stationary point is a point \(x=c\) where \(f'(c)=0\). The tangent line there is horizontal, but that fact alone does not tell us whether the graph has a local maximum, a local minimum, or neither. The second derivative test uses the value of \(f''(c)\) to classify certain stationary points efficiently.

The key is to check the test's conditions before using its conclusion. The point must be in the interior of the domain, the function must be twice differentiable on an interval around it, and its first derivative must be zero there. When those conditions hold, a negative second derivative indicates a local maximum; a positive second derivative indicates a local minimum.

Theorem: Suppose \(c\) is an interior point of the domain of \(f\), \(f\) is twice differentiable on an open interval containing \(c\), and \(f'(c)=0\). If \(f''(c)<0\), then \(f\) has a local maximum at \(c\). If \(f''(c)>0\), then \(f\) has a local minimum at \(c\).

What the Test Concludes

A local maximum at \(c\) means that, for every \(x\) sufficiently close to \(c\), \(f(x)\leq f(c)\). A local minimum means that, for every \(x\) sufficiently close to \(c\), \(f(x)\geq f(c)\). These are local comparisons: the function need not be largest or smallest on its entire domain.

The test classifies the point \(x=c\). If a problem asks for the corresponding point on the graph, report \((c,f(c))\), not just the \(x\)-coordinate. It is also useful to keep the two derivative roles separate: \(f'(c)=0\) identifies a stationary point, while the sign of \(f''(c)\) classifies it under the theorem's hypotheses.

A Justification Using Derivative Signs

The reason the test works is that the second derivative describes how the first derivative changes near \(c\). At a stationary point, \(f'(c)=0\). The definition of \(f''(c)\) gives the limit

$$ \lim_{x\to c}\frac{f'(x)-f'(c)}{x-c}=f''(c). $$

Since \(f'(c)=0\), the quotient in this limit is \(f'(x)/(x-c)\). If its limit is positive, then sufficiently near \(c\), for \(x\ne c\), the quotient is positive. If its limit is negative, the quotient is negative. Because \(x-c\) is negative to the left of \(c\) and positive to the right, these quotient signs determine the signs of \(f'(x)\) on either side.

1
If \(f''(c)>0\).
Near \(c\), \(f'(x)/(x-c)>0\). Thus \(f'(x)<0\) just left of \(c\), and \(f'(x)>0\) just right of \(c\).
2
Use the derivative signs.
The function decreases as it approaches \(c\) from the left and increases after \(c\). Therefore \(f(c)\) is less than nearby function values: \(c\) is a local minimum.
3
If \(f''(c)<0\).
Near \(c\), \(f'(x)/(x-c)<0\). Thus \(f'(x)>0\) just left of \(c\), and \(f'(x)<0\) just right of \(c\). The function increases and then decreases, so \(c\) is a local maximum.

This argument uses the relationship between derivative signs and monotonicity. The quotient's sign remains the same as its nonzero limit sufficiently close to \(c\); this is why a strict inequality in the theorem matters.

A Reliable Procedure

For a candidate point \(c\), use the following sequence. In particular, do not begin by looking only at the second derivative: first establish that the candidate is in a setting where the theorem applies.

  1. Check that \(c\) is in the interior of the domain.
  2. Check that \(f\) is twice differentiable on an open interval containing \(c\).
  3. Verify that \(f'(c)=0\).
  4. Compute \(f''(c)\), keeping the value exact where possible.
  5. If \(f''(c)<0\), conclude that \(c\) is a local maximum. If \(f''(c)>0\), conclude that \(c\) is a local minimum.
  6. Find \(f(c)\) if the problem asks for the point on the graph or the local extreme value.

Worked Examples

Worked Example: Classify Two Stationary Points

Classify the stationary points of \(f(x)=x^3-3x^2-9x+1\).

This is a polynomial, so it is twice differentiable for every real \(x\). Its domain is \(\mathbb{R}\), and every real point is interior to the domain. Differentiate:

$$ f'(x)=3x^2-6x-9=3(x^2-2x-3)=3(x-3)(x+1). $$

Setting \(f'(x)=0\) gives \(x=3\) or \(x=-1\). The second derivative is

$$ f''(x)=6x-6. $$

At \(c=-1\), \(f''(-1)=6(-1)-6=-12<0\), so \(x=-1\) is a local maximum. Its function value is

$$ f(-1)=(-1)^3-3(-1)^2-9(-1)+1=-1-3+9+1=6. $$

At \(c=3\), \(f''(3)=6(3)-6=12>0\), so \(x=3\) is a local minimum. Its function value is

$$ f(3)=3^3-3(3)^2-9(3)+1=27-27-27+1=-26. $$

Check the stationary-point calculations: \(f'(-1)=3(-1-3)(-1+1)=0\), and \(f'(3)=3(3-3)(3+1)=0\). Thus the classifications apply, and the graph points are \((-1,6)\) for the local maximum and \((3,-26)\) for the local minimum.

Worked Example: A Local Maximum of a Trigonometric Function

Classify the stationary point of \(f(x)=\sin x+\cos x\) at \(c=\frac{\pi}{4}\).

Sine and cosine are twice differentiable for all real \(x\), and \(\frac{\pi}{4}\) is an interior point of the domain. Differentiate:

$$ f'(x)=\cos x-\sin x, \qquad f''(x)=-\sin x-\cos x. $$

Since \(\sin(\frac{\pi}{4})=\cos(\frac{\pi}{4})=\frac{\sqrt{2}}{2}\),

$$ f'\left(\frac{\pi}{4}\right)=\frac{\sqrt{2}}{2}-\frac{\sqrt{2}}{2}=0, $$

and

$$ f''\left(\frac{\pi}{4}\right) =-\frac{\sqrt{2}}{2}-\frac{\sqrt{2}}{2} =-\sqrt{2}<0. $$

The hypotheses hold, so \(x=\frac{\pi}{4}\) is a local maximum. The function value is

$$ f\left(\frac{\pi}{4}\right)=\frac{\sqrt{2}}{2}+\frac{\sqrt{2}}{2}=\sqrt{2}. $$

Check: substituting into the first derivative gives \(f'(\frac{\pi}{4})=0\), and the second derivative is negative there. The local maximum point is \((\frac{\pi}{4},\sqrt{2})\).

Worked Example: A Local Minimum Involving a Logarithm

Classify the stationary point of \(f(x)=e^x-2x\).

The exponential function and the linear function are twice differentiable for all real \(x\), so the domain and differentiability conditions hold at any real candidate. First find the stationary point:

$$ f'(x)=e^x-2, \qquad e^x-2=0 \quad\Longrightarrow\quad e^x=2 \quad\Longrightarrow\quad x=\ln 2. $$

The second derivative is \(f''(x)=e^x\), so

$$ f''(\ln 2)=e^{\ln 2}=2>0. $$

Therefore \(x=\ln 2\) is a local minimum. Its function value is

$$ f(\ln 2)=e^{\ln 2}-2\ln 2=2-2\ln 2. $$

Check: \(f'(\ln 2)=e^{\ln 2}-2=2-2=0\), and \(f''(\ln 2)=2>0\). The local minimum point is \((\ln 2,2-2\ln 2)\).

Common Pitfall: Skipping the Hypothesis Check

A positive second derivative does not, by itself, classify every point as a local minimum. The test requires a stationary point and the stated differentiability and domain conditions. For instance, consider \(g(x)=x^2\) at \(c=1\). Although \(g''(1)=2>0\), the first derivative is \(g'(x)=2x\), so \(g'(1)=2\ne0\). The second derivative test in the theorem cannot classify \(x=1\), because it is not a stationary point.

Another common error is reversing the conclusions. For example, let \(h(x)=-x^2+4x\) and consider \(c=2\). Then \(h'(x)=-2x+4\), so \(h'(2)=-4+4=0\). Also, \(h''(x)=-2\), giving \(h''(2)=-2<0\). The correct conclusion is a local maximum, not a local minimum. As a check, \(h(2)=-4+8=4\), while \(h(2+t)=4-t^2<4\) for every nonzero \(t\), confirming the maximum.

Always pair the second-derivative sign with the verified stationary-point condition: negative means local maximum; positive means local minimum.

Why the Test Is Useful

Once stationary points have been found, the second derivative test can classify them by evaluating one additional derivative at each point. This is especially convenient when the second derivative is simple, as in a polynomial or exponential example. It also supplies a concise mathematical justification: the sign of \(f''(c)\) determines the nearby signs of \(f'\), which determine whether the function decreases then increases or increases then decreases.

The conclusions are local and conditional. The test does not state that a local maximum is an absolute maximum, and it does not apply merely because a second derivative has a particular sign somewhere. Its value comes from combining a checked stationary point with a strict second-derivative sign under the required hypotheses.

Check Your Understanding

For each question, state any hypothesis that must be checked before applying the test.

  1. If \(f'(c)=0\) and \(f''(c)=7\), what classification follows when the test's hypotheses hold?
  2. If \(f'(c)=0\) and \(f''(c)=-3\), what classification follows when the test's hypotheses hold?
  3. For \(p(x)=x^2+6x+5\), find its stationary point and classify it with the second derivative test.
  4. Why does the condition \(f'(c)=0\) matter when using the second derivative test?
  5. What does the test tell you about the function value at the classified point, and what does it not establish about the entire domain?

Test yourself: AP Calculus practice exams

Ready to check what you know? Work an AP-style practice exam, then open the full solutions.

Want all 1,114 practice problems?

This tutorial covers one topic. Calc Pass covers all of AP Calculus AB & BC: full review, every practice question, and step-by-step solutions to each one.

QR code to download the Calc Pass app

Get the Calc Pass App

Scan to download and practice on the go, with instant scoring.

Calc Pass Volume 1: 1,114 Practice Questions book cover

Vol. 1: 1,114 Questions

The complete practice question bank, organized by AB & BC topic.

View on Amazon
Calc Pass Volume 2: Solutions Manual book cover

Vol. 2: Solutions Manual

Fully worked solutions to every question in Volume 1.

View on Amazon