I am trying to study least square and linear regression and I understand the solution for $Ax = b$ when x is the unknown and the LS solution is given by $(A^TA)^{-1}A^TA$. Now, I was wondering if something similar exists when A is unknown. I was wondering if I do the corresponding:
$$ Ax=b $$ $$ x^TA^T = b $$
Therefore, $A^T = (xx^T)^{-1}xb$ or $A = b^Tx^T ((xx^T)^{-1})^T$
Since $xx^T$ is a rank one matrix, it is not invertible and $(xx^T)^{-1}$ does not exist. Your system is therefore underdetermined.
The best way to obtain a (pseudo-)unique solution is either to replace $(xx^T)^{-1}$ by the Moore-Penrose pseudoinverse of $x^Tx$ or to use a regularization procedure (like the Tikhonov one, where you would replace $(xx^T)^{-1}$ by $(xx^T+\lambda I)^{-1}$ with $\lambda > 0$).