Local Maximum

Calculus & Advanced Math

A local maximum is a point on a function that is higher than all nearby points, like the top of a hill.

Formula

f(c) \ge f(x) \text{ for all } x \text{ near } c

Definition

A local maximum is the highest point in a neighborhood, like the top of a hill. Nearby points are all lower, even if there are higher peaks elsewhere.

Example

A roller coaster has many local maxima at the tops of its hills. Each hilltop is higher than the track right around it, but might not be the highest point of the whole ride.

Key Insight

"Local" means only the immediate neighborhood counts. You do not compare to points far away.

Definition

$f$ has a local maximum at $c$ if $f(c) \ge f(x)$ for all $x$ in some open interval around $c$. At a local max (if $f$ is differentiable), $f'(c) = 0$ and $f$ changes from positive to negative there.

Example

$f(x) = -x^2 + 4x$: $f'(x) = -2x + 4 = 0$ at $x = 2$. $f''(2) = -2 < 0$, confirming a local (and global) maximum at $f(2) = 4$.

Key Insight

A local maximum always occurs at a critical point, but not all critical points are local maxima. The first or second derivative test distinguishes them.

Definition

$c$ is a strict local maximum if there exists $\epsilon > 0$ such that $f(c) > f(x)$ for all $x$ in $(c - \epsilon, c + \epsilon)$ with $x \neq c$. For smooth $f$, the second-order condition $f''(c) < 0$ is sufficient (but not necessary). In multivariable calculus, the Hessian must be negative definite.

Example

$f(x) = -x^4$ has a local max at $0$ with $f'(0) = 0$ and $f''(0) = 0$ (second derivative test inconclusive), yet it is clearly a maximum.

Key Insight

In convex optimization, local maxima of concave functions are global. In non-convex settings (neural network training), distinguishing local maxima from saddle points is a central challenge.