Optimization Examples: 48 Problems with Answers

Worked examples of Optimization to try before you open each solution, then practice problems with answers.

Worked Examples

Example 1

easy
Find the local maximum and minimum values of f(x)=x3−3x+2.
Show solution

Answer

Local maximum: f(−1)=4; local minimum: f(1)=0

First step

1.
Find f′(x)=3x2−3=3(x2−1)=3(x−1)(x+1).

Full solution

  1. 2.
    Set f′(x)=0: critical points at x=1 and x=−1.
  2. 3.
    Find f′′(x)=6x. At x=−1: f′′(−1)=−6<0, so local maximum.
  3. 4.
    At x=1: f′′(1)=6>0, so local minimum.
  4. 5.
    Evaluate: f(−1)=−1+3+2=4 (local max); f(1)=1−3+2=0 (local min).
The second derivative test classifies critical points: negative second derivative means concave down (local max), positive means concave up (local min). Always evaluate the function at the critical point to get the actual max/min value.

Example 2

hard
A farmer has 200 m of fencing to enclose a rectangular field. What dimensions maximize the enclosed area?

Example 3

medium
Find the absolute maximum and minimum of f(x)=x3−3x2 on [−1,3].

Example 4

medium
A cylindrical can of volume V has no top. Express its surface area as a function of radius r and find the radius that minimizes surface area.

Example 5

medium
A page must contain 50 in2 of printed text, with margins of 1 in on top/bottom and 2 in on each side. What page dimensions minimize total page area?

Example 6

medium
Find the point on the line y=2x+1 closest to the origin.

Example 7

hard
A right triangle with the right angle at the origin has legs along the positive axes. The hypotenuse passes through (3,4). Find the minimum area of the triangle.

Example 8

hard
A lighthouse beam of constant intensity passes over a wall at distance d. If light intensity at angle θ from the beam axis is proportional to cos⁡2θ, where is the brightest point on the wall?

Example 9

challenge
Find the dimensions of the rectangle of maximum area that can be inscribed in the ellipse x2a2+y2b2=1 with sides parallel to the axes.

Practice Problems

Try each one, then open the solution to compare your method.

Example 1

easy
Find the critical points of f(x)=2x3−9x2+12x−4 and classify them.

Example 2

medium
Find the absolute maximum and minimum of f(x)=x3−6x2+9x+1 on [0,4].

Example 3

easy
Find the critical points of f(x)=x2−6x+5.

Example 4

easy
Where does f(x)=x2 attain its minimum?

Example 5

easy
Find the critical point of f(x)=−x2+4x.

Example 6

easy
Find the critical points of f(x)=x3−3x.

Example 7

easy
Is x=0 a max, min, or neither for f(x)=x3?

Example 8

easy
Find the absolute max of f(x)=4−x2 on [−1,1].

Example 9

easy
Find the critical points of f(x)=x2+2x for x>0.

Example 10

easy
Find where f(x)=ex−x has a critical point.

Example 11

medium
Find the absolute extrema of f(x)=x3−3x on [−2,2].

Example 12

medium
Use the second derivative test to classify the critical point of f(x)=x2−4x+1.

Example 13

medium
A farmer has 40 m of fence for a rectangular pen against a wall (no fence on the wall side). Maximize the area.

Example 14

medium
Find the dimensions of a rectangle with perimeter 20 that maximizes area.

Example 15

medium
Minimize f(x)=x+4x for x>0.

Example 16

medium
Find the maximum of f(x)=xe−x for x≥0.

Example 17

medium
A box with a square base and open top has volume 32. Minimize surface area.

Example 18

challenge
Find the point on y=x2 closest to (0,2).

Example 19

challenge
Maximize the area of a rectangle inscribed under y=4−x2 (above the x-axis), with base on the axis.

Example 20

challenge
A 12 cm wire is cut into two pieces, one bent into a square and one into a circle. Where to cut to minimize total area? (Set up the critical-point equation.)

Example 21

medium
Classify the critical point of f(x)=−x2+6x using the second derivative test.

Example 22

medium
Find the number whose sum with its square is minimized.

Example 23

easy
Find the critical points of f(x)=x2−8x+7.

Example 24

easy
Find the critical points of f(x)=x3−12x.

Example 25

easy
Find the absolute minimum of f(x)=(x−3)2+1.

Example 26

easy
Find the maximum value of f(x)=−2x2+8x−3.

Example 27

medium
A box with a square base and open top has volume 32 cubic units. Find dimensions that minimize the surface area.

Example 28

medium
A rectangle is inscribed under the parabola y=4−x2 with two vertices on the x-axis. Find the maximum area.

Example 29

medium
Find the maximum value of f(x)=xe−x for x≥0.

Example 30

medium
Find local extrema of f(x)=x4−8x2+5.

Example 31

medium
Find two non-negative numbers whose sum is 20 and whose product is maximum.

Example 32

medium
A poster has area 180 cm2. If margins are 3 cm on top and bottom and 2 cm on each side, what poster dimensions maximize the printed area?

Example 33

medium
Find the absolute extrema of f(x)=sin⁡x+cos⁡x on [0,2π].

Example 34

hard
A wire of length 100 cm is cut into two pieces, one bent into a square and the other into a circle. Where should it be cut to minimize total area?

Example 35

hard
Find local extrema of f(x)=ln⁡x−x for x>0.

Example 36

hard
Find the dimensions of the right circular cone of maximum volume that can be inscribed in a sphere of radius R.

Example 37

hard
A revenue function is R(x)=100x−0.5x2 and a cost function is C(x)=10x+200 for x units sold. Find the production level that maximizes profit.

Example 38

hard
Find the absolute minimum value of f(x)=x2+16x for x>0.

Example 39

challenge
Snell's law: a swimmer at (0,4) on land swims to point (x,0) on a straight shoreline, then swims in the water to (10,−3). Land speed 5 m/s, water speed 3 m/s. Set up the time function T(x) and write the equation that x must satisfy (don't solve numerically).

What to focus on

Core idea: Optimization uses derivatives to find a function's maxima and minima by locating where f′(x)=0 and classifying them.

Common stuck point: The procedure for optimization is the easy part; the trap is stopping at f′(x)=0 without classifying. Asking "Am I seeking an extreme value by finding where the slope is zero and then classifying it?" first is what keeps a correct-looking calculation from being attached to the wrong concept.

Ask yourself: Am I seeking an extreme value by finding where the slope is zero and then classifying it?

Concept recap

The process of using derivatives to systematically find maximum or minimum values of a function over a domain.

Hiking a ridge in fog, you know you are at a summit or the bottom of a dip when the path goes level, so level ground is where to look. But a level spot can also be a flat ledge partway up a climb, and the hike's highest point might be where the trail ends at a cliff. So check every level spot and both ends.

Read the full lesson on Optimization

Optimization is covered with related ideas in the guide Derivatives Explained: Rules, Interpretation, and Applications.

Related concepts

Background knowledge

These ideas may be useful before you work through the harder examples.

derivative