  One of the main challenges in quantum technologies is the ability to control
individual quantum systems. This task becomes increasingly difficult as the
dimension of the system grows. Here we propose a general setup for cyclic
permutations $X_d$ in $d$ dimensions, a major primitive for constructing
arbitrary qudit gates. Using orbital angular momentum states as a qudit, the
simplest implementation of the $X_d$ gate in $d$ dimensions requires a single
quantum sorter $S_d$ and two spiral phase plates. We then extend this
construction to a generalised $X_d(p)$ gate to perform a cyclic permutation of
a set of $d$, equally spaced values $\{ \ket{\ell_0}, \ket{\ell_0+p},\ldots,
\ket{\ell_0+(d-1)p} \} \mapsto \{ \ket{\ell_0+p}, \ket {\ell_0+2p},\ldots,
\ket{\ell_0} \}$. We find compact implementations for the generalised $X_d(p)$
gate in both Michelson (one sorter $S_d$, two spiral phase plates) and
Mach-Zehnder configurations (two sorters $S_d$, two spiral phase plates).
Remarkably, the number of spiral phase plates is independent of the qudit
dimension $d$. Our architecture for $X_d$ and generalised $X_d(p)$ gate will
enable complex quantum algorithms for qudits, for example quantum protocols
using photonic OAM states.
