Friday, September 5, 2025
HomeLanguagesPython | Inverse Fast Fourier Transformation

Python | Inverse Fast Fourier Transformation

Inverse Fast Fourier transform (IDFT) is an algorithm to undoes the process of DFT. It is also known as backward Fourier transform. It converts a space or time signal to a signal of the frequency domain. The DFT signal is generated by the distribution of value sequences to different frequency components. Working directly to convert on Fourier transform is computationally too expensive. So, Fast Fourier transform is used as it rapidly computes by factorizing the DFT matrix as the product of sparse factors. As a result, it reduces the DFT computation complexity from O(N2) to O(N log N). And this is a huge difference when working on a large dataset. Also, FFT algorithms are very accurate as compared to the DFT definition directly, in the presence of round-off error.

This transformation is a translation from the configuration space to frequency space and this is very important in terms of exploring both transformations of certain problems for more efficient computation and in exploring the power spectrum of a signal. This translation can be from xn to Xk. It is converting spatial or temporal data into the frequency domain data.

f(t)=\frac{1}{2 \pi} \int_{-\infty}^{\infty} F(x) e^{-i x t} d x

sympy.discrete.transforms.ifft() :
It can perform Inverse Discrete Fourier Transform (DFT) in the complex domain.
Automatically the sequence is padded with zero to the right because the radix-2 FFT requires the sample point number as a power of 2. For short sequences use this method with default arguments only as with the size of the sequence, the complexity of expressions increases.

 Parameters : 

-> seq : [iterable] sequence on which Inverse DFT is to be applied.
-> dps : [Integer] number of decimal digits for precision.

Returns : 
Fast Fourier Transform

Example 1:




# import sympy 
from sympy import ifft
  
# sequence 
seq = [15, 21, 13, 44]
  
# fft
transform = ifft(seq)
print ("Inverse FFT : ", transform)


Output:

Inverse FFT :  [93/4, 1/2 + 23*I/4, -37/4, 1/2 - 23*I/4]

Example 2:




# import sympy 
from sympy import ifft
  
# sequence 
seq = [15, 21, 13, 44]
  
decimal_point = 4
  
# fft
transform = ifft(seq, decimal_point )
print ("Inverse FFT : ", transform)


Output:

Inverse FFT :  [23.25, 0.5 + 5.75*I, -9.250, 0.5 - 5.75*I]
Dominic
Dominichttp://wardslaus.com
infosec,malicious & dos attacks generator, boot rom exploit philanthropist , wild hacker , game developer,
RELATED ARTICLES

Most Popular

Dominic
32269 POSTS0 COMMENTS
Milvus
81 POSTS0 COMMENTS
Nango Kala
6636 POSTS0 COMMENTS
Nicole Veronica
11802 POSTS0 COMMENTS
Nokonwaba Nkukhwana
11865 POSTS0 COMMENTS
Shaida Kate Naidoo
6752 POSTS0 COMMENTS
Ted Musemwa
7027 POSTS0 COMMENTS
Thapelo Manthata
6703 POSTS0 COMMENTS
Umr Jansen
6721 POSTS0 COMMENTS