Has anyone written a fast Fourier transform extension for R that modifies R's native fft() function so that when you call for the inverse fast Fourier transform you don't have to divide by the length of the fast Fourier transform output? I'm doing a lot of FFTs and inverse FFTs and having to do this every time is getting annoying.
X = ifft( Y ) computes the inverse discrete Fourier transform of Y using a fast Fourier transform algorithm. X is the same size as Y . If Y is a vector, then ifft(Y) returns the inverse transform of the vector. If Y is a matrix, then ifft(Y) returns the inverse transform of each column of the matrix.
FFT (Fast Fourier Transform) is able to convert a signal from the time domain to the frequency domain. IFFT (Inverse FFT) converts a signal from the frequency domain to the time domain.
The transformation from the time domain to the frequency domain is reversible.
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.
You could write your own:
fftinv <- function( x ) { fft( x, inverse=TRUE ) / length( x ) }
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With