Main Content

iirpeak

Second-order IIR peak or resonator filter

Description

[num,den] = iirpeak(w0,bw) returns a second-order digital peaking filter with the peak located at w0, and with the bandwidth at the +3 dB point set to bw.

[num,den] = iirpeak(w0,bw,ab) returns a digital peaking filter whose bandwidth, bw, is specified at a level of +ab decibels.

Examples

collapse all

Design and plot an IIR peaking filter that boosts the frequency at 1.75 KHz in a signal and has a bandwidth of 500 Hz at the –3 dB point. The peak filter has the desired gain and bandwidth at 1.75 KHz.

fs = 10000; 
wo = 1750/(fs/2);  
bw = 500/(fs/2);
[b,a] = iirpeak(wo,bw);
fvtool(b,a,Fs=fs)

Figure Figure 1: Magnitude Response (dB) contains an axes object. The axes object with title Magnitude Response (dB), xlabel Frequency (kHz), ylabel Magnitude (dB) contains an object of type line.

Input Arguments

collapse all

Peak frequency of the IIR filter, specified as a positive scalar in the range (0.0,1.0), where 1.0 corresponds to π radians per sample in the frequency range.

Data Types: single | double

Bandwidth of the filter at a level of +ab decibels, specified as a positive scalar in the range (0.0,1.0).

The quality factor (Q factor) q for the filter is related to the filter bandwidth by q = ω0 / bw where ω0 is the signal frequency to boost.

Data Types: single | double

Magnitude response at the filter bandwidth bw, specified as a scalar in dB. Including the optional input argument ab lets you specify the magnitude response bandwidth at a level that is not the default +3 dB point, such as +6 dB or 0 dB.

Data Types: single | double

Output Arguments

collapse all

Numerator coefficients of the second order IIR peak filter transfer function, returned as a real-valued three-element row vector.

Data Types: single | double

Denominator coefficients of the second order IIR peak filter transfer function, returned as a real-valued three-element row vector.

Data Types: single | double

References

[1] S.J.Orfanidis. Introduction To Signal Processing. Englewood Cliffs, New Jersey: Prentice-Hall, 1996.

Extended Capabilities

C/C++ Code Generation
Generate C and C++ code using MATLAB® Coder™.

Version History

Introduced in R2011a

See Also

Functions