Applications of Differentiation · Maxima & Minima

Maxima and Minima — Finding Where Functions Peak and Valley

The derivative's most powerful application is locating the highest and lowest points of a function. Whether you are maximising profit, minimising drag, or finding the turning point of a curve, it all comes down to finding where f′ = 0: and then checking whether that point is a peak, a valley, or neither.

Share this page

§ 01Local vs Global — Two Types of Extreme Value

A function can have many peaks and valleys scattered across its domain, and one overall highest and lowest point. The first are called local extrema; the second are called global (or absolute) extrema. Every problem in optimisation is ultimately asking for one of these two things.

The definitions are precise. A local maximum at x = c means f(c) ≥ f(x) for all x near c, the function is higher there than anywhere in some open interval around c. A local minimum is the same idea but lower. A global maximum means f(c) ≥ f(x) for every x in the domain, nothing anywhere is higher.

x y local max local min global max local min local max f(x)
A single function can have multiple local maxima and minima. The global maximum is the highest point on the entire curve. Local extrema are only highest or lowest in their immediate neighbourhood.
Prerequisites You need confident differentiation — the chain rule, product rule, and standard derivatives (xⁿ, eˣ, ln x, trig functions). Familiarity with solving polynomial and trigonometric equations is also essential.

§ 02Critical Points — Where to Look

Every local extremum hides at a critical point. A critical point of f is any value x = c in the domain where either f′(c) = 0 or f′(c) does not exist. This is Fermat's Theorem in action:

Theorem
Fermat's Theorem
If f has a local maximum or minimum at x = c, and if f is differentiable at c, then f′(c) = 0. Therefore every local extremum is a critical point — but not every critical point is an extremum.

The second sentence is crucial. The classic counter-example is f(x) = x³ at x = 0: f′(0) = 0 so x = 0 is a critical point, but f is increasing on both sides: no extremum at all. Setting f′ = 0 gives candidates; a further test determines whether each candidate is a maximum, minimum, or neither.

Definition — Critical Point
x = c is a critical point if f′(c) = 0 or f′(c) is undefined

Also called a stationary point (for the f′ = 0 case). Points where f′ doesn't exist, corners, cusps, vertical tangents, are critical points even though the derivative test doesn't apply there directly.

Step 1 in Every Extremum Problem — Find all Critical Points

  • Differentiate f to find f′(x).

  • Set f′(x) = 0 and solve. These are the stationary points.

  • Find where f′(x) does not exist within the domain of f. Include these too.

  • You now have a complete list of critical point candidates. Test each one.

§ 03The First Derivative Test

The first derivative test classifies a critical point by examining the sign of f′ on either side of it. The logic is geometric: if f′ changes from positive to negative, the function was rising then falling, that is a peak. If f′ changes from negative to positive, it was falling then rising, that is a valley.

Theorem
First Derivative Test
Let c be a critical point of f. Then:

If f′ changes from + to − at c → f has a local maximum at c.
If f′ changes from − to + at c → f has a local minimum at c.
If f′ does not change sign at c → f has neither a maximum nor a minimum (e.g., an inflection point).

The practical tool is a sign chart: divide the real line at every critical point, then evaluate the sign of f′ in each interval by plugging in a test value.

1st Deriv. TestClassify the extrema of f(x) = x³ − 3x
  1. Differentiate: f′(x) = 3x² − 3 = 3(x²−1) = 3(x−1)(x+1).
  2. Critical points: f′(x) = 0 → x = 1 and x = −1.
  3. Sign chart: test x = −2, 0, 2 in f′(x):
IntervalTest pointf′ signf behaviour
(−∞, −1)x = −2+Increasing ↗
x = −10Local MAX
(−1, 1)x = 0Decreasing ↘
x = 10Local MIN
(1, ∞)x = 2+Increasing ↗
  1. f(−1) = −1−3(−1) = 2 → local max at (−1, 2).
  2. f(1) = 1−3 = −2 → local min at (1, −2).
