Presentation is loading. Please wait.

Presentation is loading. Please wait.

Consider minimizing and/or maximizing a function z = f(x,y) subject to a constraint g(x,y) = c. y z x z = f(x,y) Parametrize the curve defined by g(x,y)

Similar presentations


Presentation on theme: "Consider minimizing and/or maximizing a function z = f(x,y) subject to a constraint g(x,y) = c. y z x z = f(x,y) Parametrize the curve defined by g(x,y)"— Presentation transcript:

1 Consider minimizing and/or maximizing a function z = f(x,y) subject to a constraint g(x,y) = c. y z x z = f(x,y) Parametrize the curve defined by g(x,y) = c as c(t) = (x(t),y(t))  g(c(t)) = c. For example, consider minimizing and maximizing the function z = x 2 – y 2 subject to the constraint x 2 + y 2 = 1. Parametrize x 2 + y 2 = 1 as c(t) = (cos t, sin t)  cos 2 t + sin 2 t = 1. d —g(c(t)) = dt d — c dt  g(c(t)) c  (t) = 0 d —(cos 2 t + sin 2 t) = dt d — 1 dt

2 Parametrize the curve defined by g(x,y) = c as c(t) = (x(t),y(t))  g(c(t)).= c. Parametrize x 2 + y 2 = 1 as c(t) = (cos t, sin t)  cos 2 t + sin 2 t = 1. d —g(c(t)) = dt d — c dt  g(c(t)) c  (t) = 0 d —(cos 2 t + sin 2 t) = dt d — 1 dt 2x 2y = 0 – sin t cos t Maximizing/Minimizing f(x,y) subject to g(x,y) = c is the same as maximizing/minimizing f(c(t)). Consequently, Maximizing/Minimizing f(x,y) = x 2 – y 2 subject to x 2 + y 2 = 1 is the same as maximizing/minimizing cos 2 t – sin 2 t. d —f(c(t)) = 0 dt d —(cos 2 t – sin 2 t) = 0 dt  f (c(t)) c  (t) = 0 Observe that both  f (c(t)) and  g(c(t)) must be orthogonal to c  (t).

3 y x If both  f (c(t)) and  g(c(t)) must be orthogonal to c  (t), then  f (c(t)) and  g(c(t)) must be c  (t0)c  (t0)multiples of each other, that is, for any point c(t 0 ) = (x 0, y 0 ) at which  f and  g are both orthogonal to c  (t), we must have  f(x 0, y 0 ) =  g(x 0, y 0 ), assuming neither gradient is the zero vector. This motivates the Method of Lagrange Multipliers (stated in its most general form in Theorem 8 on page 226). To maximize/minimize f(x,y) subject to g(x,y) = c, (1) (2) (3) Set up the system of equations  f(x,y) =  g(x,y) and g(x,y) = c. Let = 0 to find critical points of the function f(x,y), but eliminate these points from consideration if they do not satisfy g(x,y) = c. Assume  0, solve for (x,y), and substitute each candidate for an extremum into f to find the desired maximum/minimum values for f.

4 Find the extreme values of z = x 2 – y 2 along the circle of radius 1 centered at the origin in the xy plane. With f(x,y) = x 2 – y 2 and g(x,y) = x 2 + y 2, we have  f(x,y) =  g(x,y) = Setting  f(x,y) =  g(x,y) and including the constraint equation, we have [ 2x – 2y ] [ 2x 2y ] 2x= 2x – 2y= 2y x 2 + y 2 = 1 = 0 implies x = y = 0, which is not possible, since the third equation is not satisfied. Candidates for extrema are(0,1), (0,–1), (1,0), (–1,0). f(0,1) = f(0,–1) = –1 is the minimum value of the function on the circle. f(1,0) = f(–1,0) = 1 is the maximum value of the function on the circle.  0 implies either x or y must be zero, since we cannot have both = 1 and = –1. If x = 0, then from the third equation y = 1 or y = –1. If y = 0, then from the third equation x = 1 or x = –1.

