Maximise the volume of a rectangular prism with 2 constraints

phosgene
Messages
145
Reaction score
1

Homework Statement



Maximise the volume of a rectangular prism with the following constraints: the surface area must equal 2m^2 and the total edge length must be 12m.

Homework Equations



Using Lagrange multipliers, we construct the function we want to optimise with

h(x,y,z, λ_{1}, λ_{2}) = f(x,y,z) + λ_{1}g_{1}(x,y,z) + λ_{2}g_{2}(x,y,z)

The Attempt at a Solution



In this case our f(x,y,z) is the volume of the rectangular prism, so f(x,y,z)=xyz, where we take x to be the length, y the widge and z the depth. g_{1}(x,y,z)=λ_{1}(xy + yz + zx - 1), the surface area constraint and g_{2}(x,y,z)=λ_{2}(x+y+z-3) (the edge length constraint).

The function to be optimised is then h(x,y,z, λ_{1}, λ_{2}) = xyz + λ_{1}(xy + yz + zx - 1) + λ_{2}(x+y+z-3)

Obtain all the partial derivatives:

1. \frac{∂h}{∂x} = yz + λ_{1}(y+z) + λ_{2} = 0

2. \frac{∂h}{∂y} = xz + λ_{1}(x+z) + λ_{2} = 0

3. \frac{∂h}{∂z} = yx + λ_{1}(y+z) + λ_{2} = 0

4. \frac{∂h}{∂λ_{1}} = xy + yx + zy -1 = 0

5. \frac{∂h}{∂λ_{2}} = x + y + z -3 = 0

Add 1, 2 and 3. Then sub in 4 and 5 to obtain the result λ_{1}=-(3λ_{2}+1)/6

But from here I'm totally lost. I can re-arrange 1,2 and 3 to get λ2 by itself, then equate them all to get

\frac{\frac{1}{6}(y+z) - yz}{1-\frac{1}{2}(y+z)}=\frac{\frac{1}{6}(y+x) - yx}{1-\frac{1}{2}(y+x)}=\frac{\frac{1}{6}(z+x) - zx}{1-\frac{1}{2}(z+x)}

But doesn't this imply that x=y=z? This cannot satisfy both 4 *and* 5.
 
Physics news on Phys.org
What that tells you is that the constraints are impossible- you cannot have a rectangular prism with surface area 2 square meters and total edge length 12 meters.
 
HallsofIvy said:
What that tells you is that the constraints are impossible- you cannot have a rectangular prism with surface area 2 square meters and total edge length 12 meters.

No, you can have such a prism. In fact, over the physically allowable region ##x,y,z \geq 0, x+y+z = 3## the half-area ##A = xy + xz + yz## ranges from ##A = 0## at the points ##(x,y,z) = (3,0,0), (0,3,0), (0,0, 3)## to ##A = 3## at the point ##(x,y,z) = (1,1,1)##. Any value of ##A## from 0 to 3 is attainable.

However, the OP made a number of errors (perhaps typographical, perhaps not).

I found it much easier to use one of the constraints to eliminate one of the variables. For example, from ##g_2 = 3## we have ##z = 3 - x - y##, and putting that in ##g_1## yields ##G_1(x,y) = g_1(x,y,3-x-y) = 3x+3y-x^2-y^2-xy-1## Now the problem is to maximize ##F = x y (3-x-y)##, subject to ##G_1(x,y) = 0##. This can be attacked using a Lagrange multiplier method; there are solutions.
 
Last edited:
There are two things I don't understand about this problem. First, when finding the nth root of a number, there should in theory be n solutions. However, the formula produces n+1 roots. Here is how. The first root is simply ##\left(r\right)^{\left(\frac{1}{n}\right)}##. Then you multiply this first root by n additional expressions given by the formula, as you go through k=0,1,...n-1. So you end up with n+1 roots, which cannot be correct. Let me illustrate what I mean. For this...
Back
Top