Find the least value of the expression $x^2+2xy+2y^2+4y+7$ Find the least value of the expression
$x^2+2xy+2y^2+4y+7$
I am not able to solve this equation though i am able to differentiate it. 
 A: I like dxiv's factorization approach.
For a more routine method, solve
$$\frac{\partial f}{\partial x}=2x+2y=0$$
$$\frac{\partial f}{\partial y}=2x+4y+4=0$$
where the equations by equating the derivative to zero.
Remember to check the Hessian is positive definite a well.
A: Given $x^2+2y^2+2xy+4y+7$$$x^2+2y^2+2xy+4y+7$$$$x^2+y^2+2xy+y^2+4y+7$$$$x^2+y^2+2xy+y^2+4y+4+3$$$$(x+y)^2+(y+2)^2+3$$Minimum of square of any number is $0$. So, minima will be at $x=2,y=-2$
Therefore, $(2+(-2))^2+(-2+2)^2+3=3$
Therefore, the least value of the expression $x^2+2y^2+2xy+4y+7$ is $3$
A: For $x^2+axy+bx+cy-d=0,$
$$x^2+x(ay+b)+cy-d=0$$
As $x$ is real, the discriminant must be $\ge0$ 
i.e.,  $$(ay+b)^2\ge4(cy-d)\iff4d\ge4cy-(a^2y^2+2aby+b^2)$$
$$=-b^2-a^2y^2-2y(ab-2c)$$
$$=\left(\dfrac{ab-2c}a\right)^2-b^2-\left(ay+\dfrac{ab-2c}a\right)^2$$
$$\ge\left(\dfrac{ab-2c}a\right)^2-b^2$$ 
the equality occurs if $ay+\dfrac{ab-2c}a=0$
A: The following one may be a more general solution without any trick. At first, let's recall a simple fact involving the quadric expression, which states that

$$ax^2+bx+c \geq \frac{4ac-b^2}{4a}~~~$$ 

holds for $a>0$ and with the equality
 holding iff $x=-\dfrac{b}{2a}.$
Hence, we have 
\begin{align*}
x^2+2y\cdot x+2y^2+4y+7 &\geq \frac{4 \cdot 1 \cdot (2y^2+4y+7)-(2y)^2}{4\cdot 1}\\&=y^2+4y+7\\&\geq \frac{4\cdot 1 \cdot 7-4^2}{4 \cdot 1}\\&=3,
\end{align*}
with the equality holding iff $x=-\dfrac{2y}{2 \cdot 1}$ and $y=-\dfrac{4}{2\cdot 1}$, namely, $x=2, y=-2.$
