Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
H ( e j )
N
Li z i
H (z) = i=0
M
1+ i=
K i z i
Filter specification in terms
of amplitude response and Transfer function
error tolerance
Advantages:
- Decades of experiences in designing analog filters
- Typical less complex (fewer registers, arithmetic units) than
FIR in realizing the design filter spectrum
Advantages:
- Advantages of any FIR filter : always stable, linear phase
- Optimal CAD method (not covered in this class)
General procedure:
1. Design an analog filter Ha(s) that satisfies the specification.
2. Map the analog filter Ha(s) into a discrete-time filter Hd(z)
Page 9-1
EE 422G Notes Instructor: Cheung
ya(t) ya(nT)
y(nT)
x(nT) y(nT)
H(z)
Goal: for a GIVEN x(t), we want the output of our digital filter y(nT) to be
identical to the sampled version ya(nT) of the continuous-time filter output.
0.5( s + 4)
Example: Given H a ( s ) =
( s + 1)( s + 2)
Page 9-2
EE 422G Notes Instructor: Cheung
Step 6: Finally choose a sampling period T and obtain the numerical representation
of the digital filter.
Page 9-3
EE 422G Notes Instructor: Cheung
1.4
1.2
1
Amplitude Response
0.8
0.6
0.4
0.2
0
0 10 20 30 40 50 60 70 80 90 100
Frequency (rad/s)
Frequency (Hz)
Ans: The FT of the discrete filter is periodic with period 2fs=2(10) 63 rad/s.
If your client cannot stomach the divergence starting at 30Hz, what should you do?
1.8
1.6
Important: We cannot use
invariance method to design
1.4 any non band-limited filter
Amplitude Response
0.2
0
0 2 4 6 8 10
Frequency (Hz)
Page 9-4
EE 422G Notes Instructor: Cheung
Lets say you have a low-pass analog filter with cutoff frequency (-3dB frequency)
at 1 rad/s as follows:
1
H ( s) =
( s + 1)( s 2 + s + 1)
To design a HIGH-PASS filter with cutoff frequency at p, we use the following
transformation:
' = p or equivalently s ' = p
s
1 s3
Let p=2, H HP ( s ) = =
2 2 2
2
( s + 2)( s 2 + 2 s + 4)
+ 1 + + 1
s s s
0.8
Amplitude Response
0.6
0.4
==0 =0=
0.2
0
0 2 4 6 8 10
Frequency (rad/s)
Page 9-5
EE 422G Notes Instructor: Cheung
CTFT extends from negative infinity to positive infinity, while DTFT is periodic
with period equal to the sampling frequency (2/T). To ELIMINATE ALIASING,
we need to come up with a frequency transform f such that
0.5 s =
1
T
c
0.5
-0.5
-1 0.5 s =
T
-1.5
-2
-5 0 5
When c is small (-1 c 1), the distortion is relatively small and we have
2
d c
T
Beyond that, the transformation compresses c causing a fair amount of distortion.
Page 9-6
EE 422G Notes Instructor: Cheung
Proof:
1 e jd T
jc = C
1 + e jd T
d T d T
1 e j 2
e j 2
=C d T d T
1 + e j 2
e j 2
d T d T
ej 2
e j 2
=C d T d T
e j 2 + e j 2
2 j sin(d T 2 )
=C d T
= Cj tan (d T 2 )
2 cos( 2 )
c = C tan (d T 2 )
d = 2 T arctan (c C )
Solving C:
c
C= = 229168.76
c T
tan
2
0.292893 + 0.585786 z 1 + 0.292893z 2
H d ( z) =
1 + 0.171573z 2
Page 9-7
EE 422G Notes Instructor: Cheung
0
4. Delay hnc (nT ) to make it casual.
Page 9-8
EE 422G Notes Instructor: Cheung
1
Example: Design a FIR filter that approximates H ( r ) = (1 + cos 2 r )
2
Solution:
1 1/ 2
Compute hd ( nT ) = (1 + cos 2r )e jn 2r dr
2 1 / 2
1 1/ 2 1 1/ 2 1 1/ 2 1
For n = 0, dh ( 0 ) = (1 + cos 2r ) dr = dr + cos 2rdr =
2 1 / 2 2 1 / 2 2 1 / 2 2
For n 0 ,
1 1 / 2 jn 2 r 1 1/ 2 e j 2 r + e j 2 r j 2nr
hd ( nT ) = e dr + e dr
2 1/ 2 2 1 / 2 2
1 1/ 2 1 1/ 2 1
= e j 2 ( n +1) r dr + e j 2 ( n 1) r dr = for n = 1 and 0 otherwise
4 1 / 2 4 1/ 2 4
1 j 2 r 1 1 j 2 r
H ( r ) =
n =
hd ( nT ) e j 2n r
=
4
e + + e
2 4
h (0) = 1 , h ( T ) =
1
, hd (nT ) = 0, | n | 2
d
2
d
4
The impulse response is finite duration. Thus there is no need to truncate.
1 | n | M
where wr ( n ) =
0 | n |> M
Truncation = time multiplication with rectangular window function
Convolving in frequency domain with a sinc function
Page 9-9
EE 422G Notes Instructor: Cheung
M
sin (2 M + 1) r
wr (e j 2 r ) = e
n= M
j 2 n r
=
sin r
- Sinc function in frequency domain
Suppose the original analog filter H(r) is an ideal low-pass filter, windowing in
time domain corresponds to convolution in frequency with a sinc function.
Sliding sinc function in convolution
Ideal LP
Page 9-10
EE 422G Notes Instructor: Cheung
n
0.54 0.46 cos 0nM
Hamming : wh (n ) = M
0 otherwise
Page 9-11
EE 422G Notes Instructor: Cheung
Example: Design a 17-tap low-pass FIR digital filter with Hamming window to
approximate
1 | r | 0.15
H (r ) =
0 0.15 <| r | 0.5
Step 1: Inverse Fourier Transform
0.15 1 1
hd ( nT ) = e j 2 n r dr =
( e j 0.3 e j 0.3 ) = sin 0.3 n
0.15 j 2n n
d (sin 0.3 n) / d ( n) 0.3 cos 0.3 n
hd (0T ) = lim = lim = 0.3
n 0 d ( n) / d ( n) n 0 1
hd (0) = 0.3
sin 0.3n
h ( nT ) = n0
d
n
Step 2 & 3: Multiply by 17-tap Hamming window (M=8) and make it acausal.
8
H NC ( z ) = h
n = 8
d ( nT ) wh (n) z n , H C = z 8 H NC ( z )
Page 9-12
EE 422G Notes Instructor: Cheung
Page 9-13