Local max: (−1, 2)  |  Local min: (1, −2)
1st Deriv. TestClassify extrema of f(x) = x⁴ − 8x²
  1. f′(x) = 4x³ − 16x = 4x(x²−4) = 4x(x−2)(x+2).
  2. Critical points: x = −2, 0, 2.
  3. Signs: f′ < 0 on (−∞,−2), f′ > 0 on (−2,0), f′ < 0 on (0,2), f′ > 0 on (2,∞).
  4. At x=−2: − to + → local min.   At x=0: + to − → local max.   At x=2: − to + → local min.
  5. Values: f(±2) = 16−32 = −16.   f(0) = 0.
Local minima at (±2, −16)  |  Local max at (0, 0)
1st Deriv. Testf(x) = |x| — critical point where f′ is undefined
  1. f′(x) = −1 for x < 0, and f′(x) = 1 for x > 0. At x = 0, f′ is undefined (corner).
  2. Sign of f′ changes from − to + at x = 0 → local (and global) minimum at x = 0.
Global minimum at (0, 0). Fermat's theorem does not apply here (f not differentiable at 0) — yet we still find the minimum using the sign of f′.

§ 04The Second Derivative Test

Once a stationary point (f′(c) = 0) is found, the second derivative f″(c) often classifies it instantly: no sign chart needed.

Concave Up → Minimum
f″(c) > 0
If f′(c) = 0 and f″(c) > 0, the curve is concave up at c — like a bowl. The function has a local minimum at c.
f′(c)=0, f″(c)>0 → local min
Concave Down → Maximum
f″(c) < 0
If f′(c) = 0 and f″(c) < 0, the curve is concave down at c — like an arch. The function has a local maximum at c.
f′(c)=0, f″(c)<0 → local max
When the Second Derivative Test Fails If f″(c) = 0, the test is inconclusive. The point could be a local max, a local min, or an inflection point. You must fall back to the first derivative test. Classic example: f(x) = x⁴ has f′(0) = 0 and f″(0) = 0, yet x = 0 is a global minimum.
concave up local min f″ > 0 concave down local max f″ < 0
Concave up (f″ > 0) means the tangent slope is increasing — the curve bends upward like a bowl, giving a local minimum. Concave down (f″ < 0) means the tangent slope is decreasing — the curve bends like an arch, giving a local maximum.
2nd Deriv. TestClassify the critical points of f(x) = x³ − 3x using f″
  1. From §03: critical points x = ±1. f″(x) = 6x.
  2. f″(−1) = −6 < 0 → local maximum at x = −1.
  3. f″(1) = 6 > 0 → local minimum at x = 1.
Matches the first derivative test: local max at (−1, 2), local min at (1, −2).
2nd Deriv. Testf(x) = x⁴ — second derivative test inconclusive at x = 0
  1. f′(x) = 4x³ = 0 → x = 0.   f″(x) = 12x² → f″(0) = 0. Test fails.
  2. Use first derivative test: f′(x) = 4x³ < 0 for x < 0, > 0 for x > 0 → sign changes − to + → local (global) minimum.
x = 0 is a global minimum at (0, 0). The SDT gave no information here.
2nd Deriv. TestClassify extrema of f(x) = 2sin x − x on [0, 2π]
  1. f′(x) = 2cos x − 1 = 0 → cos x = 1/2 → x = π/3, 5π/3.
  2. f″(x) = −2sin x.
  3. f″(π/3) = −2sin(π/3) = −√3 < 0 → local max at x = π/3.
  4. f″(5π/3) = −2sin(5π/3) = √3 > 0 → local min at x = 5π/3.
  5. Values: f(π/3) = √3 − π/3 ≈ 0.685.   f(5π/3) = −√3 − 5π/3 ≈ −6.97.
Local max at x = π/3, local min at x = 5π/3.

§ 05Absolute Extrema and the Closed Interval Method

Local extrema tell us about peaks and valleys in the interior. But many real problems ask for the absolute best or worst over a specific range, that is the global extremum on a closed, bounded interval.

