Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
-
Upload
muslim-munawar -
Category
Documents
-
view
222 -
download
5
Transcript of Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
1/28
TUGAS
PENGOLAHANSINYAL DIGITAL
KELOMPOK 12
AGGOTA :
AHADI ANGGUN RAHARJO H1C009029
WISNU HERDANANTO H1C009032
HERU BUDIANTO H1C009033
KEMENTERIAN PENDIDIKAN DAN KEBUDAYAAN
UNIVERSITAS JENDERAL SOEDIRMAN
FAKULTAS SAINS DAN TEKNIK
PROGRAM STUDI TEKNIK ELEKTRO
PURBALINGGA
2012
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
2/28
Frekuensi cutoff yang ternormalisasi :
c=2 fcTs=21500
8000
c=0.375
saat 2M + 1 = 3
h(0)=c
n, n1
h(n)=(sin c n)(n )
=(sin0.375n)
(n)
Koefisien filter yang dihitung melalui ekspresi sebelumnya terdaftar sebagai:
h(0)=0.375
=0.375
h(1)=sin(0.3751)(10.375)
=0.2942
menggunakan symetri mengarah ke :
h(1)=h (1)=0.2942
sehingga menunda h(n) oleh M = 1 sampel menggunakan persamaan 7.2 yg diberikan :
b(0)h(01)=h (1)=0.2942b(1)=b (11)=h (0)=0.375b(2)=b(21)=h(1)=0.2942
fungsi jendela rectangular :
w rec(n)=1,MnMw rec(0)=1w rec(1)=1
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
3/28
respone impluse dengan jendela dihitung sebagai :hw (0)=h(0)wrec(0)=0.3751=0.375hw (1)=h(1)wrec (1)=0.29421=0.2942hw (1)=hw(1)=0.2942
dengan demikian menunda hw(n) oleh M = 1 diperoleh sampel :
b(0)=b(2)=0.2942,b(1)=0.375fungsi alih yang diperoleh sebagai berikut :
H(Z)=0.2942+ 0.375z1+ 0.2942z2
Y(Z)X(Z)
=H(Z)=0.2942+ 0.375z1+ 0.2942 z2
Y(Z)=0.2942X(Z)+ 0.375z1X(Z)+ 0.2942z2 X(Z)
Menerapkan z-transform balik di kedua sisi, persamaan perbedaan dihasilkan sebagai
y (n)=0.2942x (n)+ 0.375x (n)+ 0.2942x (n2)
magnitud frekuensi respone :
H(e j)=0.2942+ 0.375 e(j)+ 0.2942 e(j2)
H e( j)=e(j)[0.2942e(j)+ 0.375+ 0.2942 e(j)]
H e( j)=e(j)(0.375+ 0.5584 cos())
maka magnitud respon dan frekuensi respon diperoleh :
| H e( j)
| = | e(j)(0.375+ 0.5584cos()) |
and sudut
H e( j)=, if0.375+ 0.5884cos, n> 0
H e( j)=+ , if0.375+ 0.5884cos, n> 0
b. jendel hamming :
whm (0)=0.54+ 0.46cos (01
)=1.0
whm (1)=0.54+ 0.46cos(1
1)=0.08
wham (-1) = wham(1) = 0.54
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
4/28
The windowed impulse response is calculated as
hw (0)=h(0)wham(0)=0.951=0.95hw (1)=h(1)wham(1)=0.29420.08=0.0235hw (1)=hw(1)=0.0235
transfer function is achieved as:
H(z)=0.0235+ 0.95Z1+ 0.0235z2
c. magnitud frekuensi dan respone frekuensi :
H(e j)=0.0235+ 0.95 e(j)+ 0.0235 e(j2)
H e( j)=e(j)[0.0235 e(j)+ 0.375+ 0.0235 e(j)]
H e( j)=e(j)(0.375+ 0.047cos())
maka magnitud respon dan frekuensi respon diperoleh :
| H e( j)
| = | e(j)(0.375+ 0.047cos()) |
and sudut
H e( j)=, if0.375+ 0.047cos, n> 0
H e( j)=+ , if0.375+ 0.047cos, n< 0
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
5/28
7.2 Desain a 3-tap FIR highpass filter with a cutoff frequency of 1600 Hz and a sampling rate of 8000
Hz using :
a. rectangular window function.b. Hamming window function.
Determine the transfer function and difference equation of the designed FIR system, andcompute and plot the magnitude frequency response for =0, /4, /2, 3/4, and radians.
requency cutoff ternormalisasi :
c = 2 fc Ts =2x 1600
8000=0,4 radian
2M + 1 = 3 M = 1
h(0) =c
=0.4
=0,6
h(1) =sin c n
n=sin 0,4
=sin 72
3,14=0,303
Applying Hamming :
ham(0) = 0,540,46cos nM
=0,540,46cos0=1
ham(1) = 0,540,46cos n
M
=0,540,46cos=0,08
simetry ham(1) = ham(-1) = 0,08
the windowed impuls respons is calculated as :
h(0) = h(0) ham(0) = 0,6 x 1 = 0,6
h(1) = h(1) ham(1) = - 0,303 x 0,08 = - 0,02424
h(-1) = h(-1) ham(-1) = - 0,303 x 0,08 = - 0,02424
delay
b0 = h(n M) = h(0 -1) = h(-1)b1 = h(n M) = h(1 -1) = h(0)
b2 = h(n M) = h(2 -1) = h(1)
jadi h(1) = h(-1)
H(z) = - 0,02424 + 0,6 z-1 0,02424 z-2
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
6/28
YzXz
=Hz
Y(z) = -0,02424 X(z) + 0,6 z-1 X(z) 0,02424 z-2 X(z)
y(n) = - 0,02424x(n) + 0,6 x(n -1) 0,02424x(n -2)
H(z) = - 0,02424 + 0,6 z-1 0,02424 z-2
H(ej) = - 0,02424 + 0,6 e-j 0,02424 e-j2
= e-j (-0,02424 ej + 0,6 0,02424e-j )= e-j (0,6 0,4848 cos )
|H(ej)| = |0,6 0,04848 cos |
0
- + if 0,6 0,04848 cos < 0
f 0,6 0,04848 cos |H(ej)| |H(ej)| dB
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
7/28
L=2 fL T = 21600
8000= 0,4 rad
L=2 fHT = 21800
8000 = 0,45 rad
2M1=5
h n=. HL
n=0
sin Hn
n-
sin L nn
n=0 - n2
When , n=0 --> h(0) =HL
=
0,450,4
= 0,05
h(1) =sin 0,451
1-
sin 0,411
= 0.1166
h(2) =sin 0,452
2-
sin 0,422
= -0,43789
h(-1)= 0,1166
h(-2) = -0,43789
sec= rec n=1 , MnM
ham= n=0,546046cos nM
, MnM
a rec 0=1
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
8/28
rec 1=1 rec 2=1 rec 1=1 rec 2=1
h0 =h 0 rec 0=0,051=0,01
h1=h 1=0,11661=0,1166
h2 =h2 =0,437891=0,43789
b0=b
4=0,43789, b
1=b
3=0,1166danb
2=0,05
Hz=0,437890,1166z10,05770,1166z30,43789z4
b. ham0=0,540,46cos
2=1
ham1 =0,540,46cos
12
=0,54
ham2=0,540,46cos22
=0,08
ham1 =ham1 =0,54
ham2=ham2=0,08
h
0
=h0
.ham
0
=0,051=0,01
h1=h1=0,11660,54=0,06296
h2 =h2 =0,437890,08=0,03503
HZ=0,035030,06296z10,05z20,06296z
30,03503z4
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
9/28
Frekuensi cutoff yang ternormalisasi :
L=2 fLT=21600
8000=0.4
H=2 fH T=21800
8000=0.45
Since 2M + 1 = 5 in this case, using the equation in Table 7.1 yields
when n = 0, we have
h(0)= H+ L
=0.45+ 0.4=0.95
The other computed filter coefficients via the previous expression are
listed as
h(1)=sin(0.41)
1
sin(0.451)1
=0.302880.31455=0.01167
h(2)=sin(0.42)
2
sin(0.452)2
=0.0935960.04921=0.0444
Using the symmetry leads to
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
10/28
h(-1) = h(1) = -0.01167h(-2) = h(2) = 0.0444
dikarenakan penjendelaan rectangular memiliki fungsi
w rec(n)=1,MnMw rec(0)=1w rec(1)=1w rec(2)=1w rec(3)=1
respone impluse dengan jendela dihitung sebagai :hw (0)=h(0)wrec(0)=0.951=0.95hw (1)=h(1)wrec (1)=0.011671=0.01167hw (2)=h(2)wrec (2)=0.04441=0.0444h(1)=h(1)=0.01167h(2)=h(2)=0.0444
thus, delaying h(n) by M = 2 sample gives :b0=b4=0.0444, b1=b3=0.01167b2=0.95
the transfer function is achieved as
H(z)=0.04440.01167z1+ 0.95z20.01167z3+ 0.0444z4
The magnitude frequency response and phase response can be obtained
using the technique introduced in Chapter 6. Substituting z=e j intoH(z), it follows that
H(e j)=0.04440.01167(ej)+ 0.95 (e j2)0.01167(ej3)+ 0.0444(ej4)
b. dengan menggunakan penjendelaan hamming
whm (0)=0.54+ 0.46cos(0
2)=1
whm (1)=0.54+ 0.46cos(12
)=0.54
whm (1)=0.54+ 0.46cos( 22 )=0.08
whm (-1) = whm (1) = 0.54whm (-2) = whm (2) = 0.08
The windowed impulse response is calculated as
hw (0)=h(0)wham(0)=0.951=0.95hw (1)=h(1)wham(1)=0.011670.54=0.006
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
11/28
hw (2)=h(2)wham (2)=0.04440.08=0.0035hw(-1) = hw(1) = -0.006hw(-2) = hw(2) = 0.0035
thus, delying hw(n) by M = 2 sample gives
bo = b4 = 0.006 , b1=b3 0.0035 b2 = 0.95The transfer function is achieved as
H(z)=0.006+ 0.0035z1+ 0.95z2+ 0.0035z30.006z4
dengan demikian menunda hw(n) oleh M = 1 diperoleh sampel :
b(0)=b(2)=0.2942,b(1)=0.375fungsi alih yang diperoleh sebagai berikut :
H(Z)=0.2942+ 0.375z1+ 0.2942z2
Y(Z)X(Z)
=H(Z)=0.2942+ 0.375z1+ 0.2942 z2
Y(Z)=0.2942X(Z)+ 0.375z1X(Z)+ 0.2942z2 X(Z)
Menerapkan z-transform balik di kedua sisi, persamaan perbedaan dihasilkan sebagaiy (n)=0.2942x (n)+ 0.375x (n)+ 0.2942x (n2)magnitud frekuensi respone :
H(e j)=0.2942+ 0.375 e(j)+ 0.2942 e(j2)
H e( j )=e(j)[0.2942e(j)+ 0.375+ 0.2942 e(j)]
H e( j)=e(j)(0.375+ 0.5584 cos())
maka magnitud respon dan frekuensi respon diperoleh :
| H e( j)
| = | e(j)(0.375+ 0.5584cos()) |
and sudut
H e( j)=, if0.375+ 0.5884cos, n> 0
H e( j)=+ , if0.375+ 0.5884cos, n> 0
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
12/28
7.5 Given an FIR lowpass filter design with the following spesifications
Passband = 0 800 Hz
Stopband = 1200 4000 Hz
Passband ripple = 0.1 dBStopband attenuation = 40 dB
Sampling rate = 8000 Hz
determine the following :a. window method
b. length of the FIT filter
c. cutoff frequency for the design equation.
a. stopband atenuation = 40 dB jadi menggunakan metode Hanning
passband ripple 0,0546
b.
f =1200800
8000=
400
8000=0,05
N =3,1
f=
3,1
0,05=62
c.
fc=fpassfstop
2
=8001200
2
=1000Hz
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
13/28
FIR High pass filter
Pass band = 0-1500 HzStep = 2000-4000 Hz
Pass Band ripple = 0,02 dB hamming : pass band ripple= 0,0194 & topband attenuation= 53 dB
stopband attenuation = 60 dB
sampling rate = 8000 Hz
f = |2000-1500|/8000=0,0625
N = 3,3/Af
= 3,3/0,625
= 52,8pilih angka yang ganjil, maka N=53
cutt off frequency= (1500+2000)/2 = 1750 Hz
c=17502
8000=0,4375 rad
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
14/28
7.7 Diberikan design FIR bandpass filter dengan spesifikasi sebagai berikut:
frekuensi cutoff bawah = 1500 Hz
Lebar transisi bawah = 600 Hz
Frekuensi cutoff atas = 2300Hz
Lebar transisi atas = 600 HzPassband ripple = 0,1 dB
Attenuasi Stopband = 50 dB
Kecepatan laju sampling = 8000 Hz
Tentukan:
a. Metode window
b. Panjang dari FIR filter
c. Frekuensi cutoff
a) Berdasarkan pada spesifikasi diatas, jendela Hamming adalah metode jendela yang tepat untuk
permasalahan ini, karena memiliki passband ripple 0,0194 dB dan attenuasi stopband sebesar 53 dB
b) Menghitung lebar transisi normal:
f1=600
8000=0.075 dan f2=
600
8000=0.075
dan panjang filternya yang ditentukan menggunakan jendela Hamming adalah:
N1=3,3
f=3,3
0,075=44
N2=3,3
f=
3,3
0,075=44
kita pilih agka ganjil untuk nilai N, maka N = 45.
c) Frekuensi cutoff lower dan upper dapat dihitung:
L=21500
8000=0,375 radian
H=223008000=0,575 radian
N= 2M+1= 45
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
15/28
7.8 Given an FIR bandstop filter design with the following spesifications :
Lower passband n= 0 120 Hz
Stopband = 1600 2000 Hz
Upper passband = 2400 4000 HzPassband ripple = 0,05 dB
Stopband attenuation = 60 dB
Sanpling rate = 8000 Hzdetermine the following :
a. window method
b. length of the FIR filterc. cutoff frequency for the design equation
answer:
a.Stopband attenuation 60 dB blackman passband ripple = 0,0017
b. f1=16001200
8000=0,05 f2=
240020008000
=0,05
N=5,5
f=
5,5
0,05=110
c. fclow=fpassfstop
2=
120016002
=1400 Hz
frequency cutoff ternormalisasi
L =1400 x 2
2=0,35 radians
fch=fpass fstop
2=
400016002
=5600
2=2800Hz
frequency cutoff ternomalisasi
H =2800x 2
8000=0,7 radians
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
16/28
a. y(n)=0.25x(n)-0.5x(n-1)+0.25x(n-2)
b. y n=0,25x n0,5x n10,2x n20,5x n30,2x n4
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
17/28
8.1 Given an analog filter with the transfer function
H(s) =1000
s1000,
convert it to the digital filter transfer function and difference equation using theBLT if the DSP system has a sampling period of T = 0.001 second.
Answer :
Menggunakan BLT
H(z) = H(s) | s =2z1Tz1
=1000
s1000| s =
2z1Tz1
T = 0.001 s
H(z) =
1000
2z1Tz1
1000=
1000
2z10.001z1
1000=
1000
2000z1z1
1000
=
0.5
z1T10.5
=0.5z1
z10.5z1=
0.5z0.51.5z0.5
jadi :
H(z) =0.5z0.5/1.5z 1.5z0.5/1.5z
=0.330.33z1
10.33z1
maka :y(n) = 0.33x(n) + 0.33 x(n-1) + 0.33 y(n-1)
8.2 Hps=
1
s1 dengan frekuensi cut off = 30 Hz dan sampling rate of 200 Hz
a.) first we obtain the digital frekuensi as
wd=2 f=230=60 rad/sec T=1
fs=
1
200=0,005sec
wa=2
Ttan
wd T
2=
2
0,005tan
60 x 0,0052
=400tan 27=203,81 rad/s
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
18/28
lalu perform the prototype transformation
Hs=Hps =wa
swa=
203,81
s203,81
apply the BLT
Hs=Hps =wa
swa=
203,81
s203,81dengan s=
2z1Tz1
Hz=203,81
400z1z1
203,81=
203,81
400
z1z1
203,81
400
=0,509
z1z1
0,509
lalu kalikan dengan (z+1)
0,509z1
z10,509z1=
0,509z0,509z10,509z0,509
=0,509z0,5091,509z0,491
terakhir bagi pembilang dan penyebut dengan 1,509z
Hz=0,3370,377 z1
10,325 z1
b) program matlab
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
19/28
% Plot the magnitude and phase responsesfs = 200;% Sampling rate (Hz)[B, A] = lp2lp([1],[1 1],203.81);[b, a] = bilinear(B, A, fs)%b = [0.337 0.337] numerator coefficients of the digital filter from MATLAB%a = [1 -0.325]denominator coefficients of the digital filter from MATLAB[hz, f] = freqz([0.337 0.337],[1-0.325],512,fs);%the frequency responsephi = 180*unwrap(angle(hz))/pi;
subplot(2,1,1), plot(f, abs(hz)),grid;axis([0 fs/2 0 1]);xlabel('Frequency (Hz)'); ylabel('Magnitude Response')subplot(2,1,2), plot(f, phi); grid;axis([0 fs/2 100 0]);xlabel('Frequency (Hz)'); ylabel('Phase (degrees)')
8.3. The normalized lowpass filter with a cutoff frequency of 1 rad/sec is given as
Hps=1
s1a. Use Hp(s) and the BLT to obtain a corresponding IIR digital highpass filter with a cutofffrequency of 30 Hz, assuming a sampling rate of 200 Hz.b. Use MATLAB to plot the magnitude and phase frequency responses of H(z).
Answer :a. First, we obtain the digital frequency as d=2 f=230=60 rad/sec ;T=1/ fs=1/200sec
We then follow the design procedure:1. First calculate the prewarped analog frequency as
a= 2Ttan dT
2= 2
1/200tan 60/200
2
that is, a=400x tan 27o=400x 0,51=203,81 rad/sec
2. Then perform the prototype transformation (lowpass to lowpass) as follows:
HS=Hpss=
1
a
=1
as1
=s
as
which yields an analog filter:
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
20/28
Hs=s
203,81s3. Apply the BLT, which yields
Hz=[ s203,81s ]s=2z1Tz1
We simplify the algebra by dividing both the numerator and the denominator by
180:
Hz=180 x
z1z1
203,81180xz1z1
Hz=
z1z1
203,81
180
z1z1
Hz=
z1z1
1,13z1z1
Then we multiply both numerator and denominator by (z + 1) to obtain
Hz= z1z1 x z1
1,13z1z1 x z1Hz=
z11,13z1z1
Hz=z1
1,13z1,13z1
Hz=z1
0,13z0,13Finally, we divide both numerator and denominator by 0.13z to getnthe transferfunction in the standard format:
Hz=z1/0,13z
0,13z0,13/0,13z
Hz=7.697.69z1
1z1
b. The corresponding MATLAB design is listed in Program 8.2. Figure 8.12 shows themagnitude and phase frequency responses.
%Example 8.6% Plot the magnitude and phase responsesfs = 200;% Sampling rate (Hz)[B, A] =lp2lp([1],[1 1],203.81);[b, a] =bilinear(B, A, fs)%b = [0.3660 0.3660] numerator coefficients of the digital filter from MATLAB%a =[1 _0:2679]denominator coefficients of the digital filter from MATLAB
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
21/28
[hz, f] = freqz([7.69 7.69],[1-0.13],512,fs);%the frequency responsephi =180*unwrap(angle(hz))/pi;subplot(2,1,1), plot(f, abs(hz)),grid;axis([0 fs/2 0 50]);xlabel('Frequency (Hz)'); ylabel('Magnitude Response')subplot(2,1,2), plot(f, phi); grid;axis([0 fs/2 -100 0]);xlabel('Frequency (Hz)'); ylabel('Phase (degrees)')
8.4 Consider the normalized lowpass filter with a cutoff frequency of 1 rad/ sec:
Hp(s) =1
s1
a. Use Hp(s) and the BLT to design a corresponding IIR digital notch (bandstop) filter
with a lower cutoff frequency of 20 Hz, an upper cutoff frequency of 40 Hz, and a
sampling rate of 120 Hz.
b. Use MATLAB to plot the magnitude and phase frequency
responses of H(z).
Answer :
A. wh = 2 fh = 2 (40) = 80 rad/secwl = 2 fl = 2 (20) = 40 rad/sec
T = 1/fs = 1/120 sec
wah = 2/T tanwh T
2= 240 x tan
80/1202
= 4.156 x 102 rad/sec
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
22/28
wal = 240 tanwl T
2= 240 x tan
40/1202
= 1.385 x 102 rad/sec
W = wah wal = 415.6 138.5 = 277.03 rad/sec
wo2 = wah x wal = 5.75606 x 104
Hp(s) =1
s1
H(s) = Hp(s)|s
2wo2
sW=
Ws
s2wsw02
=277.03s
s2277,03s5.75606x104
H(z) =277.03s
s2277,03s5.75606x104
| s = 240 (z-1)/(z+1)
B. dengan menggunakan MATLAB
% Design of the digital bandpass Butterworth filterformat longfs = 120;[B A] = lp2bp([1],[1 1],sqrt(5.75606*10^4),277.03)% Complete step 2[b a] = bilinear(B,A,fs) % Complete step 3% Plot the magnitude and phase responses%b = [0:0730 - 0:0730]; numerator coefficients from MATLAB%a = [1 0:7117 0:8541]; denominator coefficients from MATLABfreqz(b, a,512,fs);axis([0 fs/2-40 10])
Tampilan pada common
B =
1.0e+002 *
2.77030000000000 0.00000000000008
A =
1.0e+004 *
0.00010000000000 0.02770300000000 5.75606000000000
b =
0.36602259977825 0.00000000000000 -0.36602259977825
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
23/28
a =
1.00000000000000 -0.00043380652009 0.26795480044350
Grafik :
8.5 Hps=1
s1dengan frekuensi lowpass cut off = 15 Hz , upper cutoff = 25
Hz dan sampling rate of 200 Hz
a) untuk yg lowpass = 15 Hz
wd=2 f=215=30 rad/sec T=1
fs=
1
120=0,0083sec
wa=2
Ttan
wd T
2=
2
0,0083tan
30x 0,00832
=240,96tan 22,41=99,36 rad/s
lalu perform the prototype transformation
Hs=Hps =wa
swa=
99,36
s99,36
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
24/28
apply the BLT
Hs=Hps =wa
swa=
99,36
s99,36dengan s=
2z1Tz1
Hz= 99,36240,96z1z1
99,36=
99,36
240,96z1z1
99,96
240,96
= 0,412z1z1
0,412
lalu kalikan dengan (z+1)
0,412z1z10,412z1
=0,412z0,412
z10,412z0,412=
0,412z0,4121,412z0,588
terakhir bagi pembilang dan penyebut dengan 1,412z
Hz=0,2920,292z1
10,42z1
untuk yang upper cutoff = 25 Hz
wd=2 f=225=50 rad/sec T=1
fs=
1
120=0,0083sec
wa=2
Ttan
wd T
2=
2
0,0083tan
50x 0,00832
=240,96tan 37,35=183,89 rad/s
lalu perform the prototype transformation
Hs=Hps =wa
swa=
183,89
s183,89
apply the BLT
Hs=Hps =wa
swa=
183,89
s183,89dengan s=
2z1Tz1
Hz=183,89
240,96z1z1
183,89=
183,89
240,96
z1z1
183,89
240,96
=0,763
z1z1
0,763
lalu kalikan dengan (z+1)
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
25/28
0,763z1z10,763z1
=0,763z0,763
z10,763z0,763=
0,763z0,7631,763z0,237
terakhir bagi pembilang dan penyebut dengan 1,763z
Hz=0,4330,433z1
10,134z1
b) program matlab untuk frekuensi cutt off = 15 Hz
% Plot the magnitude and phase responsesfs = 120;% Sampling rate (Hz)[B, A] = lp2lp([1],[1 1],99.36);[b, a] = bilinear(B, A, fs)%b = [0.292 0.292] numerator coefficients of the digital filter from MATLAB%a = [1 -0.42]denominator coefficients of the digital filter from MATLAB[hz, f] = freqz([0.292 0.292],[1-0.42],512,fs);%the frequency responsephi = 180*unwrap(angle(hz))/pi;subplot(2,1,1), plot(f, abs(hz)),grid;axis([0 fs/2 0 1]);xlabel('Frequency (Hz)'); ylabel('Magnitude Response')
subplot(2,1,2), plot(f, phi); grid;axis([0 fs/2 100 0]);xlabel('Frequency (Hz)'); ylabel('Phase (degrees)')
untuk yang frekuensi cuttoff = 25 Hz
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
26/28
% Plot the magnitude and phase responsesfs = 120;% Sampling rate (Hz)[B, A] = lp2lp([1],[1 1],183.89);[b, a] = bilinear(B, A, fs)%b = [0.433 0.433] numerator coefficients of the digital filter from MATLAB%a = [1 -0.134]denominator coefficients of the digital filter from MATLAB[hz, f] = freqz([0.433 0.433],[1-0.134],512,fs);%the frequency responsephi = 180*unwrap(angle(hz))/pi;subplot(2,1,1), plot(f, abs(hz)),grid;axis([0 fs/2 0 1]);xlabel('Frequency (Hz)'); ylabel('Magnitude Response')subplot(2,1,2), plot(f, phi); grid;axis([0 fs/2 100 0]);
xlabel('Frequency (Hz)'); ylabel('Phase (degrees)')
8.6. Design a first-order digital lowpass Butterworth filter with a cutoff frequency of 1.5kHz and a passband ripple of 3 dB at a sampling frequency of 8,000 Hz.a. Determine the transfer function and difference equation.b. Use MATLAB to plot the magnitude and phase frequency responses.
Answera.
d=21500=3000 rad/sec dan T= 1fs= 1
8000sec
1. a 2/Ttan d T2=1600tan
3000/80002
= 1,069104 rad/sec
2. Hp(s)=1
s1
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
27/28
H(s)=Hp(s)|as
=
1
as1
=s
s1.069x104 rad/sec
3. dengan BLT :
H(z) =s
s1.069x104
rad/sec
|s=16000(z-1)/(z+1)
H(z)=
16000z1z1
16000z1z1
1.069x104
z1z1
=16000z1
16000z11.069x104z1
= 16000 z116000 z11.069x10 4z1
=16000z16000
16000z1600010690z10690
=16000z1600026690z5310
=0.559z0.599
z0.1989
pembilang dan penyebut dibagi dengan z:
H(z)=0.5990.599z1
10.1989z1
b. program MATLAB:
%Soal 8.6
% Design of the digital lowpass Butterworth filterformat longfs = 8000; % Sampling rate[B A] = lp2lp([1],[0 1 1], 1.0690*10 ^ 4) % Complete step 2
[b a] = bilinear(B,A,fs)% Complete step 3% Plot the magnitude and phase responses%b = [0.7157 1.4315 0.7157]; numerator coefficients from MATLAB%a = [1 1.3490 0.5140]; denominator coefficients from MATLABfreqz(b,a,512,fs);axis([0 fs/2 -40 10])
Setelah di-run:
-
7/28/2019 Pengolahan Sinyal Digital B 2011 2012 12 (Bab 7 & 8)
28/28
B =
10690
A =
1 10690
b =
0.40052454102660 0.40052454102660
a =
1.00000000000000 -0.19895091794680