Ta có :
\(x^2+3y^2+2xy-10x-14y+18=0\)
\(\Leftrightarrow\left(x^2+2xy+y^2\right)-10x-10y+25+\left(2y^2-4y+2\right)-9=0\)
\(\Leftrightarrow\left(x+y\right)^2-2.\left(x+y\right).5+25+2\left(y^2-2y+1\right)=9\)
\(\Leftrightarrow\left(x+y-5\right)^2+2\left(y-1\right)^2=9\)
Vì \(2\left(y-1\right)^2\ge0\forall y\)nên \(\left(x+y-5\right)^2\le9\)hay \(\left(M-5\right)^2\le9\)
\(\Rightarrow-3\le M-5\le3\Leftrightarrow2\le M\le8\)
\(Min_M=2\)khi \(\hept{\begin{cases}x=1\\y=1\end{cases}}\)\(Max_M=8\)khi\(\hept{\begin{cases}x=7\\y=1\end{cases}}\)