Second-order tunable notching and peaking IIR filter
The NotchPeakFilter
object filters each channel of the
input using IIR filter implementation.
To filter each channel of the input:
Create the dsp.NotchPeakFilter
object and set its properties.
Call the object with arguments, as if it were a function.
To learn more about how System objects work, see What Are System Objects?.
returns a
second-order notching and peaking IIR filter that independently filters each channel of
the input over time, using a specified center frequency and 3 dB bandwidth.npFilter
= dsp.NotchPeakFilter
npFilter = dsp.NotchPeakFilter('Specification','Quality
factor and center frequency')
specifies the quality factor (Q factor) of the notch or peak filter instead of the
3
dB bandwidth.
npFilter = dsp.NotchPeakFilter('Specification','Coefficients')
specifies the coefficient values that affect bandwidth and center frequency directly,
rather than specifying the design parameters in Hz. This removes the trigonometry
calculations involved when the properties are tuned.
npFilter = dsp.NotchPeakFilter(
returns a notch filter with each specified property name set to the specified value.
Unspecified properties have default values.Name,Value
)
To use an object function, specify the
System object™ as the first input argument. For
example, to release system resources of a System object named obj
, use
this syntax:
release(obj)
The design equation for the peak filter is:
The design equation for the notch filter is:
with
where ω0 = 2πf0/fs is the center frequency in radians/sample (f0 is the center frequency in Hz and fs is the sampling frequency in Hz). Δω = 2πΔf/fs is the 3 dB bandwidth in radians/sample (Δf is the 3 dB bandwidth in Hz). Note that the two filters are complementary:
The filter is implemented as follows:
where
Notice that Gcf depends only on the center frequency, and G3dB depends only on the 3 dB bandwidth.
[1] Orfanidis, Sophocles J. Introduction to Signal Processing. Upper Saddle River, NJ: Prentice-Hall, 1996.