?? fresamp.m
字號:
function Fresamp
%Design arbitrary FIR filter by frequency sampling method
n=15;
m = [1 1 1 1 0.5571 0.0841 0 0];
f = [0 1/7 2/7 3/7 4/7 5/7 6/7 1];
window = [1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1]; % n+1 elements long
b = fir2(n,f,m,window); % get filter coefficients
%Output the results
disp('The coefficients are:'); disp(b);
[h,w] = freqz(b,1,128);
plot(f,m,w/pi,abs(h)); title('Desired and Actual Frequency Responses');
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -