Next: Appendix
Up: algebra
Previous: Vector and matrix differentiation
In general an over-determined linear equation system of
unknowns but
equations has no solution if
. But it is still possible to find the
optimal approximation in the least squares sense, so that the squared error is
minimized. Specifically, consider an over determined linear equation system
which can also be represented in matrix form as
where
As in general no
can satisfy the equation system, there is always some
residual for each of the
equations:
or in matrix form
where
. The total error can be defined as
To find the optimal
that minimizes
, we let
which yields
This can be expressed in the matrix form as
Or in matrix form we have:
Solving this for
, we get the same result above. This matrix equation
can be solved for
by multiplying both sides by the inverse of
, if it exists:
where
is the pseudo-inverse of the non-square matrix
.
Sometime it is desired for the unknown
to be as small as possible, then
a cost function can be constructed as
where a greater
means the size of the corresponding
is more
tightly controlled. Then repeating the process above we get:
which yields
or in matrix form
where
.
Solving this for
we get:
Next: Appendix
Up: algebra
Previous: Vector and matrix differentiation
Ruye Wang
2015-04-27