Solve a matrix equation of the form $A=XB$

1.6k Views Asked by At

Given matrices $A \in \mathbb{R}^{n \times p}$ and $B \in \mathbb{R}^{m \times p}$, is it possible to solve the matrix equation $A=XB$?

I don't know if this is feasible. It may even be quite easy in fact but I'm stuck with that equation in my work (I'm not a math specialist). I've tried to make the inverse of $B$, but as $B$ is not a square matrix in my data, I can't do that. In my data $A$ is $120 \times 170$ and $B$ is $10 \times 170$. I am expecting $X$ to be $120 \times10$. Any ideas?

EDIT: matrix $B B^\top$ is invertible. Giving a $10 \times 10$ matrix.

3

There are 3 best solutions below

0
On BEST ANSWER

There can not be guaranteed solution. This is evident by the fact, that $A$ can has a rank up to $p$, while the rank of $XB$ is limited by $p$ (if we keep the order of your sizes). If you draw a picture of your matrices (just the boxes) you find, that you are searching for a low rank representation of $A$ with a specific set of right singular vectors. I italize because these are most likely not orthogonal.

You can approximate $A$ by your product. The best (I assume) way to do this, is by choosing the pseudo-inverse of $B$. (Matlab gives this by pinv).

3
On

The system has solution $\iff Row(A)\subseteq Row(B)$ thus we can find a basis for $Row (B)$ and check that the condition is matched.

If $Row(A)\subseteq Row(B)$ we can obtain $X$ solving the system row by row

$$R_i(A)=R_i(X)B$$

0
On

The way to think of this is as a "multiple right-hand side problem"

$$A = X B $$ can be thought of as $$ \left( \begin{array}{c} a_0^T \\ a_1^T \\ \vdots \end{array} \right) = \left( \begin{array}{c} x_0^T \\ x_1^T \\ \vdots \end{array} \right) B = \left( \begin{array}{c} x_0^T B\\ x_1^T B\\ \vdots \end{array} \right) $$ where $ a_i^T $ and $ x_i^T $ are the rows of $ A $ and $ X $ indexed with $ i $, respectively.

What you recognize is that you are solving many $ a_i^T = x_i^T B $ problems. Transpose both sides and you get $ B^T x_i = a_i $, which should look a lot more familiar, and then you can extend everything you know about solving such a system.