You are on page 1of 50

CH.

5
LAGRANGE METHOD

05/27/2021
Example Boundary
2. Find the global extreme of
f(x,y) =x2–y2+1 on the closed and bounded S={(x,y)| x2 + y2  1}
Answer.
fx(x,y) = 2x fy(x,y) = – 2y
fxx(x,y) = 2 fyy(x,y) = –2
fxy(x,y) = 0
The critical points, obtained by solving the simultaneous
equation fx(x,y) = 0 and fy(x,y)=0, that is (0,0)
Hence, the critical points is (0, 0)( this point lies inside S),
but it is a saddle point (D < 0)
For the boundary point, let x= cos t and y = sint
(because S is a unit circle), we obtain
f(t)=cos2 t – sin2t+1

05/27/2021 2
Example (Cont.)
We wish to maximize and minimize the function of one variable f,
that is:
f ’(t)=–2 cost sin t – 2 sin t cost = 0  4 cos t sint= 0

sin2t= 0  2t= 0, , 2, 3  t= 0, /2, , 3/2


For t = 0
 x = 1, y = 0  f(1, 0) = 2
For t = /2
 x = 0, y = 1  f(0, 1) = 0
For t = 
 x = -1, y = 0  f(-1, 0) = 2
For t = 3/2
 x = 0, y = -1  f(0, -1) = 0
Hence, the global maximum value is 2 at point (1,0) and (-1,0),

and the global minimum value is 0 at point (0,1) and (0,-1)

05/27/2021 3
Problem Set
1. Find the extreme, by the following function:
2 4
a. f(x,y) = x +y -6xy
3 3 e. f ( x, y )  xy  
x y
b. f(x,y) = xy2 –6 x2 – 6y2 ( x 2  y 2  4 y )
f . f ( x, y )  e
c. f(x,y) = x2 +4 y2 – 2x+8y – 1
d. f(x,y) = 3x3 +y2 – 9x + 4y

2. Find the global extreme value by the following function:

a. f(x,y)=x2–6x+y2–8y+7 on the closed S={(x,y)|x2+y2 1}

b. f(x,y) =2x2+y2-4x-2y+5 on the closed


S={(x,y)| x2+½ y2 1}

05/27/2021 4
5

Lagrange multipliers
• Let z =f(x,y) subject to the constraint g (x, y) = 0

g(x,y) = 0. Find the extreme value f


subject to the constraint g.
Let the level curve of the function
f (x,y) = 9 – x2 – y2, that is :
To maximize f subject to constraint g(x,y) =0 is to find the level curve with the
greatest possible k that intersects the constraint curve, thus we obtain k≥
f(x,y) for each x, y  Df along g (x, y) = 0

Because the level curve and the constraint curve are tangent, the two curves
have a common perpendicular line. Hence, the gradient vector f and g are
parallel, that is,
 
 f ( x , y)    g ( x , y)

05/27/2021
Lagrange’s Method
• To maximize/minimize f(x0,y0) subject to the the
constraint g(x0,y0)=0, solve the system of equations
 
 f ( x 0 , y 0 )    g ( x 0 , y 0 ) dan g ( x 0 , y 0 )  0
where (x0,y0) is critical points ,  is Lagrange multiplier.

 To maximize/minimize f(x0,y0) subject to the the


constraint g(x0,y0)=0 and h(x0,y0)=0, solve the system of
 equations  
 f ( x0 , y0 )    g( x0 , y 0 )    h( x0 , y0 ) , g(x0,y0)=0, h(x0,y0)=0
where (x0,y0) is critical points ,  is Lagrange multiplier

05/27/2021 6
Example
7

Use Lagrange’s method to find the maximum dan minimum value of


1. f(x,y)= x2 – y2 + 1 on the circle x2+y2=1
Answer:  
 f (x, y )  2 x ˆi  2y ˆj  g(x, y )  2 x ˆi  2y ˆj
To find the critical points, we solve the equations
 
 f (x, y )    g(x, y ) and g(x, y )  0
