# How to Solve Bilinear Matrix Equation?

How should I solve this matrix equation? What is the solution for $X$?

$$BXC +B^TXC^T=D$$

-

Rewrite it as a system of linear equations $(C^T\otimes B+C\otimes B^T)\operatorname{vec}(X)=\operatorname{vec}(D)$ (see Wikipedia entries on Kronecker product and vectorisation for the meanings of the symbols $\otimes$ and $\operatorname{vec}$) and solve it.