The function is subject to 2 constraints: g(x,y,z)
= x-y+z=1 and h(x,y,z) = x^2+y^2-1=0.
We'll use the
Lagrange's five equations to determine the maximum value of the
function.
df/dx = s*(dg/dx) +
t*(dh/dx)
1= s + 2x*t
(1)
df/dy = s*(dg/dy) +
t*(dh/dy)
2 = -s + 2y*t
(2)
df/dz = s*(dg/dz) +
t*(dh/dz)
3 = s (3)
x - y + z
= 1 (4)
x^2+y^2 = 1 (5)
We'll
substitute s = 3 in (1):
s + 2x*t =
1
3 + 2x*t = 1
2x*t =
-2
x*t = -1
x = -1/t
(6)
We'll substitute s = 3 in
(2):
2 = -3 + 2y*t
2yt =
5
y = 5/2t (7)
We'll
substitute (6) and (7) in (5):
(1/t^2) + (25/4t^2) =
1
29/4t^2 = 1
t^2 =
29/4
t1 = -sqrt29/2 ; t2 =
sqrt29/2
x1 = 2/sqrt29 ; x2 =
-2/sqrt29
y1 = -5/sqrt29 ; y2 =
5/sqrt29
z1 = 1 - 7/sqrt29 ; z2 = 1 +
7/sqrt29
The maximum value of f
is:
f max = -2/sqrt29 + 2*5/sqrt29 +
3(1+7/sqrt29)
fmax = -2/sqrt29 + 10/sqrt29 + 3 +
21/sqrt29
fmax = 29/sqrt29 +
3
fmax = 29*sqrt29/29 + 3
fmax
= sqrt29 + 3
The maximum value of f is: fmax
= sqrt29 + 3.
No comments:
Post a Comment