Math Course Work
Math Course Work
EE3SPR
SIGNAL PROCESSING
ASSESSMENT 1
By:
CHUA Kok Vee
(074152883)
Submitted on
23rd April 2009.
The aim of this assessment is to design a low pass filter using the MATLAB
software. The following report shows how the design of the filter is done to achieve
the objectives as given in the question.
Objectives:-
Designs Approach.
There are two approaches in achieving the above objectives for the assessment.
One approach would be to place poles and zeros in the s-plane to give a suitable
frequency response; to adopt an active or passive filter implementation; and to
calculate component values appropriately.
Another approach that can be used to achieve the above objectives are by
investigating classical filter designs, for example Butterworth filter, Chebychev type 1
filter, Chebychev type 2 filter or Elliptic filter.
The following report here is based on the later approach where an investigation of
classical filters between the Butterworth filter and the Chebychev which are
compared and investigated.
Before implementing the filters, there are several MATLAB library functions which
are useful to the assessment. These are stated on the next topic.
Some procedure and steps have to be taken in designing the low pass filter. Apart
from those procedures, library files are also used for easy implementation. The
library files that are used in designing the low pass filters are ‘lp2lp’, ‘zp2tf’, ‘cheb1ap’
and ‘buttap’.
‘lp2lp’ means low pass to low pass analogue transformation. It simply transforms the
low pass filter prototype NUM(s)/DEN(s) with unity cut off frequency of 1 rad/s. The
command to use this function is shown below:-
[NUM, DEN] = LP2LP (NUM, DEN, Wo);
where NUM = Numerator,
DEN = Denominator,
Wo = Cut off Frequency.
‘cheb1ap’ is a type 1 analogue low pass filter prototype that is available in the
MATLAB library. It returns the zeros, poles and gain of an Nth order normalised low
pass filter when used. The command to use this function is shown below:-
[Z,P,K] = CHEB1AP(N, Rp);
where Z = Zeros,
P = Poles,
K = Gain,
N = Order of filter,
Rp = Decibels of ripple in passband.
[z, p, k] = cheb1ap(Filter_Order,0.5);
The filter designed is a 4th order Chebyshev type 1 filter. The passband ripple
selected is 0.5dB. The cut-off frequency as above on the program listing is
programmed to be 3000 Hz where it is converted to radians as shown above in line
4. Figure below shows all the characteristics of the frequency response for the low
pass filter designed.
As shown on figure of frequency response above, it can be seen that the cut-off
frequency for the filter designed is 3.27 kHz at -3dB point and also it has at least
20dB of attenuation at 5 kHz as required for the design objectives.
After this filter has been finalized, certain coefficients and values can be determined
from MATLAB. With these values and the transfer function of the filter known, the
component values can be determined and also pole-zero can be plotted.
Below are the coefficients of the filter designed obtained from the MATLAB. These
coefficients are the transfer function for a low pass filter of chebyshev type 1 filter:-
nc(s) = 4.5175e+016
dc(s) = 1.0e+016 *
(0.0000 0.0000 0.0000 0.0007 4.7852)
s4 s3 s2 s1 s0
Using the coefficients, the transfer function of the chebyshev filter looks like this:-
Then using the function ‘tf2zp’, we can convert the transfer function with the
coefficients above to give the position of poles and zeros. The command to do this is
shown below. It will return the coefficients of poles, zeros and gain of the filter.
From the pole-zero coefficients, the diagram for zero-pole plot can be drawn also
using the MATLAB program. To plot the zero-pole figure, the command used is
shown.
From the plot above, there are no zeroes and there are 4 poles located on the left
hand side of the s-plane. This determines that the filter is stable and it is in the order
of 4.
[z, p, k] = buttap(Filter_Order);
================================================================
The filter designed is based on a 5th order Butterworth filter. The cut-off frequency as
above on the program listing is programmed to be 3000 Hz where it is converted to
radians as shown above in line 4. Figure below shows all the characteristics of the
frequency response for the low pass filter designed.
As shown on figure of frequency response above, it can be seen that the cut-off
frequency for the filter designed is 2.99 kHz at -3dB point and also it has at least
20dB of attenuation at 5 kHz as required for the design objectives.
After this filter has been finalized, certain coefficients and values can be determined
from MATLAB. With these values and the transfer function of the filter known, the
component values can be determined and also pole-zero can be plotted.
Below are the coefficients of the filter designed obtained from the MATLAB. These
coefficients are the transfer function for a low pass filter of 5th Order Butterworth
Filter:-
nc(s) = 2.3796e+021
dc(s) = 1.0e+021 *
(0.0000 0.0000 0.0000 0.0000 0.0004 2.3796)
s5 s4 s3 s2 s1 s0
Using the coefficients, the transfer function of the 4th order Butterworth filter looks like
this:-
Then using the function ‘tf2zp’, we can convert the transfer function with the
coefficients above to give the position of poles and zeros. The command to do this is
shown below. It will return the coefficients of poles, zeros and gain of the filter.
From the pole-zero coefficients, the diagram for zero-pole plot can be drawn also
using the MATLAB program. The zero-pole plot is shown below. To plot the zero-
pole figure, the command used is also shown
From the plot above, there are no zeroes and there are 5 poles located on the left
hand side of the s-plane. This determines that the filter is stable and it is in the order
of 5.
From the above investigation of the two filters, namely the Butterworth Filter and the
Chebychev Filter, there are some differences required in the design to achieve the
required objectives in designing a low pass analogue filters as required for the
assessment. Also these two filters have different characteristics. These differences
are:-
The Chebychev filter only needs a 4th order to achieve the following objectives
while the Butterworth filter requires an order of 5 only then it can achieve the
objectives.
Chebychev has a steeper roll off rate as compared to the Butterworth filter. As
a result, the Butterworth requires a higher order in order to achieve an
attenuation of 20dB at 5 kHz.
Conclusions
In conclusion with investigating the two above filters as described, a low pass
Chebychev filter is more efficient than a low pass Butterworth filter. This is because a
Chebychev filter requires a lesser amount of order to achieve the main objectives of
the design as compared to Butterworth filter as investigated above. This is because
of the characteristics of the Chebychev filter which has a steeper roll off rate than the
Butterworth filter. Overall the Chebychev filter requires lesser components to build.