⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 prog7b5.m

📁 数字信号处理实践方法
💻 M
字号:
%
%	Program name - prog7b5.m, p451
%  m-file for computing the coefficients of an FIR frequency sampling
%  filter 
%
Fs=2000;										%	Sampling frequency
N=15;											%	Filter length
fd=[0 1/7 2/7 3/7 4/7 5/7 6/7 1];	%	Frequency sampling points
Hd=[1 1 1 1 0.5571 0.0841 0 0];		%	Frequency samples
hn=fir2(N-1, fd, Hd);					%	Compute the impulse response coeffs.
[H, f] = freqz(hn, 1, 512, Fs);		%	Plot the magnitude frequency response
plot(f, abs(H)), grid on
xlabel('Frequency (Hz)')
ylabel('Magnitude ')

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -