Đặt \(\left\{{}\begin{matrix}\sqrt{a}=x>0\\\sqrt{b}=y>0\end{matrix}\right.\) \(\Rightarrow x^2+y^2-xy-4x-y+7=0\)
\(\Leftrightarrow4x^2+4y^2-4xy-16x-4y+28=0\)
\(\Leftrightarrow\left(2x-y-4\right)^2+3y^2-12y+12=0\)
\(\Leftrightarrow\left(2x-y-4\right)^2+3\left(y-2\right)^2=0\)
\(\Leftrightarrow\left\{{}\begin{matrix}2x-y-4=0\\y-2=0\end{matrix}\right.\) \(\Rightarrow\left\{{}\begin{matrix}x=3\\y=2\end{matrix}\right.\) \(\Rightarrow a+b=3^2+2^2=13\)