void NotchFilter(double NotchFrequency, double r, TVec *Num, TVec *Den, double FS = 2);
Design a second-order IIR notch (band-reject) filter.
Remarks:
Builds the transfer function of a notch that rejects NotchFrequency and stores it in num (numerator) and den (denominator) for use with IirInit / IirFilter. With a = 2pi NotchFrequency/FS the coefficients are
H(z) = (1 - 2cos(a) z^(-1) + z^(-2))/(1 - 2rcos(a) z^(-1) + r^2 z^(-2))
The numerator places a zero exactly on the unit circle at e^(+/- j a) so the gain at the notch frequency is 0; the pole radius r (just inside the unit circle) sets the notch width and depth - r closer to 1 gives a narrower, deeper notch and a longer transient. Domain: and 0 < NotchFrequency < FS/2; values outside these ranges raise an exception. FS is the sampling frequency (default 2).
Declared in Dew::Signal::Units::SignalUtils · Dew.Signal/Units.SignalUtils.h · Cross-compiler