← Back to learning objective

Maximizing area of a three-sided fenced rectangle

A farmer wants to build a rectangular pen that is bordered on one side by an existing barn wall, so fencing is only needed on the other three sides. The farmer has 240 feet of fencing available.

Let xx be the length (in feet) of each of the two sides perpendicular to the barn wall, and let yy be the length of the side parallel to the wall. The farmer has 240 ft of fencing to use on the two perpendicular sides and the one parallel side (the wall itself needs no fencing).

  1. Write the constraint relating xx and yy based on the total fencing available.
  2. Use this constraint to express the enclosed area AA as a function of xx alone.
  3. Determine the value of xx that maximizes the area, and find the maximum possible area.

What is the maximum area (in square feet) that can be enclosed?

Hint

Start with the fencing constraint 2x+y=2402x + y = 240, solve for yy, then substitute into A=xyA = xy to get a single-variable function. Find where A′(x)=0A'(x) = 0 on the domain 0<x<1200 < x < 120.

Step-by-step solution

Since fencing is used on the two sides of length xx and the one side of length yy, the constraint is 2x+y=2402x + y = 240, so y=240−2xy = 240 - 2x. Substituting into A=xyA = xy gives A(x)=x(240−2x)=240x−2x2A(x) = x(240-2x) = 240x - 2x^2, defined for 0<x<1200 < x < 120 so that both xx and yy stay positive.

Taking the derivative, A′(x)=240−4xA'(x) = 240 - 4x. Setting A′(x)=0A'(x) = 0 gives x=60x = 60. Since A′′(x)=−4<0A''(x) = -4 < 0, this critical point is a maximum. Then y=240−2(60)=120y = 240 - 2(60) = 120, so the maximum area is A(60)=60⋅120=7200A(60) = 60 \cdot 120 = 7200 square feet.

Related problems

Practice similar Calculus problems interactively.

Start Closing the Gap