r/learnmath • New User • 3d ago

Link Post Help with optimization

/r/APStudents/comments/1y1gpf3/help_with_optimization/
1 Upvotes

3 comments sorted by

1

u/Brightlinger MS in Math 3d ago

Optimization problems in calculus boil down to 4 steps:

  1. Assign variables. Sometimes this is super obvious, but sometimes there are multiple ways to assign variables. Importantly, sometimes the variable you solve for isn't directly the answer to the question. You should write down what variables you are using and what they represent; not doing this frequently leads to confusion at the end. A diagram here often helps too.

  2. Identify the constraint. The constraint is an equation that must be satisfied, involving the variables from step 1. It is the reason that the thing you are trying to optimize can't be infinity (or 0, or -infinity).

  3. Identify the objective function. This is the thing you want to maximize or minimize, and it should be a function of the variables you identified in step 1.

  4. Solve. You now have all the components, so solving the problem always follows these steps: (a) use the constraint to isolate one variable, (b) substitute that into the objective function to make it a function of one variable, (c) differentiate that objective function, and (d) find the critical points. Sometimes there is another step (e) to find which critical point is the maximum/minimum in question, but often there will only be one critical point in the first place.

As an example, suppose the problem is this:

A farmer has 100 feet of fencing to enclose a rectangular garden. One side of the garden will be against a cliff, so it does not need to be fenced off. Find the dimensions that will maximize the area of the garden.

In order, you'd go:

  1. Assign variables. We want the dimensions of a rectangle, so call them L and W for length and width. One of these is parallel to the cliff, doesn't matter which, say it's L.

  2. Identify the constraint. There are only 100 feet of fencing. That's the perimeter along the 3 fenced sides, ie, 100=L+2W.

  3. Identify the objective function. The thing we want to maximize is the area, A=LW.

  4. Solve. (a) 100=L+2W rearranges to L=100-2W. (b) A=LW=(100-2W)W=100W-2W2. (c) A'=100-4W. (d) A' is never undefined, so the only critical point is when A'=0. The solution to 0=100-4W is W=25. If W=25, then since L=100-2W we have L=50.

So the dimensions are 50'x25'.