Skip to main content

Section 4.7 Applied Optimization Problems

Learning Objectives.

  • Set up and solve optimization problems in several applied fields.

One common application of calculus is calculating the minimum or maximum value of a function. For example, companies often want to minimize production costs or maximize revenue. In manufacturing, it is often desirable to minimize the amount of material used to package a product with a certain volume. In this section, we show how to set up these types of minimization and maximization problems and solve them by using the tools developed in this chapter.

Subsection 4.7.1 Solving Optimization Problems over a Closed, Bounded Interval

The basic idea of the optimization problems that follow is the same. We have a particular quantity that we are interested in maximizing or minimizing. However, we also have some auxiliary condition that needs to be satisfied. For example, in Example 4.135, we are interested in maximizing the area of a rectangular garden. Certainly, if we keep making the side lengths of the garden larger, the area will continue to become larger. However, what if we have some restriction on how much fencing we can use for the perimeter? In this case, we cannot make the garden as large as we like. Let's look at how we can maximize the area of a rectangle subject to some constraint on the perimeter.

Example 4.135. Maximizing the Area of a Garden.

A rectangular garden is to be constructed using a rock wall as one side of the garden and wire fencing for the other three sides (Figure 4.136). Given \(100\) ft of wire fencing, determine the dimensions that would create a garden of maximum area. What is the maximum area?

"A drawing of a garden has x and y written on the vertical and horizontal sides, respectively. There is a rock wall running along the entire bottom horizontal length of the drawing."
Figure 4.136. We want to determine the measurements \(x\) and \(y\) that will create a garden with a maximum area using \(100\) ft of fencing.
Solution.

Let \(x\) denote the length of the side of the garden perpendicular to the rock wall and \(y\) denote the length of the side parallel to the rock wall. Then the area of the garden is

\begin{equation*} A=x\cdot y. \end{equation*}

We want to find the maximum possible area subject to the constraint that the total fencing is \(100 \text{ ft }.\) From Figure 4.136, the total amount of fencing used will be \(2x+y.\) Therefore, the constraint equation is

\begin{equation*} 2x+y=100. \end{equation*}

Solving this equation for \(y,\) we have \(y=100-2x.\) Thus, we can write the area as

\begin{equation*} A(x)=x\cdot(100-2x)=100x-2x^2. \end{equation*}

Before trying to maximize the area function \(A(x)=100x-2x^2,\) we need to determine the domain under consideration. To construct a rectangular garden, we certainly need the lengths of both sides to be positive. Therefore, we need \(x\gt 0\) and \(y\gt 0.\) Since \(y=100-2x,\) if \(y\gt 0,\) then \(x\lt 50.\) Therefore, we are trying to determine the maximum value of \(A(x)\) for \(x\) over the open interval \((0,50).\) We do not know that a function necessarily has a maximum value over an open interval. However, we do know that a continuous function has an absolute maximum (and absolute minimum) over a closed interval. Therefore, let's consider the function \(A(x)=100x-2x^2\) over the closed interval \([0,50].\) If the maximum value occurs at an interior point, then we have found the value \(x\) in the open interval \((0,50)\) that maximizes the area of the garden. Therefore, we consider the following problem:

Maximize \(A(x)=100x-2x^2\) over the interval \([0,50].\)

As mentioned earlier, since \(A\) is a continuous function on a closed, bounded interval, by the extreme value theorem, it has a maximum and a minimum. These extreme values occur either at endpoints or critical points. At the endpoints, \(A(x)=0.\) Since the area is positive for all \(x\) in the open interval \((0,50),\) the maximum must occur at a critical point. Differentiating the function \(A(x),\) we obtain

\begin{equation*} A'(x)=100-4x. \end{equation*}

Therefore, the only critical point is \(x=25\) (Figure 4.137). We conclude that the maximum area must occur when \(x=25.\) Then we have \(y=100-2x=100-2(25)=50.\) To maximize the area of the garden, let \(x=25\) ft and \(y=50 \text{ ft }.\) The area of this garden is \(1250\text{ft}^2\)

