Multivariable CalculusOptimization6 of 6
Optimization · 6

Lagrange Multipliers with Two Constraints

When we optimize a function f(x,y,z)\fn{f(x, y, z)} on a single constraint surface g(x,y,z)=c\gcon{g(x, y, z) = c}, we look for points where ∇f\gradf{\nabla f} points entirely in the forbidden direction perpendicular to the surface, ∇f=λ∇g\gradf{\nabla f} = \gcon{\lambda \nabla g}. Now we want to find the maximum and minimum values of f(x,y,z)\fn{f(x, y, z)} when we have to satisfy two constraints at the same time, g(x,y,z)=c1\gcon{g(x, y, z) = c_1} and h(x,y,z)=c2\hcon{h(x, y, z) = c_2}.

1

Optimizing with Two Constraints

Staying on two surfaces g(x,y,z)=c1\gcon{g(x, y, z) = c_1} and h(x,y,z)=c2\hcon{h(x, y, z) = c_2} at once restricts us to the curve where the two surfaces intersect.

Optimizing with Two Constraints
x\htmlClass{lc-mute}{x}
y\htmlClass{lc-mute}{y}
z\htmlClass{lc-mute}{z}
f(x,y,z)\fn{f(x, y, z)}
g(x,y,z)=c\gcon{g(x, y, z) = c}
6.49\fn{6.49}

At an extreme point on the intersection curve, the direction of fastest increase ∇f\gradf{\nabla f} cannot have any component along the curve. It must lie entirely in the plane perpendicular to the curve, which is spanned by the two forbidden directions ∇g\gcon{\nabla g} and ∇h\hcon{\nabla h}:

∇f\displaystyle \gradf{\nabla f} =λ∇g⏟forbidden direction off g=c1+μ∇h⏟forbidden direction off h=c2\displaystyle = \underbrace{\gcon{\lambda \nabla g}}_{\text{forbidden direction off } \gcon{g = c_1}} + \underbrace{\hcon{\mu \nabla h}}_{\text{forbidden direction off } \hcon{h = c_2}}

As you move along the intersection of the cylinder g=c1\gcon{g = c_1} and the plane h=c2\hcon{h = c_2}, ∇f\gradf{\nabla f} pulls along the curve everywhere except at the hottest and coldest points, where it lies flat in the perpendicular plane spanned by ∇g\gcon{\nabla g} and ∇h\hcon{\nabla h}.

Along the curve where the two surfaces meet, the temperature keeps changing wherever its gradient leans along the curve, and hits its hottest and coldest spots only where that gradient lies flat in the perpendicular plane made by the two surface gradients.
2

Worked Example: A Cylinder and a Plane

With three coordinates (x,y,z)(x, y, z) and two multipliers (λ,μ)(\gcon{\lambda}, \hcon{\mu}), we have five unknowns and five equations: the three components of ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} together with the two constraints g(x,y,z)=c1\gcon{g(x, y, z) = c_1} and h(x,y,z)=c2\hcon{h(x, y, z) = c_2}.

Let's find the maximum and minimum values of the temperature

f(x,y,z)=x+2y+3z\displaystyle \fn{f(x, y, z) = x + 2y + 3z}

on the curve where the cylinder g(x,y,z)=x2+y2=2\gcon{g(x, y, z) = x^2 + y^2 = 2} meets the plane h(x,y,z)=y+z=1\hcon{h(x, y, z) = y + z = 1}, along with the multipliers λ\gcon{\lambda} and μ\hcon{\mu} at each point.

