Given $(a,m) = 1$, I want to show that $a ^e \equiv a^f \pmod m \implies e \equiv f \pmod {\phi(m)}$. I already know how to show the converse, and so far I have the following:
Suppose wlog that $e \leq f$. Then, $a^{f-e} \equiv 1 \pmod m$, so by Euler-Fermat we have $a^{f-e} \equiv a^{\phi(m)} \pmod m$. Now how do I finish the proof?
Can you take a look at that?
– b_pcakes Sep 29 '16 at 19:32