Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 7 IIR Filter Design Content Preliminaries Characteristics of Prototype Analog Filters Analog-to-Digital Filter Transformations Frequency Transformations.

Similar presentations


Presentation on theme: "Chapter 7 IIR Filter Design Content Preliminaries Characteristics of Prototype Analog Filters Analog-to-Digital Filter Transformations Frequency Transformations."— Presentation transcript:

1 Chapter 7 IIR Filter Design Content Preliminaries Characteristics of Prototype Analog Filters Analog-to-Digital Filter Transformations Frequency Transformations

2 Preliminaries How to design a digital filter First: Specifications The design of a digital filter is carried out in three steps: Before we can design a filter, we must have some specifications. These specifications are determined by the applications. Second: Approximations Once the specifications are defined, we use various concepts and mathematics to come up with a filter description that approximates the given set of specifications. This step is the topic of filter design.

3 Preliminaries Third: Implementation The product of the above step is a filter description in the form of either a difference equation, or a system function, or an impulse response. From this description we implement the filter in hardware or software on a computer. In this and the next chapter we will discuss in detail only the second step, which is the conversion of specification into a filter description.

4 Preliminaries  In many applications, digital filters are used to implement frequency-selective operations;  Therefore, specifications are required in the frequency- domain in terms of the desired magnitude and phase response of the filter;  Generally a linear phase response in the passband is desirable;  An FIR filter is possible to have an exact linear phase;  An IIR filter is impossible to have linear phase in passband. Hence we will consider magnitude-only specifications. The specifications

5 Preliminaries There are two ways to give the magnitude specifications Absolute specifications Provide a set of requirements on the magnitude response function and generally used for FIR filters. Passband Stopband Transition band The ending frequency of the passband. Bandwidth The beginning frequency of the stopband. The tolerance (or ripple) in passband The tolerance (or ripple) in stopband

6 Preliminaries Relative specifications (dB) Provide requirements in decibels (dB). This approach is the most popular one in practice and used for both FIR and IIR filters The maximum tolerable passband ripple The minimum tolerable stopband attenuation

7 Preliminaries Examples  In a certain filter’s specifications the passband ripple is 0.25dB, and the stopband attenuation is 50dB. Determine the a 1 and a 2.

8 Preliminaries  Given the passband tolerance a 1 =0.02 and the stopband tolerance a 2 =0.001, determine the passband ripple and the stopband attenuation

9 Preliminaries The basic technique of IIR filter design IIR filters have infinite-length impulse responses, hence they can be matched to analog filters. Analog filter design is a mature and well developed field. We can begin the design of a digital filter in the analog domain and then convert the design into the digital domain

10 Preliminaries There are two approaches to this basic technique Approach 1 Design analog lowpass filter Apply freq. band transformation s → s Apply filter transformation s → z Designed IIR filter Approach 2 Design analog lowpass filter Apply filter transformation s → z Apply freq. band transformation z → z Designed IIR filter return

11 Characteristics of Prototype Analog Filters Magnitude-squared function Let be the frequency response of an analog filter is a passband ripple parameter is the passband cutoff frequency in rad/sec is the stopband cutoff frequency in rad/sec is a stopband attenuation parameter

12 Characteristics of Prototype Analog Filters The properties of is a real function The poles and zeros of are distributed in a mirror-image symmetry with respect to the axis. For real filters, poles and zeros occur in complex conjugate pairs.

13 Characteristics of Prototype Analog Filters 0 2 2 s-plane

14 Characteristics of Prototype Analog Filters How to construct is the system function of the analog filter. It must be causal and stable. Then all poles of must lie within the left half-plane. All left-half poles of should be assigned to Zeros are not uniquely determined. They can be halved between and. (Zeros in each half must occur in complex conjugate pairs) If a minimum-phase filter is required, the left-half zeros should be assigned to

15 Examples poles2 th order zeros We can assign left-half poles and a pair of conjugate zeros to

