Let $n$ and $r$ be co-prime. Consider the sequence of integers $a_1=n-r, a_2=2(n-r), a_3=3(n-r), \cdots , a_r=r(n-r), a_{r+1}=r(n-r-1), a_{r+2}=r(n-r-2), \cdots , a_{n-2}=2r, a_{n-1}=r$.
Consider $a_i \equiv b_i \,\, mod \,\, n$. Since $(n,r)=1$ we have $\{b_1, b_2, \cdots ,b_{n-1}\}=\{1,2, \cdots ,n-1\}$. My questions are the following:
For which $i$, $b_i=n-1$, which one is $(n-2)$ and so on.
If $b_j=k$, then what are $b_{j-1}$ and $b_{j+1}$ ?
It seems the following.
We can easily check that $b_i\equiv -ir\pmod n$ for each $i$. Since $(n,r)=1$ there exist integers $p$ and $q$ such that $pn+qr=1$ (you can find them using Euclidean algorithm). Then $qr\equiv 1 \pmod n $. Thus
If $b_i=k$ then $b_i=-ir\equiv k \pmod n$. So $i\equiv qri\equiv -qk \pmod n$.
If $b_j=k$ then $b_{j+1}\equiv b_j-r \equiv k-r \pmod n$. Similarly, $b_{j-1} \equiv k+r \pmod n$.