Theorem
Extreme Value Theorem (EVT)
If f is continuous on a closed, bounded interval [a, b], then f attains both its absolute maximum and its absolute minimum on [a, b]. These values occur either at a critical point inside (a, b) or at one of the endpoints a or b.

The EVT guarantees existence. Finding those values is mechanical: the Closed Interval Method:

  • Find all critical points of f in the open interval (a, b).

  • Evaluate f at each critical point and at both endpoints a and b.

  • The largest value is the absolute maximum; the smallest is the absolute minimum.

Endpoints Always Count The global maximum or minimum of a function on [a, b] may occur at an endpoint, not at any interior critical point. Never omit endpoint evaluations. For unrestricted domains (−∞, ∞), you must also analyse behaviour as x → ±∞.
AbsoluteFind the absolute max and min of f(x) = x³ − 3x on [−2, 3]
  1. f′(x) = 3x²−3 = 0 → critical points x = ±1. Both lie in (−2, 3).
  2. Evaluate at critical points and endpoints:
xf(x) = x³ − 3xType
−2 (endpoint)−8+6 = −2Endpoint
−1 (critical)−1+3 = 2Critical pt
1 (critical)1−3 = −2Critical pt
3 (endpoint)27−9 = 18Endpoint
Absolute maximum: 18 at x = 3  |  Absolute minimum: −2 at x = −2 and x = 1
AbsoluteFind the absolute extrema of f(x) = x² − 4x + 3 on [0, 5]
  1. f′(x) = 2x − 4 = 0 → x = 2. Lies in (0, 5).
  2. f(0) = 3, f(2) = 4−8+3 = −1, f(5) = 25−20+3 = 8.
Absolute max: 8 at x = 5  |  Absolute min: −1 at x = 2
AbsoluteFind the absolute extrema of f(x) = sin x + cos x on [0, 2π]
  1. f′(x) = cos x − sin x = 0 → tan x = 1 → x = π/4, 5π/4.
  2. Evaluate: f(0) = 1, f(π/4) = √2, f(5π/4) = −√2, f(2π) = 1.
Absolute max: √2 at x = π/4  |  Absolute min: −√2 at x = 5π/4

§ 06Further Worked Examples

1st Deriv. Testf(x) = x · eˣ — extrema on (−∞, ∞)
  1. f′(x) = eˣ + x·eˣ = eˣ(1+x). Since eˣ > 0 always, f′ = 0 only when 1+x = 0 → x = −1.
  2. For x < −1: (1+x) < 0, so f′ < 0.   For x > −1: (1+x) > 0, so f′ > 0.
  3. Sign changes − to + → local (and global) minimum.
  4. f(−1) = −1·e⁻¹ = −1/e ≈ −0.368.
Global minimum at (−1, −1/e). No maximum — f → ∞ as x → ∞.
2nd Deriv. Testf(x) = ln x − x — find and classify all critical points
  1. Domain: x > 0.   f′(x) = 1/x − 1 = 0 → x = 1.
  2. f″(x) = −1/x².   f″(1) = −1 < 0 → local (and global) maximum.
  3. f(1) = 0 − 1 = −1. As x→0⁺ f→−∞; as x→∞ f→−∞. So this is the global max.
Global maximum at (1, −1).
Absolutef(x) = 2x³ − 9x² + 12x − 3 on [0, 3]
  1. f′(x) = 6x² − 18x + 12 = 6(x²−3x+2) = 6(x−1)(x−2). Critical points: x = 1, 2.
  2. f(0) = −3.   f(1) = 2−9+12−3 = 2.   f(2) = 16−36+24−3 = 1.   f(3) = 54−81+36−3 = 6.
Absolute max: 6 at x = 3  |  Absolute min: −3 at x = 0

§ 07Quick Reference — Choosing the Right Test