5 Find the extreme values of f(x,y) = x 2 + y 2 along the line y = x + 1, that is, the line y – x = 1. With f(x,y) = x 2 + y 2 and g(x,y) = y – x, we have  f(x,y) =  g(x,y) = Setting  f(x,y) =  g(x,y) and including the constraint equation, we have [ 2x 2y ][ –1 1 ] 2x= – 2y= y – x= 1 = 0 implies x = y = 0, which is not possible, since the third equation is not satisfied. The only candidate for an extremum is(–1/2, 1/2). Since f(x,y) goes to infinity as either x or y goes to negative or positive infinity, then there can be no global maximum; therefore, the single candidate for an extremum f(–1/2, 1/2) = 1/2 is the minimum value of the function on the line.  0 implies x = –y. From the third equation, x = –1/2 and y = 1/2.

6 Note how we could have solved this problem using substitution. Since f(x,y) = x 2 + y 2 and y = x + 1, then we may write Setting h  (x) = 4x + 2 = 0, we find that x = –1/2 is a critical point. We then find that this critical point is a local minimum, since, h   (x) = 4 > 0. To use Lagrange multipliers to find the absolute maximum and minimum for a function f(x,y) over a region: (1) (2) Find the extreme values of f(x,y) = x 2 + y 2 along the line y = x + 1, that is y – x = 1. f(x,y) = x 2 + y 2 = x 2 + (x + 1) 2 = 2x 2 + 2x + 1 = h(x). Use Lagrange multipliers to find candidates for extrema on the boundary of the region. Add to the candidates for extrema all critical points of the function that lie in the region, and substitute each candidate into f.

7 Find the absolute maximum and minimum of f(x,y) = xy on the unit disc, i.e., where x 2 + y 2  1. With f(x,y) = xy and g(x,y) = x 2 + y 2, we have  f(x,y) =  g(x,y) = [ y x ][ 2x 2y ] (0,0). First, we find all critical points of f(x,y) located in the unit disk, by solving f x = f y = 0. The only critical point is Next, we locate the candidates for extrema on the boundary of the unit disk, that is, on the unit circle of radius 1. Setting  f(x,y) =  g(x,y) and including the constraint equation, we have y= 2 x x= 2 y x 2 + y 2 = 1 = 0 implies x = y = 0, which again gives us the critical point (0,0).  0 implies x and y must either both be zero or both be non-zero with x 2 = y 2. From the third equation, x = 1/  2 or x = –1/  2. Candidates for extrema are

8 (0,0) (1/  2, 1/  2) (–1/  2, 1/  2) (1/  2, –1/  2) (–1/  2, –1/  2). f(0,0) = f(1/  2, 1/  2) = f(–1/  2, 1/  2) = f(1/  2, –1/  2) = f(–1/  2, –1/  2) = 0 1/2 –1/2 1/2 The absolute maximum of f is 1/2 and occurs at (1/  2, 1/  2) and (–1/  2, –1/  2). The absolute minimum of f is –1/2 and occurs at (–1/  2, 1/  2) and (1/  2, –1/  2) Note: from the second derivative test, we find that (0,0) is a saddle point.

9 Find the absolute maximum and minimum of f(x,y) = (x 2 + y 2 )/2 on the elliptical region defined by x 2 /2 + y 2  1. With f(x,y) = (x 2 + y 2 )/2 and g(x,y) = x 2 /2 + y 2, we have  f(x,y) =  g(x,y) = [ x y ][ x 2y ] (0,0). First, we find all critical points of f(x,y) located in the elliptical region, by solving f x = f y = 0. The only critical point is Next, we locate the candidates for extrema on the boundary of the elliptical region. Setting  f(x,y) =  g(x,y) and including the constraint equation, we have x= x y= 2 y x 2 /2 + y 2 = 1 = 0 implies x = y = 0, which again gives us the critical point (0,0).  0 implies x and y cannot both be non-zero, since we cannot have both = 1 and = 1/2.

10 x= x y= 2y x 2 /2 + y 2 = 1 If x = 0, then from the third equation, y = 1 or y = –1; if y = 0, then from the third equation, x =  2 or x = –  2. Candidates for extrema are (0,0) (0, 1) (0, –1) (  2, 0) (–  2, 0). f(0,0) =f(0, 1) =f(0, –1) = f(  2, 0) =f(–  2, 0) = 01/2 11 The absolute maximum of f is 1 and occurs at (  2, 0) and (–  2, 0). The absolute minimum of f is 0 and occurs at (0,0). Using Lagrange multipliers to find the absolute maximum and minimum for a function of more than two variables over a region is a natural generalization of the method with a function of two variables.

