deerlab.fftspec#

fftspec(V, t, mode='abs', zerofilling='auto', apodization=True)[source]#

Computes the Fast-Fourier Transform (FFT) spectrum of the input signal V.

This function computes the FFT spectrum of the input signal V using the fft function from the numpy.fft module. The function allows to specify the type of spectrum to be returned, the zero-filling factor, and whether to apply a Hamming apodization window.

Parameters:
Varray_like

Signal to be processed.

tarray_like

Time axis, in microseconds.

modestring, optional

Type of spectrum to be returned ('real',``’imag’,’abs’), the default is ``'abs'.

zerofillingscalar or 'auto', optional

Number of elements in the output FFT spectrum, the default is 2*len(V).

apodizationboolean, optional

Use of a Hamming apodization window, the default is True.

Returns:
nundarray

Frequency axis, in megahertz

specndarray

FFT spectrum.