FILTDOWN Function
Decimation filter realization.
Usage
result = FILTDOWN([h,] x, m)
Input Parameters
h—(optional) An FIR filter. (Default: H(z) = 1)
x—A one-dimensional array containing the signal.
m—(scalar) The decimation factor. The parameter m must be less than or equal to the length of x.
Returned Value
result—A one-dimensional array in double precision containing the filtered and down-sampled input sequence.
Keywords
Full—Directs FILTDOWN to call FIRFILT with the Full keyword. If present and nonzero, the entire result of the convolution of the input signal is returned, including the edge effects which are normally cut off.
Discussion
FILTDOWN is designed to only work with FIR filters.
FILTDOWN realizes the multirate signal processing operation of filtering followed by down-sampling (decimation) for finite impulse response (FIR) filters, H(z), as shown in Figure 2-2: FILTDOWN Operation.
 
Figure 2-2: FILTDOWN Operation
The down-sampling operation is given by the equation:
z(n) = y(Mn)
Example 1
Suppose x is an input signal of length 100. FILTDOWN is used to down-sample x, so that only every third point in the signal array is returned.
x = RANDOM(100)
PRINT, N_ELEMENTS(x)
; PV-WAVE prints: 100
newx = FILTDOWN(x, 3)
PRINT, N_ELEMENTS(newx)
; PV-WAVE prints: 34
Example 2
In this example, an FIR filter is applied to a signal, and only every third point is returned.
t = FINDGEN(100)/99
x = SIN(2*!Pi*t) + .4*RANDOM(100)
result = FILTDOWN(FILTSTR(FIRWIN(5), [1]), x, 3)
See Also
For Additional Information
Crochiere and Rabiner, 1975, 1976.
Proakis and Manolakis, 1988.
Vaidyanathan, 1993.