# Lagrange Multiplier issues

• June 26th 2012, 06:59 PM
robman
Lagrange Multiplier issues
hey everyone, i'm currently stumped on a problem that seems impossible to solve.
the formula is ((x^2)/9)+((y^2)/4)=1, and it asks to find the maximum area of a rectangle within that limit (equation)

so far ive gotten:
y=(lambda)((2x)/9)
x=(lambda)(y/2)
((x^2)/9)+((y^2)/4)-1=0 as my equations.

i am having major problems finding the individual values of x,y and lambda. every other problem ive seen on the web has only 2 variables, which is extremely simple.

Can anyone solve this? thanks!
• June 26th 2012, 07:47 PM
Soroban
Re: Lagrange Multiplier issues
Hello, robman!

Quote:

Find the maximum area of the rectangle inscribed in the ellipse $\frac{x^2}{9} + \frac{y^2}{4} \:=\:1$

Code:

                |               *  *  *           *      |      *         * - - -  +  - - - *       *|        |        |*         |        |      y|       * |        |        | *       * | - - -  +  - - - | *       * |        |    x  | *         |        |        |       *|        |        |*         * - - -  +  - - - *           *      |      *               *  *  *
$\text{The area of the rectangle is: }\:A \:=\:(2x)(2y) \:=\:4xy$

$\text{The constraint is: }\:\frac{x^2}{9}+\frac{y^2}{4} \:=\:1$

$\text{The function is: }\:f(x,y,\lambda) \;=\;4xy + \lambda\left(\tfrac{x^2}{9} + \tfrac{y^2}{4} - 1\right)$

Can you finish it now?

• June 26th 2012, 07:57 PM
robman
Re: Lagrange Multiplier issues
still stuck...i don't think its possible to solve for 3 variables with only 3 equations
now i have 4y=(lambda)(2x)/9
4x=(lambda) (y/2)
however i try to twist around the equations still end up with 2 unknown variables...
how did you know to use 4xy as the area? isn't the area just xy?
• June 27th 2012, 01:46 AM
a tutor
Re: Lagrange Multiplier issues
Hi robman.

You have $4y=\frac{2\lambda x }{9}$ and $4x=\frac{\lambda y }{2}$

You can use these to find x in terms of y and then use the equation of the ellipse.
• June 27th 2012, 09:02 AM
robman
Re: Lagrange Multiplier issues
i got up to there easily but im having problems. i can only get 1 variable to cancel out, no matter what i do i still get 2 unknowns

thanks!
• June 27th 2012, 10:21 AM
Soroban
Re: Lagrange Multiplier issues
Hello, robman!

$\text{The function is: }\:f(x,y,\lambda) \;=\;4xy + \lambda\left(\tfrac{x^2}{9} + \tfrac{y^2}{4} - 1\right)$

$\begin{Bmatrix}f_x &=& 4y + \frac{2\lambda}{9}x &=& 0 & [1] \\f_y &=& 4x + \frac{\lambda}{2}y &=& 0 & [2] \\ f_{\lambda} &=& \frac{x^2}{9} + \frac{y^2}{4} - 1 &=& 0 & [3] \end{Bmatrix}$

From [1], we have: . $\lambda \,=\,-\frac{18y}{x}\;\;[4]$

From [2], we have: . $\lambda \,=\,-\frac{8x}{y}\;\;[5]$

Equate [4] and [5]: . $-\frac{18y}{x} \:=\:-\frac{8x}{y} \quad\Rightarrow\quad 18y^2 \:=\:8x^2$

. . . . . . . . . . . . . . . . . . $y^2 \:=\:\frac{4x^2}{9} \quad\Rightarrow\quad y \:=\:\pm\frac{2}{3}x\;\;[6]$

Substitute into [3]: . $\frac{x^2}{9} + \frac{(\frac{2}{3}x)^2}{4} \:=\:1 \quad\Rightarrow\quad \frac{2}{9}x^2 \:=\:1$

. . . . . . . . . . . . . . . . . . . . . $x^2 \:=\:\frac{9}{2} \quad\Rightarrow\quad x \:=\:\pm\frac{3}{\sqrt{2}}$

Substitute into [6]: . $y \;=\;\pm\frac{2}{3}\left(\pm\frac{3}{\sqrt{2}} \right) \quad\Rightarrow\quad y \;=\;\pm\sqrt{2}$

The area of the rectangle is: . $A \;=\;4xy \;=\;4\left(\frac{3}{\sqrt{2}}\right)\left(\sqrt{2 }\right) \;=\;12$
• June 27th 2012, 10:36 AM
HallsofIvy
Re: Lagrange Multiplier issues
I find it often simplest to start by eliminating the $\lambda$ by dividing one equation by another.

Here, you have $4y= \frac{2\lambda x}{9}$ and $4x= \frac{\lambda y}{2}$.

Dividing the first by the second gives $\frac{y}{x}= \frac{4}{9}\frac{x}{y}$ which is the same as $y^2= \frac{4}{9}x^2$. That gives $y= \pm\frac{2}{3}x$.

And, of course, we must have $\frac{x^2}{9}+ \frac{y^2}{4}= \frac{x^2}{9}+ \frac{x^2}{9}= \frac{2}{9}x^2= 1$ so that $x= \pm\frac{3}{\sqrt{2}}$. Since the " $\pm$" in $y= \pm\frac{2}{3}x$ goes with both positive and values of x, there are four solutions.
• June 27th 2012, 10:42 AM
robman
Re: Lagrange Multiplier issues
wow thanks...what program do you use to solve the equations? I sure could use something like that on my tests :D also, why did you use 4xy if the area of a rectangle is xy?
• June 27th 2012, 01:35 PM
a tutor
Re: Lagrange Multiplier issues
I don't think anyone is using any software to solve the equations. Perhaps you're referring to the LaTeX which is used to produce easy to read mathematical notation. You can read about it here:
http://mathhelpforum.com/latex-help/...-tutorial.html

The area of the rectangle is $2x\times 2y = 4xy$.