polyphase

Polyphase decomposition of multirate filter

Syntax

p = polyphase(hm)
polyphase(hm)
p = polyphase(hs)
p = polyphase(hs,Name,Value)
polyphase(hs)

Description

p = polyphase(hm) returns the polyphase matrix p of the multirate filter hm.

polyphase(hm) launches the Filter Visualization Tool (FVTool) with all the polyphase subfilters to allow you to analyze each component subfilter individually.

p = polyphase(hs) returns the polyphase matrix p of the multirate filter System object™ hs.

p = polyphase(hs,Name,Value) returns the polyphase matrix p of the multirate filter System object hs.

polyphase(hs) launches the Filter Visualization Tool (FVTool) with all the polyphase subfilters to allow you to analyze each component subfilter individually.

Input Arguments

expand all

hm

Multirate mfilt filter object. CIC-based filters do not have coefficients, so the function does not support CIC filter structures such as mfilt.cicdecim.

hs

Filter System object.

The following Filter System objects are supported by this analysis function:

Filter System objects
dsp.FIRInterpolator
dsp.FIRDecimator
dsp.FIRRateConverter

Name-Value Pair Arguments

Specify optional comma-separated pairs of Name,Value arguments. Name is the argument name and Value is the corresponding value. Name must appear inside single quotes (' '). You can specify several name and value pair arguments in any order as Name1,Value1,...,NameN,ValueN.

'Arithmetic' — Value types:‘double' | 'single' | 'fixed'

For filter System object inputs only, specify the arithmetic used during analysis. When you specify 'double' or 'single', the function performs double- or single-precision analysis. When you specify 'fixed' , the arithmetic changes depending on the setting of the CoefficientDataType property and whether the System object is locked or unlocked.

 Details for Fixed-Point Arithmetic

When you do not specify the arithmetic for non-CIC structures, the function uses double-precision arithmetic if the filter System object is in an unlocked state. If the System object is locked, the function performs analysis based on the locked input data type. CIC structures only support fixed-point arithmetic.

Output Arguments

p

Polyphase matrix p of the multirate filter. Each row in the matrix represents one subfilter of the multirate filter. The first row of matrix p represents the first subfilter, the second row the second subfilter, and so on to the last subfilter.

Examples

When you create a multirate filter that uses polyphase decomposition, polyphase lets you analyze the component filters individually by returning the components as rows in a matrix.

First, create an interpolate-by-eight filter.

hm=mfilt.firinterp(8)
 
hm =
 
         FilterStructure: 'Direct-Form FIR Polyphase Interpolator'
               Numerator: [1x192 double]
     InterpolationFactor: 8
        PersistentMemory: false
                  States: [23x1 double]

In this syntax, the matrix p contains all of the subfilters for hm, one filter per matrix row.

p=polyphase(hm)

p =

  Columns 1 through 8 

         0         0         0         0         0         0         0         0
   -0.0000    0.0002   -0.0006    0.0013   -0.0026    0.0048   -0.0081    0.0133
   -0.0001    0.0004   -0.0012    0.0026   -0.0052    0.0094   -0.0160    0.0261
   -0.0001    0.0006   -0.0017    0.0038   -0.0074    0.0132   -0.0223    0.0361
   -0.0002    0.0008   -0.0020    0.0045   -0.0086    0.0153   -0.0257    0.0415
   -0.0002    0.0008   -0.0021    0.0045   -0.0086    0.0151   -0.0252    0.0406
   -0.0002    0.0007   -0.0018    0.0038   -0.0071    0.0124   -0.0205    0.0330
   -0.0001    0.0004   -0.0011    0.0022   -0.0041    0.0072   -0.0118    0.0189

  Columns 9 through 16 

         0         0         0         0    1.0000         0         0         0
   -0.0212    0.0342   -0.0594    0.1365    0.9741   -0.1048    0.0511   -0.0303
   -0.0416    0.0673   -0.1189    0.2958    0.8989   -0.1730    0.0878   -0.0527
   -0.0576    0.0938   -0.1691    0.4659    0.7814   -0.2038    0.1071   -0.0648
   -0.0661    0.1084   -0.2003    0.6326    0.6326   -0.2003    0.1084   -0.0661
   -0.0648    0.1071   -0.2038    0.7814    0.4659   -0.1691    0.0938   -0.0576
   -0.0527    0.0878   -0.1730    0.8989    0.2958   -0.1189    0.0673   -0.0416
   -0.0303    0.0511   -0.1048    0.9741    0.1365   -0.0594    0.0342   -0.0212

  Columns 17 through 24 

         0         0         0         0         0         0         0         0
    0.0189   -0.0118    0.0072   -0.0041    0.0022   -0.0011    0.0004   -0.0001
    0.0330   -0.0205    0.0124   -0.0071    0.0038   -0.0018    0.0007   -0.0002
    0.0406   -0.0252    0.0151   -0.0086    0.0045   -0.0021    0.0008   -0.0002
    0.0415   -0.0257    0.0153   -0.0086    0.0045   -0.0020    0.0008   -0.0002
    0.0361   -0.0223    0.0132   -0.0074    0.0038   -0.0017    0.0006   -0.0001
    0.0261   -0.0160    0.0094   -0.0052    0.0026   -0.0012    0.0004   -0.0001
    0.0133   -0.0081    0.0048   -0.0026    0.0013   -0.0006    0.0002   -0.0000

Finally, using polyphase without an output argument opens the Filter Visualization Tool, ready for you to use the analysis capabilities of the tool to investigate the interpolator hm.

polyphase(hm)

In the following figure, FVTool shows the magnitude responses for the subfilters.

See Also

Was this topic helpful?