FIR Filter Calculator

Design FIR taps quickly for lowpass, highpass, bandpass needs. Estimate cutoff, ripple, delay, response accurately. Visualize coefficients, attenuation, transition width, and frequency curves instantly.

Calculator Inputs

Example Data Table

Use Case Filter Type Sample Rate Taps Window Cutoff Setup
Audio smoothing Lowpass 48,000 Hz 51 Hamming 5,000 Hz
Sensor drift removal Highpass 1,000 Hz 61 Hann 10 Hz
Speech band isolation Bandpass 16,000 Hz 81 Blackman 300 Hz to 3,400 Hz
Narrow interference rejection Bandstop 44,100 Hz 101 Bartlett 950 Hz to 1,050 Hz

Formula Used

The calculator uses the windowed-sinc FIR design method. First, it builds an ideal impulse response. Then it multiplies that response by the chosen window to control ripple and transition behavior.

1) Ideal lowpass impulse response

h_d[n] = 2fc/fs when n = M

h_d[n] = sin(2πfc(n-M)/fs) / (π(n-M)) when n ≠ M

2) Other filter types

Highpass = δ[n-M] - Lowpass

Bandpass = Lowpass(fc2) - Lowpass(fc1)

Bandstop = δ[n-M] - Bandpass

3) Windowed coefficient

h[n] = h_d[n] × w[n]

4) Group delay for linear-phase FIR

Delay = (N - 1) / 2 samples

5) Frequency response

H(e^jω) = Σ h[n]e^(-jωn)

The plotted magnitude response is shown in dB using 20 log10(|H|).

How to Use This Calculator

  1. Select the required FIR type: lowpass, highpass, bandpass, or bandstop.
  2. Enter the sample rate for your digital system.
  3. Choose an odd number of taps for symmetric linear-phase behavior.
  4. Enter the primary cutoff. Add a secondary cutoff for band filters.
  5. Select a window to balance sidelobe suppression and transition width.
  6. Set passband gain and decide whether normalization should be enabled.
  7. Click the calculate button to view coefficients, delay, charts, and export options.

FAQs

1) What are FIR taps?

Taps are the filter coefficients. More taps usually create a sharper transition and better selectivity, but they also add delay and computational cost. Symmetric taps give predictable linear-phase behavior.

2) Why does the calculator prefer odd taps?

Odd taps keep the filter centered on one sample. That symmetry simplifies linear-phase design and makes delay equal to half the order. It also avoids some edge issues for practical highpass and bandstop designs.

3) What does the window choice change?

The window changes ripple, sidelobe level, and transition width. Hamming is a balanced default. Blackman gives stronger attenuation but a wider transition. Rectangular is narrowest, yet produces the most sidelobes.

4) What is group delay in an FIR filter?

Group delay is the time shift applied to the filtered signal. For symmetric FIR filters, delay stays almost constant across frequency. That is valuable when waveform shape and timing consistency matter.

5) Why are my bandpass or bandstop cutoffs rejected?

The second cutoff must be larger than the first and both must stay below Nyquist, which is half the sample rate. Reversing them or exceeding Nyquist makes the design physically invalid.

6) What does normalization do?

Normalization rescales the coefficients so the chosen passband target is closer to the requested gain. That helps the designed filter match intended amplitude at DC, Nyquist, or band center, depending on type.

7) Why is the transition width only estimated?

Transition width depends on taps, cutoff placement, and window behavior. This tool uses common window-based approximations for quick design guidance. Exact response is still shown in the plotted frequency curve.

8) When should I increase the tap count?

Increase taps when you need a narrower transition band, stronger separation, or closer agreement with an ideal response. Keep in mind that larger filters cost more processing and increase group delay.

Related Calculators

db to linearpeak to rmsband stop filterfrequency response plotterhigh pass filternoise power calculatorband pass filterdeconvolution calculatoriir filter calculatordigital filter designer

Important Note: All the Calculators listed in this site are for educational purpose only and we do not guarentee the accuracy of results. Please do consult with other sources as well.