Second Derivative Test for Local Extrema

If a function has a horizontal tangent at a critical point and is concave up there, the point is a local minimum. If the function is concave down, it is a local maximum. This is the Second Derivative Test.

Condition Conclusion
f'(c)=0 and f''(c)>0 f has a local minimum at c
f'(c)=0 and f''(c)<0 f has a local maximum at c
f'(c)=0 and f''(c)=0 Test is inconclusive; use First Derivative Test

The Theorem

Two graphs: left shows a function with horizontal tangent and concave up (local min), right shows horizontal tangent and concave down (local max)
If f has a horizontal tangent at a point and is concave up, it has a local minimum; if concave down, it has a local maximum.

Suppose f'(c)=0.

(a) If f''(c)>0, then f has a local minimum at c .

(b) If f''(c)<0, then f has a local maximum at c .

Proof **(a)** Suppose f''(c)>0. By definition: f''(c)=\lim_{\Delta x\to0}\frac{f'(c+\Delta x)-f'(c)}{\Delta x}=\lim_{\Delta x\to0}\frac{f'(c+\Delta x)}{\Delta x} where we used f'(c)=0. Since f''(c)>0, for sufficiently small Δ x : \frac{f'(c+\Delta x)}{\Delta x}>0. Therefore: - For small Δ x < 0 : f'(c+\Delta x)<0, so f is decreasing to the left of c . - For small Δ x > 0 : f'(c+\Delta x)>0, so f is increasing to the right of c . By the First Derivative Test (sign changes from to + ), f has a local minimum at c . The proof of part (b) is analogous.

When the Test is Inconclusive

There are three situations where the Second Derivative Test gives no conclusion:

  1. f'(c)=f''(c)=0
  2. f'(c)=0 and f''(c) does not exist
  3. f'(c) does not exist

In these cases, c may be a local minimum, a local maximum, or neither. The three functions f ( x ) = x 4 , f ( x ) = x 4 , and f ( x ) = x 3 illustrate this: for all three, f'(0)=f''(0)=0, but x = 0 is a local minimum for x 4 , a local maximum for x 4 , and neither for x 3 .

Graphs of x^4 (local min at 0), -x^4 (local max at 0), and x^3 (neither at 0)

Whenever the Second Derivative Test is inconclusive, or when the second derivative is tedious to compute, use the First Derivative Test.

Examples

Use the Second Derivative Test to find the local extrema of f ( x ) = 1 2 x 3 3 2 x 2 + 1 .

Solution f'(x)=\frac{3}{2}x^2-3x=\frac{3}{2}x(x-2). Critical points: f'(0)=0 and f'(2)=0, so c = 0 and c = 2 . f''(x)=3x-3. At c = 0 : f''(0)=3(0)-3=-3<0\quad(\text{concave down})\Rightarrow f\text{ has a local maximum at }x=0. At c = 2 : f''(2)=3(2)-3=3>0\quad(\text{concave up})\Rightarrow f\text{ has a local minimum at }x=2.
Graph of f(x) = (1/2)x^3 - (3/2)x^2 + 1 showing local max at x=0 and local min at x=2
Graph of f ( x ) = 1 2 x 3 3 2 x 2 + 1 .

Use the Second Derivative Test to find the local extrema of f ( x ) = x 2 4 x + 5 x 2 + 1 .

Solution Using the quotient rule: f'(x)=\frac{(2x-4)(x^2+1)-2x(x^2-4x+5)}{(x^2+1)^2}=\frac{4(x^2-2x-1)}{(x^2+1)^2}. Setting f'(x)=0: x 2 2 x 1 = 0 x = 1 ± 2 . Critical points: c 1 = 1 + 2 and c 2 = 1 2 . For f'', at a critical point x 2 2 x 1 = 0 , so the complicated term involving this factor drops out: f''(c_{1,2})\propto(2c_{1,2}-2)=2(c_{1,2}-1). The sign of f'' at each critical point equals the sign of c 1 : \text{sgn}(f''(1+\sqrt{2}))=\text{sgn}(\sqrt{2})>0\Rightarrow\text{local minimum at }x=1+\sqrt{2}. \text{sgn}(f''(1-\sqrt{2}))=\text{sgn}(-\sqrt{2})<0\Rightarrow\text{local maximum at }x=1-\sqrt{2}.
Graph of y = (x^2 - 4x + 5)/(x^2 + 1) showing local max at x = 1-sqrt(2) and local min at x = 1+sqrt(2)
Graph of y = x 2 4 x + 5 x 2 + 1 .

Use the Second Derivative Test to find the local maxima and minima of f ( x ) = 2 sin x + cos 2 x .

Solution Since f is periodic with period 2 π , we work on [ 0 , 2 π ] . f'(x)=2\cos x-2\sin2x=2\cos x-4\sin x\cos x=2\cos x(1-2\sin x). Setting f'(x)=0: cos x = 0 x = π 2 ,   3 π 2 1 2 sin x = 0 sin x = 1 2 x = π 6 ,   5 π 6
Unit circle showing solutions to sin x = 1/2 in [0, 2pi]
Solutions of sin x = 1 2 in [ 0 , 2 π ] : x = π 6 and x = 5 π 6 .
Critical points: c 1 = π 6 , c 2 = π 2 , c 3 = 5 π 6 , c 4 = 3 π 2 . f''(x)=-2\sin x-4\cos2x. At c 1 = π / 6 : f''\!\left(\frac{\pi}{6}\right)=-2\cdot\frac{1}{2}-4\cdot\frac{1}{2}=-3<0\Rightarrow\textbf{local maximum}. At c 2 = π / 2 : f''\!\left(\frac{\pi}{2}\right)=-2(1)-4(-1)=2>0\Rightarrow\textbf{local minimum}. At c 3 = 5 π / 6 : f''\!\left(\frac{5\pi}{6}\right)=-2\cdot\frac{1}{2}-4\cdot\frac{1}{2}=-3<0\Rightarrow\textbf{local maximum}. At c 4 = 3 π / 2 : f''\!\left(\frac{3\pi}{2}\right)=-2(-1)-4(-1)=2>0\Rightarrow\textbf{local minimum}.
Graph of y = 2 sin x + cos 2x showing local maxima at pi/6 and 5pi/6, and local minima at pi/2 and 3pi/2
Graph of y = 2 sin x + cos 2 x .

Frequently Asked Questions

Which test is better to use: the First or Second Derivative Test? Neither is universally better. The Second Derivative Test requires less work when f'' is easy to compute and f''(c)\neq0. But it fails when f''(c)=0 or f''(c) does not exist. The First Derivative Test always works for continuous functions and is more reliable, though it requires analyzing a sign diagram.

What happens if f'(c) ≠ 0? The Second Derivative Test requires f'(c)=0 as its starting point. If f'(c)\neq0, then c is not even a critical point, and the function cannot have a local extremum at c (by Fermat's Theorem).

If f''(c) = 0, is the point always an inflection point? Not necessarily. It could be a local extremum ( f ( x ) = x 4 has a local minimum at x = 0 with f''(0)=0), an inflection point ( f ( x ) = x 3 has an inflection point at x = 0 with f''(0)=0), or even a local maximum. You must use the First Derivative Test to determine which.