decimate
Decimation — decrease sample rate by integer factor
Description
Examples
Input Arguments
Output Arguments
Algorithms
Decimation reduces the original sample rate of a sequence to a lower rate. It is the
opposite of interpolation. decimate lowpass filters the input to
guard against aliasing and downsamples the result. The function uses decimation
algorithms 8.2 and 8.3 from [1].
decimatecreates a lowpass filter. The default is a Chebyshev Type I filter designed usingcheby1. This filter has a normalized cutoff frequency of0.8/rand a passband ripple of 0.05 dB. Sometimes, the specified filter order produces passband distortion due to round-off errors accumulated from the convolutions needed to create the transfer function.decimateautomatically reduces the filter order when distortion causes the magnitude response at the cutoff frequency to differ from the ripple by more than 10–6.When the
"fir"option is chosen,decimateusesfir1to design a lowpass FIR filter with cutoff frequency1/r.When using the FIR filter,
decimatefilters the input sequence in only one direction. This conserves memory and is useful for working with long sequences. In the IIR case,decimateapplies the filter in the forward and reverse directions usingfiltfiltto remove phase distortion. In effect, this process doubles the filter order. In both cases, the function minimizes transient effects at both ends of the signal by matching endpoint conditions.Finally,
decimateresamples the data by selecting everyrth point from the interior of the filtered signal. In the resampled sequence (y),y(end)matchesx(end)when the IIR filter is used, andy(1)matchesx(1)when the FIR filter is used.
References
[1] Digital Signal Processing Committee of the IEEE® Acoustics, Speech, and Signal Processing Society, eds. Programs for Digital Signal Processing. New York: IEEE Press, 1979.


