Lagrange MultipliersDate: 07/25/99 at 14:21:09 From: Robert Botnick Subject: Lagrange Multipliers My class was given this problem for extra credit. Now the class is over, and it's still driving me crazy. Can you help? Let F(x,y) = xy + yz + xz. Find the extreme values of F. The constraint is x^2 + y^2 + z^2 = 1. Solve using Lagrange multipliers. Date: 07/25/99 at 17:30:25 From: Doctor Anthony Subject: Re: Lagrange Multipliers The general problem is to find stationary points of f(x,y,z) subject to constraint g(x,y,z) = 0 [note that the constraint must be written in this form]. So for our problem g(x,y,z) = x^2 + y^2 + z^2 - 1 At stationary points of f(x,y) we have df = part(df/dx)*dx + part(df/dy)*dy + part(df/dz)*dz = 0 This implies that the vector [part(df/dx), part(df/dy), part(df/dz)] is perpendicular to the vector [dx, dy, dz] Since g(x,y,z) = 0, we can write dg = part(dg/dx)*dx + part(dg/dy)*dy + part(dg/dz)*dz = 0 Thus the vector [part(dg/dx), part(dg/dy), part(dg/dz)] is also perpendicular to the vector [dx, dy, dz]. This implies that the vector [part(df/dx), part(df/dy), part(df/dz)] is parallel to the vector [part(dg/dx), part(dg/dy), part(dg/dz)] and that we can find a scalar k such that [part(df/dx), part(df/dy), part(df/dz)] - k[part(dg/dx), part(dg/dy), part(dg/dz)] = [0, 0, 0] This can be summarized by writing phi(x,y,z) = f(x,y,z) - kg(x,y,z) Then f(x,y,z) will have a stationary point subject to constraint g(x,y,z) = 0 when part(d(phi)/dx) = 0, part(d(phi)/dy) = 0, part(d(phi)/dz) = 0, and g(x,y,z) = 0. This gives four equations to find x, y, z and k. k is the Lagrange multiplier and phi is the auxiliary function. Applying these ideas to our problem, we have f(x,y,z)= xy + yz + zx and g(x,y,z) = x^2 + y^2 + z^2 - 1 The auxiliary function is phi(x,y,z) = f(x,y,z) - kg(x,y,z) = xy+yz+zx - k(x^2 + y^2 + z^2 - 1) Then: part(d(phi)/dx) = y + z - 2kx = 0 ...............(1) part(d(phi)/dy) = x + z - 2ky = 0 ...............(2) part(d(phi)/dz) = y + x - 2kz = 0 ...............(3) g(x,y,z) = x^2 + y^2 + z^2 - 1 = 0 .......(4) Now we must solve (1), (2), (3) and (4) for k, x, y and z. Adding (1), (2) and (3) 2(x+y+z) - 2k(x+y+z) = 0 dividing out by 2(x+y+z) this gives 1-k = 0 and so k = 1. Subtracting (2) from (1) (y-x) - 2(x-y) = 0 3(x-y) = 0 This clearly requires x = y, similarly we can show x = z, so we must have: x = y = z and also x^2 + y^2 + z^2 = 1 3x^2 = 1 x^2 = 1/3 x = +-1/sqrt(3) So the stationary points are x = +-1/sqrt(3), y = +-1/sqrt(3), z = +-1/sqrt(3) The combinations of signs must be such as to satisfy equations (1), (2) and (3) above. This means we can take all + signs or all - signs. - Doctor Anthony, The Math Forum http://mathforum.org/dr.math/ Date: 07/28/99 at 23:29:51 From: Robert Durant Subject: Re: Lagrange Multipliers Thanks for writing back so quickly. I have one more question though. In this problem you assume that (x+y+z) is not equal to zero. What if (x+y+z) is equal to zero? Would you then be able to calculate f min? Is there a min in that case? Date: 07/29/99 at 06:54:03 From: Doctor Anthony Subject: Re: Lagrange Multipliers Yes. You are correct. I should have considered the alternative possibility that x+y+z = 0. This means y+z = -x and equation (1) above becomes -x -2kx = 0 -x(1+2k) = 0 so k = -1/2. Putting this into (1), (2) and (3) gives x+y+z = 0 in each case, so we must use equation (4) to see what happens to f(x,y,z) Consider (x+y+z)^2 = x^2 + y^2 + z^2 + 2(xy +yz + zx) 0 = 1 + 2(xy + yz + zx) -1 = 2.f(x,y,z) and another stationary value is f(x,y,z) = -1/2. Going back to the first solution we have: f(x,y,z) = 1/3 + 1/3 + 1/3 = 1 So the two stationary values are 1 and -1/2 - Doctor Anthony, The Math Forum http://mathforum.org/dr.math/ |
Search the Dr. Math Library: |
[Privacy Policy] [Terms of Use]
Ask Dr. Math^{TM}
© 1994-2015 The Math Forum
http://mathforum.org/dr.math/