Professional Documents
Culture Documents
This lter produces an output which is a scaled average of three successive inputs, with the centre point of the three weighted twice as heavily as its two adjacent neighbours.
2 43 1 !5# 3 687 ! 3 6 9 1 which has two zeroes at 3 9 !@# 3 ! 43 ! 1 9 i.e. 3 A& . Remember that this corresponds to a double damping at the Nyquist frequency. This will give
attenuation of HF signals i.e. a LPF effect. Alternatively we could argue to put a 71
(BDC)B 2 E3 1
of the way along the real axis. This gives 3 68 7 &F F & C C 3 3 687
and thus
which gives a LPF as a recurrent lter (which is thus an IIR lter). In general, we may use out knowledge of the Laplace design of transfer functions to argue the design in the z-domain as well. This is simple for low-order lters (as above), but would be tedious at higher orders there are other ways.
`Ya@bRc ed
#0b pDq q U rV X1tsvuIw0xgye `Y 6 aY f (6.1) bW`Y f The sampled impulse response h% (which would be obtained by taking the inverse DFT of the discrete equivalent brick-wall frequency characteristics) is the sampled version of the continuous W function. It is not possible to implement h f 1i
the corresponding low-pass lter design because: 72
gf 1
1 U WV X
Figure 6.1: Impulse response of brick wall lter in (left) continuous and (right) discrete time domains.
an innite number of coefcients would be required the impulse response is that of a non-causal system and .
(&
(1
h% exists between
g f i g h % Q 9ed % l&)m4 dkj for the lter, we can also obtain its transfer function g g U 43 1k f gn9eh d 36 dj As before, we can obtain the actual frequency response of the lter by evaluating U E3 1 on the unit circle (i.e. U s uIwpo 1 ). This is shown in Fig 6.3 using both
linear and logarithmic plots for the amplitude response. 73
This is shown in Fig 6.2. Now that we have the difference equation
1.2
10
0.8
0.6
10
0.4
10
2
0.2
/4
0 0 20
/4
40
60
80
100
120
140
10
20
40
60
80
100
120
140
Figure 6.3: Linear (left) and log (right) responses for 21 and 11 coefcients in the brick wall lter. Better solution The truncation of the impulse response is equivalent to multiplying it by a rectangular window function. This leads to an overshoot and ripple before and after the discontinuity in the frequency response a phenomenom known as Gibbs phenomenom (the overshoot is about 9% see previous Fig). The amplitude of the overshoot does not decrease if more and more coefcients are included in the digital lter. A more successful way of designing an FIR lter is to use a nite weighting sequence . There are a number of such sequences, for example the Hamming,
q %
74
C ! &FC1vuxw { &F|i}@~}| t q % sr 0 elsewhere yz If C@v this is the Hamming window, if C@v this is the Hanning, or raised
cosine, window. Fig 6.4 shows the 11 point Hamming window. The Fourier
1 0.8 0.6 w[k] 0.4 0.2 0 0
6 k
10
12
Figure 6.4: 11 point Hamming window. transform of these windows consists of a central lobe which contains most of the energy and side lobes which generally decay very rapidly. The use of such a window to reduce the Fourier coefcients for the higher frequency terms leads to a reduction in ripple amplitude, at the expense of a slightly worse initial cut-off slope. The frequency response of the 21-coefcient FIR lter Fig. 6.3 is shown in Fig. 6.5 together with that of the equivalent windowed ) using lter (the lter weights on this case being computed from a Hamming window.
hS% QhS% 4 q
1.4
1.2
/4
0.8
0.6
0.4
0.2
20
40
60
80
100
120
140
Figure 6.5: Hamming window removing overshoot. anti-symmetrical). FIR lters are mostly realised as non-recursive structures; such lters are always stable. However, if a sharp cut-off in the amplitude response is required, a large number of coefcients are needed (usually 100).
76
U s uew0o 1k
U s uIwpo 1
687 where d sampling period d # ! & 33 8 67 Under this mapping, the entire V axis in the -plane is mapped onto the unit circle in the 3 -plane; the left-half -plane is mapped inside the unit circle and the right-half -plane is mapped outside the unit circle. The bilinear transformation gives a non-linear relationship between analogue frequency ` and digital frequency ` . Since the frequency response of a digital lter is evaluated by setting 3 s uIwpo : V a #d F & s 6 uIweo d # s uIw o !Ps 6 Iu w o s uIw 99 o # ` ie. d$
77
The form of this non-linearity is shown in Fig. 6.6 for the case . For small values of , the mapping is almost linear; for most of the frequency scale, however, the mapping is highly non-linear.
d #
3.5 3 2.5
1.5
Figure 6.6: The bilinear mapping function. The cut-off frequencies of a digital lter will therefore be tangentially warped compared with those of the analogue lter from which it was designed. In order to compensate for this undesirable effect, it is necessary to pre-warp the required cut-off frequencies before designing the analogue lter. Thus
the desired set of digital lter cut-off frequencies is determined rst. For and ). example, if there are four critcial cut-off frequencies, Using the frequency warping relationship derived above, the lter cut-off frequencies are converted to a new set of analogue cut-off frequencies, and . Finally, an analogue lter is designed with the appropriate warped cut-off frequencies. Applying the bilinear transformation to this analogue lter gives a digital lter with the desired cut-off frequencies. 78
` 7 ` 9 `t
aI
a 7 ` 9 `I
ae
# v a 7 d #' v#pbve#e d # e( rads/sec ` 7 d5 v # #d v ` 9 d #' v v #0b@v rads/sec ` 9 # (ie. #" kHz and v kHz this shows the warping effect near 4 ) 7 9 9 The order of lter required can now be worked out as before: g h h w g h h7Ed e e E w g 7Ed7 7 meets the specication
U 1k 9 ! #pY9 `Y!) Y9 Substitute ` `Yk"# o 9 in above equation and use the bilinear transfor7 mation o 9 7e6 : 74 1 9 "# 9 9 k 1 o U 43 o 9 1 9 7e6 1 9 ! # o 9 1 9 v#e 7e6 e 1! o 9 1 9 v#e 1 9 74 74 e
79
(NB:
o 9 1 factor cancels out) v#ee 1 U E3 1 9 ! # 7e6 e 1!$v# 7e47 6 e 74 e # 3 687 ! 3 6 9 U E3 1kv#ee #"e&)v!5 # 3 687 !$vee 3 6 9 # 3 687 ! 3 6 9 U E3 1v#e &Fv !5 e 3 687 !$v e# 3 6 9
5 ! # ! 3 3 9 1 v e # e U E3 & ) v $ ! v 39 3 e# dc gain: ` d 3 which gives U 1 3dB cut-off frequency ` 7 d @v b Thus b! V " b1! x u w v b ! " b $ ! # x u w v V s u k 1 v # Udz W &)ve uw v b! V v bR1!Pv e# uxw "b! V vb W t V v # 5 ! " # s u k 1 @ v e # ie. U d which gives U~ ve & v # $ ! " e # e V z
80
U 43 1
You can also check the 30dB minimum attenuation requirement by working out .
s d z u 1
6.4.2 Conclusion
With recursive IIR lters, we can generally achieve a desired frequency response characteristic with a lter of lower order than for a non-recursive lter (especially if elliptic designs are used). A recursive lter has both poles and zeroes which can be selected by the designer, hence there are more free parameters than for a non-recursive lter of the same order (only zeroes can be varied). However, when the poles of an IIR lter are close to the unit circle, they need to be specied very accurately (typically 3 to 6 decimal places) if instability is to be avoided.
81