Lagrange Multipliers I. Quiz II. Homework III. Lagrange Multipliers Suppose that we have a function f(x,y) that we want to maximize in the restricted domain g(x,y) = c for some constant c. A picture will be given in class. Then we can look at the level curves of f and seek the largest level curve that intersects the curve g(x,y) = c. It is not hard to see that these curves will be tangent. Hence the gradient vectors will be parallel. Theorem: Let f(x,y) be differentiable and g(x,y) = c define a smooth curve. Then the max and min of f subject to the constraint g occur when fx = lgx and fy = lgy for some constant l. Example: Find the extrema of f(x,y) = x2 - y2 subject to the constraint y - x2 = 0 Solution: We have <2x,-2y> = lambda<-2x,1> 2x = l(-2x), -2y = l(1) This gives us the three equations: 2x = -l2x -2y = l (1) y - x2 = 0 the first equation gives us l= -1 Hence the second equation becomes -2y = -1 so that y = 1/2 the third equation gives us 1/2 - x2 = 0 Hence x = sqrt2/2 Example 2: Find the distance from the origin to the surface xyz = 8 Solution: We minimize D = x2 + y2 + z2 subject to the constraint xyz = 1 We have <2x,2y,2z> = lambda<yz,xz,xy> 2x = lambda yz 2y = lambda xz 2z = lambda xy or lambda = 2x/yz = 2y/xz = 2z/xy or 2x2 = 2y2 = 2z2 Hence x = +- y = +- z so that +-x3 = 8 or x = +-2 We get the points (2,2,2), (2,-2,-2), (-2,-2,2),(-2,2,-2) these all have distance sqrt(12) from the origin. IV. Two constraints Example: Maximize xy + z on the intersection of the two surfaces: y2 + z = 0 and x2 + z = 1 Solution: Now we set gradf = a grad g + b grad h <y,x,1> = a<0,2y,1> + b<2x, 0,1> we have the five equations: y = 2bx x = 2ay 1 = a + b y2 + z = 0 and x2 + z = 1 Using the third equation: y = 2(1 - a)x x = 2ay y2 + z = 0 and x2 + z = 1 The first two equations give us: a = x - y/2 = x/2y Hence 2xy - y2 = x or x = y2 /(2y - 1) the last equations give: z = -y2 = -x2 + 1 Hence -y2 = -[y2 /(2y - 1)]2 + 1 the best way to solve this is to use the solver to get that y is about .7 Hence x = 1.2 and z = -.49
|