Worked Example: A Cylinder and a Plane
x\htmlClass{lc-mute}{x}
y\htmlClass{lc-mute}{y}
z\htmlClass{lc-mute}{z}
f(x,y,z)=x+2y+3z\fn{f(x, y, z) = x + 2y + 3z}
g(x,y,z)=x2+y2=2\gcon{g(x, y, z) = x^2 + y^2 = 2}
g\gcon{g}
h(x,y,z)=y+z=1\hcon{h(x, y, z) = y + z = 1}
h\hcon{h}
Text solution
Match the components of ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h}We take the gradients of f\fn{f}, g\gcon{g}, and h\hcon{h} and set their xx-, yy-, and zz-components equal to connect the coordinates through λ\gcon{\lambda} and μ\hcon{\mu}.
∇f=(1,2,3),∇g=(2x,2y,0),∇h=(0,1,1)(1,2,3)=λ(2x,2y,0)+μ(0,1,1)x-component:1=2λxy-component:2=2λy+μz-component:3=μ\displaystyle \begin{aligned} \gradf{\nabla f} &= \gradf{(1, 2, 3)}, \\ \gcon{\nabla g} &= \gcon{(2x, 2y, 0)}, \\ \hcon{\nabla h} &= \hcon{(0, 1, 1)} \\ \gradf{(1, 2, 3)} &= \gcon{\lambda(2x, 2y, 0)} \\ &\quad + \hcon{\mu(0, 1, 1)} \\ x\text{-component:} \quad \gradf{1} &= \gcon{2\lambda x} \\ y\text{-component:} \quad \gradf{2} &= \gcon{2\lambda y} + \hcon{\mu} \\ z\text{-component:} \quad \gradf{3} &= \hcon{\mu} \end{aligned}
Use μ\hcon{\mu} and λ\gcon{\lambda} to relate xx and yyPutting μ=3\hcon{\mu = 3} from the zz-component into the yy-component lets us compare the xx- and yy-equations directly without solving for λ\gcon{\lambda} first.
2=2λy+32λy=−12λx=1  ⟹  y=−x\displaystyle \begin{aligned} \gradf{2} &= \gcon{2\lambda y} + \hcon{3} \\ \gcon{2\lambda y} &= -1 \\ \gcon{2\lambda x} &= 1 \implies y = -x \end{aligned}
Substitute y=−xy = -x into the two constraints to find the candidate pointsPlugging y=−xy = -x into the cylinder x2+y2=2\gcon{x^2 + y^2 = 2} gives the possible values of xx, and the plane y+z=1\hcon{y + z = 1} gives the matching zz for each point.
x2+(−x)2=22x2=2x=1orx=−1At x=1:y=−1,−1+z=1  ⟹  z=2  ⟹  (1,−1,2)At x=−1:y=1,1+z=1  ⟹  z=0  ⟹  (−1,1,0)\displaystyle \begin{aligned} x^2 + (-x)^2 &= 2 \\ 2x^2 &= 2 \\ x &= 1 \quad \text{or} \quad x = -1 \\ \text{At } x = 1: \\ \quad y &= -1, \quad -1 + z = 1 \\ &\implies z = 2 \\ &\implies (1, -1, 2) \\ \text{At } x = -1: \\ \quad y &= 1, \quad 1 + z = 1 \\ &\implies z = 0 \\ &\implies (-1, 1, 0) \end{aligned}
Evaluate f\fn{f} and find λ\gcon{\lambda} and μ\hcon{\mu} at each pointWe plug both points into f(x,y,z)=x+2y+3z\fn{f(x, y, z) = x + 2y + 3z} to find the hottest and coldest spots, then use 2λx=1\gcon{2\lambda x} = 1 and μ=3\hcon{\mu = 3} to find the multipliers at each one.
f(1,−1,2)=1+2(−1)+3(2)=5(Maximum, with λ=12,  μ=3)f(−1,1,0)=−1+2(1)+3(0)=1(Minimum, with λ=−12,  μ=3)\displaystyle \begin{gathered} \begin{aligned} \fn{f(1, -1, 2)} &= 1 + 2(-1) + 3(2) \\ &= \fn{5} \end{aligned} \\ \left(\text{Maximum, with } \gcon{\lambda = \tfrac{1}{2}}, \; \hcon{\mu = 3}\right) \\ \begin{aligned} \fn{f(-1, 1, 0)} &= -1 + 2(1) + 3(0) \\ &= \fn{1} \end{aligned} \\ \left(\text{Minimum, with } \gcon{\lambda = -\tfrac{1}{2}}, \; \hcon{\mu = 3}\right) \end{gathered}

So on the curve where the cylinder and plane meet, the maximum temperature is 55 at (1,−1,2)(1, -1, 2) and the minimum temperature is 11 at (−1,1,0)(-1, 1, 0).

3

What the Multiplier Means

A multiplier is the rate at which the extreme value of f\fn{f} changes when we adjust the constraint constant.

Suppose we change a single constraint slightly from g(x,y,z)=c\gcon{g(x, y, z) = c} to g(x,y,z)=c+Δc\gcon{g(x, y, z) = c + \Delta c}, shifting the boundary surface and moving the extreme value fbest\fn{f_{\text{best}}} (either fmax\fn{f_{\text{max}}} or fmin\fn{f_{\text{min}}}).

What the Multiplier Means
x\htmlClass{lc-mute}{x}
y\htmlClass{lc-mute}{y}
z\htmlClass{lc-mute}{z}
g(x,y,z)=c→c+Δc\gcon{g(x, y, z) = c} \to \gcon{c + \Delta c}
c\gcon{c}
fmax\fn{f_{\text{max}}}
ΔfbestΔc≈  ?\dfrac{\fn{\Delta f_{\text{best}}}}{\gcon{\Delta c}} \approx \;?

When the constraint surface shifts, moving from the old peak to the new one combines a sideways slide along the surface with a step perpendicular to it. Because f\fn{f} has zero rate of change along the surface at an extreme point, a small sideways slide does not change f\fn{f}, so all the change comes from the perpendicular step where ∇f=λ∇g\gradf{\nabla f} = \gcon{\lambda \nabla g}:

Δfbest≈λΔc(λ=dfmaxdc or dfmindc)\displaystyle \fn{\Delta f_{\text{best}}} \approx \gcon{\lambda \Delta c} \qquad \left(\gcon{\lambda} = \frac{d\fn{f_{\text{max}}}}{\gcon{dc}} \text{ or } \frac{d\fn{f_{\text{min}}}}{\gcon{dc}}\right)

With two constraints g(x,y,z)=c1\gcon{g(x, y, z) = c_1} and h(x,y,z)=c2\hcon{h(x, y, z) = c_2}, changing the constants by small amounts Δc1\gcon{\Delta c_1} and Δc2\hcon{\Delta c_2} adds the effects from both boundaries:

Δfbest≈λΔc1⏟from shifting g=c1+μΔc2⏟from shifting h=c2(λ=∂fbest∂c1,μ=∂fbest∂c2)\displaystyle \begin{gathered}\fn{\Delta f_{\text{best}}} \approx \underbrace{\gcon{\lambda \Delta c_1}}_{\text{from shifting } \gcon{g = c_1}} + \underbrace{\hcon{\mu \Delta c_2}}_{\text{from shifting } \hcon{h = c_2}} \\ \left(\gcon{\lambda} = \frac{\partial \fn{f_{\text{best}}}}{\gcon{\partial c_1}}, \quad \hcon{\mu} = \frac{\partial \fn{f_{\text{best}}}}{\hcon{\partial c_2}}\right)\end{gathered}

When the surface g(x,y,z)=c\gcon{g(x, y, z) = c} shifts to g=c+Δc\gcon{g = c + \Delta c}, the perpendicular step across to the new surface changes the extreme value by λΔc\gcon{\lambda \Delta c}. The extreme value rises when the surface shifts in the direction of ∇f\gradf{\nabla f} (λΔc>0)(\gcon{\lambda \Delta c > 0}) and falls when it shifts opposite to ∇f\gradf{\nabla f} (λΔc<0)(\gcon{\lambda \Delta c < 0}).

When you nudge the surface, sliding sideways to the new peak adds nothing, so the whole change in the peak value comes from stepping straight across to the new surface.
4

Estimating Changes When Constraints Shift

Once we have the multipliers λ\gcon{\lambda} and μ\hcon{\mu} at an extreme point, we can estimate how the maximum or minimum value changes when the constraints shift slightly, without solving the system over again.

In our cylinder-and-plane example (f(x,y,z)=x+2y+3z(\fn{f(x, y, z) = x + 2y + 3z} on x2+y2=2\gcon{x^2 + y^2 = 2} and y+z=1)\hcon{y + z = 1}), we found fmax=5\fn{f_{\text{max}} = 5} with λ=12,μ=3\gcon{\lambda = \frac{1}{2}}, \hcon{\mu = 3} and fmin=1\fn{f_{\text{min}} = 1} with λ=−12,μ=3\gcon{\lambda = -\frac{1}{2}}, \hcon{\mu = 3}. Let's estimate the new extreme values if we widen the cylinder to x2+y2=2.2\gcon{x^2 + y^2 = 2.2} and shift the plane to y+z=1.1\hcon{y + z = 1.1}.

Estimating Changes When Constraints Shift
x\htmlClass{lc-mute}{x}
y\htmlClass{lc-mute}{y}
z\htmlClass{lc-mute}{z}
f(x,y,z)=x+2y+3z\fn{f(x, y, z) = x + 2y + 3z}
x2+y2=2→2.2\gcon{x^2 + y^2 = 2} \to \gcon{2.2}
y+z=1→1.1\hcon{y + z = 1} \to \hcon{1.1}
fmax=5\fn{f_{\text{max}} = 5}
λ=12\gcon{\lambda = \dfrac{1}{2}}
μ=3\hcon{\mu = 3}
fmin=1\fn{f_{\text{min}} = 1}
λ=−12\gcon{\lambda = -\dfrac{1}{2}}
μ=3\hcon{\mu = 3}
Widening the cylinder: Δc1=+0.2\gcon{\Delta c_1 = +0.2}
x2+y2=2→2.2\gcon{x^2 + y^2 = 2 \to 2.2},  y+z=1\hcon{y + z = 1}
Shifting the plane: Δc2=+0.1\hcon{\Delta c_2 = +0.1}
x2+y2=2\gcon{x^2 + y^2 = 2},  y+z=1→1.1\hcon{y + z = 1 \to 1.1}
Text solution
Widen the cylinder from x2+y2=2\gcon{x^2 + y^2 = 2} to x2+y2=2.2\gcon{x^2 + y^2 = 2.2} (Δc1=+0.2,Δc2=0\gcon{\Delta c_1 = +0.2}, \hcon{\Delta c_2 = 0})We multiply Δc1=0.2\gcon{\Delta c_1 = 0.2} by the value of λ\gcon{\lambda} at each extreme point to estimate how the maximum and minimum temperatures change when the cylinder widens.
Δfmax≈λΔc1=12(0.2)=+0.1  ⟹  fmax≈5+0.1=5.1Δfmin≈λΔc1=−12(0.2)=−0.1  ⟹  fmin≈1−0.1=0.9\displaystyle \begin{aligned} \fn{\Delta f_{\text{max}}} &\approx \gcon{\lambda \Delta c_1} = \gcon{\tfrac{1}{2}(0.2)} = \gcon{+0.1} \\ &\implies \fn{f_{\text{max}}} \approx 5 + \gcon{0.1} = 5.1 \\ \fn{\Delta f_{\text{min}}} &\approx \gcon{\lambda \Delta c_1} = \gcon{-\tfrac{1}{2}(0.2)} = \gcon{-0.1} \\ &\implies \fn{f_{\text{min}}} \approx 1 - \gcon{0.1} = 0.9 \end{aligned}
Shift the plane from y+z=1\hcon{y + z = 1} to y+z=1.1\hcon{y + z = 1.1} (Δc1=0,Δc2=+0.1\gcon{\Delta c_1 = 0}, \hcon{\Delta c_2 = +0.1})Since μ=3\hcon{\mu = 3} at both extreme points, sliding the plane upward by Δc2=0.1\hcon{\Delta c_2 = 0.1} raises both the maximum and minimum temperatures by the same amount.
Δfmax≈μΔc2=3(0.1)=+0.3  ⟹  fmax≈5+0.3=5.3Δfmin≈μΔc2=3(0.1)=+0.3  ⟹  fmin≈1+0.3=1.3\displaystyle \begin{aligned} \fn{\Delta f_{\text{max}}} &\approx \hcon{\mu \Delta c_2} = \hcon{3(0.1)} = \hcon{+0.3} \\ &\implies \fn{f_{\text{max}}} \approx 5 + \hcon{0.3} = 5.3 \\ \fn{\Delta f_{\text{min}}} &\approx \hcon{\mu \Delta c_2} = \hcon{3(0.1)} = \hcon{+0.3} \\ &\implies \fn{f_{\text{min}}} \approx 1 + \hcon{0.3} = 1.3 \end{aligned}
Change both constraints at once to x2+y2=2.2\gcon{x^2 + y^2 = 2.2} and y+z=1.1\hcon{y + z = 1.1} (Δc1=+0.2,Δc2=+0.1\gcon{\Delta c_1 = +0.2}, \hcon{\Delta c_2 = +0.1})When both constants shift together, we add the change from widening the cylinder and the change from shifting the plane.
Δfmax≈λΔc1+μΔc2=12(0.2)+3(0.1)=0.1+0.3=+0.4fmax≈5+0.4=5.4\displaystyle \begin{aligned} \fn{\Delta f_{\text{max}}} &\approx \gcon{\lambda \Delta c_1} + \hcon{\mu \Delta c_2} \\ &= \gcon{\tfrac{1}{2}(0.2)} + \hcon{3(0.1)} \\ &= \gcon{0.1} + \hcon{0.3} = +0.4 \\ \fn{f_{\text{max}}} &\approx 5 + 0.4 = 5.4 \end{aligned}

So widening the cylinder to 2.2\gcon{2.2} and raising the plane to 1.1\hcon{1.1} increases the maximum temperature to approximately 5.45.4. Notice that the maximum and minimum can have different multipliers (λ=12\gcon{\lambda = \frac{1}{2}} at the maximum, λ=−12\gcon{\lambda = -\frac{1}{2}} at the minimum), so always pair each extreme value with the multipliers found at that specific point.

Summary

When you optimize f(x,y,z)\fn{f(x, y, z)} on a single surface g(x,y,z)=c\gcon{g(x, y, z) = c}, there is only one forbidden direction, so ∇f=λ∇g\gradf{\nabla f} = \gcon{\lambda \nabla g} is all you need. When you have to stay on two surfaces g(x,y,z)=c1\gcon{g(x, y, z) = c_1} and h(x,y,z)=c2\hcon{h(x, y, z) = c_2} at the same time, you are moving along their intersection curve, and an extreme point occurs where ∇f\gradf{\nabla f} is built purely out of the two forbidden directions:

∇f\displaystyle \gradf{\nabla f} =λ∇g+μ∇h\displaystyle = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h}

For instance, on x2+y2=2\gcon{x^2 + y^2 = 2} and y+z=1\hcon{y + z = 1} with f(x,y,z)=x+2y+3z\fn{f(x, y, z) = x + 2y + 3z}, write (1,2,3)=λ(2x,2y,0)+μ(0,1,1)\gradf{(1, 2, 3)} = \gcon{\lambda(2x, 2y, 0)} + \hcon{\mu(0, 1, 1)}, use λ\gcon{\lambda} and μ\hcon{\mu} to connect the component equations and relate the coordinates (2λx=1\gcon{2\lambda x} = 1 and 2λy=−1\gcon{2\lambda y} = -1 give y=−xy = -x), and substitute that relationship into the two constraints.

Once you have solved the problem, do not re-solve the system from scratch if the constraint constants c1\gcon{c_1} and c2\hcon{c_2} shift by small amounts Δc1\gcon{\Delta c_1} and Δc2\hcon{\Delta c_2}. The multipliers at an extreme point are the rates of change λ=∂fbest∂c1\gcon{\lambda} = \frac{\partial \fn{f_{\text{best}}}}{\gcon{\partial c_1}} and μ=∂fbest∂c2\hcon{\mu} = \frac{\partial \fn{f_{\text{best}}}}{\hcon{\partial c_2}}, so you can estimate the change in the maximum or minimum directly:

Δfbest≈λΔc1+μΔc2\displaystyle \fn{\Delta f_{\text{best}}} \approx \gcon{\lambda \Delta c_1} + \hcon{\mu \Delta c_2}

For example, at fmax=5\fn{f_{\text{max}} = 5} where λ=12\gcon{\lambda = \frac{1}{2}} and μ=3\hcon{\mu = 3}, shifting c1=2\gcon{c_1 = 2} to 2.2\gcon{2.2} (Δc1=+0.2)(\gcon{\Delta c_1 = +0.2}) and c2=1\hcon{c_2 = 1} to 1.1\hcon{1.1} (Δc2=+0.1)(\hcon{\Delta c_2 = +0.1}) changes the maximum by Δfmax≈12(0.2)+3(0.1)=+0.4\fn{\Delta f_{\text{max}}} \approx \gcon{\frac{1}{2}(0.2)} + \hcon{3(0.1)} = +0.4, giving fmax≈5.4\fn{f_{\text{max}}} \approx 5.4.

