Find Extrema Using Lagrange Multipliers

gGo

New member
Joined
Mar 1, 2021
Messages
17
Find the extreme values of [MATH]f(x,y)=xy[/MATH] with the constraint [MATH]g(x,y)=9x^2+4y^2-36=0[/MATH].

Solution: Using Lagrange multipliers, we first find the first partial derivatives
[MATH]f_x = y, g_x = 18x \\ f_y = x, g_y = 8y[/MATH]
Then solve the system (equations 1, 2, and 3, respectively)
[MATH]y = \lambda \cdot 18x \\ x = \lambda \cdot 8y \\ 9x^2+4y^2-36=0[/MATH]
Wolfram Alpha says the solution is the points
[MATH]\left(\frac{6}{\sqrt{13}}, \frac{6}{\sqrt{13}}\right), \left(-\frac{6}{\sqrt{13}}, -\frac{6}{\sqrt{13}}\right).[/MATH]Both points are for when [MATH]\lambda[/MATH] is 1 and 3.

The solution to the problem says the points are Maximum at points
[MATH]\left(\sqrt 2, \frac{3}{\sqrt 2}\right), \left(-\sqrt 2, -\frac{3}{\sqrt 2}\right)[/MATH]and Minimum at points
[MATH]\left(\sqrt 2, -\frac{3}{\sqrt 2}\right), \left(-\sqrt 2, \frac{3}{\sqrt 2}\right).[/MATH]
I can't get either of those answers. And how can [MATH]\lambda[/MATH] equal either 1 or -1? The best I can do is subtract equation 2 from eqn 1 and get to
[MATH](y-x) + 2\lambda(4y-9x) = 0.[/MATH] But I got nothing from there.
 
Hey there. Perhaps an expert could step in here, but as a student, what I personally did was:
1. solve equation 1 and equation 2 for lambda: (meaning they now equal each other). the algebra varies by problem, but I try this first pretty often.

λ= y/18x (equation 1)
λ = x/8y (equation 2)

2. now that eqn 1 = eqn 2, we have

y/18x = x/8y

you can then cross multiply to get
8y^2 = 18x^2.

dividing each side by 2 yields

4y^2 = 9x^2. you could plug 4y^2 = 9x^2 into your original constraint g to solve for x.

once you have x solved from the constraint, you could plug it into 4y^2 = 9x^2 to get y.

To do these problems, I personally don't solve for what the actual constant λ is equal to (since you asked about how λ = 1 or -1). maybe someone else could chime in on that. also apologies for the ugly notation. i'm not familiar with LaTeX.
 
Find the extreme values of [MATH]f(x,y)=xy[/MATH] with the constraint [MATH]g(x,y)=9x^2+4y^2-36=0[/MATH].

Solution: Using Lagrange multipliers, we first find the first partial derivatives
[MATH]f_x = y, g_x = 18x \\ f_y = x, g_y = 8y[/MATH]
Then solve the system (equations 1, 2, and 3, respectively)
[MATH]y = \lambda \cdot 18x \\ x = \lambda \cdot 8y \\ 9x^2+4y^2-36=0[/MATH]
Wolfram Alpha says the solution is the points
[MATH]\left(\frac{6}{\sqrt{13}}, \frac{6}{\sqrt{13}}\right), \left(-\frac{6}{\sqrt{13}}, -\frac{6}{\sqrt{13}}\right).[/MATH]Both points are for when [MATH]\lambda[/MATH] is 1 and 3.

The solution to the problem says the points are Maximum at points
[MATH]\left(\sqrt 2, \frac{3}{\sqrt 2}\right), \left(-\sqrt 2, -\frac{3}{\sqrt 2}\right)[/MATH]and Minimum at points
[MATH]\left(\sqrt 2, -\frac{3}{\sqrt 2}\right), \left(-\sqrt 2, \frac{3}{\sqrt 2}\right).[/MATH]
I can't get either of those answers. And how can [MATH]\lambda[/MATH] equal either 1 or -1? The best I can do is subtract equation 2 from eqn 1 and get to
[MATH](y-x) + 2\lambda(4y-9x) = 0.[/MATH] But I got nothing from there.
I think it helps to be a bit formal when using a LaGrangian.