16 Characteristics of Prototype Analog Filters Butterworth lowpass filters This filter is characterized by the property that its magnitude response is flat in both passband and stopband. The magnitude-squared function of an N th -order lowpass filter is given by

17 Characteristics of Prototype Analog Filters The properties of Butterworth lowpass filters  At, for all N  At, for all N, which implies a 3dB attenuation at  is a monotonically decreasing function of  approaches an ideal lowpass filter as  is maximally flat at since derivatives of all orders exist and are equal to zero

18 Characteristics of Prototype Analog Filters The poles and zeros of

19 Characteristics of Prototype Analog Filters  There are 2N poles of, which are equally distributed on a circle of radius with angular spacing of radians.  If the N is odd, there are poles on real axis.  If the N is even, there are not poles on real axis.  The poles are symmetrically located with respect to the imaginary axis.  A pole never falls on the imaginary axis, and falls on the real axis only if N is odd.

20 Characteristics of Prototype Analog Filters In general, we consider and this results in a normalized Butterworth analog prototype filter When designing an actual filter with, we can simply do a replacement for s, that is

21 Designing equations Given, two parameters are required to determine a Butterworth lowpass filters : Solving these two equations for

22 Since the actual N chosen is larger than required, specifications can be either met or exceeded at or To satisfy the specifications exactly at

23 Example  Determine the system function of 3 th -order Butterworth analog lowpass filter. Suppose Solution:

24 Design the above filter with normalized Butterworth analog prototype filter. See table 6-4 on page 261 in case of ForWe can find

25  Design a lowpass Butterworth filter to satisfy: Passband Stopband Solution:

26

27 Look for table 6-4 on page 261

28 Look for table 6-6 on page 263 To construct a cascade structure

29 Characteristics of Prototype Analog Filters Chebyshev lowpass filters There are two types of Chebyshev filters Chebyshev-I: equiripple in the passband and monotonic in the stopband. Chebyshev-II: monotonic in the passband and equiripple in the stopband. Chebyshev filters can provide lower order than Butterworth filters for the same specifications. Chebyshev-I

30 N is the order of the filter is the N th -order Chebyshev polynomial given by is the passband ripple factor.

31 The properties of Chebyshev lowpass filters  At :  For :

32 Designing equations Given, two parameters are required to determine a Chebyshev-I filter: Note: this is only for

33 Determine system function To determine a causal and stable, we must find the poles of and select the left half-plane poles for. The poles are obtained by finding the roots of It can be shown that if are the (left half-plane) roots of the above polynomial, then

34 Where K is a normalizing factor chosen to make

35 Determine poles by geometric method The poles of fall on an ellipse with major axis and minor axis.

36  Determine the system function of 2 th -order Chebyshev-I lowpass filter. Suppose and Examples Solution:

37  Design a lowpass Chebyshev-I filter to satisfy: Passband cutoff: Passband ripple: Stopsband cutoff: Stopband attenuation: Solution:

38

39

40 Analog-to-Digital Filter Transformations Impulse invariance transformation Definition To design an IIR filter having a unit sample response h(n) that is the sampled version of the impulse response of the analog filter. That is T : Sampling interval Since this is a sampling operation, the analog and digital frequencies are related by

41 The system function and are related by This implies a mapping from the s-plane to the z-plane

42 Analog-to-Digital Filter Transformations Properties  Using  Since the entire left half of the s-plane maps into the unit circle, a causal and stable analog filter maps into a causal and stable digital filter.  All semi-infinite left strips of width map into. Thus this mapping is not unique but a many-to-one mapping

43 Analog-to-Digital Filter Transformations then There will be no aliasing. Frequency response If  To minimize the effects of aliasing, the T should be selected sufficiently small.  If the filter specifications are given in digital frequency domain, we cannot reduce aliasing by selecting T.  Aliasing occurs if the filter is not exactly band-limited

