📄 exprience3_3.m
字号:
%experience 3 (3);
Wpl=0.3*pi;
Wph=0.7*pi;
Wsl=0.4*pi;
Wsh=0.6*pi;
tr_width=min((Wsl-Wpl),(Wph-Wsh));
N=ceil(6.2*pi/tr_width)
n=0:1:N-1;
Wcl=(Wsl+Wpl)/2;
Wch=(Wsh+Wph)/2;
hd=ideal_bs (Wcl,Wch,N);
w_hann=(hanning(N))';
h=hd.*w_hann;
[db,mag,pha,w]=freqz_m2(h,[1]);
delta_w=2*pi/1000;
Ap=-(min(db(1:1:Wpl/delta_w+1)))
As=-round(max(db(Wsl/delta_w+1:1:Wsh/delta_w+1)))
subplot(221)
stem(n,hd)
title('ideal zeros impulse respons hd(n)')
subplot(222)
stem(n,w_hann)
title('hanning window w(n)')
subplot(223)
stem(n,h)
title('real aeros impluse respons hd(n)')
subplot(224)
plot(w/pi,db)
title('Amtiple response (dB)')
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -