Let $n \in \mathbb{N}$, and $U,V$ two linear subspaces of $\mathbb{R}^n$ of the same dimension. Could one always make a matrix $A \in \mathbb{M}^{n \times n}(\mathbb{R})$ such that $spanA = U$ and $spanA^T = V$?
I find it hard to find a counterexample. I know that for any $n \in \mathbb{N}$, there is such a matrix if $\dim U = \dim V \in \{0,n\}$, we could just take $0,I$ as matrices. Moreover, if $U,V$ are lines, that means $U = \mathbb{R}v$ and $V = \mathbb{R}w$ for some nontrivial vectors $v,w$, then the matrix below works.
$$ \left( \ w_1v \ | \ w_2v \ | \ \cdots \ | \ w_nv \ \right) $$ Here $w_i$ are coordinates of the vector $w$, and each entry represents a column this way.
Then I took two subspaces of dimension two in $\mathbb{R}^3$, namely $$ U \quad = \quad span \left\{ \left( \begin{array}{ccc} 1 \\ 0 \\ 0 \end{array} \right) , \left( \begin{array}{ccc} 0 \\ 1\\ 0 \end{array} \right) \right\} \qquad V \quad = \quad \left( \begin{array}{ccc} 0 \\ 1\\ 0 \end{array} \right)^\perp $$ The matrix we need here is $$ \left( \begin{array}{ccc} 1 & 0 & 0 \\ -1 & 1 & 0 \\ 0 & -1 & 0 \end{array} \right) $$
I find it hard to deal with the general case. Could you give me some help to establish the statement, or give a counterexemple?
Let $m$ be the dimension of $U$ and $V$. Let $M_U$ be an $n\times m$ matrix whose columns are a basis of $U$ and $M_V$ be an $n \times m$ matrix whose columns are a basis of $V$. Now $U = \{M_U \vec{x} : \vec{x} \in \mathbb{R}^m \}$ and $V = \{M_V \vec{x} : \vec{x} \in \mathbb{R}^m \}$.
We wish to find a matrix $A$ such that $$ \begin{align*} U &= \{M_U \vec{x} : \vec{x} \in \mathbb{R}^m \} = \{A \vec{x} : \vec{x} \in \mathbb{R}^n \}, \\ V &= \{M_V \vec{x} : \vec{x} \in \mathbb{R}^m \} = \{A^T \vec{x} : \vec{x} \in \mathbb{R}^n \}. \end{align*} $$
We note that $\{ M_V^T \vec{x} : \vec{x} \in \mathbb{R}^n\} = \mathbb{R}^m$, because the rank of $M_V^T$ is $m$ and it has $m$ rows. Thus $$ U = \{M_U \vec{x} : \vec{x} \in \mathbb{R}^m \} = \{M_U M_V^T \vec{x} : \vec{x} \in \mathbb{R}^n \}. $$ But this immediately suggests that $A=M_U M_V^T$, because $\mathrm{span}(M_U M_V^T) = U$. By symmetry, also $\mathrm{span}(M_V M_U^T) = V$, and because $A^T=M_V M_U^T$, we are done.