that is:
2x =  2x …….(1)
– 2y =  2y …….(2)
x2+y2 = 1 ……..(3)
Example (Cont.)
By the equation (3), x and y cannot both be 0, thus

If x  0, from (1),we obtain  = 1, and the equation (2)


that y = 0, and from (3), that x2=1  x = ± 1

If y  0, from (2), that  = -1, then from (1),


we obtain x = 0, and from (3), that y2=1  y = ± 1
The critical points are (1,0), (-1,0), (0,1) and (0,-1)

For (1,0)
 f(1, 0) = 2, For (-1,0)
 f(-1, 0) = 2
For (0,1)
 f(0, 1) = 0, For (0,-1)
 f(0,-1) = 0
Hence, global maximum value = 2 at point (1,0) and (-1,0),
and global minimum=0 at point (0,1) and (0,-1)

05/27/2021 8
9

Example
2. f(x,y,z)= x + 2y+3z on the ellipse that is the intersection
of the cylinder x2+y2=2 and the plane y + z = 1
Answer: 
 
 f ( x, y )  ˆ j  3 kˆ
i 2ˆ  g(x, y )  2 x ˆ
i  2y ˆ
j j  kˆ
 h ( x, y )  ˆ
To find the critical points, we solve the equations
  
 f (x, y , z )    g(x, y , z )    h( x, y , z ) , g(x, y , z )  0
and h( x, y , z )  0

that is: 1 = 2x …………….(1) x2+y2 = 2 ……..…..(4)


2 = 2y +  …….(2) y + z = 1 ……..…..(5)
3 =  ……………….(3)

05/27/2021
Example (Cont.)
10

From (1), x = 1/(2), from (2) and (3), y = -1/(2). Hence from (4), we obtain  = ± ½.
For  = ½, we obtain the critical point (1, -1, 2), (-1, -1, 2).

For  = -½, we obtain the critical point (-1, 1, 0), (1, 1, 0).

Hence, the maximum value = 5 at point (1,-1,2),


and the minimum value = 1 at point (-1,1,0)
Problem Set
11

Use Lagrange’s method to


1. find the minimum value of f(x,y) = x 2 + y2 subject
to the constraint g(x,y)= xy – 3 = 0
2. find the maximum value of f(x,y) = xy subject
to the constraint x2 + y2 = 1
3. find the maximum value of f(x,y) = 4x 2 – 4xy+ y2
subject to the constraint x2+y2 = 1
4. find the minimum value of f(x,y) = x 2+y2+z2 subject
to the constraint x + 3y – 2z = 12
Inequality Constraint
•  If we have objective function f(x,y) and constraint g(x,y) < 0 then we
have equation
L(x,y,)=f(x,y)- [g(x,y)]
• To find the Maximize/Minimize from the equation we have consider 5
condition:
• Lx(x,y,) = 0 (derivative of x on L(x,y,))
• Ly(x,y,) = 0 (derivative of x on L(x,y,))
• .[g(x,y)] = 0
• 
One Inequality Constraint
•  Since we only consider 1 constraint then we have one variable of
lagrange multiplier () . Next. from 5 equations, we make in 2 case:
• Case 1: We consider that  =0
• Case 2: We consider  > 0 (for finding maximize) and  < 0 (for finding
minimize)
• Example 1:
Minimize subject to .
Solution: Lagrange Function
• Case
  1: When  =0

• =0, then we can conclude that x=0 and y=0


The solution:
Then from case 1, we have conclusion x=0 and y=0 x=0 and y=0
• Case 2: When  < 0

• 0, since x=4/5 then we have =4/5. It means

Then from case 2, we don’t have solution


Application in Industrial Engineering
• Suppose you are running a factory, producing some sort of widget
that requires steel as a raw material. Your costs are predominantly
human labor, which is $20 per hour for your workers, and the steel
itself, which runs for $170 per ton. Suppose your revenue R is loosely
modeled by the following equation:
2 /3 1/ 3
 
𝑅 =200 h 𝑠
h is hours of labor and s is tons of steel. If your budget is $20,000dollar,
what is the maximum possible revenue?

You might also like