Let $n=2m$. What is the order of the following permutation $\sigma$?
$$1\leq k\leq m \Rightarrow \sigma(k)=2k , \quad \sigma(m+k)=2k-1$$
Let $n=2m$. What is the order of the following permutation $\sigma$?
$$1\leq k\leq m \Rightarrow \sigma(k)=2k , \quad \sigma(m+k)=2k-1$$
By adding a fixed point at $0$ (which preserves the order), the permutation $\sigma$ considered is just the multiplication by $2$ modulo $2m+1$. Thus, for $k \ge 0$, $\sigma^k$ is the identity map if and only if it fixes $1$, namely if and only if $2m+1$ divides $2^k-1$.
Hence, the order of $\sigma$ is the order of $2$ in $(\mathbb{Z}/(2m+1)\mathbb{Z})^\times$. I do not think that there are formulas for this, although the order necessarily divides $\phi(2m+1)$ by Lagrange theorem.