Forum Discussion
Altera_Forum
Honored Contributor
11 years ago --- Quote Start --- Hi Kaz, The code: H_comp = [H_comp H_comp H_comp H_comp]; Does this line of code return the frequency response of the compensation FIR filter, performing additional decimation by 2? --- Quote End --- Not exactly. The frequency response of compensation filter is the line of freqz. Then I interpolated it back by 4 in the frequency domain (by repeating 4 copies) in order to compare it (and multiply) with cic filter at same Fs --- Quote Start --- Do you know how to calculate the impulse response of this decimat-by-2 FIR filter? --- Quote End --- impulse response is just: plot(h_comp); if you mean frequency response of impulse input then it is the freqz line. The z domain approach can also be used for both filters and overall system.