Privacy note: We capture your IP address to provide customised and focused services. See our Privacy Policy.

AP Calculus AB: Deep Dive — Alpha School

Lesson 6: Optimisation: Finding the Best Value

What Optimisation Asks

Optimisation asks for the largest or smallest value of a quantity, subject to a constraint. A farmer has 100 m of fencing and wants the largest rectangular field; a company wants the box of greatest volume from a sheet of card; a runner wants the fastest route to a point across a field and a road. The quantity to maximise or minimise is the objective function, and the constraint is the fixed resource, such as the length of fencing or the area of card. The calculus finds where the objective stops increasing and starts decreasing.

The method is the same in every case. Write the objective as a function of one variable, using the constraint to eliminate the others. Differentiate, set the derivative to zero, and solve: those are the critical points. Then check the endpoints of the allowed interval, because the maximum or minimum often sits at an endpoint rather than at a critical point. Finally, justify: a first-derivative sign change, or a second derivative, shows that the point is a maximum and not a minimum.

Worked example with a box: an open box is made from a square sheet of card 12 cm on a side by cutting squares of side x from the corners and folding up the sides. The volume is x times 12 minus 2x squared, which is 144x minus 48x squared plus 4x cubed. The derivative is 144 minus 96x plus 12x squared, which is zero when x is 2 or 6. At x equals 6 the box has no base, so the volume is zero; at x equals 2 the volume is 2 times 64, which is 128 cubic centimetres, the maximum. The endpoints are x equals 0 and x equals 6, where the volume is zero, so the interior critical point at x equals 2 is the maximum. The second derivative is minus 96 plus 24x, which at x equals 2 is minus 48, confirming the maximum.

Worked Example: The Fenced Field

Worked example: a rectangular field is fenced on three sides, with a wall forming the fourth side, using 100 m of fencing. Let x be the depth from the wall and the width along the wall be 100 minus 2x. The area is x times 100 minus 2x, which is 100x minus 2x squared. The derivative is 100 minus 4x, which is zero at x equals 25. The width is then 50 m, and the area is 25 times 50, which is 1250 square metres.

The justification matters as much as the number. The second derivative is minus 4, which is negative, so the critical point is a maximum. The endpoints are x equals 0 and x equals 50, where the area is zero, so the interior maximum of 1250 square metres is the largest possible. A complete answer gives the dimensions, the maximum value, and the reason it is a maximum, not just the value of x.

Endpoints and Justification

Forgetting the endpoints is the most common optimisation error. On a closed interval, the maximum of a continuous function is either at a critical point or at an endpoint, and the only way to be sure is to evaluate the function at all of them. A box with a fixed surface area might have its largest volume at an interior point, but a quantity defined on an interval that includes zero, such as a length, may be largest at the boundary. Check both, every time.

Justification can use the first or the second derivative. The first derivative test watches the sign change: if the derivative goes from positive to negative, the function rises then falls, so the point is a maximum. The second derivative test is quicker when the second derivative is easy: negative means concave down, hence a maximum. Either is acceptable, but one of them must be written down. A critical point without a justification is only a candidate, not an answer.

Key Terms

Optimisation
Finding the maximum or minimum value of a quantity, subject to a constraint.
Objective function
The quantity to be maximised or minimised, written as a function of one variable.
Constraint
The fixed condition, such as a length of fencing or an area of card, that limits the variables.
Critical point
A point where the derivative is zero or undefined; a candidate for a maximum or minimum.
Endpoint
The end of the allowed interval; a maximum or minimum can occur there even with no critical point.
First derivative test
Deciding maximum or minimum from the sign change of the derivative around a critical point.

Discussion Questions

  1. Why must you check the endpoints as well as the critical points?
  2. What is the difference between a critical point and a maximum?
  3. Why is a justification needed after finding where the derivative is zero?

Practice Questions

  1. In the field worked example, what depth gives the largest area?
  2. What is the largest area in that example?
  3. Why is the point x equals 25 a maximum and not a minimum?
  4. A function on a closed interval has one critical point. Where else must you check for the maximum?
  5. What does the first derivative test look for?
Show answers
  1. 25 m, with a width of 50 m along the wall.
  2. 1250 square metres.
  3. Because the second derivative is minus 4, which is negative, so the function is concave down there.
  4. At both endpoints of the interval.
  5. A sign change of the derivative: positive to negative means a maximum.
Keep reading to complete this lesson