This question already has an answer here:

We say that two matrices $A,B$ with complex entries are similar if and only if there exists an invertible complex matrix $P$ so that $A = P^{-1} B P$.

Does $P$ always have to be a complex matrix? I've done so many exercises where you are asked to determine if two matrices are similar and I've never come across a matrix with any complex entries. Is it safe to say that if $A$ and $B$ have real entries, then $P$ will also be real?

If we restrict this even more, say $A$ and $B$ both have only coordinates from the rational numbers, then $P$ will also be rational? What about the integers? (no, right? because when you do row operations you will likely start working with fractions) Is there a theorem about this? I've tried looking it up and came across 'rational canonical form' but I'm not sure it's what I'm looking for.


marked as duplicate by user1551 linear-algebra May 6 '15 at 9:07

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • 3
    $\begingroup$ If $A$ and $B$ are real and we have a complex matrix $P$ s.t $A=P^{-1}BP$ then we can find a real $Q$ s.t $A=Q^{-1}BQ$. $\endgroup$ – Kitegi May 6 '15 at 4:22
  • $\begingroup$ See the linked (duplicated) question. Put it simply, if both $A$ and $B$ comes from some field $K$ (e.g. $\mathbb Q$) and they are similar over a larger field $F$ (e.g. $\mathbb R$), then they are similar over $K$ too. In other words, if $K$ is a subfield of $F$, the matrices $A,B$ have entries in $K$ and $B=PAP^{-1}$ for some $P\in M_n(F)$, then there exists an invertible matrix $S\in M_n(K)$ such that $B=SAS^{-1}$. (Note that $P$ is not necessarily equal to $S$.) $\endgroup$ – user1551 May 6 '15 at 9:13

Frequently the conjugating matrix has all real entries, but there are cases of real matrices that are conjugate via a non-real matrix $P$. For instance, for any invertible non-real matrix $P$, we can see that for $A = B = I$, $P$ provides a conjugation from $A$ to $B$.

And for $A = B = I$, we can take $P$ to be a matrix that looks like $I$ except that its upper-left entry is some number $r$. If $r$ is not rational, then you have a non-rational conjugation between two rational matrices.

I think the question you want to ask might be this:

Suppose that $A$ and $B$ are conjugate matrices in some class; is there a matrix $P$ in that class with $A = P^{-1} B P$?

(This question, for the classes "real", "rational", "integer", is the one you asked. There are other classes of interest though, like "symmetric" or "integer-unimodular".)


Not the answer you're looking for? Browse other questions tagged or ask your own question.