Define a transformed wavefunction by
Indeed, writing gives
This is the electromagnetic gauge transformation generated by : and . The transformed Hamiltonian operator is consequently , but the original periodic boundary condition becomes the twisted boundary condition
For the domain of the self-adjoint kinetic Hamiltonian operator, the derivative has the same twist, . Thus the magnetic flux has moved into the boundary condition. The transformation is a single-valued gauge on periodic representatives only when is an integer multiple of ; otherwise it is understood on the cut interval with the displayed identification of its endpoints.