"The function A(x) = 100x-2x^2 is graphed. At its maximum there is an intersection of two dashed lines and text that reads "Maximum area is 1250 square feet when x = 25 feet.""
Figure 4.137. To maximize the area of the garden, we need to find the maximum value of the function \(A(x)=100x-2x^2.\)

Checkpoint 4.138.

Determine the maximum area if we want to make the same rectangular garden as in Figure 4.137, but we have \(200\) ft of fencing.

Hint.

We need to maximize the function \(A(x)=200x-2x^2\) over the interval \([0,100].\)

Solution.

The maximum area is \(5000\text{ ft}^2\)

Now let's look at a general strategy for solving optimization problems similar to Example 4.135.

Note 4.139. Problem-Solving Strategy: Solving Optimization Problems.

  1. Introduce all variables. If applicable, draw a figure and label all variables.

  2. Determine which quantity is to be maximized or minimized, and for what range of values of the other variables (if this can be determined at this time).

  3. Write a formula for the quantity to be maximized or minimized in terms of the variables. This formula may involve more than one variable.

  4. Write any equations relating the independent variables in the formula from step \(3.\) Use these equations to write the quantity to be maximized or minimized as a function of one variable.

  5. Identify the domain of consideration for the function in step \(4\) based on the physical problem to be solved.

  6. Locate the maximum or minimum value of the function from step \(4.\) This step typically involves looking for critical points and evaluating a function at endpoints.

Now let's apply this strategy to maximize the volume of an open-top box given a constraint on the amount of material to be used.

Example 4.140. Maximizing the Volume of a Box.

An open-top box is to be made from a \(24\) in. by \(36\) in. piece of cardboard by removing a square from each corner of the box and folding up the flaps on each side. What size square should be cut out of each corner to get a box with the maximum volume?

Solution.

Step 1: Let \(x\) be the side length of the square to be removed from each corner (Figure 4.141). Then, the remaining four flaps can be folded up to form an open-top box. Let \(V\) be the volume of the resulting box.

"There are two figures for this figure. The first one is a rectangle with sides 24 in and 36 in, with each corner having a square of side length x taken out of it. In the second picture, there is a box with side lengths x in, 24-2x in, and 36-2x in."
Figure 4.141. A square with side length \(x\) inches is removed from each corner of the piece of cardboard. The remaining flaps are folded to form an open-top box.

Step 2: We are trying to maximize the volume of a box. Therefore, the problem is to maximize \(V.\)

Step 3: As mentioned in step \(2,\) are trying to maximize the volume of a box. The volume of a box is \(V=L\cdot W\cdot H,\) where \(L,W, \text{ and } H\) are the length, width, and height, respectively.

Step 4: From Figure 4.141, we see that the height of the box is \(x\) inches, the length is \(36-2x\) inches, and the width is \(24-2x\) inches. Therefore, the volume of the box is

\begin{equation*} V(x)=(36-2x)(24-2x)x=4x^3-120x^2+864x. \end{equation*}

Step 5: To determine the domain of consideration, let's examine Figure 4.141. Certainly, we need \(x\gt 0.\) Furthermore, the side length of the square cannot be greater than or equal to half the length of the shorter side, \(24\) in.; otherwise, one of the flaps would be completely cut off. Therefore, we are trying to determine whether there is a maximum volume of the box for \(x\) over the open interval \((0,12).\) Since \(V\) is a continuous function over the closed interval \([0,12],\) we know \(V\) will have an absolute maximum over the closed interval. Therefore, we consider \(V\) over the closed interval \([0,12]\) and check whether the absolute maximum occurs at an interior point.

Step 6: Since \(V(x)\) is a continuous function over the closed, bounded interval \([0,12],\) \(V\) must have an absolute maximum (and an absolute minimum). Since \(V(x)=0\) at the endpoints and \(V(x)\gt 0\) for \(0\lt x\lt 12,\) the maximum must occur at a critical point. The derivative is

\begin{equation*} V'(x)=12x^2-240x+864. \end{equation*}

To find the critical points, we need to solve the equation

\begin{equation*} 12x^2-240x+864=0. \end{equation*}

Dividing both sides of this equation by \(12,\) the problem simplifies to solving the equation

\begin{equation*} x^2-20x+72=0. \end{equation*}

Using the quadratic formula, we find that the critical points are

