AP Calculus AB · Analytical applications of differentiation
Optimization
1The idea
Optimization problems ask for the largest or smallest value of some quantity: the maximum area, the minimum cost, the shortest distance. Calculus solves them by finding the absolute extrema of a function.
The method:
- Draw and label a diagram. Identify the quantity to optimise.
- Write the objective function for that quantity.
- Use a constraint (a given fact) to write the objective in terms of one variable.
- Find the domain of that variable from the context.
- Find critical points: differentiate and set equal to zero.
- Justify that you have the absolute maximum or minimum (candidates test, first derivative test, or second derivative test).
- Answer the question asked, with units.
Check yourself
In an optimization problem, what is the constraint used for?
Show the answer
To write the objective function in terms of one variable
It links the variables.
2Maximising an area
a farmer has 600 m of fencing to enclose a rectangular field along a river. No fence is needed along the river. What dimensions maximise the area?
- Let $x$ be the length of each side perpendicular to the river and $y$ the side parallel to it.
- Objective: $A = xy$.
- Constraint: $2x + y = 600$, so $y = 600 - 2x$, and $A(x) = 600x - 2x^2$.
- Domain: $0 < x < 300$.
- $A'(x) = 600 - 4x = 0$ gives $x = 150$.
- $A''(x) = -4 < 0$, so $A$ is concave down everywhere and $x = 150$ gives the absolute maximum.
- Dimensions: 150 m by 300 m (300 m along the river). Maximum area: $45{,}000$ m².
The area function for the fence problem peaks at x = 150 m
Check yourself
In the fence problem, why is x = 150 an absolute maximum, not just a relative one?
Show the answer
A″ < 0 everywhere and x = 150 is the only critical point
One critical point plus concavity gives the absolute extremum.
3Minimising a cost or surface area
an open-top box with a square base must hold 32,000 cm³. Find the dimensions that use the least material.
- Base side $x$, height $h$.
- Objective (surface area): $S = x^2 + 4xh$.
- Constraint: $x^2h = 32{,}000$, so $h = \frac{32000}{x^2}$, and $S(x) = x^2 + \frac{128000}{x}$.
- Domain: $x > 0$.
- $S'(x) = 2x - \frac{128000}{x^2} = 0$ gives $x^3 = 64000$, so $x = 40$.
- $S'' = 2 + \frac{256000}{x^3} > 0$ for $x > 0$, so this is the absolute minimum.
- Base 40 cm by 40 cm, height $h = \frac{32000}{1600} = 20$ cm.
Check yourself
For S(x) = x² + 128000/x, the critical point is x =
Show the answer
40
2x³ = 128000.
4Distance problems
find the point on $y = \sqrt{x}$ closest to $(3, 0)$.
- A point on the curve is $(x, \sqrt{x})$.
- Distance squared: $D = (x - 3)^2 + (\sqrt{x})^2 = x^2 - 5x + 9$. (Minimising $D$ also minimises the distance, since square root is increasing. This avoids messy roots.)
- $D'(x) = 2x - 5 = 0$ gives $x = 2.5$.
- $D'' = 2 > 0$: a minimum.
- The closest point is $\left(2.5, \sqrt{2.5}\right) \approx (2.5, 1.58)$.
Check yourself
Why minimise the square of the distance instead of the distance?
Show the answer
It has the same minimum point and avoids square roots
√ is an increasing function.
5Checking the endpoints
When the domain is a closed interval, you must also check the endpoints, because the absolute extremum could be there.
a wire 10 cm long is cut into two pieces: one bent into a square, the other into a circle. Where should it be cut to maximise the total area?
- Let $x$ be the length for the square ($0 \le x \le 10$). Area $= \left(\frac{x}{4}\right)^2 + \pi\left(\frac{10 - x}{2\pi}\right)^2 = \frac{x^2}{16} + \frac{(10 - x)^2}{4\pi}$.
- Setting $A'(x) = 0$ gives $x = \frac{40}{4 + \pi} \approx 5.6$, but this is a minimum (the function is concave up).
- Endpoints: $A(0) = \frac{25}{\pi} \approx 7.96$; $A(10) = 6.25$.
- Maximum total area: use all the wire for the circle.
The critical point alone would have given the wrong answer.
Check yourself
On a closed domain, the absolute maximum might occur:
Show the answer
At an endpoint
Always check the endpoints.
6Going deeper: a reliable procedure and three classic problems, fully justified
Procedure
- Draw and name the variables.
- Write the quantity to optimize (the objective) as a formula.
- Use the constraint to reduce it to a function of one variable.
- State the domain.
- Differentiate; find critical points.
- Justify that the critical point gives a maximum or minimum (candidates test, first or second derivative test).
- Answer the question asked, with units.
Worked example (fence): 100 m of fencing encloses a rectangle against a straight wall (no fence needed along the wall). Maximize the area.
- Let x be each side perpendicular to the wall; the side parallel is 100 − 2x.
- $A(x) = x(100 - 2x) = 100x - 2x^2$, for 0 < x < 50.
- $A'(x) = 100 - 4x = 0$: x = 25.
- $A''(x) = -4 < 0$: a maximum (and the only critical point).
- Dimensions 25 m by 50 m; area 1250 m².
Worked example (open box): squares of side x are cut from the corners of a 12 cm by 12 cm sheet and the sides folded up. Maximize the volume.
- $V(x) = x(12 - 2x)^2$, for 0 < x < 6.
- $V'(x) = (12 - 2x)^2 + x \cdot 2(12 - 2x)(-2) = (12 - 2x)(12 - 6x)$.
- Critical points: x = 6 (an endpoint, volume 0) and x = 2.
- V′ changes from positive to negative at x = 2: maximum.
- Volume = 2(8)² = 128 cm³.
Worked example (can): a closed cylinder must hold 1000 cm³. Minimize the surface area.
- Constraint: $\pi r^2h = 1000$, so $h = \frac{1000}{\pi r^2}$.
- $S = 2\pi r^2 + 2\pi rh = 2\pi r^2 + \frac{2000}{r}$, for r > 0.
- $S' = 4\pi r - \frac{2000}{r^2} = 0$: $r^3 = \frac{500}{\pi}$, so r = 5.42 cm.
- $S'' = 4\pi + \frac{4000}{r^3} > 0$ for all r > 0: concave up, so this is the absolute minimum.
- $h = \frac{1000}{\pi(5.42)^2} = 10.84$ cm: the height equals the diameter.
Worked example (distance): find the point on $y = \sqrt{x}$ closest to (3, 0).
- Minimize the square of the distance: $D = (x - 3)^2 + x$.
- $D' = 2(x - 3) + 1 = 0$: x = 2.5.
- D″ = 2 > 0: minimum.
- Point $(2.5, \sqrt{2.5})$; distance $\sqrt{0.25 + 2.5} = 1.66$.
Worked example (revenue): a shop sells 200 items a week at 10 dollars; each 1-dollar price rise loses 10 sales.
- With x price rises: R = (10 + x)(200 − 10x).
- R′ = 200 − 10x − 100 − 10x = 100 − 20x = 0: x = 5.
- R″ = −20 < 0: maximum.
- Price 15 dollars; revenue 15 × 150 = 2250 dollars.
Justifying on the exam
- Closed interval: compare values at critical points and endpoints.
- One critical point: "A′ changes from positive to negative at x = 25, and it is the only critical point, so A has its absolute maximum there." Or use the second derivative being negative on the whole domain.
- A critical point alone is not a justification.
Tips
- Minimizing a distance: minimize its square.
- Check that the answer lies in the domain and makes physical sense.
- Re-read the question: does it want the value of x, the dimensions, or the optimal amount?
Common mistakes
- Differentiating before eliminating the second variable.
- No justification that the critical point is a maximum or minimum.
- Ignoring endpoints of the domain.
- Answering with x when the maximum area or the dimensions were asked.
- Algebra slips with the chain rule in the box problem.
Check yourself
In an optimization problem with two variables, what must be done before differentiating?
Show the answer
Use the constraint to write the objective as a function of one variable
The derivative test applies to a function of a single variable.
7For top marks
- Define every variable with units.
- Show the objective function in one variable and state its domain.
- Justify absolute extrema: one critical point plus a sign change of $f'$, or concavity throughout, or the candidates test on a closed interval.
- Answer exactly what is asked: dimensions, the location, or the maximum value.
"Since $A'(x) > 0$ for $0 < x < 150$ and $A'(x) < 0$ for $150 < x < 300$, $A$ has its absolute maximum at $x = 150$."
Check yourself
A question asks for the maximum area. Which final answer is correct in form?
Show the answer
45,000 m²
Give the value asked for, with units.
Now test yourself
This lesson has a 8-question quiz and 5 exam-style questions with mark schemes in Impera. Free, with your progress saved.
Practise in Impera