Skip to main content
conventional notation.
Source Link

I have two filters which must apply (in series) to same input data x(n)$x[n]$ e.g of length 256 (real time asio input buffers). One filter is e.g. an IR f1impulse response $h_1[n]$ of a speaker and other one aan IR f2$h_2[n]$ of a lowpass (created by sinc, blackman). For simplicity lets say both are shorter than 256. 

So I zero pad all 3the input and both IRs to 512, FFT and then do: XF1F2$X[k]\cdot H_1[k]\cdot H_2[k]$, after this I do iFFT and use overlapp addoverlap-add to deal with the output vector of length 512. I do use a wrapped version of FFTW for performance reasons. FFTW tutorial says that doing fftFFT and afterwards ifftiFFT of a vector of length N$N$ produces an output vector which must be scaled by 1/N$\frac{1}{N}$.

My understanding problem here is, how do I have to scale? In the upper example I dontdon't just do FFT->IFFT$\to$iFFT, but I am doing FEW forward FFT of different filters, multiply them and do only ONEone backward iFFT.

I have two filters which must apply (in series) to same input data x(n) e.g of length 256 (real time asio input buffers). One filter is e.g. an IR f1 of a speaker and other one a IR f2 of a lowpass (created by sinc, blackman). For simplicity lets say both are shorter than 256. So I zero pad all 3 IRs to 512, FFT and then do: XF1F2, after this I do iFFT and use overlapp add to deal with the output vector of length 512. I do use a wrapped version of FFTW for performance reasons. FFTW tutorial says that doing fft and afterwards ifft of a vector of length N produces an output vector which must be scaled by 1/N.

My understanding problem here is, how do I have to scale? In the upper example I dont just do FFT->IFFT, but I am doing FEW forward FFT of different filters, multiply them and do only ONE backward iFFT.

I have two filters which must apply (in series) to same input data $x[n]$ e.g of length 256 (real time asio input buffers). One filter is e.g. an impulse response $h_1[n]$ of a speaker and other one an IR $h_2[n]$ of a lowpass (created by sinc, blackman). For simplicity lets say both are shorter than 256. 

So I zero pad the input and both IRs to 512, FFT and then do: $X[k]\cdot H_1[k]\cdot H_2[k]$, after this I do iFFT and use overlap-add to deal with the output vector of length 512. I do use a wrapped version of FFTW for performance reasons. FFTW tutorial says that doing FFT and afterwards iFFT of a vector of length $N$ produces an output vector which must be scaled by $\frac{1}{N}$.

My understanding problem here is, how do I have to scale? In the upper example I don't just do FFT$\to$iFFT, but I am doing FEW forward FFT of different filters, multiply them and do only one backward iFFT.

Source Link
f.f
  • 101
  • 3

Scaling issue after doing manipulations in FFT

I have two filters which must apply (in series) to same input data x(n) e.g of length 256 (real time asio input buffers). One filter is e.g. an IR f1 of a speaker and other one a IR f2 of a lowpass (created by sinc, blackman). For simplicity lets say both are shorter than 256. So I zero pad all 3 IRs to 512, FFT and then do: XF1F2, after this I do iFFT and use overlapp add to deal with the output vector of length 512. I do use a wrapped version of FFTW for performance reasons. FFTW tutorial says that doing fft and afterwards ifft of a vector of length N produces an output vector which must be scaled by 1/N.

My understanding problem here is, how do I have to scale? In the upper example I dont just do FFT->IFFT, but I am doing FEW forward FFT of different filters, multiply them and do only ONE backward iFFT.