\begin{align*} x\amp=\frac{20\pm\sqrt{(-20)^2-4(1)(72)}}{2}\\ x\amp=\frac{20\pm\sqrt{112}}{2}\\ x\amp=\frac{20\pm 4\sqrt{7}}{2}\\ x\amp=10\pm 2\sqrt{7}. \end{align*}

Since \(10+2\sqrt{7}\) is not in the domain of consideration, the only critical point we need to consider is \(10-2\sqrt{7}.\) Therefore, the volume is maximized if we let \(x=10-2\sqrt{7} \text{ in }.\) The maximum volume is \(V(10-2\sqrt{7})=640+448\sqrt{7}\approx 1825 \text{ in. }^3\) as shown in the following graph.

"The function V(x) = 4x3 – 120x2 + 864x is graphed. At its maximum there is an intersection of two dashed lines and text that reads “Maximum volume is approximately 1825 cubic inches when x ≈ 4.7 inches.”"
Figure 4.142. Maximizing the volume of the box leads to finding the maximum value of a cubic polynomial.

Note 4.143.

Watch a video 1  about optimizing the volume of a box.

Checkpoint 4.144.

Suppose the dimensions of the cardboard in Example 4.140 are 20 in. by 30 in. Let \(x\) be the side length of each square and write the volume of the open-top box as a function of \(x.\) Determine the domain of consideration for \(x.\)

Hint.

The volume of the box is \(L\cdot W\cdot H.\)

Solution.

\(V(x)=x(20-2x)(30-2x).\) The domain is \([0,10].\)

In business, companies are interested in maximizing revenue. In the following example, we consider a scenario in which a company has collected data on how many cars it is able to lease, depending on the price it charges its customers to rent a car. Let's use these data to determine the price the company should charge to maximize the amount of money it brings in.

Example 4.145. Maximizing Revenue.

Owners of a car rental company have determined that if they charge customers \(p\) dollars per day to rent a car, where \(50\leq p\leq 200,\) the number of cars \(n\) they rent per day can be modeled by the linear function \(n(p)=1000-5p.\) If they charge \(\$ 50\) per day or less, they will rent all their cars. If they charge \(\$ 200\) per day or more, they will not rent any cars. Assuming the owners plan to charge customers between $50 per day and \(\$ 200\) per day to rent a car, how much should they charge to maximize their revenue?

Solution.

Step 1: Let \(p\) be the price charged per car per day and let \(n\) be the number of cars rented per day. Let \(R\) be the revenue per day.

Step 2: The problem is to maximize \(R.\)

Step 3: The revenue (per day) is equal to the number of cars rented per day times the price charged per car per day—that is, \(R=n \times p.\)

Step 4: Since the number of cars rented per day is modeled by the linear function \(n(p)=1000-5p,\) the revenue \(R\) can be represented by the function

\begin{equation*} R(p)=n \times p=(1000-5p)p=-5p^2+1000p. \end{equation*}

Step 5: Since the owners plan to charge between \(\$ 50\) per car per day and \(\$ 200\) per car per day, the problem is to find the maximum revenue \(R(p)\) for \(p\) in the closed interval \([50,200].\)

Step 6: Since \(R\) is a continuous function over the closed, bounded interval \([50,200],\) it has an absolute maximum (and an absolute minimum) in that interval. To find the maximum value, look for critical points. The derivative is \(R'(p)=-10p+1000.\) Therefore, the critical point is \(p=100\) When \(p=100,\) \(R(100)=\$ 50,000.\) When \(p=50,\) \(R(p)=\$ 37,500.\) When \(p=200,\) \(R(p)=\$ 0.\) Therefore, the absolute maximum occurs at \(p=\$ 100.\) The car rental company should charge \(\$ 100\) per day per car to maximize revenue as shown in the following figure.

"The function R(p) is graphed. At its maximum there is an intersection of two dashed lines and text that reads "Maximum revenue is $50,000 per day when the price charged per car is $100 per day.""
Figure 4.146. To maximize revenue, a car rental company has to balance the price of a rental against the number of cars people will rent at that price.

Example 4.147.

A theater owner charges $5 per ticket and sells 250 tickets. By checking other theaters, the owner decided that for every one dollar she raises the ticket price, she will lose 10 customers. What should she charge to maximize revenue?
Solution.

Step 1: We can model the problem by defining the following variables:

\begin{align*} n\amp=\text{ number of 1 dollar increases}\\ x\amp=\text{ number of tickets sold (quantity)}\\ p\amp=\text{ price per ticket} \end{align*}

Step 2: We are trying to maximize the revenue. Therefore, the problem is to maximize \(R\text{.}\)

Step 3: As mentioned in step 2 are trying to maximize the revenue. Recall that the revenue is given by \(R=p\cdot x\text{.}\) Currently, the theater owner charges $5 per ticket and sells 250 tickets but for every one dollar she raises the ticket price, she will lose 10 customers. Since \(n\) is the number of $1 increases, this gives us our constraints

\begin{align*} x\amp=250-10n\\ p\amp=5+n \end{align*}

Step 4: Using the equations from step 3, we see that the revenue equation is given by

\begin{equation*} R=p\cdot x=(5+n)(250-10n)\text{.} \end{equation*}

Step 5: In order to determine the domain of consideration, note that we need \(x\geq 0\text{ and }p\geq0\text{.}\) Using the equations from step 3:

\(x\geq0:\)

\begin{align*} 250-10n\amp\geq0\\ n\amp\geq25 \end{align*}

\(p\geq0:\)

\begin{align*} 5+n\amp\geq0\\ n\amp\geq-5. \end{align*}

Therefore, we are trying to determine whether there is a maximum revenue over the closed interval [-5,25]. Since \(R\) is a continuous function over the closed, bounded interval [-5,25] it has an absolute maximum (and an absolute minimum) in that interval. To find the maximum value, look for critical points. The derivative is \(R'(n)=1\cdot(250-10n)+(5+n)\cdot(-10)=200-20n\text{.}\) Therefore, the critical point is \(n=10\text{.}\) When \(n=10,\; R(10)=\$2250\text{.}\) When \(n=-5,\; R(-5)=\$0\text{.}\) When \(n=25,\; R(25)=\$0\text{.}\) Therefore, the absolute maximum occurs at \(n=10\text{.}\) Note that when \(n=10,\;p=5+10=\$15.\)The theater owner should charge $15 per ticket in order to maximize revenue as shown in the following figure.

"The function \(R(n)=(5+n)(250-10n)\) over the interval [-5,25] with an absolute maximum at (10,2250)."
Figure 4.148. \(R(n)=(5+n)(250-10n)\) has absolute maximum at (10,2250).

Checkpoint 4.149.

A car rental company charges its customers \(p\) dollars per day, where \(60\leq p\leq 150.\) It has found that the number of cars rented per day can be modeled by the linear function \(n(p)=750-5p.\) How much should the company charge each customer to maximize revenue?

Hint.

\(R(p)=n \times p,\) where \(n\) is the number of cars rented and \(p\) is the price charged per car.

Solution.

The company should charge \(\$ 75\) per car per day.

Subsection 4.7.2 Solving Optimization Problems when the Interval Is Not Closed or Is Unbounded

In the previous examples, we considered functions on closed, bounded domains. Consequently, by the extreme value theorem, we were guaranteed that the functions had absolute extrema. Let's now consider functions for which the domain is neither closed nor bounded.

Many functions still have at least one absolute extrema, even if the domain is not closed or the domain is unbounded. For example, the function \(f(x)=x^2+4\) over \((-\infty,\infty)\) has an absolute minimum of \(4\) at \(x=0.\) Therefore, we can still consider functions over unbounded domains or open intervals and determine whether they have any absolute extrema. In the next example, we try to minimize a function over an unbounded domain. We will see that, although the domain of consideration is \((0,\infty),\) the function has an absolute minimum.

In the following example, we look at constructing a box of least surface area with a prescribed volume. It is not difficult to show that for a closed-top box, by symmetry, among all boxes with a specified volume, a cube will have the smallest surface area. Consequently, we consider the modified problem of determining which open-topped box with a specified volume has the smallest surface area.

Example 4.150. Minimizing Surface Area.

A rectangular box with a square base, an open top, and a volume of \(216\) in.3 is to be constructed. What should the dimensions of the box be to minimize the surface area of the box? What is the minimum surface area?

Solution.

Step 1: Draw a rectangular box and introduce the variable \(x\) to represent the length of each side of the square base; let \(y\) represent the height of the box. Let \(S\) denote the surface area of the open-top box.

"A box with square base is shown. The base has side length x, and the height is y."
Figure 4.151. We want to minimize the surface area of a square-based box with a given volume.

Step 2: We need to minimize the surface area. Therefore, we need to minimize \(S.\)

Step 3: Since the box has an open top, we need only determine the area of the four vertical sides and the base. The area of each of the four vertical sides is \(x\cdot y.\) The area of the base is \(x^2.\) Therefore, the surface area of the box is

\begin{equation*} S=4xy+x^2. \end{equation*}

Step 4: Since the volume of this box is \(x^2y\) and the volume is given as \(216 \text{ in. }^3,\) the constraint equation is

\begin{equation*} x^2y=216. \end{equation*}

Solving the constraint equation for \(y,\) we have \(y=\frac{216}{x^2}.\) Therefore, we can write the surface area as a function of \(x\) only:

\begin{equation*} S(x)=4x\left(\frac{216}{x^2}\right)+x^2. \end{equation*}

Therefore, \(S(x)=\frac{864}{x}+x^2.\)

Step 5: Since we are requiring that \(x^2y=216,\) we cannot have \(x=0.\) Therefore, we need \(x\gt 0.\) On the other hand, \(x\) is allowed to have any positive value. Note that as \(x\) becomes large, the height of the box \(y\) becomes correspondingly small so that \(x^2y=216.\) Similarly, as \(x\) becomes small, the height of the box becomes correspondingly large. We conclude that the domain is the open, unbounded interval \((0,\infty).\) Note that, unlike the previous examples, we cannot reduce our problem to looking for an absolute maximum or absolute minimum over a closed, bounded interval. However, in the next step, we discover why this function must have an absolute minimum over the interval \((0,\infty).\)

Step 6: Note that as \(x\to0^+,\) \(S(x)\to\infty.\) Also, as \(x\to\infty,\) \(S(x)\to\infty.\) Since \(S\) is a continuous function that approaches infinity at the ends, it must have an absolute minimum at some \(x\in(0,\infty).\) This minimum must occur at a critical point of \(S.\) The derivative is

\begin{equation*} S'(x)=-\frac{864}{x^2}+2x. \end{equation*}

Therefore, \(S'(x)=0\) when \(2x=\frac{864}{x^2}.\) Solving this equation for \(x,\) we obtain \(x^3=432,\) so \(x=\sqrt[3]{432}=6\sqrt[3]{2}.\) Since this is the only critical point of \(S,\) the absolute minimum must occur at \(x=6\sqrt[3]{2}\) (see Figure 4.152). When \(x=6\sqrt[3]{2},\) \(y=\frac{216}{(6\sqrt[3]{2})^2}=3\sqrt[3]{2} \text{ in }.\) Therefore, the dimensions of the box should be \(x=6\sqrt[3]{2} \text{ in }.\) and \(y=3\sqrt[3]{2} \text{ in }.\) With these dimensions, the surface area is

\begin{equation*} S(6\sqrt[3]{2})=\frac{864}{6\sqrt[3]{2}}+(6\sqrt[3]{2})^2=108\sqrt[3]{4} \text{ in. }^2> \end{equation*}
"The function \(S(x) = 864/x + x^2\) is graphed. At its minimum there is a dashed line and text that reads "Minimum surface area is 108 times the cube root of 4 square inches when x = 6 times the cube root of 2 inches.""
Figure 4.152. We can use a graph to determine the dimensions of a box of given the volume and the minimum surface area.

Example 4.153. Minimizing Cost.

A company must produce a sturdy rectangular container with a square base and a volume of 128 cubic ft. The cost to produce the top and sides of this box is $2 per square foot and the cost to produce the bottom is $6 per square foot. FInd the dimensions of the box that will minimize cost.
Solution.

Step 1: Draw a rectangular box and introduce the variable \(x\) to represent the length of each side of the square base; let \(h\) represent the height of the box. Let \(C\) denote the cost of producing the box.

"A box with square base is shown. The base has side length x, and the height is h."
Figure 4.154. We want to minimize the cost to produce a square-based box with a given volume.
-->

Step 2: We need to minimize the cost. Therefore, we need to minimize \(C.\)

Step 3: We need to determine the cost of the four vertical sides, the top, and the base. In order to find the cost, we must first find the surface area of the box. The area of each of the four vertical sides is \(x\cdot h.\) The area of the base and top are both \(x^2.\) Since the cost to produce the top and sides of this box is $2 per square foot and the cost to produce the bottom is $6 per square foot, then the cost is

\begin{equation*} C=2x^2+8xh+6x^2=8x^2+8xh \end{equation*}

Step 4: Since the volume of this box is \(x^2h\) and the volume is given as \(128\) cubic ft, the constraint equation is

\begin{equation*} x^2h=128. \end{equation*}

Solving the constraint equation for \(h,\) we have \(h=\frac{128}{x^2}.\) Therefore, we can write the cost as a function of \(x\) only:

\begin{equation*} C(x)=8x^2+8x\cdot\frac{128}{x^2}=8x^2+\frac{1024}{x}. \end{equation*}

Step 5: Since we are requiring that \(x^2h=128,\) we cannot have \(x=0.\) Therefore, we need \(x\gt 0.\) On the other hand, \(x\) is allowed to have any positive value. Note that as \(x\) becomes large, the height of the box \(h\) becomes correspondingly small so that \(x^2h=128.\) Similarly, as \(x\) becomes small, the height of the box becomes correspondingly large. We conclude that the domain is the open, unbounded interval \((0,\infty).\) Note that, unlike the previous examples, we cannot reduce our problem to looking for an absolute maximum or absolute minimum over a closed, bounded interval. However, in the next step, we discover why this function must have an absolute minimum over the interval \((0,\infty).\)

Step 6: Note that as \(x\to0^+,\) \(C(x)\to\infty.\) Also, as \(x\to\infty,\) \(C(x)\to\infty.\) Since \(C\) is a continuous function that approaches infinity at the ends, it must have an absolute minimum at some \(x\in(0,\infty).\) This minimum must occur at a critical point of \(C.\) The derivative is

\begin{equation*} C'(x)=16x-\frac{1024}{x^2}. \end{equation*}

Therefore, \(C'(x)=0\) when \(16x=\frac{1024}{x^2}.\) Solving this equation for \(x,\) we obtain \(x^3=64,\) so \(x=4.\) Since this is the only critical point of \(C,\) the absolute minimum must occur at \(x=4\) (see Figure 4.155). When \(x=4,\) \(h=\frac{128}{4^2}=8\) feet. Therefore, the dimensions of the box should be \(x=4\) feet and \(h=8\) feet. With these dimensions, the cost is

\begin{equation*} C(4)=8(4)^2+\frac{1024}{4}=\$384. \end{equation*}
"The function \(C(x)=8x^2+\frac{1024}{x}\) is graphed on the interval \((0,\infty)\) and has an absolute minimum at (4,384)."
Figure 4.155. \(C(x)=8x^2+\frac{1024}{x}\) has an absolute minimum at (4,384).

Checkpoint 4.156.

Consider the an open-top box, which is to have volume \(216 \text{ in. }^3.\) Suppose the cost of the material for the base is \(20\text{ cents }/\text{ in. }^2 \) and the cost of the material for the sides is \(30\text{ cents }/\text{ in. }^2 \) and we are trying to minimize the cost of this box. Write the cost as a function of the side lengths of the base. (Let \(x\) be the side length of the base and \(y\) be the height of the box.)

Hint.

If the cost of one of the sides is \(30\text{ cents }/\text{ in. }^2 ,\) the cost of that side is \(0.30xy.\)

Solution.

\(C(x)=\frac{259.2}{x}+0.2x^2\) dollars

Subsection 4.7.3 Key Concepts

  • To solve an optimization problem, begin by drawing a picture and introducing variables.

  • Find an equation relating the variables.

  • Find a function of one variable to describe the quantity that is to be minimized or maximized.

  • Look for critical points to locate local extrema.

http://www.openstax.org/l/20_boxvolume