[Math] Lagrange multiplier problem – Why doesn’t the method work

lagrange multiplieroptimization

Maximize the distance to the origin of a function with four variables given the constraints:

\begin{align}
xyza &= 1 \\
x + y + z + a &= 4
\end{align}

Here's my solution: We maximize $f(x,y,z,a) = x^2+y^2+z^2+a^2$ subject to the given constraint equations. The Lagrange multiplier method yields six equations with six variables.

\begin{align}
2x &= \lambda_1yza+\lambda_2\\
2y &= \lambda_1xza+\lambda_2\\
2z &= \lambda_1xya+\lambda_2\\
2a &= \lambda_1xyz+\lambda_2\\
xyza &= 1\\
x + y + z + a &= 4
\end{align}

Mathematica is unable to solve this system. Is there something wrong in the question (I made it up) itself? Thanks!

Best Answer

The question is ill posed.

One of the first things you should do before applying Lagrange is to verify that there is indeed a solution. There is no solution in this case.

Fix $z=-1$, then look for solutions of $x+y-1-{1 \over xy} = 4$. Multiplying across by $x$ gives $x^2+x (y-5) -{1 \over y} = 0$, which has a solution $x= {1 \over 2} (5-y -\sqrt{(y-5)^2+{4 \over y}})$.

Letting $y \to \infty$ there are solutions, hence the distance to the origin is unbounded.

Related Question