# Is the rank of a matrix with coefficients $\{-1,0,1\}$ the same as the rank of the matrix with coefficients in $GF(3)$?

I have a set of matrices defined over the ring of the integers, which items are using only coefficients -1, 0 and 1. For example:

$$A = \left(\begin{matrix} 1 & 0 & -1 \\ -1 & 1 & 0 \\ 0 & 1 & 0 \end{matrix}\right) \hspace{1em} \text{(over }\mathbb{Z}\text{)}$$

Now I'm wondering, if I transform my matrices into equivalent matrices in GF(3) (mapping 0 to 0, 1 to 1, and -1 to 2), is their rank preserved?

With my example, the transformed matrix is:

$$A' = \left(\begin{matrix} 1 & 0 & 2 \\ 2 & 1 & 0 \\ 0 & 1 & 0 \end{matrix}\right) \hspace{1em} \text{(over }GF(3)\text{)}$$

and $$\operatorname{rank} A = \operatorname{rank} A' = 3$$. Is this result true in general?

No, the result is not true in general, because $$\det(A)$$ may be a nonzero multiple of $$3$$, which becomes $$0$$ over $$\Bbb F_3$$. For example, $$A=\begin{pmatrix} 1 & -1 & 1\cr -1 & 0 & 1 \cr 1 & 1 & 0\end{pmatrix}$$ has determinant $$\det(A)=-3$$ over $$\Bbb Z$$, which is $$0$$ over $$\Bbb F_3$$.
• Is it possible to have $\det A = 3k$, if all the items of $A$ are in $\{-1,0,1\}$ though? – lennox Feb 21 at 17:25
• Yes, it is, at least for $k=\pm 1$. – Dietrich Burde Feb 21 at 17:26
Take the matrix $$M =\begin{pmatrix} 1 & 1 & 1 \\ -1 & 0 & 1 \\ 0 & -1 & 1 \end{pmatrix}$$ It is clearly of full rank over $$\mathbb{Z}$$ but the transformed is not. We also have that $$\det(M) = 3$$ hence it is not invertible $$\pmod{3}$$.