Find minimum and maximum of $f(x,y) = x^2+y^2 $ where $D=\{(x,y)| x\geq0 ,y\geq0 ,x+y\leq1\}$

lagrange multipliermaxima-minimamultivariable-calculus

find minimum and maximum of $f(x,y) = x^2+y^2 $ where $D=\{(x,y)| x\geq0 ,y\geq0 ,x+y\leq1\}$

So here's my take at it :

first finding points inside the domain:

$\frac{\partial f}{\partial x}= 2x,\; \frac{\partial f}{\partial y}= 2y.$

therefore we get $(0,0)$ is a crucial point.

since the hessian is $4$ at $(0,0)$ we get that $(0,0)$ is a minimum.

on the boundary:

using lagrange multipliers we get :
$g(x,y) = x+y-1 \text{ so with } \nabla g= (1,1) \text{ we get: }\\ \begin{align*}
2x &= \,\lambda \\
2y &= \,\lambda \\
x+y &= \,1
\end{align*}$

$\text{solving this we get : } \\ x=y=\frac{1}{2}$

and that point should be a minimum since $f(x,y) = \frac{1}{2}$

other critical points :

$(0,1) , (1,0)$

plugging them in we get : $f(1,0)=f(0,1) = 1 , \text{so by the second Weierstrass theorem f gets minimum and maximum values therefore } (0,1)$ and $(1,0)$ are max and $(\frac{1}{2},\frac{1}{2})$ is a minimum

is this actually correct? I mean f gets a minimum at $(0,0)$, how do I know one of the other points on the constraint are not saddle points?

Best Answer

You don't need all that. Since $f(0,0)=0$ and since $f(x,y)>0$ when $(x,y)\neq(0,0)$, it is clear that $f$ has a minimum at $(0,0)$.

On the other hand, if $(x,y)\in F$, then$$f(x,y)=x^2+y^2=(x+y)^2-2xy\leqslant(x+y)^2\leqslant1.$$So, there is no way that $(1,0)$ and $(0,1)$ are saddle points. The function $f$ attains its maximum at both of those points.