Find the least-square solution of Ax=b for \(A = \begin{bmatrix} 1 & -6\\ 1 & -2\\ 1 & 1\\ 1 & 7 \end{bmatrix}\) and \(b = \begin{bmatrix}-1 \\ 2\\ 1\\ 6 \end{bmatrix}\)

This answer is restricted. Please login to view the answer of this question.

Login Now

Here,

A = \(\begin{bmatrix}1 & -6\\ 1 & -2\\ 1 & 1\\ 1 & 7\end{bmatrix}\) and b = \(\begin{bmatrix}-1\\ 2\\ 1\\ 6\end{bmatrix}\)

Now,

\(\hat{x} = (A^{T}A)^{-1} (A^{T}b)\)  ———– (1)

AT = \(\begin{bmatrix}1 & 1 & 1 & 1\\ -6 & -2 & 1 & 7\end{bmatrix}\)

ATA = \(\begin{bmatrix}1 & 1 & 1 & 1\\ -6 & -2 & 1 & 7\end{bmatrix}\)\(\begin{bmatrix}1 & -6\\ 1 & -2\\ 1 & 1\\ 1 & 7\end{bmatrix}\)

= \(\begin{bmatrix}1+1+1+1 & -6-2+1+7\\ -6-2+1+7 & 36+4+1+49\end{bmatrix}\)

= \(\begin{bmatrix}4 & 0\\ 0 & 90\end{bmatrix}\)

and

ATb = \(\begin{bmatrix}1 & 1 & 1 & 1\\ -6 & -2 & 1 & 7\end{bmatrix}\)\(\begin{bmatrix}-1\\ 2\\ 1\\ 6\end{bmatrix}\)

= \(\begin{bmatrix}-1+2+1+6\\ 6-4+1+42\end{bmatrix}\)

= \(\begin{bmatrix}8\\ 45\end{bmatrix}\)

Since we have definition of least square; the set of least square solutions of Ax = b coincides with the non-empty set of solutions of ATAx = ATb

therefore

\(\hat{x} = (A^{T}A)^{-1} (A^{T}b)\)

Here,

|ATA| = \(\begin{bmatrix}4 & 0\\ 0 & 90\end{bmatrix}\) = 360 ≠ 0

then

(ATA)-1 = \(\frac{1}{360} \begin{bmatrix}90 & 0\\ 0 & 4\end{bmatrix}\)

then equation(1) becomes

\(\hat{x}\) = \(\frac{1}{360} \begin{bmatrix}90 & 0\\ 0 & 4\end{bmatrix}\begin{bmatrix}8\\ 45\end{bmatrix}\)

= \(\frac{1}{360}\begin{bmatrix}720+0\\ 0+180\end{bmatrix}\)

= \(\begin{bmatrix}2\\ \frac{1}{2}\end{bmatrix}\)

If you found any type of error on the answer then please mention on the comment or report an answer or submit your new answer.
Leave your Answer:

Click here to submit your answer.

Discussion
0 Comments
  Loading . . .