44 Analog-to-Digital Filter Transformations Digitalizing of analog filters Using partial fraction expansion, expand into The corresponding impulse response is To sample the

45 The z-transform of is Conclusions: Compared with  The pole in s-plane is mapped to the pole in z-plane  The partial fraction expansion coefficient of is the same as that of  The zeros in the two domains do not satisfy the same relationship

46 Analog-to-Digital Filter Transformations Advantages and disadvantages  The digital filter impulse response is similar to that of a analog filter. This means we can get a good approximations in time domain.  Due to the presence of aliasing, this method is useful only when the analog filter is essentially band-limited to a lowpass or bandpass filter in which there are no oscillations in the stopband.  It is a stable design and that the frequencies and are linearly related. So a linear phase analog filter can be mapped to a linear phase digital filter.

47 Design procedure  Choose T and determine the analog frequencies  Transform analog poles into digital poles to obtain the digital filter Given the digital lowpass filter specifications  Design an analog filter using the specifications  Using partial fraction expansion, expand into

48 Analog-to-Digital Filter Transformations Examples  Transform into a digital filter using the impulse invariance method in which T=1

49 Analog-to-Digital Filter Transformations Bilinear transformation Definition This is a conformal mapping that transforms the -axis into the unit circle in the z-plane only once, thus avoiding aliasing of frequency components. This mapping is the best transformation method.

50 0 s 1 -plane 0 z-plane 0 s-plane

51 Analog-to-Digital Filter Transformations Parameter c  Keeping a good corresponding relationship between the analog filter and the digital filter in low frequencies. i.e. in low frequencies  Keeping a good corresponding relationship between the analog filter and the digital filter in a specific frequency (for example, in the cutoff frequency, )

52 Properties  Using, we obtain So  Using, we obtain The imaginary axis maps onto the unit circle in a one-to-one fashion. Hence there is no aliasing in the frequency domain.  The entire left half-plane maps into the inside of the unit circle. Hence this is a stable transformation.

53 Analog-to-Digital Filter Transformations Advantages and disadvantages  It is a stable design;  There is no aliasing;  There is no restriction on the type of filter that can be transformed;.  The frequencies and are not linearly related. So a linear phase analog filter cannot be mapped to a linear phase digital filter.

54 Design procedure  Choose a value for T. We may set T=1 Given the digital lowpass filter specifications  Prewarp the cutoff frequencies and ; that is  Design an analog filter to meet the specifications  Finally, set and simplify to obtain as a rational function in

55 Analog-to-Digital Filter Transformations Examples  Transform into a digital filter using the bilinear transformation. Choose T=1

56  Design the digital Chebyshev-I filter using bilinear transformation. The specifications are: Solution  Let T=1  Prewarp the cutoff frequencies

57  Design an analog Chebyshev-I filter to meet the specifications

58 Analog-to-Digital Filter Transformations Comparison of three filters Using different prototype analog filters will give out different N and the minimum stopband attenuations. Given the digital filter specifications: prototypeOrder NStopband Att. Butterworth615 dB Chebyshev-I425 dB Elliptic327 dB return

59 Frequency Transformations Introduction The treatment in the preceding section is focused primarily on the design of digital lowpass IIR filters. If we wish to design a highpass or a bandpass or a bandstop filter, it is a simple matter to take a lowpass prototype filter and perform a frequency transformation. Frequency transformations in the analog domain Frequency transformations in the digital domain There are two approaches to perform the frequency transformation

60 Frequency Transformations Approach 1 Analog lowpass filter Frequency transformation s → s Filter transformation s → z Designed IIR filter Approach 2 Analog lowpass filter Filter transformation s → z Frequency transformation z → z Designed IIR filter

61 Frequency Transformations Specifications of frequency-selective filters Lowpass filter highpass filter bandpass filter bandstop filter

62 Frequency Transformations Frequency transformations in the digital domain the given prototype lowpass digital filter the desired frequency-selective digital filter Define a mapping of the form Such that To do this, we simply replace everywhere in by the function

