Main Content

getFilter

Return biquad filter object with design parameters set

Description

example

biquad = getFilter(obj) returns a dsp.BiquadFilter object, biquad. The SOSMatrix and ScaleValues properties of the biquad filter object are set as specified by the obj System object™.

Use getFilter for the design capabilities of the obj System object and the processing capabilities of the dsp.BiquadFilter System object.

Examples

collapse all

Create an octaveFilter System object™. Call getFilter on your object to return a dsp.BiquadFilter object with design parameters specified by your octaveFilter System object.

octFilt = octaveFilter;
biquad = getFilter(octFilt)
biquad = 
  dsp.SOSFilter with properties:

            Structure: 'Direct form II transposed'
    CoefficientSource: 'Property'
            Numerator: [3x3 double]
          Denominator: [3x3 double]
       HasScaleValues: false

  Use get to show all properties

Create a weightingFilter System object™.

weightFilt = weightingFilter;

Call getFilter on your object to return a dsp.BiquadFilter object with design parameters specified by your weightingFilter System object. Use fvtool to visualize the biquad filter.

biquad = getFilter(weightFilt)
biquad = 
  dsp.SOSFilter with properties:

            Structure: 'Direct form II transposed'
    CoefficientSource: 'Property'
            Numerator: [3x3 double]
          Denominator: [3x3 double]
       HasScaleValues: true
          ScaleValues: [4x1 double]

  Use get to show all properties

fvtool(biquad,'FrequencyScale','log')

Figure Figure 1: Magnitude Response (dB) contains an axes object. The axes object with title Magnitude Response (dB), xlabel Normalized Frequency ( times pi blank rad/sample), ylabel Magnitude (dB) contains an object of type line.

Input Arguments

collapse all

System object that you want to get a biquad filter object from.

Output Arguments

collapse all

Version History

Introduced in R2016b