|
Decimation-in-time Multi-threaded Radix-2 Fast Fourier Transform implemented in C++ with use of boost::thread & following C++ template parameters: number of (boost) threads, floating point size/type, FFT point-size. Usage detailsimport fft.hpp to use. See attached .cpp file for example of usage. template<class FLOAT_TYPE, int FFT_SIZE, int NUM_THREADS> class FFT; --- Example snippet:typedef double My_type; FFT<My_type, 2048, 4> user_fft; user_fft.initialise_FFT(); get_input_samples(user_fft.input_value_array, user_fft.m_fft_size); user_fft.execute_FFT(); print_output_csv(user_fft.output_value_array, 2048); Limitations-Radix-2 only - Power-of-2 FFT size only (may work for other sizes by changing the logarithm result variables from int to float, but this has not been tested) - 1-dimensional FFT only Testing & Validation Details- Tested against MIT FFTW library (results agree to max. error vector margin of 3 parts per million) - Tested with GNU GCC compiler under Ubuntu Linux - Tested with Visual Studio Express 2012 for Windows (MS Visual C++) - Nathan Bliss, April 2013 Please feel free to contribute to this open-source project with optimisations & extensions beyond the above limitations, etc
|