ex070400.m
来自「matlab的一些函数,是初学习者的好资料,」· M 代码 · 共 17 行
M
17 行
% Chapter 7:例 7.4 1-型线性相位FIR滤波器
%
subplot(1,1,1)
h = [-4,1,-1,-2,5,6,5,-2,-1,1,-4];
M = length(h); n = 0:M-1;
[Hr,w,a,L] = Hr_Type1(h);
amax = max(a)+1; amin = min(a)-1;
subplot(2,2,1); stem(n,h); axis([-1 2*L+1 amin amax])
text(2*L+1.5,amin,'n'); ylabel('h(n)'); title('脉冲响应')
subplot(2,2,3); stem(0:L,a); axis([-1 2*L+1 amin amax])
xlabel('n'); ylabel('a(n)'); title('a(n) 系数')
subplot(2,2,2);plot(w/pi,Hr);grid
text(1.05,-20,'频率pi'); ylabel('Hr')
title('1-型振幅响应')
subplot(2,2,4);pzplotz(h,1)
title('零极点分布')
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?