What is the method of least squares

  • remember how in 7.2 Projection onto subspaces and Gram-Schmidt that a projection of x onto W

    • represents the point on W that is the closest to x
    • We can see this as the same way if a vector is inconsistent and we need the solution so we can just find the solution closest to the orignal vector
  • Any which is a solution to is the closest in minimizing the least squares error, we call such a solution a best fit solution or a least squares error solution

Finding the best-fit solution to

  • it is possible to find the best-fit solution to an inconsistent system without finding by projection

    • recall that row(A) and null(A) are “orthogonal to eachother”. that is:
    • similarly
    • Since the perp part is orthogonal to Col(A), is in so we can write
      • And replacing

Examples

  • Finding best fit line