Moving Average Example
Fig. (b) Pole-Zero Diagram Fig. (c) Amplitude and phase responsesA moving average filter is a very simple FIR filter. It is sometimes called a boxcar filter, especially when followed by decimation. The filter coefficients, are found via the following equation:
To provide a more specific example, we select the filter order:
The impulse response of the resulting filter is:
The Fig. (a) on the right shows the block diagram of a 2nd-order moving-average filter discussed below. To discuss stability and spectral topics we take the z-transform of the impulse response:
Fig. (b) on the right shows the pole-zero diagram of the filter. Zero frequency (DC) corresponds to (1,0), positive frequencies advancing counterclockwise around the circle to (-1,0) at half the sample frequency. Two poles are located at the origin, and two zeros are located at, .
The frequency response, for frequency ω in radians per sample, is:
Fig. (c) on the right shows the magnitude and phase plots of the frequency response. Clearly, the moving-average filter passes low frequencies with a gain near 1, and attenuates high frequencies. This is a typical low-pass filter characteristic. Frequencies above π are aliases of the frequencies below π, and are generally ignored or filtered out if reconstructing a continuous-time signal. The following figure shows the phase response. Since the phase always follows a straight line except where it has been reduced modulo π radians (should be 2π), the linear phase property is demonstrated.
Read more about this topic: Finite Impulse Response
Famous quotes containing the words moving and/or average:
“O what venerable and reverend creatures did the aged seem! Immortal Cherubims! And young men glittering and sparkling Angels, and maids strange seraphic pieces of life and beauty! Boys and girls tumbling in the street, and playing, were moving jewels. I knew not that they were born or should die; but all things abided eternally as they were in their proper places.”
—Thomas Traherne (16361674)
“The average Kentuckian may appear a bit confused in his knowledge of history, but he is firmly certain about current politics. Kentucky cannot claim first place in political importance, but it tops the list in its keen enjoyment of politics for its own sake. It takes the average Kentuckian only a matter of moments to dispose of the weather and personal helath, but he never tires of a political discussion.”
—For the State of Kentucky, U.S. public relief program (1935-1943)