📄 29t.m
字号:
clc;
close all;
clear all;
Rp=1;Rs=40;fs=1000;
ws1=0.25*pi;ws2=0.8*pi;
wp1=0.4*pi;wp2=0.7*pi;
wp3=(2*fs)*tan(wp1/2);
wp4=(2*fs)*tan(wp2/2);
ws3=(2*fs)*tan(ws1/2);
ws4=(2*fs)*tan(ws2/2);
wp=[wp3,wp4];
ws=[ws3,ws4];
[n,wn]=cheb2ord(wp,ws,Rp,Rs,'s')
[b,a]=cheby2(n,Rs,wn,'bandpass','s');
[bz,az]=bilinear(b,a,fs);
[db,mag,pha,grd,w]=freqz_m(bz,az);
subplot(2,1,1);plot(w/pi,db);axis([0,1,-100,10]);
subplot(2,1,2);plot(w/pi,pha);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -