My friend and me were studying some group theory, and we thought of the following problem.
Let $n$ be a positive integer, and let $A\in \text{GL}_n(\mathbb{Z})$ be a matrix with integer entries that is invertible over $\mathbb{Z}$ (i.e. $\text{det}(A)=\pm 1$). Question: Does the existence of a matrix $B\in \text{GL}_n(\mathbb{Q})$ and an integer $c>1$ such that $$AB = BA^c$$ imply that there exists some pair of integers $r,s>0$ such that $(A^r-I)^s=0$? Or equivalently that $A^r-I$ is nilpotent?
This implication seems a bit too random to be true, does anyone know a counterexample (or a proof)?
What we have thought of so far:
The matrix $B$ needs to be invertible, as else $B=0$ and for example the matrix $$A=\left(\begin{matrix} 2 & 5 \\ 1 & 3\end{matrix}\right)$$ has eigenvalues that are not roots of unity, but it is actually diagonalizable, showing that $A^r-I=S(D^r-I)S^{-1}$ will never be nilpotent (its determinant is nonzero).
We are not really interested in the case when $A$ is not invertible, but when $A$ has determinant $|\text{det}(A)|>1$ the equation $AB=BA^c$ will fail for any $c>1$ by taking the determinant on both sides.
We will need $c>1$, as else we may take the commuting matrices $$A = \left(\begin{matrix} 1 & 5 \\ 1 & 6 \end{matrix}\right); B= \left(\begin{matrix} 2 & 5 \\ 1 & 7 \end{matrix}\right).$$ That is, we have $AB=BA$, but $A$ has eigenvalues that are not roots of unity, showing that $A^r-I$ will never be nilpotent for $r>0$ with the same argument as before.
We have only tried $2\times 2$ matrices, as it seems incredibly difficult to check if such a matrix $B$ exists in any case.
To show that there is some support for the question, we may take $$A = \left(\begin{matrix} 1 & -3 \\ 1 & -2 \end{matrix}\right)$$ and $$B= \left(\begin{matrix} -6 & -3 \\ -7 & 6 \end{matrix}\right).$$ This example has $AB=BA^2$, the matrix $A$ is diagonalizable and the eigenvalues are roots of unity (implying that $A$ is of finite order, so $A^r-I=0$ for some $r>0$, in this case $r=3$).
These were the final thought we had before submitting this question: only assuming the relation $AB=BA^c$ does not imply nilpotence of $A^r-I$ for some $r>0$ as we have seen above. So we do need the invertibility of $A$ and $B$. Moreover, somehow $A$ having determinant $\pm 1$ makes it more plausible for this to be true; the "excess" of the relation $AB=BA^c$ is something along the lines of $A^{c-1}$. This is a positive power, so we think this might somehow imply that the eigenvalues of $A$ must be roots of unity. Can this imply the statement?
Since $A^c=B^{-1}AB$ has the same eigenvalues as $A,$ these are indeed roots of unity. So, there exists a positive integer $r$ such that $$A=D+N,\quad DN=ND,\quad N\text{ nilpotent},\quad D^r=I.$$ Therefore (by the binomial theorem) $A^r-I$ is nilpotent.