MethodWhen to useWhat it requiresLimitation
First Derivative TestAlways — never failsSigns of f′ on either side of cSlightly more work than SDT
Second Derivative TestWhen f″ is easy to computef′(c) = 0 and f″(c) ≠ 0Fails when f″(c) = 0
Closed Interval MethodAbsolute extrema on [a, b]Continuity on [a, b]Only works on closed intervals

Common Mistakes

Mistake 1 — Confusing critical points with extrema Not every critical point is an extremum. f(x) = x³ has f′(0) = 0 but no extremum at x = 0 — it is an inflection point. Always apply the first or second derivative test.
Mistake 2 — Omitting endpoints in the Closed Interval Method The absolute extremum on [a, b] often occurs at an endpoint. Only evaluating interior critical points is a very common and costly error.
Mistake 3 — Applying the EVT on an open interval The EVT requires a closed bounded interval. On (0, 1), the function f(x) = 1/x is continuous but has no minimum — the EVT doesn't apply here.
Mistake 4 — Trusting the SDT when f″(c) = 0 If f″(c) = 0, stop and use the first derivative test instead. The SDT gives no information when the second derivative is zero at the critical point.

§ 08Test Yourself — 10-Question Quiz

Score: 0 / 0
Question 1 of 10

What is a critical point of f?

A critical point is any x in the domain where f′(x) = 0 (stationary point) or f′(x) does not exist. These are the only candidates for local extrema by Fermat's Theorem.

Question 2 of 10

How many critical points does f(x) = x³ − 3x have?

  1. f′(x) = 3x²−3 = 3(x−1)(x+1) = 0 → x = 1 and x = −1.
  2. Two critical points.
Question 3 of 10

For the first derivative test, a critical point is a local maximum when:

f′ changes from + to −: the function was increasing then decreasing: that is a peak (local max). f′ changes from − to + gives a local minimum.

Question 4 of 10

For f(x) = x³ − 3x, the second derivative is f″(x) = 6x. What does f″(1) tell us about x = 1?

f″(1) = 6 > 0 means concave up at x = 1 (a bowl shape) so x = 1 is a local minimum. f(1) = 1−3 = −2.

Question 5 of 10

Find the absolute maximum of f(x) = x² − 4x + 1 on [0, 4].

  1. f′=2x−4=0 → x=2. Evaluate: f(0)=1, f(2)=4−8+1=−3, f(4)=16−16+1=1.
  2. Absolute max = 1 (attained at both x=0 and x=4). Absolute min = −3 at x=2.
Question 6 of 10

The second derivative test is inconclusive (gives no information) when:

When f′(c) = 0 and f″(c) = 0 the SDT gives no information. The point could be a max, min, or inflection. Use the first derivative test instead.

Question 7 of 10

Find the x-coordinate of the local minimum of f(x) = x⁴ − 8x². (There are two: enter the positive one.)

  1. f′ = 4x(x−2)(x+2) = 0 → x = 0, ±2.
  2. Sign chart: f′ goes − to + at x = 2 and x = −2 (local minima). f′ goes + to − at x = 0 (local max).
  3. Positive local min at x = 2. f(2) = 16−32 = −16.
Question 8 of 10

The Extreme Value Theorem guarantees that a function attains both its absolute max and min on [a, b] provided the function is:

The EVT requires continuity on the closed interval [a, b]. Differentiability is not needed. A continuous function on a closed interval is guaranteed to attain its extreme values.

Question 9 of 10

What is the absolute minimum value of f(x) = x³ − 3x on [−2, 3]? (from Example 7)

From the closed interval method: f(−2)=−2, f(−1)=2, f(1)=−2, f(3)=18. The minimum value is −2, attained at both x=−2 and x=1.

Question 10 of 10

f(x) = x³ has f′(0) = 0. What type of point is x = 0?

f′(x) = 3x². At x = 0: f′ = 0, but f′ > 0 on both sides (no sign change). So x = 0 is a critical point that is neither a max nor a min, it is an inflection point. f is increasing through it.

Quiz complete!

Cookie Settings