Pseudoinverse

The Moore-Penrose generalization of a matrix inverse — exists for any matrix, even non-square or singular ones, and gives the least-squares solution.

Pseudoinverse chooses the closest reachable output
reachable output spacebclosest fitresidual
Problem
For a tall matrix, Ax often cannot equal b exactly.
Pseudoinverse answer
xbest = A+ b
It picks the input whose output lands closest to the target.
Geometry
The leftover error is perpendicular to the reachable output space.
Definition

Only square, invertible matrices have a true inverse A1A^{-1}. The pseudoinverse A+A^+ (also called the Moore-Penrose inverse) extends the idea of "undoing" a matrix to any matrix — square or not, invertible or not.

When AA is actually invertible, A+=A1A^+ = A^{-1}. When it isn't, A+A^+ gives the best possible substitute: the matrix that turns Ax=bAx = b into the closest thing to a solution, even when no exact solution exists or when many solutions do.

Why ordinary inverses aren't enough

Suppose AA is 5×25 \times 2 — five equations, two unknowns. Generically, Ax=bAx = b has no exact solution: you're asking five constraints to be satisfied by only two degrees of freedom.

A+A^+ doesn't pretend a solution exists. Instead, x=A+bx = A^+ b gives the xx that makes AxAx as close to bb as possible — the least-squares solution.

Try it

If AA is square and invertible, what should A+A^+ equal, and why?

Solution

A+=A1A^+ = A^{-1}. The pseudoinverse is built to generalize the inverse, so whenever the ordinary inverse exists, the pseudoinverse must agree with it — otherwise it wouldn't deserve the name.

Related concepts