Digital Signal Processing Reference
In-Depth Information
consistent output, as rapid fluctuations are damped out. A
moving average filter is simply a filter with all the coefficients set
to 1. The more filter taps, the longer the averaging, and the more
smoothing takes place. This gives an idea of how a filter structure
can remove high frequencies, or rapid fluctuations. Now imagine
if the filter taps were alternating
and so on. A
slowly varying input signal will have adjacent samples nearly the
same, and these will cancel in the filter, resulting in a nearly zero
output. This filter is blocking low frequencies. On the other hand,
an input signal near the Nyquist rate will have big changes from
sample to sample, and will result in a much larger output. To get
a more precise handle on how to configure the coefficient values
to get the desired frequency response however, we need to use
a bit of math.
We will start by computing the frequency response of the filter
from the coefficients. Remember, the frequency response of the
filter is determined by the coefficients (also called the impulse
response).
Let's begin by trying to determine the frequency response of
a filter by measurement. Imagine if we take a complex expo-
nential signal of a given frequency, and use this as the input to our
filter. Then we measure the output. If the frequency of the
exponential signal is in the passband of the filter, it will appear at
the output. But if the frequency of the exponential signal is in the
stopband of the filter, it will appear at the output with a much
lower level than the input, or not at all. Imagine we start with
a very low frequency exponential input, and take this measure-
ment, then slightly increase the frequency of the exponential
input, measure again, and keep going until the exponential
frequency is equal to the Nyquist frequency. If we plot the level of
the output signal across the frequency from 0 to F Nyquist , we will
have the frequency response of the filter. It turns out that we
don't have to take all these measurements as we can compute this
fairly easily as shown below.
Let's review the last equation. It's just a sampled version of
a signal rotating around the unit circle. We sample at time
þ
1,
1,
þ
1,
1
.
¼
m,
y k ¼ P i¼0to4 C i x k-i
Output of our ve-tap example lter.
y k ¼ P i¼ - N to N C i x k-i
Same equation, except that we are
allowing an in nite number of
coef cients (no limits on lter length).
x m ¼ e jum
¼ cos(um) þ j
This is our complex exponential input at
u
sin(
u
m)
radians per sample.
Search WWH ::




Custom Search