5

Practice

1

Find the maximum and minimum values of f(x,y,z)=x+2y+5z\fn{f(x, y, z) = x + 2y + 5z} on the intersection of the cylinder g(x,y,z)=x2+z2=8\gcon{g(x, y, z) = x^2 + z^2 = 8} and the plane h(x,y,z)=x+y+2z=6\hcon{h(x, y, z) = x + y + 2z = 6}, and give the points and multipliers λ\gcon{\lambda} and μ\hcon{\mu} where they occur.

Which coordinate is missing from the cylinder x2+z2=8\gcon{x^2 + z^2 = 8}? Start with that component of ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} to get μ\hcon{\mu} immediately.

Setting ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} gives (1,2,5)=λ(2x,0,2z)+μ(1,1,2)\gradf{(1, 2, 5)} = \gcon{\lambda(2x, 0, 2z)} + \hcon{\mu(1, 1, 2)}:
x-component:1=2λx+μy-component:2=μz-component:5=2λz+2μ\displaystyle \begin{aligned} x\text{-component:} \quad \gradf{1} &= \gcon{2\lambda x} + \hcon{\mu} \\ y\text{-component:} \quad \gradf{2} &= \hcon{\mu} \\ z\text{-component:} \quad \gradf{5} &= \gcon{2\lambda z} + \hcon{2\mu} \end{aligned}
Substituting μ=2\hcon{\mu = 2} into the xx- and zz-components gives 2λx=−1\gcon{2\lambda x} = -1 and 2λz=1\gcon{2\lambda z} = 1, so z=−xz = -x. (Watch the minus sign here: dropping the negative sign and writing z=xz = x leads to the points (2,0,2)(2, 0, 2) and (−2,12,−2)(-2, 12, -2), which both give the wrong value f=12f = 12; also remember to multiply μ=2\hcon{\mu = 2} by 22 in the zz-component 5=2λz+2μ\gradf{5} = \gcon{2\lambda z} + \hcon{2\mu}.)
Plugging z=−xz = -x into x2+z2=8\gcon{x^2 + z^2 = 8} gives 2x2=82x^2 = 8, so x=−2x = -2 or x=2x = 2:
At x=−2:z=2,−2+y+2(2)=6  ⟹  y=4  ⟹  (−2,4,2)At x=2:z=−2,2+y+2(−2)=6  ⟹  y=8  ⟹  (2,8,−2)\displaystyle \begin{aligned} \text{At } x = -2: \quad z &= 2, \quad -2 + y + 2(2) = 6 \implies y = 4 \implies (-2, 4, 2) \\ \text{At } x = 2: \quad z &= -2, \quad 2 + y + 2(-2) = 6 \implies y = 8 \implies (2, 8, -2) \end{aligned}
Evaluating f(x,y,z)=x+2y+5z\fn{f(x, y, z) = x + 2y + 5z} and using 2λx=−1\gcon{2\lambda x} = -1:
Maximum value 1616 at (−2,4,2)(-2, 4, 2) with λ=14\gcon{\lambda = \frac{1}{4}} and μ=2\hcon{\mu = 2}; minimum value 88 at (2,8,−2)(2, 8, -2) with λ=−14\gcon{\lambda = -\frac{1}{4}} and μ=2\hcon{\mu = 2}.
2

Find the minimum value of f(x,y,z)=x2+y2+z2\fn{f(x, y, z) = x^2 + y^2 + z^2} subject to the two plane constraints g(x,y,z)=x+y+z=6\gcon{g(x, y, z) = x + y + z = 6} and h(x,y,z)=x−y=2\hcon{h(x, y, z) = x - y = 2}, and state the point where it occurs.

Look at the zz-component of ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} to write λ\gcon{\lambda} in terms of zz, then add the xx- and yy-components to eliminate μ\hcon{\mu}.

