Filter Design Toolbox    
mfilt.firtdecim

Construct an mfilt object for decimation based on a direct-form transposed FIR filter structure

Syntax

Description

hm = mfilt.firtdecim(m) returns a polyphase decimator mfilt object hm based on a direct-form transposed FIR structure with a decimation factor of m. A low-pass Nyquist filter of gain 1 and cutoff frequency of /m is designed by default.

hm = mfilt.firtdecim(m,num) uses the coefficients specified by num for the decimation filter. num is a vector containing the coefficients of the transposed FIR lowpass filter used for decimation. If omitted, a low-pass Nyquist filter with gain equal to 1 and cutoff frequency of /m results by default.

Input Arguments

The following table describes the input arguments for creating hm.

Input Argument
Description
num
Vector containing the coefficients of the FIR lowpass filter used for interpolation. When num is not provided as an input, firtdecim uses a lowpass Nyquist filter with gain equal to l and cutoff frequency equal to /m by default.
m
Decimation factor for the filter. m specifies the amount to reduce the sampling rate of the input signal. It must be an integer. When you do not specify a value for m it defaults to 2.

mfilt.firtdecim Object Properties

Every multirate filter object has properties that govern the way it behaves when you use it. Note that many of the properties are also input arguments for creating mfilt.firtdecim objects.The next table describes each property for an mfilt.firtdecim filter object.

Name
Values
Description
FilterStructure
String
Reports the type of filter object, such as a decimator or fractional decimator. You cannot set this property--it is always read only and results from your choice of mfilt object
Numerator
Double vector
Vector containing the coefficients of the FIR lowpass filter used for decimation
DecimationFactor
Integer
Decimation factor for the filter. m specifies the amount to reduce the sampling rate of the input signal. It must be an integer
NonProcessedSamples
Double vector
Shows the values of the samples that were not processed during the filtering operation. Note that this is not the number of samples that were not processed
ResetBeforeFiltering
'off' or 'on'
Determine whether the filter states get restored to zero for each filtering operation
States
Double array
Filter states. states defaults to a vector of zeros that has length equal to nstates(hm)
NumSamplesProcessed
Integer
Returns the number of samples processed during filtering. As a check, the number of samples reported processed plus the number of nonprocessed samples should be the total number of input samples.

Examples

Demonstrate decimating an input signal be a factor of 2, in this case converting from 44.1 KHz down to 22.05 KHz.

See Also

mfilt.firdecim, mfilt.firfracdecim, mfilt.cicdecim, mfilt.cicdecimzerolat


  mfilt.firsrc mfilt.holdinterp 

Learn more about the latest releases of MathWorks products:

 © 1994-2009 The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS