Optimizing fft