Implementing a low-pass FIR filter, when do you need to use FFT and IFFT instead of time-domain convolution?
The goal is to achieve the smallest processor time required for real-time calculations. As I know, FFT has O (n log n) complexity, but time-domain convolution has O (nΒ²) complexity. To implement a low-pass filter in the frequency domain, you need to use FFT, then multiply each value with filter coefficients (which are translated into the frequency domain), and then do IFFT.
So the question is, when is it justifiable to use frequency filtering (FFT + IFFT) instead of using a direct convolution-based FIR filter? Say, if you have 32 fixed-point ratios, should you use FFT + IFFT or not? What about 128 odds? And so on...
Trying to optimize the existing source code (based on convolution based on the FIR filter), I'm completely confused, either I have to use FFT, or just optimize it to use SSE or not.
c math fft audio signal-processing
psihodelia
source share