First Derivative Test

The first derivative test uses the sign of f′ to find where a function increases or decreases and to classify its critical points. If f′ changes from positive to negative at a critical number c, f has a local maximum at c. If f′ changes from negative to positive, f has a local minimum.

Before this lesson: Critical Points, Mean Value Theorem and Polynomial Inequalities

Increasing, decreasing and the sign of f′

Where f'(x) \gt 0, the tangent lines slope up, so f is increasing. Where f'(x) \lt 0, f is decreasing. (The mean value theorem is what makes this true.)

A local maximum is a point higher than every nearby point: the graph rises into it and falls after it. A local minimum is lower than every nearby point: the graph falls into it and rises after it. Together they are called local extrema.

Graph of f(x) = x³ − 3x² − 9x + 2 for x from −3 to 5.5, with a sign chart for f′ above it. f′ is positive for x < −1, negative between −1 and 3, and positive for x > 3. The graph rises to a local maximum at (−1, 7), falls to a local minimum at (3, −25), then rises again.
Where f′ changes from + to −, the graph peaks; where it changes from − to +, the graph bottoms out.

The first derivative test

Sign of f′ around cWhat happens at c
+ then −Local maximum
− then +Local minimum
+ then +, or − then −No local extremum
  1. Find the critical numbers of f.
  2. Mark them on a number line. They split it into intervals.
  3. Pick a test value in each interval and find the sign of f′ there. This is a sign chart.
  4. Read off where f is increasing (+) and decreasing (−).
  5. Classify each critical number with the table, and find f(c) for the extreme values.

Also mark x-values that are not in the domain (like an asymptote) on the sign chart. f′ can change sign there, but they are not extrema.

First derivative test examples

Example 1: A cubic

Find where f(x) = x^3 - 3x^2 - 9x + 2 is increasing and decreasing, and find its local extrema.

f'(x) = 3x^2 - 6x - 9

Differentiate.

f'(x) = 3(x - 3)(x + 1)

Factor out 3, then factor the trinomial (see factoring trinomials).

x = -1, \; x = 3

The critical numbers.

f'(-2) = 3(-5)(-1) = 15

Test x = −2 in (−∞, −1): positive.

f'(0) = 3(-3)(1) = -9

Test x = 0 in (−1, 3): negative.

f'(4) = 3(1)(5) = 15

Test x = 4 in (3, ∞): positive.

f(-1) = -1 - 3 + 9 + 2 = 7

+ to − at x = −1: local maximum value.

f(3) = 27 - 27 - 27 + 2 = -25

− to + at x = 3: local minimum value.

Answer: f is increasing on (−∞, −1) and (3, ∞), and decreasing on (−1, 3). It has a local maximum of 7 at x = −1 and a local minimum of −25 at x = 3.

Example 2: A critical point that is not an extremum

Classify the critical numbers of f(x) = x^4 - 4x^3.

f'(x) = 4x^3 - 12x^2 = 4x^2(x - 3)

Differentiate and factor out 4x².

x = 0, \; x = 3

The critical numbers.

f'(-1) = 4(1)(-4) = -16

Test x = −1: negative.

f'(1) = 4(1)(-2) = -8

Test x = 1: negative. No sign change at 0.

f'(4) = 4(16)(1) = 64

Test x = 4: positive.

f(3) = 81 - 108 = -27

− to + at x = 3: local minimum value.

Answer: x = 0 is not an extremum (f′ stays negative; the graph just flattens for a moment). There is a local minimum of −27 at x = 3. The factor x² never changes sign, which is why nothing happens at 0.

Example 3: A critical point where f′ is undefined

Find the local extrema of f(x) = x - 3x^{2/3}.

f'(x) = 1 - 2x^{-1/3}

Power rule: (3)(2/3) = 2 and 2/3 − 1 = −1/3.

f'(x) = \frac{x^{1/3} - 2}{x^{1/3}}

Write it as one fraction.

x = 8, \; x = 0

The numerator is 0 when x^(1/3) = 2, so x = 8. The denominator is 0 at x = 0.

f'(-1) = \frac{-1 - 2}{-1} = 3

Test x = −1: positive.

f'(1) = \frac{1 - 2}{1} = -1

Test x = 1: negative.

f'(27) = \frac{3 - 2}{3} = \frac{1}{3}

Test x = 27: positive.

