FIR Filter Tap Count and Cutoff Calculator
Estimate how many taps a low-pass FIR filter needs to hit your passband, stopband, and attenuation targets.
🎚️ What is FIR Filter Tap Count?
FIR filter tap count (also called filter order or filter length) is the number of coefficients in a Finite Impulse Response digital filter. Each tap multiplies a delayed copy of the input signal by a coefficient and sums the results, so more taps mean a longer computation per sample but a sharper, more selective frequency response.
Designers use tap count estimation constantly: audio engineers building anti-aliasing filters before downsampling, communications engineers shaping pulse trains before transmission, and embedded developers budgeting CPU cycles for a real-time filter all need to know roughly how many taps a design will need before writing any code. Getting this estimate early avoids discovering, after a full design cycle, that a filter needs thousands of taps and won't run in real time on the target hardware.
A common misconception is that cutoff frequency alone determines tap count. It does not. Tap count is driven primarily by the transition bandwidth (the gap between the passband and stopband edges) and the desired stopband attenuation. A filter with a very sharp cutoff (narrow transition band) needs far more taps than one with a gentle roll-off, even if both share the same nominal cutoff frequency.
This calculator uses the Kaiser window method, a widely used empirical formula, to estimate the number of taps needed for a given passband edge, stopband edge, sampling rate, and stopband attenuation target, along with the ideal cutoff frequency and the Kaiser window's shape parameter (beta).
📐 Formula
📖 How to Use This Calculator
Steps
💡 Example Calculations
Example 1 — Audio Anti-Alias Low-Pass Filter
fs = 8,000 Hz, passband = 1,000 Hz, stopband = 1,200 Hz, 60 dB attenuation
Example 2 — High-Rate Anti-Alias Filter Before Decimation
fs = 44,100 Hz, passband = 15,000 Hz, stopband = 17,000 Hz, 80 dB attenuation
Example 3 — Low-Rate Sensor Smoothing Filter
fs = 1,000 Hz, passband = 100 Hz, stopband = 150 Hz, 40 dB attenuation
❓ Frequently Asked Questions
🔗 Related Calculators
How do you estimate the number of taps for an FIR filter?
Use the Kaiser formula: N = (A - 7.95) x fs / (14.36 x delta f), where A is the desired stopband attenuation in dB, fs is the sampling rate, and delta f is the transition bandwidth (stopband edge minus passband edge). Round the result up to the next odd integer for a symmetric linear-phase filter.
What is transition bandwidth in an FIR filter?
Transition bandwidth is the frequency gap between the passband edge (where the filter must still pass signal at full strength) and the stopband edge (where the filter must have suppressed the signal to the target attenuation). A narrower transition band always demands more taps.
Why does a narrower transition band require more taps?
A sharper cutoff (narrower transition band) approximates an ideal brick-wall filter more closely, which mathematically requires a longer impulse response (more taps) to represent. Tap count is inversely proportional to transition bandwidth in the Kaiser estimate, so halving the transition band roughly doubles the tap count.
What is the Kaiser window beta parameter?
Beta (β) is a shape parameter for the Kaiser window that controls the trade-off between main lobe width and side-lobe (stopband ripple) suppression. It is computed directly from the target stopband attenuation: higher attenuation targets require a larger beta, which widens the window's main lobe and adds more taps.
What cutoff frequency should I use for my FIR design?
A common practical choice is the midpoint of the passband and stopband edges, fc = (f_pass + f_stop) / 2. This calculator reports that midpoint cutoff as a starting point for windowed-sinc or Kaiser-window FIR design functions that expect a single cutoff frequency.
Is the Kaiser tap count formula exact?
No, it is a well-established empirical approximation (from Kaiser's 1974 windowing method), accurate enough for initial design but not exact. Always verify the actual frequency response of the designed filter and adjust the tap count up or down if the ripple or attenuation misses the target.
Why must the tap count be odd?
An odd tap count produces a Type I linear-phase FIR filter with a symmetric impulse response, giving an integer group delay of (N-1)/2 samples. Even tap counts (Type II) work for low-pass filters too, but odd is the conventional default for a simple, well-behaved linear-phase design.
How does sampling rate affect the required tap count?
Tap count scales directly with sampling rate for a fixed transition bandwidth in Hz. Doubling the sampling rate while keeping the same absolute transition bandwidth (in Hz) roughly doubles the required tap count, because the transition band now represents a smaller fraction of the total spectrum.
What does 'stopband attenuation' mean in FIR filter design?
Stopband attenuation is how much the filter suppresses signal energy beyond the stopband edge, expressed in decibels. A 60 dB target means stopband content is reduced to about 0.1% of its original amplitude; 80 dB means about 0.01%, a stricter and more tap-hungry requirement.
Can this formula be used for high-pass or band-pass filters?
The Kaiser tap-count formula is derived for low-pass prototypes but works as a reasonable order estimate for high-pass, band-pass, and band-stop FIR filters too, since it is really driven by the narrowest transition band in the design, not by which side is passed or stopped.