Apply the Fast Fourier Transform (FFT) More...

Modules

 fft
 C++ interface for Fast Fourier Transform.
 
 af_fft
 C interface for Fast Fourier Transform.
 
 fft_info
 Fast Fourier Transform Info Functions.
 

Detailed Description

Apply the Fast Fourier Transform (FFT)

The Fast Fourier Transform (FFT) is an efficient algorithm to compute the discrete Fourier transform (DFT) of a signal or array. This is most commonly used to convert data in the time (or space) domain to the frequency domain, Then, the inverse FFT (iFFT) is used to return the data to the original domain.

There are numerous algorithms to compute the FFT of an array, and the specifics of the algorithm depend on the target hardware. Most algorithms, however, use a Cooley-Tukey scheme in a divide-and-conquer approach.

ArrayFire supports up to three-dimensional FFTs. Typically, these multi-dimensional FFTs are implemented using 1D FFTs combined with transpose operations.

array a = randu(4,4);
// a =
// 0.7402 0.9251 0.4702 0.7140
// 0.9210 0.4464 0.5132 0.3585
// 0.0390 0.6673 0.7762 0.6814
// 0.9690 0.1099 0.2948 0.2920
array f = fft(a);
// f =
// 2.6692 + 0.0000i 2.1487 + 0.0000i 2.0544 + 0.0000i 2.0459 + 0.0000i
// 0.7012 + 0.0480i 0.2578 - 0.3364i -0.3060 - 0.2184i 0.0326 - 0.0665i
// -1.1107 + 0.0000i 1.0362 + 0.0000i 0.4384 + 0.0000i 0.7449 + 0.0000i
// 0.7012 - 0.0480i 0.2578 + 0.3364i -0.3060 + 0.2184i 0.0326 + 0.0665i
array i = ifft(f);
// i =
// 0.7402 + 0.0000i 0.9251 + 0.0000i 0.4702 + 0.0000i 0.7140 + 0.0000i
// 0.9210 + 0.0000i 0.4464 - 0.0000i 0.5132 - 0.0000i 0.3585 - 0.0000i
// 0.0390 + 0.0000i 0.6673 + 0.0000i 0.7762 + 0.0000i 0.6814 + 0.0000i
// 0.9690 - 0.0000i 0.1099 + 0.0000i 0.2948 + 0.0000i 0.2920 + 0.0000i