f(0) = 0, \; f(8) = 8 - 3(4) = -4

8^(2/3) = 4.

Answer: a local maximum of 0 at x = 0 (a sharp peak, or cusp) and a local minimum of −4 at x = 8.

Example 4: An exponential function

Find the local extrema of f(x) = xe^{-x}.

f'(x) = e^{-x} - xe^{-x} = e^{-x}(1 - x)

Product rule, then factor out e^(−x).

x = 1

e^(−x) is always positive, so only 1 − x = 0.

f'(0) = 1 \cdot 1 = 1, \; f'(2) = e^{-2}(-1) \lt 0

Test on each side: + then −.

f(1) = e^{-1} \approx 0.368

Local maximum value.

Answer: f increases on (−∞, 1), decreases on (1, ∞), and has a local maximum of \frac{1}{e} \approx 0.368 at x = 1.

Example 5: Word problem with app users

An app’s daily users (in thousands) t days after an update are U(t) = t^3 - 15t^2 + 63t for 0 \le t \le 10. When were users rising and falling, and when were there local highs and lows?

U'(t) = 3t^2 - 30t + 63 = 3(t - 3)(t - 7)

Differentiate and factor.

t = 3, \; t = 7

Critical numbers.

U'(1) = 3(-2)(-6) = 36

Test t = 1: positive.

U'(5) = 3(2)(-2) = -12

Test t = 5: negative.

U'(8) = 3(5)(1) = 15

Test t = 8: positive.

U(3) = 27 - 135 + 189 = 81

Local maximum value.

U(7) = 343 - 735 + 441 = 49

Local minimum value.

Answer: users rose for the first 3 days to a local high of 81,000, fell until day 7 to a local low of 49,000, then rose again through day 10.

Common mistakes

MistakeExample of the errorFix
Calling every critical point an extremumSaying x = 0 is a min of x^4 - 4x^3Check the sign on both sides. No sign change means no extremum.
Testing the sign of f instead of f′Using f(−2) to decide if f is increasingIncreasing and decreasing come from the sign of f′.
Giving x when the value is asked“The local max is −1” for Example 1The max occurs at x = −1; its value is f(−1) = 7.
Forgetting where f′ is undefinedMissing x = 0 for x - 3x^{2/3}Include points where f′ does not exist, if f is defined there.
Including an asymptote as an extremumCalling x = 0 an extremum of x + \frac{4}{x}x = 0 is not in the domain. Mark it on the chart, but don’t classify it.

Related methods

The second derivative test

Instead of a sign chart, you can sometimes check the sign of f″ at a critical point where f′ = 0. That is the second derivative test, later in this unit.

Absolute extrema

The first derivative test finds local extrema. To find the highest and lowest values on a closed interval, compare f at the critical numbers and at the endpoints. That is the next lesson, Absolute Extrema.

Practice problems

  1. Find the intervals of increase and decrease and the local extrema of f(x) = x^2 - 6x + 5.
  2. Find the local extrema of f(x) = x^3 - 12x.
  3. Find the local extrema of f(x) = 2x^3 + 3x^2 - 12x.
  4. Does f(x) = x^3 have a local extremum at x = 0?
  5. Find the local extrema of f(x) = x^4 - 2x^2.
  6. Find the local extrema of f(x) = \frac{x}{x^2 + 1}.
  7. Find the local extremum of f(x) = x\ln x.
  8. Find the local extremum of f(x) = |x + 2|.
  9. Find the local extrema of f(x) = x + \frac{4}{x}.
  10. Find the local extrema of f(x) = \sin x + \cos x on (0, 2π).
Show answers

1.

f'(x) = 2x - 6 = 0 \Rightarrow x = 3

Differentiate and solve.

f'(0) = -6, \; f'(4) = 2

Test each side: − then +.

f(3) = 9 - 18 + 5 = -4

Local minimum value.

Answer: decreasing on (−∞, 3), increasing on (3, ∞); local min −4 at x = 3

2.

f'(x) = 3x^2 - 12 = 3(x - 2)(x + 2)

Differentiate and factor.

f'(-3) = 15, \; f'(0) = -12, \; f'(3) = 15

Signs: +, −, +.

f(-2) = -8 + 24 = 16, \; f(2) = 8 - 24 = -16

Evaluate f.

Answer: local max 16 at x = −2; local min −16 at x = 2

3.

