KFR

DFT functions

dft

template<typename T, size_t Tag>
univector<complex<T>> dft(const univector<complex<T>, Tag> &input)

Performs Direct DFT using cached plan

Source:

template <typename T, size_t Tag>
univector<complex<T>> dft(const univector<complex<T>, Tag>& input)

idft

template<typename T, size_t Tag>
univector<complex<T>> idft(const univector<complex<T>, Tag> &input)

Performs Inverse DFT using cached plan

Source:

template <typename T, size_t Tag>
univector<complex<T>> idft(const univector<complex<T>, Tag>& input)

realdft

template<typename T, size_t Tag>
univector<complex<T>> realdft(const univector<T, Tag> &input)

Performs Real Direct DFT using cached plan

Source:

template <typename T, size_t Tag>
univector<complex<T>> realdft(const univector<T, Tag>& input)

irealdft

template<typename T, size_t Tag>
univector<T> irealdft(const univector<complex<T>, Tag> &input)

Permorms Real Inverse DFT using cached plan

Source:

template <typename T, size_t Tag>
univector<T> irealdft(const univector<complex<T>, Tag>& input)

dft_plan

template<typename T>
class dft_plan

Class for performing DFT/FFT

reference_fft

template<typename Tnumber = double, typename T>
void reference_fft(complex<T> *out, const complex<T> *in, size_t size, bool inversion = false)

Performs Complex FFT using reference implementation (slow, used for testing)

Source:

template <typename Tnumber = double, typename T>
void reference_fft(complex<T>* out, const complex<T>* in, size_t size, bool inversion = false)
template<typename Tnumber = double, typename T>
void reference_fft(complex<T> *out, const T *in, size_t size)

Performs Direct Real FFT using reference implementation (slow, used for testing)

Source:

template <typename Tnumber = double, typename T>
void reference_fft(complex<T>* out, const T* in, size_t size)
template<typename Tnumber = double, typename T>
void reference_fft(T *out, const complex<T> *in, size_t size)

Performs Inverse Real FFT using reference implementation (slow, used for testing)

Source:

template <typename Tnumber = double, typename T>
void reference_fft(T* out, const complex<T>* in, size_t size)

reference_dft

template<typename Tnumber = double, typename T>
void reference_dft(complex<T> *out, const complex<T> *in, size_t size, bool inversion = false)

Performs Complex DFT using reference implementation (slow, used for testing)

Source:

template <typename Tnumber = double, typename T>
void reference_dft(complex<T>* out, const complex<T>* in, size_t size, bool inversion = false)
template<typename Tnumber = double, typename T>
inline univector<complex<T>> reference_dft(const univector<complex<T>> &in, bool inversion = false)

Performs DFT using reference implementation (slow, used for testing)

Source:

template <typename Tnumber = double, typename T>
inline univector<complex<T>> reference_dft(const univector<complex<T>>& in, bool inversion = false)

fft_inverse

template<typename E>
class fft_inverse

[0, N - 1, N - 2, N - 3, …, 3, 2, 1]

cmul

template<typename T, size_t N1, size_t N2>
vec<T, const_max(N1, N2)> cmul(const vec<T, N1> &x, const vec<T, N2> &y)

Complex Multiplication

Source:

template <typename T, size_t N1, size_t N2>
CMT_INLINE vec<T, const_max(N1, N2)> cmul(const vec<T, N1>& x, const vec<T, N2>& y)