How can I prove that $a^m-1|a^n-1 \Leftrightarrow m|n$? Suppose that $(a,m,n)\in \mathbb{N}^{3}$, as $a>1$
How can I prove that $a^m-1|a^n-1 \Leftrightarrow m|n$?
I proved that $m|n \implies a^m-1|a^n-1$, but I couldn't prove the reciproque.

Suppose $a^m-1\mid a^n-1$. I claim $m\mid n$. Write $n=qm+r$ for $0\leq r<m$. Then notice
$$
a^n-1=(a^{qm+r}-a^r)+(a^r-1)=a^r(a^{qm}-1)+(a^r-1).
$$
But $m\mid qm$, so by your previous work, you know $a^m-1\mid a^{qm}-1$. This implies
$a^m-1\mid a^r-1$. But $a^m-1>a^r-1$ since $m>r$ and $a>1$, so necessarily $a^r-1=0$, or $r=0$. Thus $m\mid n$.
