Y = fft(X) %computes the FFT of Vector or Matrix X using a default Transform Length of 256 (to be confirmed for version)
Y = fft(X,n) %computes the FFT of X using n as Transform Length, n must be a 2-power based number. If the length of X is less than n, then Matlab will automatically pad X with zeros such that length(X) = n
Y = fft(X,n,dim) %computes the FFT of X using n as Transform Length along dimension dim (can be 1 or 2 for horizontal or vertical respectively)
Y = fft2(X) % Compute the 2D FFT of X
Y = fftn(X, dim) % Compute the dim-dimensional FFT of X, with respect to the vector of dimensions dim.
y = ifft(X) %computes the Inverse of FFT of X (which is a matrix/vector of numbers) using the default 256 Transform Length
y = ifft(X,n) %computes the IFFT of X using n as Transform Length
y = ifft(X,n,dim) %computes the IFFT of X using n as Transform Length over dimension dim (can be 1 or 2 for horizontal or vertical respectively)
y = ifft(X,n,dim,'symmetric') %The Symmetric option causes ifft to treat X as conjugate symmetric along the active dimension. This option is useful when X is not exactly conjugate symmetric, merely because of round-off error.
y = ifft2(X) % Compute the inverse 2D ft of X
y= ifftn(X,dim) %Compute the inverse dim-dimensional fft of X.
Parameter | Description |
---|---|
X | this is your input Time-Domain signal, it should be a vector of numerics. |
n | this is the NFFT parameter known as Transform Length, think of it as resolution of your FFT result, it MUST be a number that is a power of 2 (i.e. 64,128,256...2^N) |
dim | this is the dimension you want to compute FFT on, use 1 if you want to compute your FFT in the horizontal direction and 2 if you want to compute your FFT in the vertical direction - Note this parameter is usually left blank, as the function is capable of detecting the direction of your vector. |
Matlab FFT is a very parallelized process capable of handling large amounts of data. It can also use the GPU to huge advantage.
ifft(fft(X)) = X
The above statement is true if rounding errors are omitted.