TITLE: Similar matrices and field extensions
QUESTION [61 upvotes]: Given a field $F$ and a subfield $K$ of $F$. Let $A$, $B$ be $n\times n$ matrices such that all the entries of $A$ and $B$ are in $K$. Is it true that if $A$ is similar to $B$ in $F^{n\times n}$ then they are similar in $K^{n\times n}$?

Any help ... thanks!

REPLY [2 votes]: While the structure theory for finitely generated modules over a PID provides the royal route to this result, it does so in a rather indirect way, and it is not easy to see for instance by which basis change two matrices that turn out to produce the same invariant factors under the Smith normal form algorithm are similar. I'll therefore try to formulate a second answer which, although inspired by this structure theory, proceeds in a more straightforward way.
First some terminology. Fixing a linear operator$~\phi$ of a finite dimensional vector space $V$ over$~F$, say that a vector $v\in V$ "generates" the subspace spanned by it and its repeated images by the operator, $\bigl<\phi^k(v)\mid k\in\mathbf N\,\bigr>_F\,$, and call such subspaces "cyclic" subspaces (the terminology mimicks that used in Abelian groups). The first linear dependence between the images $\phi^k(v)$ determines a monic polynomial $P$ such that $P[\phi](v)=0$, which I shall call the "order" of$~v$ (for$~\phi$). Since $P$ is the minimal polynomial of the restriction of$~\phi$ to that cyclic subspace, it does not depend on which generator was used (different vectors may generate the same subspace), and this polynomial can therefore be called the order of the cyclic subspace.
The construction is based on the following two facts.
Proposition 1. There exists a vector whose order equals the minimal polynomial of$~\phi$ (on$~V$).
Proposition 2. If $V$ admits two decompositions as direct sum of a sequence of cyclic subspaces of nonzero dimension such that the order of each subspace divides the order of any subspace before it, then the two decompositions have the same sequence of orders of their subspaces.
Admitting these for the moment, we can proceed as follows. First construct a decomposition into cyclic subspaces satisfying the divisibility condition of proposition 2, by induction on $\dim V$. For $\dim V=0$ the empty direct sum works. So assume $\dim V>0$, and use proposition 1 to find a vector $v$ whose order is the minimal polynomial$~\mu$ of$~\phi$. The dimension$~d$ of the subspace$~S$ generated by$~v$ is $\deg\mu>0$. In order to find a $\phi$-stable complementary subspace$~C$ to$~S$, choose a linear functional $\alpha$ on$~V$ that vanishes on $v=\phi^0(v),\phi(v),\ldots,\phi^{d-2}(v)$ but not on $\phi^{d-1}(v)$ (this can be done for instance by extending those vectors to a basis of $V$, and taking the coordinate function corresponding to the basis vector $\phi^{d-1}(v)$). Then $\alpha=\alpha\circ\phi^0,\alpha\circ\phi,\ldots,\alpha\circ\phi^{d-1}$ are linearly independent functionals: for $0\leq i<d$ the vector $\phi^{d-1-i}(v)$ is annihilated by all functionals in the list before $\alpha\circ\phi^i$, but not by $\alpha\circ\phi^i$ itself, which shows that the latter functional is independent of its predecessors. These $d$ linearly independent functionals span a $\phi$-stable subspace of $V^*$ (the stability follows from $\alpha\circ\mu[\phi]=0$), and the annihilator of this subspace (the space of vectors on which $\alpha,\ldots,\alpha\circ\phi^{d-1}$ all vanish) gives our $\phi$-stable complement$~C$ of$~S$ in$~V$, as is easily checked. The minimal polynomial of the restriction of$~\phi$ to$~C$ obviously divides the global minimal polynomial$~\mu$, so one can apply the induction hypothesis to decompose $C$ (whose dimension is $\dim V-d$) as a direct sum of cyclic subspaces, all of whose orders will divide$~\mu$.
If $A$ and $B$ are similar matrices over$~F$, then they can be seen as matrices of the same linear operator$~\phi$ expressed on different bases. Proposition$~$2 now says that the above procedure will always produce the same sequence of orders of the cyclic factors. Conversely if one finds the same sequence of orders of the cyclic factors using $A$ or $B$ to define$~\phi$, then choosing in each cyclic subspace the basis $v,\phi(v),\ldots,\phi^{d-1}(v)$ finds a pair of bases transformed to which $A$ and $B$ are given by the same matrix (the rational canonical form), showing that $A$ and $B$ are similar over$~F$.
And to answer the question, if $A$ and $B$ are not similar over$~F$, then one gets decompositions with different sequences of orders of the cyclic factors. These decompositions persist under extending the field to$~K$, with the same orders, and this shows that $A$ and $B$ cannot become similar over$~K$.
Now both propositions are easy to show using the canonical decomposition of $V$ into subspaces associated to the distinct irreducible factors of$~\mu$, according to the Chinese remainder theorem for the ring $F[X]/(\mu)$: