Czy wolisz polską wersję strony elektroda?
Nie, dziękuję Przekieruj mnie tamfir filter
• A Finite-Impulse-Response (FIR) filter is a discrete-time, non-recursive digital filter whose output is the weighted sum of a finite number of present and past input samples.
• Key points
– Always BIBO-stable (all poles at the origin)
– Can be made exactly linear-phase by imposing symmetry on the coefficients
– Implemented as a tapped-delay line performing a convolution between the input sequence and a fixed set of coefficients (“taps”)
Mathematical model
Given an input sequence \(x[n]\) and an \(M\)-tap impulse response \(h[k]\)\,( \(k=0,\dots ,M-1\) ), the output is
\[
y[n] \;=\; \sum{k=0}^{M-1} h[k]\;x[n-k]
\]
• Z-domain transfer function: \(H(z)=\sum{k=0}^{M-1}h[k]\,z^{-k}\). All poles are at \(z=0\).
• Frequency response on the unit circle: \(H(e^{j\omega}) = \sum_{k=0}^{M-1} h[k]\,e^{-j\omega k}\).
Phase properties
• Even symmetry ( \(h[k]=h[M-1-k]\) ) → linear phase with an integer delay of \((M-1)/2\) samples.
• Odd symmetry → linear phase with a \(\pi/2\) phase offset (useful for differentiators, Hilbert transformers).
Design methodologies (classical)
a) Windowed-sinc (truncation + window: Hamming, Kaiser, etc.) – intuitive, analytical filter-length formulae.
b) Frequency-sampling – specify \(H(e^{j\omega})\) on a grid, apply IDFT.
c) Parks–McClellan (Remez / equiripple) – minimax-optimal magnitude error; sharpest transition for a given order.
d) Least-squares and constrained least-squares – minimise RMS error with optional weighting.
e) Convex-optimisation and linear-matrix-inequality (LMI) methods – arbitrary magnitude + phase constraints.
Implementation structures
• Direct form (FIR transpose) – one multiply per tap, highly pipelinable; suited to DSP blocks and SIMD.
• Polyphase decomposition – essential for multirate (decimation / interpolation) systems; reduces multiplications by a factor ≈ interpolation / decimation ratio.
• FFT overlap-save / overlap-add – for long filters in the frequency domain, \(O(N\log N)\) instead of \(O(MN)\).
• Half-band optimisation – every other coefficient zero except centre tap.
Quantisation and hardware aspects
• Coefficient word-length strongly influences stop-band attenuation; use canonic-signed-digit (CSD) or power-of-two coefficients for multiplier-free ASICs.
• Round-off noise does not accumulate (no feedback), but truncation degrades magnitude ripple; dither when necessary.
• FPGA/ASIC realisation: exploit coefficient symmetry (2x MAC reuse), DSP48 chain, and block-RAM for coefficient storage.
Comparison with IIR
| Item | FIR | IIR |
|—|—|—|
| Stability | Unconditionally stable | Must place poles inside unit circle |
| Phase | Exactly linear (if desired) | Generally non-linear |
| Order for same transition | Higher | Lower |
| Arithmetic sensitivity | Low | High (pole-zero cancellation) |
| Computational delay | \(= (M-1)/2\) samples | Often smaller |
• Ultra-long FIRs (10 k–100 k taps) are now practical on FPGAs using time-multiplexed DSP slices and block-floating-point.
• 5 G / Wi-Fi 7 front-ends employ polyphase channelisation (N-point DFT filter banks) instead of single-band FIRs.
• AI-assisted design (e.g., Bayesian optimisation over Parks–McClellan initial seeds) accelerates coefficient search for very tight pass/stop specifications.
• Audio plug-ins increasingly ship with partitioned convolution: small low-latency FIR for early taps + large FFT part for the tail.
• Embedded ARM-Cortex-M devices use CMSIS-DSP FIR kernels with optional Helium/SIMD acceleration; typical throughput > 50 MS/s for 64-tap filters at 160 MHz.
Example: 0.2 Fs low-pass design via Kaiser window
Practical tip: verify in MATLAB/Octave
N = 148; % order
fc = 0.2; % normalised
beta = kaiserbeta(60); % helper function
b = fir1(N,fc,kaiser(N+1,beta),'noscale');
freqz(b,1,2048);
• FIR filters are routinely used for content redaction (e.g., removing specific frequencies in intercepted communications). Misuse for covert surveillance raises privacy concerns; regulations such as GDPR and FCC Part 15 may restrict certain signal-processing activities.
• Medical devices using FIR-based ECG/EEG filtering must comply with IEC 60601 and FDA guidelines to avoid diagnostic distortion (linear phase requirement often mandated).
firpmord
. Potential challenges & mitigations
• Excessive order ⇒ switch to multi-rate + polyphase.
• Latency constraints ⇒ try minimum-phase FIR (via spectral factorisation) or hybrid FIR/IIR.
• Exact linear phase costs half the filter order in latency; unacceptable for servo-control loops < 1 ms.
• High-resolution (≥100 dB) stop-bands demand > 16-bit coefficients; may exceed low-cost MCU capability.
• Sparse FIR optimisation exploiting compressive-sensing techniques for low-power IoT DSP.
• Adaptive FIRs with FPGA-based LMS/RLS for active noise cancellation in EV cabins.
• Mixed-precision implementations (int8 coefficients + float32 accumulators) on AI accelerators.
• Exploration of neural-network-trained convolution kernels as “non-linear-phase FIR equivalents”.
Recommended resources
• Mitra, “Digital Signal Processing: A Computer-Based Approach”, 4 th ed.
• Crochiere & Rabiner, “Multirate Digital Signal Processing”.
• IEEE Std 1057-2017, “Digitising Waveform Recorder Instrumentation”.
A FIR filter realises discrete convolution with a finite set of coefficients, guaranteeing stability and enabling exact linear-phase operation. Design methods range from simple windowing to optimal equiripple techniques, while modern trends leverage polyphase structures, FFT convolution, and AI-assisted optimisation to meet stringent bandwidth, latency, and power targets in applications from 5 G radios to audio plug-ins. Understanding specification trade-offs, coefficient quantisation, and implementation constraints is essential for delivering robust, regulation-compliant filtering solutions.