Setting ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} gives (2x,2y,2z)=λ(1,1,1)+μ(1,−1,0)\gradf{(2x, 2y, 2z)} = \gcon{\lambda(1, 1, 1)} + \hcon{\mu(1, -1, 0)}:
2x=λ+μ2y=λ−μ2z=λ\displaystyle \begin{aligned} \gradf{2x} &= \gcon{\lambda} + \hcon{\mu} \\ \gradf{2y} &= \gcon{\lambda} - \hcon{\mu} \\ \gradf{2z} &= \gcon{\lambda} \end{aligned}
Adding the xx- and yy-equations eliminates μ\hcon{\mu} and gives 2x+2y=2λ2x + 2y = \gcon{2\lambda}, so x+y=λ=2zx + y = \gcon{\lambda} = 2z. (Be careful to add both λ\gcon{\lambda}'s on the right: writing 2x+2y=λ2x + 2y = \lambda instead of 2λ\gcon{2\lambda} gives x+y=zx + y = z, which leads to (52,12,3)\left(\frac{5}{2}, \frac{1}{2}, 3\right) and the wrong value 15.515.5.)
Substituting x+y=2zx + y = 2z into x+y+z=6\gcon{x + y + z = 6} gives 3z=6  ⟹  z=23z = 6 \implies z = 2. Then x+y=4x + y = 4 and x−y=2\hcon{x - y = 2} give x=3x = 3 and y=1y = 1, where f(3,1,2)=32+12+22=14\fn{f(3, 1, 2)} = 3^2 + 1^2 + 2^2 = \fn{14}.
Minimum value 1414 at (3,1,2)(3, 1, 2).
3

Optimizing a function f(x,y,z)\fn{f(x, y, z)} subject to g(x,y,z)=10\gcon{g(x, y, z) = 10} and h(x,y,z)=5\hcon{h(x, y, z) = 5} gives a maximum value fmax=20\fn{f_{\text{max}} = 20} with multipliers λ=−2\gcon{\lambda = -2} and μ=4\hcon{\mu = 4}, and a minimum value fmin=6\fn{f_{\text{min}} = 6} with multipliers λ=3\gcon{\lambda = 3} and μ=−1\hcon{\mu = -1}. Estimate the new maximum and minimum values if the constraints are changed to g(x,y,z)=10.3\gcon{g(x, y, z) = 10.3} and h(x,y,z)=4.8\hcon{h(x, y, z) = 4.8}.

Find the signed changes Δc1\gcon{\Delta c_1} and Δc2\hcon{\Delta c_2} first, then pair fmax\fn{f_{\text{max}}} and fmin\fn{f_{\text{min}}} with their own multipliers in Δfbest≈λΔc1+μΔc2\fn{\Delta f_{\text{best}}} \approx \gcon{\lambda \Delta c_1} + \hcon{\mu \Delta c_2}.

The constraint constants change by Δc1=10.3−10=+0.3\gcon{\Delta c_1 = 10.3 - 10 = +0.3} and Δc2=4.8−5=−0.2\hcon{\Delta c_2 = 4.8 - 5 = -0.2}. (Watch the negative sign on Δc2\hcon{\Delta c_2}: using +0.2+0.2 instead of −0.2\hcon{-0.2} when h\hcon{h} drops from 5\hcon{5} to 4.8\hcon{4.8} gives the wrong estimates fmax≈20.2f_{\text{max}} \approx 20.2 and fmin≈6.7f_{\text{min}} \approx 6.7.)
Δfmax≈(−2)(0.3)+4(−0.2)=−0.6−0.8=−1.4  ⟹  fmax≈20−1.4=18.6Δfmin≈3(0.3)+(−1)(−0.2)=0.9+0.2=+1.1  ⟹  fmin≈6+1.1=7.1\displaystyle \begin{aligned} \fn{\Delta f_{\text{max}}} &\approx \gcon{(-2)(0.3)} + \hcon{4(-0.2)} = \gcon{-0.6} - \hcon{0.8} = -1.4 \implies \fn{f_{\text{max}}} \approx 20 - 1.4 = 18.6 \\ \fn{\Delta f_{\text{min}}} &\approx \gcon{3(0.3)} + \hcon{(-1)(-0.2)} = \gcon{0.9} + \hcon{0.2} = +1.1 \implies \fn{f_{\text{min}}} \approx 6 + 1.1 = 7.1 \end{aligned}
fmax≈18.6\fn{f_{\text{max}}} \approx 18.6 and fmin≈7.1\fn{f_{\text{min}}} \approx 7.1.
4

Find the maximum and minimum values of f(x,y,z)=2x+y+2z\fn{f(x, y, z) = 2x + y + 2z} subject to g(x,y,z)=x2+y2=4\gcon{g(x, y, z) = x^2 + y^2 = 4} and h(x,y,z)=x+z=3\hcon{h(x, y, z) = x + z = 3}, and then use the multipliers to estimate the new maximum value if the constraints are changed to x2+y2=3.6\gcon{x^2 + y^2 = 3.6} and x+z=3.2\hcon{x + z = 3.2}.

Use the zz-component of ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} to find μ\hcon{\mu}, then look at the xx- and yy-components together. Since 2λy=1\gcon{2\lambda y} = 1, can λ\gcon{\lambda} be zero in 2λx=0\gcon{2\lambda x} = 0?