f'(x) = 6x^2 + 6x - 12 = 6(x + 2)(x - 1)

Differentiate and factor.

f'(-3) = 24, \; f'(0) = -12, \; f'(2) = 24

Signs: +, −, +.

f(-2) = -16 + 12 + 24 = 20, \; f(1) = 2 + 3 - 12 = -7

Evaluate f.

Answer: local max 20 at x = −2; local min −7 at x = 1

4.

f'(x) = 3x^2

Differentiate.

f'(-1) = 3, \; f'(1) = 3

Positive on both sides of 0.

Answer: no. f′ does not change sign, so x = 0 is not an extremum.

5.

f'(x) = 4x^3 - 4x = 4x(x - 1)(x + 1)

Differentiate and factor.

f'(-2) = -24, \; f'(-0.5) = 1.5, \; f'(0.5) = -1.5, \; f'(2) = 24

Signs: −, +, −, +.

f(-1) = -1, \; f(0) = 0, \; f(1) = -1

Evaluate f.

Answer: local min −1 at x = ±1; local max 0 at x = 0

6.

f'(x) = \frac{1 - x^2}{(x^2 + 1)^2}

Quotient rule.

f'(-2) = -\frac{3}{25}, \; f'(0) = 1, \; f'(2) = -\frac{3}{25}

Signs: −, +, − around x = −1 and x = 1.

f(-1) = -\frac{1}{2}, \; f(1) = \frac{1}{2}

Evaluate f.

Answer: local min −½ at x = −1; local max ½ at x = 1

7.

f'(x) = \ln x + 1 = 0 \Rightarrow x = \frac{1}{e}

Differentiate and solve.

f'(0.1) \approx -1.30, \; f'(1) = 1

Signs: − then +.

f\left(\frac{1}{e}\right) = \frac{1}{e}\ln\frac{1}{e} = -\frac{1}{e}

ln(1/e) = −1.

Answer: local min -\frac{1}{e} \approx -0.368 at x = \frac{1}{e}

8.

f'(x) = -1 \text{ for } x \lt -2, \; f'(x) = 1 \text{ for } x \gt -2

A V-shaped graph with its corner at x = −2.

Answer: local min 0 at x = −2 (f′ undefined there, − then +)

9.

f'(x) = 1 - \frac{4}{x^2} = \frac{x^2 - 4}{x^2}

Differentiate and combine.

x = \pm 2

Critical numbers; x = 0 is not in the domain.

f'(-3) = \frac{5}{9}, \; f'(-1) = -3, \; f'(1) = -3, \; f'(3) = \frac{5}{9}

Signs: +, −, −, + (the chart breaks at 0).

f(-2) = -4, \; f(2) = 4

Evaluate f.

Answer: local max −4 at x = −2; local min 4 at x = 2

10.

f'(x) = \cos x - \sin x = 0 \Rightarrow x = \frac{\pi}{4}, \frac{5\pi}{4}

tan x = 1 in (0, 2π).

f'(0.1) \gt 0, \; f'(\pi) = -1, \; f'(6) \gt 0

Signs: +, −, +.

f\left(\frac{\pi}{4}\right) = \sqrt{2}, \; f\left(\frac{5\pi}{4}\right) = -\sqrt{2}

Evaluate f.

Answer: local max √2 at π/4; local min −√2 at 5π/4

First derivative test FAQ

What is the first derivative test?

A way to classify a critical point by the sign of f′ on each side: + to − is a local max, − to + is a local min, and no change is neither.

How do you find where a function is increasing?

Find where f'(x) \gt 0. Make a sign chart for f′ using its critical numbers and test a value in each interval.

What is the difference between a local and an absolute maximum?

A local maximum is the highest point nearby. An absolute maximum is the highest point on the whole domain or interval. A function can have several local maximums but only one absolute maximum value.

Do you include endpoints in increasing intervals?

Many textbooks use open intervals, like (−1, 3). Including endpoints where f is continuous is also correct; follow your teacher’s convention.

Summary

  • f′ positive: f increasing. f′ negative: f decreasing.
  • Make a sign chart for f′ using the critical numbers (and any breaks in the domain).
  • + to −: local max. − to +: local min. No change: no extremum.
  • Report the extreme value f(c), not just the location c.

Previous lesson: Critical Points

Next lesson: Absolute Extrema

Back to the Calculus 1 Index