Low pass fir filter with non-unity gain

In my filter specs, the passband gain is given as 6.02db. How do I achieve this?

Usually all texts give the passband gain as 0db (as well as passband ripples if any).

As pointed out by niaren, you have to multiply by two, but this also means that your whole magnitude response is shifted up by 6dB, also in the stopbands. So you will have 6dB less stopband attenuation. Of course, the attenuation relative to the passband gain remains constant. You have to take this into account when designing your filter. Say you need 60dB stopband attenuation in absolute terms, not relative to the passband gain, then you need to design a 0dB gain filter with 66dB stopband gain. After multiplying the coefficients by 2 you'll get 6dB passband gain and 60dB stopband attenuation.

This simply means that you have a non-unity gain in the passband. The number 6.02 in decibels corresponds to a multiplicative gain factor of two. You can check it like so:

$$10^\tfrac{6.02}{20} = 2$$

All you have to do then is multiply all you FIR filter coefficients by 2.

• It should be $10^{\frac{6.02}{20}} = 2$ because we're talking dBs. – Matt L. Apr 25 '13 at 10:35
• @Matt You're absolutely right, thanks. I realized it as I was writing the answer and then forgot to fix it. Very eagle eyed of you! = ) – Phonon Apr 25 '13 at 10:38
• Just to make sure that we don't cause even more confusion ... :) – Matt L. Apr 25 '13 at 10:43

Just multiply your FIR coefficients by 2. You can verify your passband gain at DC by setting $z=1$ which amounts to just summing the coefficients.

• but if i multiply by 2, will it affect my other filter specs like transition region or passband/stopband ripples – saggy Apr 25 '13 at 6:28
• @saggy: It will shift your entire filter response up by 6 dB. It won't change the amount of ripple. – Jason R Apr 25 '13 at 12:39