Sie sind auf Seite 1von 5

EXPERIMENT V

Digital Filter
I. Objectives
Student able to explain the definition of filer, digital filter, FIR, IIR,
transfer function, magnitude response and phase response.
Student able to demonstrate transfer function, magnitude and phase
response from a discrete time system using MATLAB.

II. Scope

A. Brief Theory
Filter is a system or network which selectively change characteristics
(wave length, frequency, phase and amplitude) from a signal to enhance the
quality of a signal [1][2][3][4].
Generally, objectives of filter is to enhance the quality of a signal for
example to reduce or remove noise, get signal-carried information or to
separate combination of two or more signals which is combined in order to
use available communication channel efficiently.
Digital filter is implementation of mathematical algorithm into
hardware and/or software which operate on input signal to produce digital
signal output in order to reach filter objectives[10][11].
Digital filter application are for data compression, sound processing,
image processing, data transmission and echo canceller in telephone.

h(k), k = 0,1,...
x(n) y(n)
Digital signal input Digital signal output
Figure 5.1
h(k ) Impulse response (Kernel) or digital filter coeficient s
which determine the type and characteristics of a digital filter

Based on the block diagram above, generally filter can be divided in


two. They are digital filter FIR and digital filter IIR.
N 1
FIR: y(n) h(k)x(n k)
k 0
N M
IIR: y(n) h(k)x(n k) ak x(n k) bk y(n k)
k 0 k 0 k 1
Advantage of digital filter to the analog filter:
Can have characteristics which impossibly owned by analog filter,
like linear phase response.
Its characteristics are not change by the environment change, like the
change of temperature, humidity and so on, therefore repeated
calibration is not required.
Frequency response can be set automatically because implemented
by using processor which can be programmed. So that digital filter
can adapt.

Digital Signal Processing Guidance Computer Engineering Laboratory


Experiment V Page: 1 of 5
Can filter some input signal or channel with only one filter without
having to make the hardware again.
Filtered or unfiltered data can be saved for another need
With the growth of large scale IC technology, the dimension become
smaller, lower power usage and cheaper price.
Its accuracy only limited by the word length of the processor
Can be used at very low frequency which is usually needed by
biomedical application.
Can be made with a wide range frequency by only set its sampling
frequency

Disadvantages of digital filter to analog filter:


The speed is limited by the processor speed and arithmetical
operation conducted by filter algorithm.
Maximum bandwidth smaller compared to analog filter because
limited by its sampling frequency.
Conversion time from ADC and settling time from DAC limit the
highest frequency that can be processed.
Round-off noise produce error at analog signal quantization process
in ADC and quantization coefficient in which the higher the filter
order, the accumulation of round-off noise will cause instability.

Transfer function is the output and input ratio in S domain (Laplace


Transform) for analog filter or Z domain (Z-Transform) for digital filter.

LAPLACE TRANSFORM
X(s) Y(s) Filter
H(s)
x(t )e
st
X (S ) dt Analog

Z TRANSFORM X(z) Y(z) Filter


H(z)
Digital
X ( z) x ( n) z
n
n

Figure 5.2

Transfer function can also viewed as Laplace transform (for analog) or


Z transform (for digital) for filter impulse response.
Frequency response is the comparison of output and input for all
sinusoidal input frequency entering the filter.

Frequency response obtained from transfer function:


For analog filter :
s j
H s H j
For digital filter :
z e j
H z H e j

Digital Signal Processing Guidance Computer Engineering Laboratory


Experiment V Page: 2 of 5
Frequency response is complex number which contain two
information, they are magnitude information in the magnitude response and
phase information in the phase response.

Magnitude Response
H j
H e j

Analog Filter Digital Filter


Phase Response
arg H j arg H e j
Analog Filter Digital Filter

Example vin R vout


C

y n ax n -by n-1
Figure 5.3

B. Devices

PC
MATLAB

III. References
1. Samuel D.Streans. (2002). Digital Signal Processing with Example in
Matlab. Edisi 1. CRC Press. New York. 978-0849310911.
2. Davis J Defatta ; Joseph G. Lucas ; William S.H. (1995). Digital Signal
Processing : A System Design Approach. John Wiley & Son.
3. Emannuel C Ifeachor. (1993). Digital Signal Processing : A Pratical
Approach. Addison-Wesley Publi.
4. John G Proakis ; Dimitris G.Manolakis. (1992). Digital Signal
Procesing, Principles, Algorithms, And Applications.2. Macmilian
Publishing. New York
5. Dag Stranneby. (2001). Digital Signal Processing & Applications.
Edisi 1. Newnes. Oxford. 0 7506 48112.
6. Richard G. Lyons. (2004). Understanding Digital Signal Processing.
Edisi 2. Prentice Hall. New Jersey. 978-0131089891.
7. Bob Meddins. (2000). Introduction to Digital Signal Processing. Edisi
1. Newnes. Oxford. 0 7506 5048 6.
8. Steven W. Smith. (1999). The Scientist and Engineer's Guide to
Digital Signal Processing. Edisi 2. California Technical Publishing.
California. 0-9660176-7-6.
9. Tentang efek penempatan pole dan zero terhadap: http://www.nst.ing.tu-
bs.de/schaukasten/polezero/en_idx.html
10. About digital filter: http://www.dspguide.com/ch14.htm
11. About filter: http://www.bores.com/courses/intro/filters/index.htm
12. Matlab HELP
Digital Signal Processing Guidance Computer Engineering Laboratory
Experiment V Page: 3 of 5
IV. Task Description and Procedure
A. Analog Filter
1. Given the transfer function of the image below

Figure 5.4
With C1=C2=100f, R1 =R2 =2000
25
H (S ) 2
S 15 S 50

Find and draw the magnitude response and phase response from the
image above in MATLAB

clear
close
F=0:1:50;
W=2*pi*F;
H=25./(((1i.*W).^2)+(15.*(1i.*W))+50);
MR=abs(H);
PR=angle(H)*180/pi;
subplot(211);plot(F,MR)
xlabel('Frekuensi (Hz)')
ylabel('Magnitude')
title('Magnitude Response')
subplot(212);plot(F,PR)
xlabel('Frekuensi (Hz)')
ylabel('Phase (degree)')
title('Phase Response')

2. If provided an analog filter schematic as follow

Figure 5.5
With R1=R2=1000and C=100f.
10
H (S )
S 20
Find and draw the magnitude response and phase response from
the image above in MATLAB

B. Digital Filter
Find the transfer function and draw the magnitude response and phase response
from digital filter with equation:
1. y[n] + 0.5y[n-1] = 2x[n-1]
2. y[n] + 1.2y[n-1] + 0.32y[n-2] = x[n]-x[n-1]

Digital Signal Processing Guidance Computer Engineering Laboratory


Experiment V Page: 4 of 5
V. Report Assignment
Use these points below in report
1. Explanation about filter, analog filter and digital filter!
2. Derive transfer function equation from figure 5.4 and figure 5.5!
3. Analyze the practicum in this experiment.
4. What is the effect of sampling frequency in digital filter?
5. Draw discrete time structure with its frequency response (Magnitude and
phase response) from this equation.
y(n) y(n) 2 y(n 1) 0.2 y(n 3) 2 x(n) 2 x(n 1) 0,5x(n 3)
Use MATLAB and explain your program!
6. Give 5 conclusions about this experiment.

Digital Signal Processing Guidance Computer Engineering Laboratory


Experiment V Page: 5 of 5

Das könnte Ihnen auch gefallen