Setting ∇f=λ∇g+μ∇h\gradf{\nabla f} = \gcon{\lambda \nabla g} + \hcon{\mu \nabla h} gives (2,1,2)=λ(2x,2y,0)+μ(1,0,1)\gradf{(2, 1, 2)} = \gcon{\lambda(2x, 2y, 0)} + \hcon{\mu(1, 0, 1)}:
x-component:2=2λx+μy-component:1=2λyz-component:2=μ\displaystyle \begin{aligned} x\text{-component:} \quad \gradf{2} &= \gcon{2\lambda x} + \hcon{\mu} \\ y\text{-component:} \quad \gradf{1} &= \gcon{2\lambda y} \\ z\text{-component:} \quad \gradf{2} &= \hcon{\mu} \end{aligned}
Substituting μ=2\hcon{\mu = 2} into the xx-component gives 2λx=0\gcon{2\lambda x} = 0. Because 2λy=1\gcon{2\lambda y} = 1 means λ≠0\gcon{\lambda \neq 0}, we must have x=0x = 0. Then x2+y2=4\gcon{x^2 + y^2 = 4} gives y=2y = 2 or y=−2y = -2, and x+z=3\hcon{x + z = 3} gives z=3z = 3:
At (0,2,3)(0, 2, 3): f(0,2,3)=8\fn{f(0, 2, 3) = 8} (Maximum), with 2λ(2)=1  ⟹  λ=14\gcon{2\lambda(2)} = 1 \implies \gcon{\lambda = \frac{1}{4}} and μ=2\hcon{\mu = 2}.
At (0,−2,3)(0, -2, 3): f(0,−2,3)=4\fn{f(0, -2, 3) = 4} (Minimum), with 2λ(−2)=1  ⟹  λ=−14\gcon{2\lambda(-2)} = 1 \implies \gcon{\lambda = -\frac{1}{4}} and μ=2\hcon{\mu = 2}.
When the constraints shift to x2+y2=3.6\gcon{x^2 + y^2 = 3.6} and x+z=3.2\hcon{x + z = 3.2}, the changes in the constants are Δc1=3.6−4=−0.4\gcon{\Delta c_1 = 3.6 - 4 = -0.4} and Δc2=3.2−3=+0.2\hcon{\Delta c_2 = 3.2 - 3 = +0.2}. (Be sure to use Δc1=−0.4\gcon{\Delta c_1 = -0.4} rather than +0.4+0.4, which would give the wrong estimate 8.58.5.)
Δfmax≈14(−0.4)+2(0.2)\displaystyle \fn{\Delta f_{\text{max}}} \approx \gcon{\tfrac{1}{4}(-0.4)} + \hcon{2(0.2)} =−0.1+0.4\displaystyle = \gcon{-0.1} + \hcon{0.4} =+0.3  ⟹  fmax≈8+0.3\displaystyle = +0.3 \implies \fn{f_{\text{max}}} \approx 8 + 0.3 =8.3\displaystyle = 8.3
Maximum value 88 at (0,2,3)(0, 2, 3) with λ=14,μ=2\gcon{\lambda = \frac{1}{4}}, \hcon{\mu = 2}, and minimum value 44 at (0,−2,3)(0, -2, 3) with λ=−14,μ=2\gcon{\lambda = -\frac{1}{4}}, \hcon{\mu = 2}; for the shifted constraints, fmax≈8.3\fn{f_{\text{max}}} \approx 8.3.