Takes in data, and calculates the dft using fft algorithm from fftw