attempting to fix fft code