What happens if you rescale the constraint in constraint optimization?

382 Views Asked by At

Say you have a function and its constraint

$$ maximize \ \ f(x,y)=xy$$ $$ subject \ to: g(x,y) = 2x +3y =6 $$

if I "rescale" the constraint to be $$ 2x+3y=1$$

if we do the calculations the x and y obtained will just be scaled by 1/6.

Is there a theorem for this? Or does this hold in general? Can we explain this intuitively? E.g. we just have to scale the original solution of x and y by 1/6 and we can see that the constraint is satisfied and because the original solution is a maximum the scaled solution is also a maximum?

This does not seem quite right to me....does anyone have a better explanation?

Edit:

If we do the maths: $$ \nabla f(x,y)=\begin{pmatrix}y \\x \end{pmatrix} $$ $$\lambda \nabla g(x,y)=\lambda\begin{pmatrix}2 \\3 \end{pmatrix} $$

If we substitute y=2λ and x = 3λ into 2x+3y = 6 we get 12λ=6 so λ = 0.5 and this is the answer under the first constraint

Clearly, if the 6 is changed to a 1, then the λ obtained is just divided by 6, and your x and y are also divided by 6.

3

There are 3 best solutions below

2
On

You’re asked to find the maximum of $xy$ on the line $2x+3y=6$. If you change this to $2x+3y=1$, this is a different line, so, unless you make some other adjustments, you’ll get the wrong answer.

You could do a change of variables: $u = \tfrac16x, v = \tfrac16y$. Then the line $2x+3y=6$ becomes the line $2u +3v=1$, so you get to use your favorite line as the constraint. But you have to express the objective function in $(u,v)$ coordinates, too; it becomes $36uv$. You can solve the problem in $(u,v)$ coordinates and then convert back to $(x,y)$ coordinates when you’re done.

But I don’t see how this change of variables helps to make the problem easier.

Intuitively, this change of variables just changes the units you’re using to measure distances in the “horizontal” plane, or it changes the scale, if you like. Basically the same idea as choosing to measure lengths in millimeters rather than inches. But you have to make the change consistently in all parts of the problem; you can’t just do it in the constraint equation(s).

Edit
Your technique might work if the constraints are linear and the objective function is linear in each variable. Here’s an example where it doesn’t work: $\min(x^2 + y^2)$ subject to $x+y = 2$. So, we’re looking for the square of the minimum distance between the origin and the line $x+y=2$. Clearly this is $2$. If we use the line $x+y=4$, instead, then the min squared distance is $8$, not $4$.

2
On

It does not sound right to me. Did you try it? What happened?

Graphically, you could transform the first line to the second by dilating it by factor 1/6 with respect to the origin.

$2x + 3y = 6$

$→ 2(6x) + 3(6y) = 6$

$2x + 3y = 1$

The first solution would be $xy = k$, for some $k$. That equation can be plotted as a hyperbola tangent to the first line. For the solution to the second condition, the hyperbola could be dilated just as the line was.

$xy = k$

$→ (6x)(6y) = k$

$xy = k/36$

So no, your conjecture was maybe too simplistic. It is not 1/6 the first solution. It would not have taken long to check it though.

Follow-up: Now I see what you were doing. The $λ$ you derived is not the solution. That is, it is not the maximum of $xy$. It will lead you to that maximum though.

$y = 2λ = 2(1/2) = 1$

$x = 3λ = 3(1/2) = 3/2$

$xy = (3/2)(1) = 3/2$

This 3/2 is the maximum $xy$ with regard to the first line. With the second line you should get 1/24.

0
On

Your original problem has as lagrangian

$$ L(x,y,\lambda) = x y +\lambda(2x+3y-k) $$

now this lagrangian can be posed equivalently as

$$ L\left(\frac xk,\frac yk,\lambda\right) = k^2\frac xk\frac yk+\lambda\left(2\frac xk + 3 \frac yk -1\right) $$

calling now $X = \frac xk,\ Y = \frac yk$ we follow with the equivalent lagrangian

$$ L\left(X,Y,\lambda\right) = k^2XY+\lambda\left(2X + 3 Y -1\right) $$