Finite Fourier transform