The Wang--Sun Sum over Affine Derangements
Let $n$ be even, let $\zeta$ be a primitive $n$-th root of unity, and let $\Delta_n$ be the set of derangements in the affine group $\overrightarrow{GL}(\mathbb{Z}/n\mathbb{Z})$. We evaluate the Wang--Sun type sum \[ S_n=\sum_{\pi\in\Delta_n}\mathrm{sign}(\pi) \prod_{x\in\mathbb{Z}/n\mathbb{Z}} \frac{1+\zeta^{x-\pi(x)}...