Let $G$ be a cyclic group generated by $a$ satisfy the property that there exist $n \in \mathbb N$ such that $n=$ min$\{|i-j| : i\neq j \in \mathbb N,$ $a^i = a^j \}$. Then the order of $G$ is $n$.
Clearly $a, a^2, a^3, \cdots, a^n$ are all distict elements and there exist $r \in \mathbb N$ such that $a^{n+r} = a^r$. I want to show that $a^{n+1} = a$. Any help would be appreciated. Thank you