11 Find the absolute maximum and minimum of f(x,y,z) = xy + z 2 subject to the constraint that x 2 + y 2 + z 2 = 1. With f(x,y,z) = xy + z 2 and g(x,y,z) = x 2 + y 2 + z 2, we have  f(x,y,z) =  g(x,y,z) = Setting  f(x,y,z) =  g(x,y,z) and including the constraint equation, we have [ y x 2z ][2x 2y 2z ] y = 2 x x = 2 y 2z = 2 z x 2 + y 2 + z 2 = 1 = 0  x = y = z = 0, which is not possible, since the fourth equation is not satisfied. Candidates for extrema are (1/  2, 1/  2, 0), (–1/  2, 1/  2, 0), (1/  2, –1/  2, 0), (–1/  2, –1/  2, 0) f (–1/  2, 1/  2, 0) = f(1/  2, –1/  2, 0) = –1/2 is the absolute minimum,  0  either that x = y = 0 and z = –1 or 1, or that x 2 = y 2 = 1/2 and z = 0. (0, 0, 1), (0, 0, –1), and f(0, 0, 1) = f(0, 0, –1) = 1 is the absolute maximum.

12 Find the absolute maximum and minimum of f(x,y,z) = xy + yz subject to the constraint that x 2 + y 2 + z 2 = 1. With f(x,y,z) = xy + yz and g(x,y,z) = x 2 + y 2 + z 2, we have  f(x,y,z) =  g(x,y,z) = Setting  f(x,y,z) =  g(x,y,z) and including the constraint equation, we have [ y x + z y ][2x 2y 2z ] y = 2 x x + z = 2 y y = 2 z x 2 + y 2 + z 2 = 1 = 0  y = 0 and x = – z, which gives us x = 1/  2 & z = –1/  2 or x = –1/  2 & z = 1/  2.  0  x = z  0 and y 2 = 2x 2, which gives us that x = z = 1/2 and y = 1/  2 or –1/  2, or Candidates for extrema are (1/  2, 0, –1/  2), (–1/  2, 0, 1/  2), f (1/2, –1/  2, 1/2) = f(–1/2, 1/  2, –1/2) = –1/  2 is the absolute minimum, and (1/2, 1/  2, 1/2), (1/2, –1/  2, 1/2), (–1/2, 1/  2, –1/2), (–1/2, –1/  2, –1/2). f(1/2, 1/  2, 1/2) = f(–1/2, –1/  2, –1/2) = 1/  2 is the absolute maximum. that x = z = –1/2 and y = 1/  2 or –1/  2.

13 Let x, y, and z be the dimensions of a rectangular box. Maximize the volume V = subject to the constraint that the surface area of the box is S = With f(x,y,z) = and g(x,y,z) =, we have  f(x,y,z) =  g(x,y,z) = Setting  f(x,y,z) =  g(x,y,z) and including the constraint equation, we have [ yz xz xy ][2y +2z 2x +2z 2x +2y ] yz = 2 (y+z) xz = 2 (x+z) xy = 2 (x+y) 2xy + 2xz + 2yz = S = 0 implies xy = xz = yz = 0, which is not possible, since the fourth equation is not satisfied (and the box must have positive dimensions). yz xz From the first two equations,—— =——, from which it follows x = y. y+z x+z  0 implies none of x, y, or z can be 0. xz xy From the last two equations,—— =——, from which it follows y = z. x+z x+y xyz 2xy + 2xz + 2yz. xyz2xy + 2xz + 2yz

14 Then, from the constraint equation, we find that the only candidate for extrema where each of x, y, and z is nonnegative is (  S/6,  S/6,  S/6). We know this must be an absolute maximum by checking that volume can only become smaller as any one of the dimensions goes to zero. The maximum volume is yz = 2 (y+z) xz = 2 (x+z) xy = 2 (x+y) 2xy + 2xz + 2yz = S = 0 implies of x, y, and z is 0, which is not possible, since the fourth equation is not satisfied (i.e., the box must have positive dimensions). yz xz From the first two equations,—— =——, from which it follows x = y. y+z x+z  0 implies none of x, y, or z can be 0. xz xy From the last two equations,—— =——, from which it follows y = z. x+z x+y (S/6) 3/2.


Download ppt "Consider minimizing and/or maximizing a function z = f(x,y) subject to a constraint g(x,y) = c. y z x z = f(x,y) Parametrize the curve defined by g(x,y)"

Similar presentations


Ads by Google