[MATH]L(x,\ y, \ \lambda ) = xy - \lambda (36 - 9x^2 - 4y^2).[/MATH]
[MATH]\dfrac{ \delta L }{\delta x} = 0 \implies y - 18x \lambda = 0 \implies y = 18x \lambda.[/MATH]
[MATH]\dfrac{ \delta L }{\delta y} = 0 \implies x - 8y \lambda = 0 \implies x = 8y \lambda.[/MATH]
[MATH]\dfrac{ \delta L }{\delta \lambda} = 0 \implies - (36 - 9x^2 - 4y^2) = 0 \implies 9x^2 + 4y^2 = 36.[/MATH]
[MATH]x = 0 \implies y = 0 \implies 0 = 36, \text { which is false.}[/MATH]
[MATH]\therefore x \ne 0 \implies \lambda = \dfrac{y}{18x} \implies x = 8y * \dfrac{y}{18x} \implies 9x^2 = 4y^2.[/MATH]
[MATH]4y^2 + 4y^2 = 36 \implies y^2 = \dfrac{36}{8} = \dfrac{9}{2} \implies y = \pm \dfrac{3}{\sqrt{2}} \implies [/MATH]
[MATH]9x^2 = 4 * \dfrac{3^2}{2} \implies x^2 = 2 \implies x = \pm \sqrt{2}.[/MATH]
Your book is correct.

Wolfram is wrong.

The general way to solve a system of simultaneous equations is by repeated substitution rather than by elimination. In any case, your attempt at elimination was unsuccessful. (I am not sure that elimination is even possible with equations of this type, and I certainly would not waste time on looking for a method of elimination.)

It is of course possible to solve for lambda. The only field that I know where the value of lambda has a use is in economics. Obviously, your book does not care what the value of lambda is. That is because you can solve the problem a different way that does not need lambda. But in case you ever study economics, we found

[MATH]\lambda = y \div 18x = \pm \dfrac{3}{\sqrt{2}} \div \pm 18 \sqrt{2} = \pm \dfrac{3}{\sqrt{2}} * \dfrac{1}{18 \sqrt{2}} = \pm \dfrac{1}{12}.[/MATH]
Let’s check that.

[MATH]x = \pm 8 * \dfrac{1}{12} * \dfrac{3}{\sqrt{2}} = \pm \dfrac{24}{12 \sqrt{2}} = \pm \dfrac{2}{\sqrt{2}} = \pm \dfrac{2\sqrt{2}}{2} = \pm \sqrt{2}. \ \checkmark[/MATH]
Where did you get plus and minus 1? And where did you get 3?
 
I said that there was a different way to find the extrema of

[MATH]z = xy \text { subject to the constraint that } 9x^2 + 4y^2 - 36 = 0.[/MATH]
Here is how.

[MATH]9x^2 + 4y^2 - 36 = 0 \implies 4y^2 = 36 - 9x^2 \implies y = \pm \sqrt{9 - \dfrac{9x^2}{4}}.[/MATH]
[MATH]z = xy \implies z = \pm \sqrt{9x^2 - \dfrac{9x^4}{4}} \implies 4z^2 = 36x^2 - 9x^4 \implies[/MATH]
[MATH]8z * \dfrac{dz}{dx} = 72x - 36x^3 \implies \dfrac{dz}{dx} = \dfrac{72x - 36x^3}{8z} = \dfrac{36x(2 - x^2)}{8z}.[/MATH]
[MATH]\text {If } 36x(2 - x^2) = 0, \text { then it is possible that } x = 0 \implies[/MATH]
[MATH]z = 0 \implies \dfrac{dz}{dx} = \dfrac{0}{0}.[/MATH]
That is a problem, but it is quite obvious that if x = 0 then z = 0 and that is not an extremum.

[MATH]\therefore \dfrac{dz}{dx} = 0 \implies 2 - x^2 = 0 \implies x = \pm \sqrt{2}.[/MATH]
Now we go back and solve for y.

[MATH]y = \pm \sqrt{9 - \dfrac{9 * 2}{4}} = \pm \sqrt{9 - \dfrac{9}{2}} = \pm \sqrt{\dfrac{2 * 9 - 9}{2}} = \pm \sqrt{\dfrac{9}{2}} = \pm \dfrac{3}{\sqrt{2}}.[/MATH]
Same answer as before.

The problem with this method is when you have multiple constraints the mechanics can get very ugly. LaGrangians are usually simpler to work with.
 
Last edited:
Top