# Thread: Help With Lagrange Multipliers 2 Questions

1. ## Help With Lagrange Multipliers 2 Questions

I need help with these two questions

1.
Use Lagrange multipliers to show that, of all the triangles inscribed in a circle of radius
R, the equilateral triangle has the largest perimeter.

For this I know that the equation for the unit circle is
x^2+y^2 = 1
But i'm not sure what the constraint is.
Is it that for a triangle to be on a circle, each side must be <= to the diameter?

2.
In dimensions 2 and 3, the Lagrange condition can be replaced by a cross product condition. If a is an extremum for f(x) subject to a constraint g(x) = 0, then Gr[f] × Gr[g] = 0.

the x is a cross product sign
Gr is the gradient
fx is derivative of f w.r.t. x

If f and g are functions of 2 variables, Gr[f] × Gr[g] =
det
[e1 e2 e3]
[fx fy 0]
[gx gy 0]
= (fx gy − fy gx) e3.

Use the cross product condition to find the extrema of f(x, y) = x y on the unit circle.

2. ## Re: Help With Lagrange Multipliers 2 Questions

Originally Posted by Sneaky
I need help with these two questions

1.
Use Lagrange multipliers to show that, of all the triangles inscribed in a circle of radius
R, the equilateral triangle has the largest perimeter.

For this I know that the equation for the unit circle is
x^2+y^2 = 1
But i'm not sure what the constraint is.
Is it that for a triangle to be on a circle, each side must be <= to the diameter?
You only need consider triangles inscribed in the unit circle, so:

Take the vertices of the triangle be to be $\displaystyle (0,0)$, $\displaystyle (\cos(\theta_1) , \sin(\theta_1))$ , and $\displaystyle (\cos(\theta_2) , \sin(\theta_2))$ with $\displaystyle \theta_i >0, \theta_i<2 \pi,\ \ i=1,2$ and $\displaystyle \theta_1<\theta_2$

There is a neater way of expressing this but the above will do.

CB

3. ## Re: Help With Lagrange Multipliers 2 Questions

Originally Posted by Sneaky
2.
In dimensions 2 and 3, the Lagrange condition can be replaced by a cross product condition. If a is an extremum for f(x) subject to a constraint g(x) = 0, then Gr[f] × Gr[g] = 0.

the x is a cross product sign
Gr is the gradient
fx is derivative of f w.r.t. x

If f and g are functions of 2 variables, Gr[f] × Gr[g] =
det
[e1 e2 e3]
[fx fy 0]
[gx gy 0]
= (fx gy − fy gx) e3.

Use the cross product condition to find the extrema of f(x, y) = x y on the unit circle.
Okay, ON the unit circle $\displaystyle g(x,y)= x^2+ y^2- 1= 0$ and you are given that f(x,y)= xy.
What does $\displaystyle f_xg_y- f_yg_x= 0$ give you?

4. ## Re: Help With Lagrange Multipliers 2 Questions

Originally Posted by HallsofIvy
Okay, ON the unit circle $\displaystyle g(x,y)= x^2+ y^2- 1= 0$ and you are given that f(x,y)= xy.
What does $\displaystyle f_xg_y- f_yg_x= 0$ give you?
I got

$\displaystyle (2y^2 - 2x^2)e_3 = 0$

so
$\displaystyle f_xg_y- f_yg_x= 0$
is
$\displaystyle 2y^2 - 2x^2= 0$

does that mean the lagrange equation is

$\displaystyle h(x,y,\lambda) = xy - \lambda(2y^2 - 2x^2)$
?

5. ## Re: Help With Lagrange Multipliers 2 Questions

Originally Posted by CaptainBlack
You only need consider triangles inscribed in the unit circle, so:

Take the vertices of the triangle be to be $\displaystyle (0,0)$, $\displaystyle (\cos(\theta_1) , \sin(\theta_1))$ , and $\displaystyle (\cos(\theta_2) , \sin(\theta_2))$ with $\displaystyle \theta_i >0, \theta_i<2 \pi,\ \ i=1,2$ and $\displaystyle \theta_1<\theta_2$

There is a neater way of expressing this but the above will do.

CB

So this means that I am maximizing the distance between the vertexes so that the distance is <= diameter of the circle?

Circle with radius R

Triangle with sides A, B, C

$\displaystyle Point_1: (0,0)$
$\displaystyle Point_2: (cos(\theta_1),sin(\theta_1))$
$\displaystyle Point_3: (cos(\theta_2),sin(\theta_2))$

$\displaystyle A = \sqrt{ (0-cos(\theta_1))^2 + (0-sin(\theta_1))^2 }$
$\displaystyle B = \sqrt{(cos(\theta_1)-(cos(\theta_2))^2 + (sin(\theta_1)-sin(\theta_2))^2}$
$\displaystyle C = \sqrt{(cos(\theta_2)-0)^2 + (sin(\theta_2)-0)^2}$

Constraints are
$\displaystyle A <= 2R$
$\displaystyle B <= 2R$
$\displaystyle C <= 2R$

So then does the Lagrange equation become this?

$\displaystyle h(\theta_1,\theta_2,\lambda_1,\lambda_2,\lambda_3) = A+B+C - \lambda_1(A-2R) - \lambda_2(B-2R) - \lambda_3(C-2R)$