63 Frequency Transformations Given that is a stable and causal filter, we also want to be stable and causal. This imposes the following requirements: The unit circle of the z-plane must map onto the unit circle of the Z-plane The inside of the unit circle of the z-plane must also map onto the inside of the unit circle of the Z-plane. must be a rational function in so that is implementable.

64 Frequency Transformations Let and be the frequency variables of and, respectively. That is. Then Hence the is an all-pass function By choosing an appropriate order N and the coefficients, we can obtain a variety of mappings

65 Frequency Transformations Frequency transformation formulae Lowpass - Lowpass : Cutoff frequency of new digital filter The cutoff frequency of prototype lowpass digital filter

66 Frequency Transformations Lowpass - Highpass : Cutoff frequency of new digital filter

67 Frequency Transformations Lowpass - Bandpass : lower cutoff frequency of bandpass digital filter: upper cutoff frequency of bandpass digital filter : center frequency of the passband

68 Frequency Transformations Lowpass - Bandstop : lower cutoff frequency of bandstop digital filter: upper cutoff frequency of bandstop digital filter : center frequency of the stopband

69 Frequency Transformations Design procedure Determine the specifications of the digital prototype lowpass filter; Determine the specifications of the analog prototype lowpass filter; Design the analog prototype lowpass filter; Transform the analog prototype lowpass filter into a digital prototype lowpass filter using bilinear transformation; Perform the frequency transformation in digital domain to obtain the desired frequency-selective filters.

70 Frequency Transformations Examples Given the specifications of Chebyshev-I lowpass filter Design a highpass filter with the above tolerances but with passband beginning at and its system function

71 Frequency Transformations Solution

72 Frequency Transformations Using the Chebyshev-I prototype to design a highpass digital filter to satisfy  Determine the specifications of the digital prototype lowpass filter Solution Choose the passband frequency with a reasonable value: Determine the stopband frequency by

73  Determine the specifications of the analog prototype lowpass filter Set T = 1 and prewarp the cutoff frequencies

74  Design an analog Chebyshev-I prototype lowpass filter to satisfy the specification:  Transform the analog prototype lowpass filter into a digital prototype lowpass filter using bilinear transformation

75  Perform the frequency transformation in digital domain to obtain the desired digital highpass filter

76 Frequency Transformations Using the Chebyshev-I prototype to design a bandpass digital filter to satisfy  Determine the specifications of the digital prototype lowpass filter Solution Choose the passband frequency with a reasonable value:

77 Determine the stopband frequency by

78  Determine the specifications of the analog prototype lowpass filter Set T = 1 and prewarp the cutoff frequencies  Design an analog Chebyshev-I prototype lowpass filter to satisfy the specification:

79  Transform the analog prototype lowpass filter into a digital prototype lowpass filter using bilinear transformation  Perform the frequency transformation in digital domain to obtain the desired digital bandpass filter

80 Frequency Transformations Using the Chebyshev-I prototype to design a bandstop digital filter to satisfy  Determine the specifications of the digital prototype lowpass filter Solution Choose the passband frequency with a reasonable value:

81 Determine the stopband frequency by

82  Determine the specifications of the analog prototype lowpass filter Set T = 1 and prewarp the cutoff frequencies  Design an analog Chebyshev-I prototype lowpass filter to satisfy the specification:

83  Transform the analog prototype lowpass filter into a digital prototype lowpass filter using bilinear transformation  Perform the frequency transformation in digital domain to obtain the desired digital bandstop filter return

84

85

86

87

88

89

90

91

92

93

94

95

96

97

98

99

100

101

102

103

104

105

106

107

108


Download ppt "Chapter 7 IIR Filter Design Content Preliminaries Characteristics of Prototype Analog Filters Analog-to-Digital Filter Transformations Frequency Transformations."

Similar presentations


Ads by Google