The problem is:
Find the least square solution of $Ax=b$ if $A = \begin{pmatrix}1 & 2\\1 & 3\\1 & 4 \end{pmatrix} \text{ and }b = \begin{pmatrix}2\\3\\2\end{pmatrix}.$ I have $x = (A^TA)^{-1}A^Tb$
$x = \begin{pmatrix}5&7&9\\7&10&13\\9&13&17\end{pmatrix}^{-1} \times \begin{pmatrix}7\\21\end{pmatrix}$
Can someone tell me if I am on the right track at figuring this out?