Ask a Question | Search DSPSR: |
Home
|
Public Member Functions |
Static Public Attributes |
Protected Member Functions |
Protected Attributes |
List of all members
dsp::OptimalFFT Class Reference Chooses the optimal FFT length for Filterbank and/or Convolution. More...
Inheritance diagram for dsp::OptimalFFT:
Detailed DescriptionChooses the optimal FFT length for Filterbank and/or Convolution. Member Function Documentation◆ get_nfft()
This method computes the optimal FFT length to use when performing multiple FFTs on a long time series. If FFT cost measurements are not available, this function assumes that the FFT is an O(NlogN) operation. GIVEN: nchan - number of channels into which data will be divided nfilt - filter length (points discarded from each FFT in each channel) RETURNS: The return value is the optimal FFT length, nfft Where ngood = nfft - nfilt, the following ideas are held: 1) performance is better if ngood is a large fraction of nfft, 2) FFT performance is much better with smaller nfft. The timescale for one FFT is proportional to NlogN, or: t = nfft * log(nfft) The number of FFTs performed on a segment of M time samples is: Nf = M / (nfft - nfilt) The total time spent on FFTs is then: T = t * Nf = nfft * log(nfft) * M/(nfft-nfilt) Where M may be considered constant, and nfilt is given, this function aims to minimize: T(nfft) = nfft * log(nfft) / (nfft-nfilt) The documentation for this class was generated from the following files:
Generated using doxygen 1.8.17
|