Solve $Ax=b$ when the matrix $AA^T$ is regular

linear algebramatrices

I need to solve the equation $Ax=b$ symbolically for a vectors $x \in \mathbb{R}^n$ given a matrix $A \in \mathbb{R}^{m \times n}$ and a vector $b \in \mathbb{R}^m$ when the matrix $AA^T$ is regular.

If the matrix $A^TA$ was regular, than the solution would be fairly straightforward. I would multiply the equation by $A^T$ from the left and multiply it by $A^TA$ also from left. Result would be: $x = (A^TA)^{-1}A^Tb$.

But I cannot solve the same problem for $AA^T$ regular.

It seems, that the solution could be $A^T(AA^T)^{-1}b$, since when I substitute for b, I get the equation $A^T(AA^T)^{-1}b = A^T(AA^T)^{-1}Ax$ and by multiplying it by A from the left, I get $Ax = b$. I tried to use it numerically and it seems to be the correct solution. I think, it can somehow be related to the fact, that $P = A^T(AA^T)^{-1}A$ is an orthogonal projector.

Could you please help me solve this problem?

Any help would be very appreciated.

Thanks,

Jonas

EDIT:
I realized, that I used an invertible matrix A, when I tried to verify my equation $x = A^T(AA^T)^{-1}b$ numerically. When A is invertible, the orthogonal projector P is the identity matrix. I still don't know, if my solution works in general.

Best Answer

Your solution is correct. You have verified directly that $x=A^T(AA^T)^{-1}b$ is a solution. Therefore (as general solution = particular solution + solution to homogeneous equation) the general solution is given by $x=A^T(AA^T)^{-1}b+u$, where $u$ is any vector in $\ker(A)$. It is also known that among all solutions $x$ to $Ax=b$, the solution $x=A^T(AA^T)^{-1}b$ has the least Euclidean norm, because $u\perp A^T(AA^T)^{-1}b$ for every $u\in\ker(A)$.

Related Question