Find the minimum and maximum values of the function $f(x, y)=x^2y+x+y$ subject to the constraint $=4$.

638 Views Asked by At

I am trying to solve this problem using Lagrange multipliers. So far I have found potential values for $x$ and $y$ ($\pm 2\sqrt{5}$ for both $x$ and $y$) by solving the Lagrange equation and then plugging that value into the constraint equation and then plugging the resulting $x$ and $y$ values into the original function. However, my answer does not match the solution. Could someone please show me how to solve this?

1

There are 1 best solutions below

2
On

There is no need to use Lagrange multipliers, as you can use the constraint to find $x$ or $y$ in terms of the other, so you can reduce it to a single variable function. If $xy=4$, then $y=4/x$ and $f(x,y) = x^2y+x+y$ becomes $f(x,4/x)=4x+x+4/x$. Differentiate this wrt $x$ and you get $5-4x^{-2}$. Set this equal to $0$ as usual and solve for $x \;$:$$5-4x^{-2} = 0$$ $$4x^{-2}=5$$ $$4=5x^2$$ $$4/5 = x^2$$ $$x=±2/\sqrt{5}$$

If $x=-2/\sqrt{5}$, then $y=\frac{4\sqrt{5}}{-2} = -2\sqrt{5}$, so $(-2/\sqrt{5},-2\sqrt{5})$ is our first solution; likewise, if $x=2/\sqrt{5}$ then $y=2\sqrt{5}$, giving $(2/\sqrt{5},2\sqrt{5})$ as the second solution.