Iir 1
Iir 1
Iir 1
5.1 Introduction
Nomenclature With a0 = 1 in the linear constant coefficient difference equation,
a0 y(n) + a1 y(n1) + + aN y(nN)
= b0 x(n) + b1 x(n1) + + bM x(nM),
a0 0
we have,
M
b z
H(z) =
i 0
N
1 ai z i
i 1
This represents an IIR filter if at least one of a1 through aN is nonzero, and all the roots of the
denominator are not canceled exactly by the roots of the numerator. In general, there are M finite
zeros and N finite poles. There is no restriction that M should be less than or greater than or equal
to N. In most cases, especially digital filters derived from analog designs, M N. Systems of this
type are called Nth order systems. This is the case with IIR filter design in this Unit.
When M > N, the order of the system is no longer unambiguous. In this case, H(z) may be
taken to be an Nth order system in cascade with an FIR filter of order (M N).
When N = 0, as in the case of an FIR filter, according to our convention the order is 0.
However, it is more meaningful in such a case to focus on M and call the filter an FIR filter of M
stages or (M+1) coefficients.
Example The system H(z) = (1 z 8 ) (1 z 1 ) is not an IIR filter. Why (verify)?
IIR filter design An analog filter specified by the Laplace transfer function, Ha(s), may be
designed to either frequency domain or time domain specifications. Similarly, a digital filter,
H(z), may be required to have either (1) a given frequency response, or (2) a specific time
domain response to an impulse, step, or ramp, etc.
Analog design using digital filters, i = iT Another possibility is that a digital filter may be
required to simulate a continuous-time (analog) system. To simulate an analog filter the discretetime filter is used in the A/D H(z) D/A structure shown below. The A/D converter can be
thought of roughly as a sampler and coder, while the D/A converter, in many cases, represents a
decoder and holder followed by a low pass filter (smoothing filter). The A/D converter may be
preceded by a low pass filter, also called an anti-aliasing filter or pre-filter.
Equivalent Analog Filter
xa(t)
A/D
x(n)
xa(nT)
(1/T) samples/sec
H(z)
y(n)
ya(t)
D/A
ya(nT)
(1/T) samples/sec
We will usually be given a set of analog requirements with critical frequencies 1, 2,,
N in radians/sec., and the corresponding frequency response magnitudes K1, K2, , KN in dB.
The sampling rate 1/T of the A/D converter will be specified or can be determined from the input
signals under consideration.
The general approach for the design is to first convert the analog requirements to digital
requirements and then design the digital filter using the bilinear transformation. The conversion
of the analog specifications to digital specifications is through the formula i = iT. To show
that this is true, suppose that the input to the equivalent analog filter is xa(t) = sin it . The output
of the A/D converter with sampling rate 1/T becomes
x(n) = xa(nT) = sin i nT = sin (iT )n = sin i n
Thus, the magnitude of the discrete-time sinusoidal signal is the same as the continuous time
sinusoid, while the digital frequency i is given in terms of the analog frequency i by i = iT.
Thus, the specifications for the digital filter become 1, 2, , N with the
corresponding frequency response magnitudes K1, K2, , KN. The digital frequency, , is in
units of radians. The procedure is conceptually shown in figure below.
Equivalent
Analog Specs
1, 2, , N
K1, K2, , KN
i iT
Digital Filter
Specs
1, 2, , N
K1, K2, , KN
Ki = Ki
H(z)
Digital
Design
(Perhaps
Bilinear)
+
C = 20F
Input = x(t)
Output = y(t)
1
0.707
c= 5
, rad./sec.
Magnitude
1
|H(Omega)|
0.8
0.6
0.4
0.2
-15
-10
-5
0
5
Omega, rad/sec
Phase
10
15
-15
-10
-5
0
5
Omega, rad/sec
10
15
Phase of H(Omega)
2
1
0
-1
-2
If we adjust the values of the components R and C so that 1 RC = 1, we would have Ha(s)
1
which is a normalized filter with cut-off frequency c = 1 rad/sec and gain of 1 at = 0.
s 1
Such a normalized LP filter could be transformed to another LP filter with a different cut-off
frequency of, say, c = 10 rad/sec by the low pass to low pass transformation s s / 10 . The
transfer function then becomes
1
10
Ha(s) =
=
s 1 s ( s / 10) s 10
which still has a dc gain of 1. The gain of this filter could be scaled by a multiplier, say, K, so
that
10
Ha(s) = K
s 10
which has a dc gain of K and a cut-off frequency of c = 10 rad/sec.
The frequency response of the normalized filter Ha(s) = 1/( s 1) is Ha(j) = 1 ( j 1) . The
corresponding MATLAB plots are shown below using the function plot. Omega is a vector,
consequently we use ./ instead of / etc.
=
Magnitude
|H(Omega)|
0.5
0
-20
-15
-10
-5
0
5
Omega, rad/sec
Phase
10
15
20
-15
-10
-5
0
5
Omega, rad/sec
10
15
20
Phase of H(Omega)
2
1
0
-1
-2
-20
Butterworth filter The filter Ha(s) = 5 /( s 5) is a first order Butterworth filter with cut-off
frequency c = 5 rad/sec. Its magnitude response is given by
1
|H(j)| =
2
1 / 5
Omega = 0: pi/256: 15; H1 = 1./sqrt(1.+ (Omega/5) .^2);
plot(Omega, H1, 'k'); legend ('1st Order, Cut-off = 5 rad/sec');
xlabel ('Omega, rad/sec'), ylabel('|H(Omega)|'); grid; title ('Magnitude')
Magnitude
1
1st Order, Cut-off = 5 rad/sec
0.9
|H(Omega)|
0.8
0.7
0.6
0.5
0.4
10
Omega, rad/sec
15
Frequency response analysis The frequency response analysis in the analog frequency ()
domain is given by the following equations which may be used to illustrate, qualitatively, the
effect of LP, HP or BP analog filters on a signal.
Y(s) = H(s) X(s)
Y(j) = H(j) X(j) = H ( j) e j H ( j) X ( j) e j X ( j) = H ( j) X ( j) e j H ( j)X ( j
Y () = H () X () and
X(s)
Y () = H () + X ()
H(s)
Y(s)
Similarly, if we have a digital filter H(z) the frequency response analysis in the digital
frequency () domain is given by the following equations which may be used to illustrate,
qualitatively, the effect of LP, HP or BP digital filters on a signal.
Y(z) = H(z) X(z)
Y(j) = H(j) X(j) = H ( j ) e j H ( j ) X ( j ) e j X ( j ) = H ( j) X ( j) e j H ( j )X ( j
Y ( ) = H ( ) X ( )
X(z)
and
Y ( ) = H () + X ( )
H(z)
Y(z)
The Nth order Butterworth filter In general the magnitude response of the Nth order
Butterworth filter with cut-off frequency c is given by
1
|H(j)| =
2N
1 / c
With the normalized frequency variable defined as r = / c , the MATLAB segment below
plots the magnitude response for 1st, 3rd, and 10th order filters, that is, N = 1, 3, and 10,
respectively. Note that as the filter order increases the response becomes flatter on either side of
the cut-off; and the transition (cut-off) becomes sharper.
r = 0: 0.1: 3;
H1 = 1./sqrt(1.+ r .^2);
H3 = 1./sqrt(1.+ r .^6);
H10 = 1./sqrt(1.+ r .^20);
plot (r, H1, r, H3, 'r', r, H10, 'k');
legend ('1st Order', '3rd Order', '10th Order');
xlabel ('Normalized frequency, r'), ylabel('|H(r)|'); grid; title ('Magnitude')
Magnitude
1
1st Order
3rd Order
10th Order
0.9
0.8
0.7
|H(r)|
0.6
0.5
0.4
0.3
0.2
0.1
0
0.5
1
1.5
2
Normalized frequency, r
2.5
Writing down the Nth order filter transfer function H(s) from the pole locations Let us look
at some analog Butterworth filter theory.
1
(1) |H(j)| =
decreases monotonically with . No ripples.
2N
1 / c
(2) Poles lie on the unit circle in the s-plane (for the Chebyshev filter, in contrast,
they lie on an ellipse).
(3) The transition band is wider (than in the case of the Chebyshev filter).
(4) For the same specifications the Butterworth filter has more poles (or, is of higher
order) than the Chebyshev filter. This means that the Butterworth filter needs
more components to build.
|H(j)|
Direction of
increasing
order of filter
0.707
, rad./sec.
c = 1
The normalized analog Butterworth filter has a gain of |H(j)| = 1 at = 0, and a cut-off
frequency of c = 1 rad/sec. Given the order, N, of the filter we want to be able to write down its
transfer function from the pole locations on the Butterworth circle.
Example 5.2.2 Given the order N of the filter, divide the unit circle into 2N equal parts and place
poles on the unit circle at (3600/2N) apart. The H(s) will be made up of the N poles in the left half
plane only. Remember complex valued poles must occur as complex conjugate pairs. There will
j
s-plane
Radius = c = 1
be no poles on the imaginary axis. Since the N poles must lie on the left half semicircle, when N
is odd the odd pole must be at s = 1. Thus, for N = 1, there is one pole, s1 = 1, and H(s) is
given by
H(s) =
1
1
1
=
=
s 1
s s1
s (1)
Example 5.2.3 Filter order N = 2 so that 2N = 4 and 3600/4 = 900. The pole plot is shown above.
The poles are at
1
1
1
1
s1 =
s2 =
j
j
and
,
2
2
2
2
j
s-plane
Radius = c = 1
so that
H(s) =
1
1
=
( s s1 ) ( s s2 )
1 1 1 1
j
s
j
s
2 2 2 2
Denominator is
2
1 1
1
1
1
Dr. = s
s j 2 = s 2 2s 1
= s2 2
j
2
2
2 2
2
So
H(s) =
1
s 2s 1
2
Example 5.2.4 Filter order N = 3, so that 2N = 6 and 3600/6 = 600. Poles are at
1
1
1
3
3
, and j
s1, 2, 3 = 1, j
2
2
2 s + 2 s +1
2
2
j
s2
s-plane
s3
s1
1
s3
= s2*
Radius = c = 1
H(s) =
1
3
1
3
s j
( s 1) s j
2
2
2
2
Denominator is
2
1
3
Dr. = s 1 s j 2 = s 1 s 2 s 1
2
4
So
H(s) =
1
s 1 s 2 s 1
Example 5.2.5 Filter order N = 4, so that 2N = 8 and 3600/8 = 450. Poles are at
s = (cos 22.50 j sin 22.50) = (cos j sin )
(cos 67.50 j sin 67.50) = (cos j sin )
j
Wrong
placement
j
s-plane
s-plane
1
( s cos ) j sin ( s cos ) 2 j 2 sin 2
1
H(s) = 2
s 1.848 s 1 s 2 0.765 s 1
H(s) =
Correct
Determining the order and transfer function from the specifications A typical magnitude
response specification is sketched below. The magnitudes at the critical frequencies 1 and 2
are A and B, respectively. Typically 1 is in the pass band or is the edge of the pass band and 2
is in the stop band or is the edge of the stop band. For illustrative purposes we have arbitrarily
Transition
band
|H(j)|
Pass
band
Stop
band
A = 0.707
B = 0.25
1
, rad./sec.
taken A = 0.707 (thus 1 is the cut-off frequency, but this need not be the case) and B = 0.25.
The log-magnitude specification is diagrammed below. Note that (20 log A) = K1 dB and
(20 log B) = K2 dB. Thus the analog filter specifications are
0 20 log10 H ( j) K1 for all 1
K1
K2
10 K1 / 10 1
log
10 K 2 / 10
10
N=
2 log10 1
(3.16, Ludeman)
The result is rounded to the next larger integer. For example, if N = 3.2 by the above calculation
then it is rounded up to 4, and the order of the required filter is N = 4. In such a case the resulting
filter would exceed the specification at both 1 and 2. The cut-off frequency c is determined
from one of the two equations below.
1
2
c =
or
c =
(3.17 Ludeman)
2N
2N
10 K 2 /10 1
10 K1 / 10 1
The equation on the left will result in the specification being met exactly at 1 while the
specification is exceeded at 2. The equation on the right results in the specification being met
exactly at 2 and exceeded at 1.
Note that the design equation for N may be written in the alternative form
10 K 2 /10 1
log10 K1 /10
10
1
N=
2 log10 2
1
Example 5.2.6 What is the order and transfer function of the analog Butterworth filter that
satisfies the following specification?
1 = 200 rad/sec
2 = 600 rad/sec
K1 = 1 dB
K2 = 30 dB
10 K1 / 10 1
10 ( 1) /10 1
10 0.1 1
log 10 ( 30) /10 log10 3
log10 K 2 / 10
10
1
10
1
10 1
N=
=
=
200
200
1
2 log10
2 log 10
2 log10
600
600
1.2589 1
0.2589
0.2589
log10 1000 1 log10 999 log10 999
=
200
200
200
2 log
2 log10
2 log10
10
600
600
600
log 0.00025918 3.586
= 10
=
= 3.76 = 4
2
log
0
.
3333333
2
(
0
.
47712
)
10
Now, as in an earlier example, locate 8 poles uniformly on the unit circle, making sure to satisfy
all the requirements and write down the transfer function, H (s) , of the normalized
Butterworth filter (with a cut-off frequency of 1 rad/sec),
1
H (s) = 2
s 1.848 s 1 s 2 0.765 s 1
Next, determine the cutoff frequency c that corresponds to the given specifications and
the order N = 4 determined above
1
200
200
200
= 2( 4)
= 8
=
= 236.8 rad/sec
c =
2N
1.26 1 0.8446
10 ( 1) /10 1
10 K1 / 10 1
Finally, we make the substitution s (s / 236.8) in H (s) and thereby move the cutoff frequency
from 1 rad/sec to 236.8 rad/sec resulting in the transfer function H a (s)
(s / 236.8)
1.848 s 1 s 2 0.765 s 1
s( s / 236.8)
(236.8)
s 1.848(236.8) s 236.82 s 2 0.765(2326.8) s 236.82
=
=
(Aside) The more general Nth order Butterworth filter has the magnitude response given by
1
H ( j) =
2N
1 2 / 1
The parameter has to do with pass band attenuation and 1 is the pass band edge frequency
(not necessarily the same as the 3 dB cut-off frequency c). MATLAB takes = 1 in which case
1 = c. See DSP-HW. [See Cavicchi, Ramesh Babu].
(End of Aside)
If we are given an analog filter with system function Ha(s) the corresponding impulse-invariant
digital filter, H(z), is seen from above to be
H(z) = L1H a ( s)
t nT
, where L
Note that at this point we have not specified how Ha(s) was obtained, but rather we have
shown how to obtain the digital filter H(z) from any given Ha(s) using impulse invariance.
A
find the H(z) corresponding
s
to the impulse invariant design using a sample rate of 1/T samples/sec.
A
t
Solution The analog systems impulse response is ha (t ) = 1
= Ae u(t ) . The
s
1
X ( z ) 1 az
y(n) a y(n 1) = A x(n)
y(n) = Ax(n) a y(n 1)
Relationship between the s-plane and the z-plane ( z e s T ) We can extend the above procedure
to the case where Ha(s) is given as a sum of N terms with distinct poles as
N
Ak
Ha(s) =
k 1 s k
For this case the impulse invariant design, H(z), is given by
N
N
N
Ak
Ak
1
= Ak z =
H(z) = L
k T 1
k T
k 1 s k
k 1z e
z
k 11 e
t nT
where L1 means Laplace inverse. We observe that a pole at s = k in the s-plane gives rise to a
pole at z = e kT in the z-plane and the coefficients in the partial fraction expansion of Ha(s) and
H(z) are equal. If the analog filter is stable, corresponding to k being in the left half plane,
then the magnitude of e kT will be less than unity, so that the corresponding pole of the digital
filter is inside the unit circle, and as a result the digital filter also is stable.
While the poles in the s-plane map to poles in the z-plane according to the relationship
sT
z = e , it is important to recognize that the impulse invariance design procedure does not
correspond to a mapping (transformation) of the s-plane to the z-plane by that relationship or in
fact by any relationship. (An example of a transformation is where we actually make a
2 1 z 1
which, of course, is the bilinear transformation). For example,
substitution, say, s =
T 1 z 1
the zeros of Ha(s) do not map to zeros of H(z) according to this relation. See also matched ztransform later.
We can explore the relationship z e s T keeping in mind that it only applies to poles and
that it is not a transformation. Set s = + j and z = r e j in z = e s T to get r e j = e ( j) T =
e T e j T so that r = e T and = T.
The above relations can be used to show that poles in the left half of the primary strip in
the s-plane map into poles within the unit circle in the z-plane as shown in the figure for s = s1.
Mapping of poles, z = e s T
s-plane pole z-plane pole
r
s = + j
z = e s T = r e j
0
1
1
js/2
1
1
+ js/2
0
0
js/2
0
0
js/2
1
1
Im
z-plane
1T
Re
1
s1
=1+j1
s3
js/2 = j/T
0
Primary strip,
width = s = 2/T
j/T
j3/T
Owing to the aliasing, the impulse invariant design is suitable for the design of low pass
and band pass filters but not for high pass filters.
(Omit) Matched z-transform In this method we apply the mapping z = e s T not only to the poles
but also to the zeros of Ha(s). As a result the observations made above are valid for the matched
z-transform method of filter design.
Frequency response of the equivalent analog filter Going back to the impulse invariant design
of the first order filter, how does the frequency response of the A/D H(z) D/A structure using
this H(z) compare to the frequency response of the original system specified by Ha(s)?
Heq(j)
Ha(j)
X(s)
x(t)
Ha(s)
Y(s)
X(s)
y(t)
x(t)
A/D
H(z)
D/A
Y(s)
y(t)
A
Az
Az
and H(z) =
=
with a = e T . For the analog filter we have
T
za
s
z e
1
A
A
A
Ha(j) =
=
=
e j tan ( / )
s s j j
2 2
A
|Ha(j)| =
,
<<
2
2
For future reference note that |Ha(j0)| = A / .
To obtain the equivalent frequency response of the A/D H(z) D/A structure one must
first find the frequency response of the discrete-time filter specified by H(z). This is given by
Ae j
H(ej) = H ( z )z e j = j
,
< < (because periodic)
e e T
The analog frequency response of the equivalent analog filter is then determined by replacing
by T. Note, however, that since the digital frequency, , is restricted to (, ), the analog
frequency, , is correspondingly is restricted to (/T, /T). We get
Ae jT
A
Heq(j) = H (e j ) T = jT
=
,
T < or < /T
T
T jT
e e
1 e e
Note Ha(s) =
|Ha(j)
|
10
|Heq(j)|
For T = 1, valid for < /1
For T = 0.1, valid for < 10
10
Example 5.3.2 [Impulse invariant design of 2nd order Butterworth filter] Obtain the impulse
4
invariant digital filter corresponding to the 2nd order Butterworth filter Ha(s) = 2
s 2 2s 4
with sampling time T = 1 sec.
Solution Note that we are using T = 1 sec. simply for the purpose of comparing with the bilinear
design done later with T = 1 sec. It is important to remember that in bilinear design calculations
the value of T is immaterial since it gets cancelled in the design process; but in impulse invariant
design there is no such cancellation, so the value of T is critical (the smaller, the better).
4
4
Ha(s) = 2
=
2
2
s 2 2s 4 s 2 2 2s 2 2
2
=
2
2
2
2
2
s 2 2
s 2 2
The expression in braces is in familiar form and can be converted to its impulse invariant digital
filter equivalent. See 3(c) in HW.
=
Step invariant design Here the response of the digital filter to the unit step sequence, u(n), is
chosen to be samples of the analog step response. In this way, if the analog filter has good step
response characteristics, such as small rise-time and low peak over-shoot, these characteristics
would be preserved in the digital filter. Clearly this idea of waveform invariance can be extended
to the preservation of the output wave shape for a variety of inputs.
pa(t)
t
(Omit) Problem Given the analog system Ha(s), let ha(t) be its impulse response and let pa(t) be
its step response. The system Ha(s) is given to be continuous-time linear time-invariant. Let also
h (kT ) ?
u(n) =
(k)
p(n) =
h( k ) =
h (kT )
p(n) =
h( k )
and
pa(t) = ha ( ) d
H a (s)
K
K
A
=
= 1 + 2
s (s )
s
s
s
where K1 and K2 are the coefficients of the partial fraction expansion, given by
[pa(t)] = Pa(s) =
K1 =
A
s
=
s 0
and
K2 =
A
A
=
s s
Therefore,
A /
A/
A
A
pa (t ) = e 0 t u (t ) e t u (t )
s
s
from which we write p(n) = pa (nT ) and hence P(z ) etc. Equivalently, we may reason as follows.
The correspondence between s-plane poles and z-plane poles is
1
1
T 1
s
1 e z
Thus we get P(z) as below
A z z e T z ( z 1)
(A/)
(A/)
A z
z
P(z) =
=
= =
( z 1) z e T
1 e 0 T z 1 1 e T z 1 z 1 z e T
z
A
1 e T
=
( z 1)( z e T )
However, what we need is H(z). Since (n) = u(n) u(n1), and we know the response to u(n),
therefore, the response to u(n) u(n1) is given by h(n) = p(n) p(n1), and taking the ztransform of this last equation,
z 1
H(z) = P(z ) z 1 P( z ) = (1 z 1 ) P( z) =
P( z )
z
z
z 1 A
1 e T
=
( z 1)( z e T )
z
1
A
1 e T
=
( z e T )
Alternatively, we may also obtain the transfer function as the ratio of output and input
transforms, H(z) = P(z)/U(z).
Pa(s) =
Frequency-response analysis As we did in the case of the impulse-invariant design, here also
A
we can compare |Ha (j)| with |Heq(j)|. For the system Ha(s) =
the frequency response is
s
A
already evaluated as |Ha(j)| =
. We need the frequency response, |Heq(j)|, of the
2
2
equivalent analog filter when the above H(z) is used in a A/D H(z) D/A structure. Start with
the above H(z) and set z = e j to get
1
1
A
A
1 e T
H (e j ) = H ( z )z e j =
= 1 e T
T
j
( z e ) z e j
(e e T )
dy
= x(t)
dy = x(t )dt
dt
Here dy = area shown shaded and is given by
x(n) x(n 1)
y(n) y(n1) =
T
2
where we have used the trapezoidal rule to compute the area under a curve.
x(t)
x(nT)
x((n1)T)
(n1)T
nT
T 1 z 1
Thus the continuous time system y(t) =
x(t)
x(t )dt
y(t)
1
s
Y(s)
1
2 1 z 1
T 1 z 1
y(n)
Y(z)
In other words, given the Laplace transfer function Ha(s), the corresponding digital filter is given
2(1 z 1 )
by replacing s with
, or
T (1 z 1 )
H(z) = H a ( s)s 2(1 z 1 )
T (1 z 1 )
This is called bilinear transformation (both numerator and denominator are first order
polynomials), also known as bilinear z-transformation (BZT).
Here again, note that at this point we have not specified how Ha(s) was obtained, but
rather we are showing how to obtain the digital filter H(z) from any given Ha(s) using bilinear
transformation.
Example 5.4.1 [LP filter] [Bilinear] Design a digital filter based on the analog system Ha(s)
A
=
, using the bilinear transformation. Give the difference equation. Use T = 2 sec.
s
Solution
A
A
H(z) = H a ( s)s 2(1 z 1 ) =
=
1
( 1) ( 1) z 1
2 1 z
T (1 z 1 )
T 1 z 1
Example 2 [Ludeman, p. 178] Apply bilinear transformation to the 2nd order Butterworth filter
4
Ha(s) = 2
with T = 1 sec. Obtain (1) H(z), (2) the difference equation and
s 2 2s 4
(3) H (e j ) .
Solution
2(1 z 1 )
2 1 z 1
2
2
(1 z 1 )
(1 z 1 ) 4
1 2 z 1 z 2
=
3.4142135 0.5857865 z 2
(2) The difference equation is obtained from
1 2 z 1 z 2
Y ( z)
H(z) =
=
X ( z ) 3.4142135 0.5857865 z 2
Cross-multiply and take inverse z-transform to get
3.4142135 y(n) + 0.5857865 y(n2) = x(n) + 2x(n1) + x(n2)
By rearranging and scaling y(n) can be realized as
y(n) = 0.2928932 [x(n) + 2 x(n1) + (n2)] 0.1715729 y(n2)
(3) Frequency response
H ( z )z e j =
1 2e j e j 2
N ( )
=
j 2
3.4142135 0.5857865 e
D( )
Numerator = N ( ) = 1 2e j e j 2 = e j (e j 2 e j ) = e j (2 2 cos )
= 2(1 cos ) e j
Denominator = D( ) = 3.4142135 + 0.5857865 e j 2 = A + B e j 2
= (A + B cos 2) j B sin 2
= ( A B cos 2 ) ( B sin 2 )
2
2(1 cos )
H (e j ) =
e
( A B cos 2 ) 2 ( B sin 2 ) 2
The magnitude of the frequency response is
2(1 cos )
| H (e j ) | =
( A B cos 2 ) 2 ( B sin 2 ) 2
B sin 2
j tan 1
A B cos 2
B sin 2
j tan 1
A B cos 2
Im
s-plane,
s = +j
j2/T
Unit circle
z-plane
j1 (for = 2/T)
( = +)
j0
( = 0+)
Re
j0
j2/T
( = 0)
( = )
j1 (for = 2/T)
2
T
1 e j
j
1 e
2 e j / 2 (e j / 2 e j / 2 )
2 j 2 (e j / 2 e j / 2 ) / j 2
=
=
j / 2
(e j / 2 e j / 2 )
T 2 (e j / 2 e j / 2 ) / 2
T e
or
2 sin / 2
2
T
= tan
or
= 2 tan 1
T cos / 2 T
2
2
First we sketch (the analog frequency) as a function of (the digital frequency) as
2
given by =
tan to show qualitatively the distortion of the frequency scale that occurs
T
2
due to the nonlinear nature of the relationship.
=
2
tan( / 2)
T
Unequal
Equally spaced pass bands A are pushed together or warped on the higher frequency end
of the digital frequency scale. This effect is normally compensated for by pre-warping the analog
filter before applying bilinear transformation.
Because of warping the relationship between 1 and 2 on the one hand and 1 and 2 on
the other is not linear. The digital frequencies 1 and 2 are pushed in towards the origin ( = 0).
In this process = is transformed to =.
= 2 tan 1 T / 2
(Periodic)
2
1
K2
K1
|H()|
|H()|
(Nonperiodic)
K1
K2
1
If the bilinear transformation is applied to the system Ha(s) with critical frequency c, the
digital filter will have a critical frequency c = 2 tan 1 cT / 2 . If the resulting H(z) is used in an
A/DH(z)D/A structure, the equivalent critical frequency (of the equivalent analog filter) is
obtained by replacing c with ceqT:
2
T
T
c ceq T = 2 tan 1 c
or
ceq = tan 1 c
T
2
2
1
If (cT/2) is so small that tan cT / 2 cT/2, then we have
2 cT
= c
T 2
If this condition is not satisfied, then the warping of the critical frequency (in the bilinear
design) is compensated for by pre-warping.
ceq =
Before taking up design we reproduce below some of the material relating filter specifications to
the filter order and the cut-off frequency.
A typical magnitude response specification is sketched below. The magnitudes at the
critical frequencies 1 and 2 are A and B, respectively. For illustrative purposes we have
Transition
band
|H(j)|
Pass
band
Stop
band
A = 0.707
B = 0.25
1
, rad./sec.
arbitrarily taken A = 0.707 (thus 1 is the cut-off frequency, but this need not be the case) and B
= 0.25.
The log-magnitude specification is diagrammed below. Note that (20 log A) = K1 and (20
log B) = K2. Thus the analog filter specifications are
0 20 log10 H ( j) K1 for all 1
K1
K2
10 K1 / 10 1
log
10 K 2 / 10
10
N=
2 log10 1
(3.16, Ludeman)
The result is rounded to the next larger integer. For example, if N = 3.2 by the above calculation
then it is rounded up to 4, and the order of the required filter is N = 4. In such a case the resulting
filter would exceed the specification at both 1 and 2. The cut-off frequency c is determined
from one of the two equations below.
1
2
c =
or
c =
(3.17 Ludeman)
2N
2N
10 K 2 /10 1
10 K1 / 10 1
The equation on the left will result in the specification being met exactly at 1 while the
specification is exceeded at 2. The equation on the right results in the specification being met
exactly at 2 and exceeded at 1.
Example 5.6.1 [4.1, Ludeman] Design and realize a digital low pass filter using the bilinear
transformation method to satisfy the following characteristics:
(a) A monotonic pass band and stop band
(b) 3.01 dB cut off frequency of 0.5 rad.
(c) Magnitude down at least 15 dB at 0.75 rad.
dB (= 20 log10 |H(j)|)
0
3.01
/2 3/4
15
Note that the given frequencies are digital frequencies. The required frequency response
is shown. We use bilinear transformation on an analog prototype.
Step 1 Pre-warp the critical digital frequencies 1 = 0.5 and 2 = 0.75 using T = 1 sec. That
is, we find the analog frequencies 1 and 2 that correspond to 1 and 2:
0.5
2
1 = tan 1 = 2 tan
= 2.0 rad / sec
T
2
2
0.75
2
= 4.8284 rad / sec
2 = tan 2 = 2 tan
2
T
2
Step 2 Design LP analog filter with critical frequencies 1 and 2 that satisfy
0 20 log |Ha(j 1 )| 3.01 dB = K1, and
20 log |Ha(j 2 )| 15 dB = K2
The Butterworth filter satisfies the monotonic property and has an order N and critical
frequency c determined by Eq. 3.16 and 3.17 of Ludeman
10 K1 / 10 1
log10 K 2 / 10
10
1
1
N=
and
c =
2N
10 K1 / 10 1
2 log10 1
2
10 3.01/ 10 1
log 10 2 1
log
10 15/ 10
1
31.62 1 = 1.486 = 1.941 = 2
10
N=
=
2 2 0.3827 2 (0.3827)
2
log
10
4.828
2.0
2
c =
= 4
= 2 rad / sec
3.01/ 10
4
2 1
10
1
Note in this case that c = 1.
Therefore, the required pre-warped, normalized, unit bandwidth, analog filter of order 2
using the Butterworth Table 3.1b (or the Butterworth circle) is
1
Ha(s) = 2
(with a cut off frequency = 1 rad / sec)
s 2 s 1
Since we need a cut-off frequency of c = 2 rad/sec, we next use the low pass to low pass
transformation s s/2 in order to move the cut-off frequency from 1 to 2 rad/sec.
1
1
Ha(s) = 2
=
2
s 2 s 1 ss / 2 (s / 2) 2 (s / 2) 1
4
= 2
(with a cut-off frequency = 2 rad/sec.)
s 2 2s4
Step 3 Applying the bilinear transformation to Ha(s) with T = 1 will transform the pre-warped
analog filter into a digital filter with system function H(z) that will satisfy the given digital
requirements:
4
H(z) = H a ( s)s 2(1 z 1 ) =
2
1 z 1
2(1 z 1 )
2(1 z 1 )
2
2
4
1
1
1 z
1 z
1 2 z 1 z 2
=
3.414 0.585 z 2
HW: Obtain the difference equation. Plot | H (e j ) | and H (e j ) vs .
Bilinear transformation: Cancellation of sampling time in warping and pre-warping The
digital specifications are the set of critical frequencies {1, 2, , N} and the corresponding set
of magnitude requirements {K1, K2, , KN}. When an analog filter is used as the prototype for
the bilinear transformation method the relationship between digital and analog frequencies is
nonlinear and governed by
2
T
=
and
= 2 tan 1
tan
T
2
2
Therefore, to get the proper digital frequency, we must design an analog filter with analog
critical frequencies i: i = 1, 2, , N given by
2
i = tan i ,
i = 1, 2, , N
T
2
This operation will be referred to as pre-warping. The corresponding analog magnitude
requirements are not changed and remain the same as the corresponding digital requirements. An
analog filter Ha(s) is then designed to satisfy the pre-warped specifications given by 1, 2, ,
N and K1, K2, , KN. The bilinear transformation is then applied to Ha(s), i.e.,
H(z) = H a ( s)s 2(1 z 1 )
T (1 z 1 )
As the T in the i equation and the T in the bilinear transform cancel in the procedure described
above for low pass filter design, it is convenient to just use T = 1 in both places. This is easily
seen since if the i comes from an analog-to-analog transformation of an Ha(s) with a unit radian
2(1 z 1 )
cut-off frequency, we have s(s/ i), and when the bilinear transformation s
is
T (1 z 1 )
used the cascade of transformations is given by
2(1 z 1 )
2(1 z 1 )
(1 z 1 )
s
=
=
T (1 z 1 ) i
2
(1 z 1 ) tan i
T (1 z 1 ) tan i
2
2
T
This does not contain a T. Thus it is immaterial what value of T is used as long as it is the same
in both steps (which it is).
The procedure for the design of a digital filter using the bilinear transformation consists
of:
Step 1: Pre-warping the digital specifications
Step 2: Designing an analog filter to meet the pre-warped specs
Step 3: Applying the bilinear transformation
In the process T is arbitrarily set to 1, but it can be set equal to any value (e.g., T = 2), since it
cancels in the design. The design process is shown by the figure below.
Digital specs
1, 2 , , N
K1, K2, , KN
Pre-warp
T=1
i = (2/T) tan (i/2)
Pre-warped
Analog specs
1, 2, , N
K1, K2, , KN
Design
Analog
Filter
Ha(s)
Bilinear
transformation T = 1
s
Desired
H(z)
2 1 z 1
T 1 z 1
Example 5.6.2 [After Prob. 5.6, O & S] Design a digital low pass filter with pass band
magnitude characteristic that is constant to within 0.75 dB for frequencies below = 0.2613
and stop band attenuation of at least 20 dB for frequencies between = 0.41 and .
dB (= 20 log10 |H(j)|)
0
0.2613
0.41
0.75
20
Use bilinear transformation. Determine the transfer function H(z) for the lowest order
Butterworth design which meets these specifications. Draw the cascade form realization.
Step 1: Pre-warp 1 = 0.2613, 2 = 0.41 with T = 1 sec.
0.2613
2
1 =
= 0.8703 rad / sec
tan 1 = 2 tan
2
T
2
0.41
2
2 =
= 1.501 rad / sec
tan 2 = 2 tan
T
2
2
Step 2: Design Ha(s)
10 0.75 / 10 1
log 10 1.19 1
log
10 20 / 10
1
100 1 = 2.7203 = 5.75 = 6
10
N=
=
10
1.501
1
0.8703
0.8703
c =
=
=
= 1 rad/sec
2N
10 K1 / 10 1 12 10 0.75/10 1 0.8701
Let the left-half plane poles be denoted s1 , s1* , s 2 , s 2* , s3 , and s3* .
1
1
1
Ha(s) =
*
*
s s1 s s1 s s2 s s2 s s3 s s3*
Since c = 1 the LP to LP transformation s (s/1) results in the same Ha(s) as given above.
Step 3: H(z) = H a ( s)s 2(1 z 1 )
1 z 1
s s1 s s
*
1
2 (1 z 1 )
1
1 z
s s2 s s
*
2
2 (1 z 1 )
1
1 z
s s3 s s3* s 2(1 z
1 z1
Example 5.6.3 [2002] Determine H(z) for a Butterworth filter satisfying the following
constraints. Use the impulse invariance technique.
0.5 | H (e j ) | 1, for 0 /2
| H (e j ) | 0.2,
for 3 /4
|H()
|
1
0.707
0.2
0
/2 3/4
dB (= 20 log10 |H()|)
0
/2 3/4
13.98
Solution The critical frequencies are 1 = /2, 2 = 3 /4. Use = T to determine the analog
frequencies 1 and 2. Note T is not given. Take T = 1, so that = .1 = . (This corresponds
to the pre-warping step of the bilinear transformation with = (2 / T ) tan( / 2) ).
We have = .1, so that the critical frequencies are
K1 = 3.01 dB
1 = 1 = /2 rad/sec. (= c)
K2 = 13.98 dB
2 = 2 = 3/4 rad/sec.
The order of the filter is given by
10 K1 / 10 1
10 3.01/10 1
2 1
log
log
10 K 2 / 10
10 13.98/10 log10
10
1
10
1
25.003 1
N=
=
=
/2
2
1
2 log 10
2 log 10
2 log10
3 / 4
3
13.8
=
= 3.919 = 4
2 (0.176)
c is already known to be /2 rad/sec.
The 4th order normalized Butterworth filter (with unit bandwidth) is
1
Ha(s) (normalized) = 4
3
s 2.613 s 3.414 s 2 2.613 s 1
Using the low pass to low pass analog transformation s ( s / c ) or s (s / 1.57) we get the
Butterworth filter satisfying the required specs:
1
Ha(s) =
4
3
2
s
s
s
s
2.613
3.414
2.613
1
1.57
1.57
1.57
1.57
For the impulse invariant design we need the poles of Ha(s), so the above form is not much help.
We need to use the factored form:
1
Ha(s) (normalized) = 2
( s 0.76536 s 1) ( s 2 1.84776 s 1)
And with s (s / 1.57) , we have
1
Ha(s) =
2
2
s
s s
s
0.76536
1
1.84776
1
1.57 1.57
1.57
1.57
Put this into partial fraction form. We need the poles individually since we need to use the
relation
(s = s1) (z = e s1T ), with T = 1 of course
to get H(z) from the Ha(s). Once we get the Ha(s) we can then combine complex conjugate pole
pairs to biquadratic form and then implement as a parallel form with two biquadratics in it.
Alternatively, memorize relations 3(c) and 3(d). This latter gives the biquadratics directly.
This same problem will next be solved using the bilinear transformation to show the
difference.
2
tan with T = 1 gives
Step 1: Pre-warping according to =
2
T
1
( / 2)
1 = 2 tan
= 2 tan
= 2 rad / sec
2
2
(3 / 4)
2 = 2 tan 2 = 2 tan
= 4.828 rad / sec
2
2
Step 2: Design Ha(s)
10 3.01/ 10 1
log
10 13.98/ 10
1
10
N=
=?
2
2 log 10
4.828
1
c =
=?
2N
10 K1 /10 1
Step 3: H(z) = H a ( s)s 2(1 z 1 )
1 z 1
Example 5.6.4 Design a low pass digital filter by applying impulse invariance to an appropriate
Butterworth continuous-time filter. The digital filter specs are:
1 dB 20 Log |H()| 0,
20 Log |H()| 15 dB,
0 || 0.2
0.3 ||
Solution First convert the digital frequencies to analog frequencies . The mapping between
and is linear in the absence of aliasing. We shall use = T with T = 1. Thus the specs
become
1 dB 20 Log |Ha()| 0,
20 Log |Ha()| 15 dB,
0 || 0.2
0.3 ||
dB (= 20 log10 |H|)
0 0.2
K1 = 1 dB
0.3
K2 = 15 dB
10 K1 / 10 1
10 ( 1) / 10 1
log 10 ( 15) / 10 log 10 1.259 1
log10 K 2 / 10
1
1
31.6228 1
10
10
N=
=
=
0.2 2 log 10 0.6666
2 log10 1 2 log 10
0.3
0.2589
log10 30.6228 log 0.0085 2.0729
=
10
=
= 5.885 = 6
=
2 0.1761 2 0.1761 2 (0.3827)
1
0.2
0.2
0.2
c =
= 12
= 12
=
= 0.703 rad/sec
2N
0.8935
1.2589 1
0.2589
10 K1 / 10 1
s
0.703
To be completed
Example 5.6.5 [2003] [The Butterworth circle and the bilinear transformation] Refer to
Oppenheim & Schafer, Sec. 5.1.3 and Sec. 5.2.1. The bilinear transformation is given by
1 ( sT / 2)
2 (1 z 1 )
s=
or
z=
1
T (1 z )
1 ( sT / 2)
This last equation is used to map the poles on the Butterworth circle in the s-plane into poles on
the Butterworth circle in the z-plane. For the normalized Butterworth filter with a cut-off
frequency of 1 rad/sec., the Butterworth circle in the s-plane has unit radius. If the cut-off
frequency is c instead of 1, then the circle has a radius of c. This is the case in the example on
pp. 212-214 of Oppenheim & Schafer where the order N of the filter is 3, the radius of the
Butterworth circle in the s-plane is c, and cT = which corresponds to a sampling frequency
of twice the cut-off frequency (Figure 5.14).
For the two poles at s = c and s = c and cT = we get
1 ( cT / 2) 1 (1 / 4)
s = c:
z=
=
= 3/5
1 ( cT / 2) 1 (1 / 4)
1 ( cT / 2) 1 (1 / 4)
s = c:
z=
=
= 5/3
1 ( cT / 2) 1 (1 / 4)
Both of these z-plane poles are on the real axis as shown in figure below.
j
jc
Unit circle
Im
z-plane
j1
s-plane
3/5
Re
1
5/3
Radius = c
Butterworth circle
in the s-plane
Butterworth circle
in the z-plane
The other s-plane poles are similarly mapped to z-plane poles, though the algebra involved is a
little more. Note that the three poles in the left-half of the s-plane are mapped into the inside of
the unit circle in the z-plane.
K1 = 3.01 dB
K2 = 15 dB
Thus
1
= 0.5 rad,
2000
1
2 = 2T = 1500
= 0.75 rad,
2000
1 = 1T = 1000
K1 = 3.01 dB
K2 = 15 dB
Step 1 Pre-warping. Use T = 1. (In Steps 1 and 3 we could have used T = 1/2000 but the two
occurrences of T would cancel out).
1
2
2
and
1 = tan = 2.0 rad/sec.
2 = tan 2 = 4.828 rad/sec.
T
T
2
2
Step 2 Design Ha(s), i.e., determine the low pass Butterworth filter (see earlier example).
10 3.01/ 10 1
log 10 2 1
log 10 15/ 10
1
31.62 1 = 1.486 = 1.941 = 2
10
N=
=
2 2 0.3827 2 (0.3827)
2
log
10
4.828
2.0
2
c =
= 4
= 2 rad / sec
3.01/ 10
4
2 1
10
1
Do analog low pass to low pass transformation s(s/c), i.e., s(s/2) in order to move the cutoff frequency from 1 to 2 rad/sec. This gives the Ha(s) with pre-warped specs and c = 2 rad/sec.
1
1
Ha(s) = 2
=
2
s 2 s 1 ss / 2 ( s / 2) 2 ( s / 2) 1
4
= 2
(with a cut-off frequency = 2 rad/sec.)
s 2 2s4
2 (1 z 1 )
to Ha(s) with T = 1 will transform
T (1 z 1 )
the pre-warped analog filter into a digital filter with system function H(z) that will satisfy the
given requirements:
1 2 z 1 z 2
4
H(z) = H a ( s) s 2(1 z 1 ) =
=
2
3.414 0.585 z 2
(1 z 1 )
2(1 z 1 )
2(1 z 1 )
2 2
4
1
1
1
z
1
Example 5.7.2 [2002] Derive the Butterworth digital filter having the following specs:
Pass band: 0 to 4411 rad/sec.
Maximum ripple in pass band: 1 dB
Stop band: beyond 25975 rad/sec.
Minimum attenuation in stop band: 60 dB
Sampling frequency: 20 kHz
dB (= 20 log10 |H|)
0 0.221 1.299
1 dB
60 dB
Solution Even though pass band ripple may suggest a Chebyshev filter we shall comply with the
request for a Butterworth filter. We use bilinear transformation.
Analog frequency specs are given. Convert them to digital by using the relation = T
and T = (1/20000) sec.
1 = 4411 rad/sec. becomes 1 = 1T = 4411/20000 = 0.221 rad
2 = 25975 rad/sec. becomes 2 = 2T = 25975/20000 = 1.299 rad
Now, starting from these digital specs the design proceeds in 3 steps as usual.
Step 1 Pre-warp the critical digital frequencies 1 and 2 using T = 1 sec., to get
0.221
2
1 = tan 1 = 2 tan
= 2 tan 0.11 = 0.221 rad/sec.
2
T
2
2 =
1.299
2
tan 2 = 2 tan
= 2 tan 0.650 = 1.519 rad/sec.
2
T
2
Step 2 Design an analog low pass filter with critical frequencies 1 and 2 to satisfy
0 20 log |Ha(j 1 )| 1 dB = K1, and
20 log |Ha(j 2 )| 60 dB = K2
The Butterworth filter of order N and cut-off frequency c is given by equations (3.16) and
(3.17) of Ludeman:
10 K1 / 10 1
10 1 / 10 1
1
log10 1.259
log
log
10 K 2 / 10
10 60 / 10
6
1
1
10
10 1
10
N=
=
=
1.519
2
1
Ha(s) = 4
3
2
s 2.613 s 3.414 s 2.613 s 1 s ( s / 0.262)
Example 5.7.3 [2002] Design a digital LPF using bilinear transformation with the following
specifications, and a Butterworth approximation:
2 dB at 5 rad/sec.,
23 dB at 10 rad/sec.,
Sampling frequency = 1000 per sec.
dB (= 20 log10 |H|)
0
K1 = 2
K2 = 23
0.005
0.01
Solution Convert the analog specs to digital using = T, with T = 1/1000 sec. The critical
frequencies are
1 = 1T = 5/1000 = 0.005 rad;
K1 = 2 dB
2 = 2T = 10/1000 = 0.01rad;
K2 = 23 dB
Now apply Steps 1, 2 and 3 of the bilinear transformation design process.
Example 5.7.4 [2003] Design a digital filter that will pass a 1 Hz signal with attenuation less
than 2 dB and suppress 4 Hz signal down to at least 42 dB from the magnitude of the 1 Hz
signal.
dB (= 20 log10 |H|)
0
K1 = 2
42 dB
K2 = 44
Solution All the specs are given in the analog domain. The sampling period T is not specified.
Since 1 Hz is in the pass band and 4 Hz in the stop band we shall use some multiple of 4 Hz, say,
20 Hz as the sampling frequency. Thus T = 1/20. We shall employ the impulse invariance
method.
Step 0 Convert the analog specs to digital by using = T = 2FT. Thus
1 = 2 .1 =2 rad/sec., and
2 = 2 . 4 = 8 rad/sec.
so that 1 = 2T = 2 (1/20) = 0.1 rad., and 2 = 8T = 8 (1/20) = 0.4 rad.
Step 1 Convert the digital frequencies 1 and 2 back to analog frequencies. Since we are using
impulse invariance this involves using the same formula = T and we get the same analog
frequencies as before, viz., 1 = 2 rad/sec., and 2 = 8 rad/sec. (Note that the value of T is
irrelevant up to this point. We could have used a value of T = 1 in Steps 0 and 1, resulting in
awkward values for the s, like 2 and 8 when we expect values between 0 and ; but this is
not a problem for the design).
Step 2 Determine the order of the analog Butterworth filter.
10 K1 / 10 1
10 2 / 10 1
log
log
10 K 2 / 10
10 10 44 / 10 1
10
=
N=
2
2 log10 1 2 log 10
8
1.585 1
log 10 25118.8 1
2 0.602
4.633
=
= 3.848 = 4
1.204
Cutoff frequency c is determined next:
2
1
2
2
c =
=
= 8
=
= 6.719
2N
1.585 1 0.93515
10 K1 /10 1 8 10 2 / 10 1
Step 3 The normalized filter Ha(s) of order 4 is
1
Ha(s) = 2
( s 1.848s 1) ( s 2 0.765s 1)
We may break it down into partial fractions now (before making the transformation s(s/c).
As B
Cs D
Ha(s) = 2
+ 2
s 1.848s 1 s 0.765s 1
Determine A, B, C, and D and then substitute s(s/c).
Alternatively, we can get the individual pole locations from the Butterworth circle.
1
Ha(s) =
( s 0.924 j 0.383) ( s 0.924 j 0.383) ( s 0.383 j 0.924) ( s 0.383 j 0.924)
=
A*
C*
C
A
+
+
+
s s1*
s s2*
s s1
s s2
Determine A, A*, C and C*. Next find H a (s) s ( s / ) which is the analog prototype. From this we
c
can find the H(z) by mapping the s-plane poles to zplane poles by the relation: (s = s1) (z =
e s1T ). Here at last we must specify T; we could use T = 1/20. In general, the smaller the value of T
the better.
z
z
z
z
*
Ha(z) = A
+ A*
+
C
+
C
*
*
s1T
s
T
ze
ze 2
z e s1T
z e s2T
If we were to use the bilinear transformation use some value of T like 1/20 (justifying it
on the basis of the sampling theorem) in = T in Step 0.
Example 5.7.5 [Low pass filter] Design a digital low pass filter to approximate the following
transfer function:
1
Ha(s) = 2
s 2 s 1
Using the BZT (Bilinear z-transform) method obtain the transfer function, H(z), of the digital
filter, assuming a 3 dB cut-off frequency of 150 Hz and a sampling frequency of 1.28 kHz.
Solution This problem is a slight variation from the pattern we have followed so far in that it
specifies one critical frequency (cut-off frequency) and the filter order instead of two critical
frequencies with the filter order unknown.
Step 0 Convert the analog specs to digital
c = 2Fc = 2 150 = 300 rad/sec.
2
1
0.7715
0.7715
Step 3 Applying the BZT (with T = 1)
1
H(z) = H a ( s) s 2(1 z 1 ) =
2
T (1 z 1 )
2(1 z 1 )
2(1 z 1 )
1
1
1
(1 z ) 0.7715
(1 z ) 0.7715
=
0.0878 (1 2 z 1 z 2 )
1 1.0048 z 1 0.3561 z 2
Example 5.7.6 [Low pass filter] Design a low pass digital filter derived from a second order
Butterworth analog filter with a 3 dB cut-off frequency of 50 Hz. The sampling rate of the
system is 500 Hz.
Solution (This is similar to Example 10). The second order Butterworth analog filter is
1
Ha(s) = 2
s 2 s 1
Step 0 Convert the analog specs to digital
c = 2Fc = 2 50 = 100 rad/sec.
The corresponding digital frequency is
1
c = cT = 100
= 0.2 rad.
500
Step 1 Pre-warp (with T = 1)
2
0.2
c = tan c = 2 tan
= 0.6498
T
2
2
Step 2 Ha(s) is given to be of order 2. We only need to do the analog low pass to low pass
transformation.
1
0.42229
=
= 2
2
s 0.91901 s 0.42229
s
s
2
1
0.6498
0.6498
Step 3 Applying the BZT (with T = 1)
0.42229
H(z) = H a ( s) s 2(1 z 1 ) =
2
T (1 z 1 )
2(1 z 1 )
2(1 z 1 )
0
.
91901
0.42229
1
1
(1 z )
(1 z )
0.42229 1 z 1
4 1 z 1 (0.91901)(2) 1 z 1 1 z 1 0.42229 1 z 1
The denominator is
Dr = 41 2 z 1 z 2 1.838021 z 2 0.422291 2 z 1 z 2
Dr = (4 1.83802 0.42229) z 1 (8 0.84458) z 2 (4 1.83802 0.42229)
Dr = 6.26031 7.15542 z 1 2.58427 z 2
H(z) =
0.42229 (1 2 z 1 z 2 )
6.26031 7.15542 z 1 2.58427 z 2
0.06746 (1 2 z 1 z 2 )
6.26031 1.14298 z 1 0.4128 z 2
)
T (1 z 1 )
with T = 1 sec.
Bilinear
Analog specs given:
1, 2 (rad./sec.),
K1, K2 (dB), and
T
Step 0. (Preparation)
Use = T to convert to
Get 1, 2, and K1, K2
Then
(1)
(2)
As in the left side column
(3)
Impulse invariance
Digital specs given:
1, 2,
K1, K2, and
T (or T = 1)
(1) Determine 1, 2 using = T
(2) Find filter order N, cut-off frequency c
Find normalized filter Ha(s)
Find H a ( s) s ( s / )
c
K2
20 log10 |H(j)|
0 dB
K1
K2
0
s s c
c
transforms a low pass filter with a cut-off (or critical) frequency c to a low pass filter with a
cut-off (or critical) frequency c .
2. Low-pass to high-pass transformation Given G(s) as above the transformation s c/s
will transform the low-pass G(s) into a high-pass filter H(s) with cut-off frequency of c:
H(s) = G( s) s c / s
The critical frequency r of the filter G(s) is changed to r of H(s), given by r = c/r.
20 log10 |H(j)|
0 dB
K1
K2
There are similar transformations from low-pass to band-pass and low-pass to band-stop.
Refer to table 3.2, page 128, Ludeman.
The Low-pass prototype analog unit bandwidth filter could be any analog filter such as
Butterworth, Chebyshev etc. of any order, any ripple etc.
Digital-to-digital transformations Similarly, a set of transformations can be found that take a
low-pass digital filter and turn it into another low-pass or high-pass or band-pass or band stop
digital filter. Refer to Sec 4.3, p. 181, Ludeman.
|H(j)|
N is odd
N=5
A
N is even
N=6
B
0
Type II (Chebyshev II or Inverse Chebyshev) filter has both poles and zeros. It has a
monotonically decreasing shape in the pass band and an equiripple behavior in the stop band.
|H(j)|
1
Design of the Chebyshev I filter A typical magnitude response specification is sketched below
(shown for N = 5 and N = 6). The magnitudes at the critical frequencies 1 and 2 are A and B,
respectively. Typically 1 is in the pass band or is the edge of the pass band and 2 is in the stop
band or is the edge of the stop band. In terms of the log-magnitude the analog filter specifications
are as below. Note that (20 log A) = K1 dB and (20 log B) = K2 dB. If A and B are less than 1, K1
and K2 are negative.
0 20 log10 H ( j) K1 for all 1
|H(j)|
N is odd
N=5
A
N is even
N=6
B
0
where has to do with pass band ripple and CN(x) is the Nth order Chebyshev cosine polynomial
defined as
CN(x) = cos N cos 1 x ,
x 1 (pass band)
[Aside If the frequencies are normalized, that is, for a normalized filter, 1 = 1 rad/sec and the
magnitude characteristic of the Nth order Chebyshev I filter is given by
1
|H(j)| =
,
N = 1, 2,
2 2
1 C N
End of Aside]
At = 0 we have
CN(0) = cos N cos 1 0 = cosN / 2
= 0, N odd
1, N even
As a consequence, on the vertical axis ( = 0) the magnitude curve starts at |H(j0)| = 1 for odd N
1
and at |H(j0)| = A =
for even N.
1 2
At = 1 we have CN(1) = cos N cos 1 1 = cos 0 = 1 for all N. The corresponding
magnitude is
1
|H(j1)| = A =
,
for all N
1 2
This equation is used to compute from the given |H(j)|.
The order, N, of the filter is given by
10 K 2 /10 1
cosh 1
10 K1 /10 1
N=
cosh 1 2
The symbol means that the computed result is rounded to the next larger integer. For
example, if N = 3.2 by the above calculation then it is rounded up to 4, and the order of the
required filter is N = 4. In such a case the resulting filter would exceed the specification at both
1 and 2.
Example 5.9.1 [Filter order] Determine the order of a Chebyshev I filter to have an attenuation
of no more than 1 dB for || 1000 rad/sec and at least 10 dB for || 5000 rad/sec.
Solution The specifications as given are
0 20 log10 H ( j) 1 dB for all 1000 rad/sec
10 1
1
10 K 2 /10 1
1
1 10
cosh 1
cosh
cosh
K1 / 10
1 / 10
1
.
2589
1
10
1
10
N=
=
=
1
5000
cosh
5
1
cosh 1 2
cosh
1000
cosh 1 5.8956 2.4601
=
=
1
= 1.073 = 2
cosh 5 2.2924
[On the HP 15C, cosh 1 5.8956 is obtained by: (1) Enter Radian mode, (2) Enter 5.8956, (3) g,
(4) HYP 1 , and (5) COS]
Pole locations and transfer function The poles of the Chebyshev I filter are related to those of
the Butterworth filter of the same order and are located on an ellipse in the s-plane. If N is odd
there will be a pole on the negative real axis. In order to find the pole locations and hence the
transfer function we introduce the parameter
1
= sinh 1 1 /
N
The poles of H(s), sk = k + jk, k = 0, 1, , (N1), are given by
2k 1
2k 1
k = sin
and
k = cos
cosh
sinh
N 2
N 2
j
cosh
j1
sinh
j1
Note that if the sinh and cosh terms were not present we would have the pole locations of
the normalized Butterworth filter (on the unit circle), that is,
2k 1
2k 1
k = sin
k = cos
and
N 2
N 2
with k2 2k = 1 which is the unit circle. Thus, the hyperbolic sine and cosine terms are scale
factors which, when applied to the Butterworth pole coordinates, give the pole coordinates of a
Chebyshev I filter of the same order. The Chebyshev poles are located on an ellipse in the splane described by
k2
2k
+
=1
sinh 2 cosh 2
The major axis of the ellipse is on the imaginary (j) axis and the minor axis is on the real axis
and the foci are at = 1. The 3 dB cut-off frequency occurs at the point where the ellipse
intersects the j axis, that is, at = cosh .
In putting together the transfer function, H(s), we rely on the symmetry of pole positions
and make use of the left half plane poles only. Finally, the pole positions are scaled by the actual
cut-off frequency 1. This last step amounts to s s/1 (in the case of the Butterworth design
this was s s/c).
Example 5.9.2 [Pole locations and transfer function] Find the pole locations and the transfer
function of the Chebyshev I filter designed in above example, that is, with an attenuation of no
more than 1 dB for || 1000 rad/sec and at least 10 dB for || 5000 rad/sec.
Solution The filter order has been determined above as N = 2. Further, we know that |H(j1)| =
1 1 2 and 20 log H ( j1 ) = 1 dB. Thus
20 log 1 1 2 = 1
Solving for we get = 0.5088. Since N is even |H(j0)| = 1 1 2 = 0.8913 is the starting point
on the vertical axis.
With regard to the pole locations, if it were a Butterworth filter of order 2 the poles are
located at
2k 1
2k 1
k = sin
k = cos
k = 0, 1
,
and
N 2
N 2
s0,1 = sin
j cos
= 1 2 j 1 2
4
4
The Chebyshev I poles are then obtained from the Butterworth poles by scaling the real and
imaginary parts, respectively, by sinh and cosh and then scaling both parts by 1:
Example 5.9.3 [Ramesh Babu] Determine the order of a Chebyshev I filter to have a gain of 3
dB or better for |F| 1000 Hz and a gain of 16 dB or less for |F| 2000 Hz. Find the pole
locations and the transfer function.
Solution The specifications as given are
0 20 log10 H ( j) 3 dB for all 2 (1000) rad/sec
39.81 1
1
10 K 2 /10 1
1
1 10
cosh 1
cosh
cosh
K1 / 10
3 / 10
1
.
995
1
10
1
10
N=
=
=
1
4000
cosh
2
1
cosh 1 2
cosh
2000
cosh 1 6.2445 2.5184
=
=
1
= 1.9122 = 2
cosh 2 1.3169
2.
H(s) =
K
K
= 2
s 2sa a 2 b 2
D (s )
2:
a b2
K=
2
2
K
|H(j0)| = 2
=1
a b2
Thus
H(s) =
1
a 2 b2
2
2
2
2 s 2sa a b
= 19739005.5
1
s 4043.8s 27915169.3
2
Design of the Chebyshev II filter A typical magnitude response specification is sketched below.
The magnitudes at the critical frequencies 1 and 2 are A and B, respectively. Typically 1 is in
the pass band or is the edge of the pass band and 2 is in the stop band or is the edge of the stop
band. In terms of the log-magnitude the analog filter specifications are as below. Note that (20
log A) = K1 dB and (20 log B) = K2 dB. If A and B are less than 1, K1 and K2 are negative.
0 20 log10 H ( j) K1 for all 1
B
0
1 2
C
(
)
1 2 N2 2 1
C N ( 2 / 1 )
At = 0, CN (2 / ) = C N () , and the magnitude becomes
|H(j0)| =
= 1 for all N
2
C
(
)
1 2 N2 2 1
C N ( 2 / 0)
The magnitude curve starts at |H(j0)| = 1 on the vertical axis for all N.
At = 2 we have CN (2 / 2 ) = C N (1) = cos N cos 1 1 = cos0 = 1
1
1
|H(j2)| =
=
C 2 ( / )
C 2 ( / )
1 2 N2 2 1
1 2 N 2 1
1
C N ( 2 / 2 )
1
=
= B, for all N
2 2
1 C N ( 2 / 1 )
The order, N, of the filter is given by
10 K 2 /10 1
cosh 1
K1 / 10
10
N=
cosh 1 2
The symbol means that the computed result is rounded to the next larger integer. For
example, if N = 3.2 by the above calculation then it is rounded up to 4, and the order of the
required filter is N = 4. In such a case the resulting filter would exceed the specification at both
1 and 2.
Example 5.9.4 [2009] If an analog low pass filter is to have an attenuation of 1 dB at cut-off
frequency of 1 kHz, and a maximum stop band ripple of 0.01 for |F| > 5 kHz, determine the
required the filter order for (a) a Butterworth filter, (b) a Chebyshev I filter, and (c) a Chebyshev
II filter.
Solution The specifications are the same for all three cases but the magnitude characteristic
differs from one case to the next.
(a) The Butterworth magnitude (absolute value) characteristic is sketched below.
1 = 2F1 = 2 1000 rad/sec.,
2 = 2F2 = 2 5000 rad/sec.,
K1 = 1 dB
B = 0.01
A = 0.8912
K2 = 40 dB
|Ha(j)|
1
A =0.8912
B = 0.01
1= 21000
2= 25000
, rad./sec.
The relation between the absolute values and the dB figures (K1 = 20 log A and K2 = 20 log B) is
used to compute A = 10 K1 / 20 = 10 1/ 20 = 0.8912 and K2 = 20 log B = 20 log 0.01 = 40 dB.
The Butterworth filter order is given by
10 K1 / 10 1
10 ( 1) /10 1
10 0.1 1
log
log
log
10 K 2 / 10
10 10 ( 40) /10 1 10 10 4 1
10
=
N=
1
1
2 log 10
2 log10 1
2 log 10
5
5
2
1.25892 1
log10 10000 1 4.5868
=
=
= 3.28 = 4
2 log 10 0.2
1.3979
(b) The Chebyshev I specs and magnitude (absolute value) characteristic are diagrammed below.
As earlier we compute A = 10 K1 / 20 = 10 1/ 20 = 0.8912 and K2 = 20 log B = 20 log 0.01 = 40 dB.
1 = 2F1 = 2 1000 rad/sec.,
2 = 2F2 = 2 5000 rad/sec.,
|H(j)|
K1 = 1 dB
B = 0.01
|H(j)|
N is odd
N =?
A
A = 0.8912
K2 = 40 dB
N is even
N =?
B
0
10 K 2 /10 1
cosh 1
K1 / 10
10
=
N=
cosh 1 2
1
cosh 1 38617.3
=
cosh 1 5
( 40) / 10
1
1 10000 1
1 10
cosh
cosh
0.1
( 1) / 10
10 1
10
1 =
cosh 1 5
1 5
cosh
(c) The Chebyshev II specs and magnitude (absolute value) characteristic are shown below. As
earlier we compute A = 10 K1 / 20 = 10 1/ 20 = 0.8912 and K2 = 20 log B = 20 log 0.01 = 40 dB.
1 = 2F1 = 2 1000 rad/sec.,
K1 = 1 dB
A = 0.8912
B = 0.01
K2 = 40 dB
|H(j)|
1
A
B
0
1 2
1
10 K 2 /10 1
1 10000 1
1 10
cosh 1
cosh
cosh
K1 / 10
0.1
( 1) / 10
10
1
10
1
10
N=
=
=
1
cosh
5
1
cosh
cosh 1 2
cosh 1 38617.3 cosh 1 (196.5) 5.9738
=
=
=
1
= 2.6059 = 3
cosh 1 5
cosh 5 2.2924
Example 5.9.5 [2009] Determine the system function H(z) of the lowest order Chebyshev filter
that meets the following specs. Use the impulse invariance method.
(a) 0.5 dB ripple in the pass band, 0 || 0.24
(b) At least 50 db attenuation in the stop band, 0.35 ||
Solution We assume the Chebyshev I filter. The procedure is similar for the Chebyshev II. The
specs are:
1 = 0.24 rad.,
2 = 0.35 rad.,
K1 = 0.5 dB
K2 = 50 dB
A = 10 K1 / 20 = 0.94406
B = 10 K2 / 20 = 0.0031622
The sampling time, T, is not specified. Since this is impulse invariant design, T should be very
small the smaller the better. Strictly for convenience we shall use T = 1 sec., and convert the
digital specs to analog using the relation = T.
1 = 1/T = 0.24 rad/sec,
2 = 2/T = 0.35 rad/sec,
K1 = 0.5 dB
K2 = 50 dB
A = 10 K1 / 20 = 0.94406
B = 10 K2 / 20 = 0.0031622
|H(j)|
1
A = 10 K1 / 20
B = 10 K2 / 20
1 =
0.24
2 =
0.35
10 ( 50) /10 1
10 K 2 /10 1
1
1 100000 1
cosh 1
cosh
cosh
K1 / 10
( 0.5 ) / 10
0.05
10
1 =
10 1
10
1 =
N=
cosh 1 1.4583
0.35
cosh 1
cosh 1 2
0.24
|H(j)|2
N is odd
N=5
1/(1+2)
N is even
N=6
1/(1+2)
0
c
0
c