Local extrema
Critical points, stationary points and the Hessian test for local maxima, minima and saddles.
This page locates and classifies the local extrema of a function of several variables. At a stationary point the tangent plane is horizontal, which does not say whether the graph is a hill, a valley or a saddle. First-order calculus locates the candidates; the quadratic part of the multivariable Taylor model classifies them.
Local and absolute extrema
Local and absolute extrema
Let and let .
- has a local minimum at if for every in sufficiently close to .
- has a local maximum at if for every in sufficiently close to .
- has an absolute, or global, minimum at if for every .
- has an absolute maximum at if for every .
A local classification cannot settle a global optimisation problem.
Critical and stationary points
Critical and stationary points
For , an interior point is a critical point if is not differentiable at or if . A point at which the gradient exists and is zero is called a stationary point.
Critical points include points where differentiability fails because such points can still be extrema. The stationary-point equations locate only the critical points with zero gradient; boundary points are handled separately in a global-extrema problem.
The multivariable Fermat condition
If all first partial derivatives of exist at an interior local maximum or local minimum , then
Differentiability is sufficient for the partial derivatives to exist, but is stronger than what this coordinatewise condition needs. The condition is necessary, not a classification: a stationary point may be a local maximum, a local minimum, a saddle, or a point requiring higher-order analysis.
Fix a coordinate direction and vary only that coordinate through . Since is an interior local extremum of , the resulting one-variable function also has a local extremum at the corresponding coordinate value. The one-variable Fermat condition makes the associated partial derivative zero. Repeating this for every coordinate gives
which is exactly .
Find stationary points
For a function :
- calculate and ;
- solve
- retain the simultaneous solutions in the domain;
- classify each candidate using local geometry or the Hessian test.
For a complete search for interior extrema, also inspect points where is not differentiable; the stationary equations cannot detect those points.
[routine]
The Fermat condition needs only the coordinate partial derivatives, but their existence does not guarantee differentiability, which the tangent-plane and directional-derivative formulas require. Partial derivatives inspect only the coordinate paths and may miss behaviour along other directions.
Zero partial derivatives without differentiability
Define
Along the coordinate axes,
so
However, along ,
The function is therefore not continuous at the origin and cannot be differentiable there, even though its two partial derivatives exist and vanish.
[challenge]
The geometry of a stationary point
At a stationary point of the graph , the tangent plane has equation
because both first partial derivatives vanish.
A saddle point is a point for which every neighbourhood within the domain contains points with both larger and smaller function values than . A saddle is neither a local maximum nor a local minimum.
A saddle from two directions
For
the only stationary point is because
Along ,
whereas along ,
Every neighbourhood of the origin contains larger and smaller values than , so the origin is a saddle point.
[routine]
Classifying stationary points
The gradient gives the linear part of the local model. At a stationary point that part vanishes, so the Hessian supplies the next term to inspect. If the quadratic part also vanishes in some directions, higher-order terms may matter.
Hessian matrix
For , the Hessian at is
The second-order partial derivative test
Let be a stationary point. Assume that has continuous second-order partial derivatives on a neighbourhood of (so is there). Define
Then:
- if and , is a local minimum;
- if and , is a local maximum;
- if , is a saddle point;
- if , the test is inconclusive.
At a stationary point, the quadratic Taylor term is
For a symmetric Hessian, this quadratic form is positive definite if it is positive for every nonzero , negative definite if it is negative for every nonzero and indefinite if it takes both positive and negative values. The test uses and to tell these cases apart.
When , the quadratic form has one sign in all non-zero directions and determines whether that sign is positive or negative. When , the form changes sign, which is the algebraic signature of a saddle. If , higher-order terms or direct comparisons along curves are required.
To see the determinant rule when , write , and . Then and the quadratic part satisfies
Both coefficients on the right have the sign of , so small nonzero displacements change in the same direction.
For intuition, a symmetric Hessian has principal directions described by its eigenvectors. Its eigenvalues give the curvatures in those directions: both positive suggests a local minimum, both negative a local maximum and opposite signs a saddle. In two variables, is the product of those two eigenvalues, while picks the sign when they agree.
Classify a stationary point
For each stationary point:
- calculate the Hessian entries at the point;
- compute ;
- use the sign of and then the sign of when ;
- if , inspect higher-order terms or compare the function along carefully chosen curves.
Standard quadratic surfaces
For
the Hessian at the origin is
Thus the origin is a local minimum; everywhere, so it is also a global minimum.
For
we have and , so the origin is a local maximum.
For
the Hessian is
The origin is therefore a saddle; the two coordinate axes show this directly.
[routine]
Classifying the stationary points of a cubic
Let
The first derivatives are
Thus
so . The stationary points are and .
The Hessian is
At ,
so the origin is a saddle. At ,
Therefore is a local minimum. Its value is
[exam]
Checking a positive factor for new stationary points
Let
The derivatives factor as
The exponential factors and the terms , are always positive. Both derivatives therefore vanish only at . At that point,
The origin is a saddle. In this example, the derivative factors prove that the positive exponential adds no stationary points; positivity of a factor alone would not guarantee that for every product.
[challenge]
Revisiting the polynomial stationary points
For
the Hessian and its determinant are
At ,
so is a local minimum. At ,
so that point is a saddle.
[exam]
Local classification compares values only near one point. On a closed and bounded region, the absolute maximum and minimum also require every boundary piece; the global extrema page sets out that search.