nitraiddQ

2020-10-18

Find a least squares solution of Ax=b by constructing and solving the normal equations.
$A=\left[\begin{array}{cc}3& 1\\ 1& 1\\ 1& 4\end{array}\right],b\left[\begin{array}{c}1\\ 1\\ 1\end{array}\right]$
$\stackrel{―}{x}=$?

nitruraviX

$A=\left[\begin{array}{cc}3& 1\\ 1& 1\\ 1& 4\end{array}\right],b\left[\begin{array}{c}1\\ 1\\ 1\end{array}\right]$
${A}^{T}Ax={A}^{T}$ b. Compute the relevant matrices.
${A}^{T}A=\left[\begin{array}{ccc}3& 1& 1\\ 1& 1& 4\end{array}\right]\left[\begin{array}{cc}3& 1\\ 1& 1\\ 1& 4\end{array}\right]=\left[\begin{array}{cc}11& 8\\ 8& 18\end{array}\right]$
${A}^{T}b=\left[\begin{array}{ccc}3& 1& 1\\ 1& 1& 4\end{array}\right]\left[\begin{array}{c}1\\ 1\\ 1\end{array}\right]=\left[\begin{array}{c}5\\ 6\end{array}\right]$

Solve $\left[\begin{array}{cc}11& 8\\ 8& 18\end{array}\right]x=\left[\begin{array}{c}5\\ 6\end{array}\right]$
$\left[\begin{array}{ccc}11& 8& 5\\ 8& 18& 6\end{array}\right]\to \left[\begin{array}{ccc}-3& 10& 1\\ 8& 18& 6\end{array}\right]$
$\to \left[\begin{array}{ccc}1& 10& -3\\ 6& 18& 8\end{array}\right]$
$\to \left[\begin{array}{ccc}1& 10& -3\\ 0& -42& -10\end{array}\right]$
$\to \left[\begin{array}{ccc}1& 10& -3\\ 0& 21& 5\end{array}\right]$

${x}_{1}+10{x}_{2}=-3$
$21{x}_{2}=5$
$⇒{x}_{2}=\frac{5}{21},{x}_{1}=-\frac{113}{21}$
$⇒x=\left[\begin{array}{c}\frac{-113}{21}\\ \frac{5}{21}\end{array}\right]$

Jeffrey Jordon