Second Derivative Test

Calculus & Advanced Math

The second derivative test classifies a critical point using the sign of the second derivative: positive means local min, negative means local max.

Formula

f'(c)=0: \text{ if } f''(c)>0 \text{ then min; if } f''(c)<0 \text{ then max}
Visualization

Definition

At a critical point, the second derivative test checks whether the curve bends upward or downward there: bending up (positive second derivative) means a valley (local min), bending down (negative) means a hilltop (local max). If $f'(c) = 0$ and $f''(c) > 0$, then $c$ is a local minimum; if $f''(c) < 0$, a local maximum; if $f''(c) = 0$, the test is inconclusive and you must fall back on the first derivative test or higher derivatives. It is really a special case of the Taylor expansion around $c$: the sign of $f''(c)$ determines whether the quadratic term creates a local min or max, and in multivariable calculus the test uses the eigenvalues of the Hessian matrix.

Example

For $f(x) = x^2$: $f'(x) = 2x = 0$ at $x = 0$, and $f''(x) = 2 > 0$ everywhere confirms a local minimum. For $f(x) = x^3 - 12x$: $f' = 3x^2 - 12 = 0$ at $x = \pm 2$, and $f'' = 6x$ gives $f''(2) = 12 > 0$ (local min) and $f''(-2) = -12 < 0$ (local max). In two variables, at a critical point compute the Hessian $H = \begin{bmatrix} f_{xx} & f_{xy} \\ f_{yx} & f_{yy} \end{bmatrix}$: $\det(H) > 0$ with $f_{xx} > 0$ gives a local min, $\det(H) > 0$ with $f_{xx} < 0$ gives a local max, and $\det(H) < 0$ gives a saddle point.

Key Insight

Think of concavity: if the cup opens up at the critical point, you are at the bottom (min); if it opens down, you are at the top (max). The test is quick and clean when it works but fails when $f''(c) = 0$, so the first derivative test is the fallback. The Hessian-based version directly generalizes to optimization in machine learning, where second-order methods like Newton's method and quasi-Newton methods use curvature information to converge faster than gradient descent.