Phase optimization

why three — the root-of-unity sum, evaluated twice