Steply

A rectangular pen of 72 ft² is fenced on three sides. A barn is the…

Step by step, with the reason for every step · Optimization · Calculus 1

Step by step

The question

Question: A rectangular pen of 72 ft² is fenced on three sides.

A barn is the fourth side.

Find the least fencing needed.

1 Draw and name

The barn is one side: no fence there.

The two sides that touch the barn are x.

The side across is y.

x = each side touching the barn
y = the side across

2 Write the fencing

The fence is two x sides and one y side.

L = 2x + y

3 Use only one letter

Two letters.

The area gives the link: x times y is 72.

xy = 72

So y = 72 over x.

y = 72x

Put it in place of y.

L = 2x + 72x

4 Which x make sense

A length is positive: x is more than 0.

x > 0 =

5 Slope = 0

The smallest value is where the slope is 0.

2x gives 2.

72/x is 72x to the power −1, which gives −72/x².

L′(x) = 2 − 72x2
72x = 72x−1 → −72x−2

Set it to 0, and move the fraction across.

72x2 = 2

Times both sides by x², so they stay equal.

72 = 2x2

Divide by 2.

x2 = 36

x squared is 36, so x is 6.

Minus 6 squared is also 36, but x must be positive.

x = 6 (not −6)

Careful!

A length cannot be negative.

Only x = 6 is allowed.

Careful: not x = −6 ✗

6 Make sure it is the smallest

Before 6, the slope is negative: going down.

After it, positive: going up.

Down, then up: the bottom.

A minimum.

L′(5) = −0.88 < 0 ↘, L′(7) = 0.53 > 0 ↗

7 Answer the question

The other side: 72/6 is 12.

y = 726 = 12

So the least fencing is 24 ft.

L(6) = 2 × 6 + 12 = 24 ft

8 Check

Let's check with x a bit smaller: 5 gives 24.4.

x = 5: L = 24.4

And x = 7 gives 24.29.

Both are bigger than 24.

Right!

x = 7: L = 24.29

Let's look back.

First: draw and name.

Then: write the fencing.

Then: use only one letter.

Then: which x make sense.

Then: slope = 0.

Then: make sure it is the smallest.

Then: answer the question.

Last: check.

Answer
L(6) = 2 × 6 + 12 = 24 ft

Your turn

Try this one yourself, then check:

Show the answer
least fencing = 48 ft

More from Optimization

The whole lesson: Optimization →