📄 freqs_m.m
字号:
function [db,mag,pha,w] = freqs_m(b,a,wmax)
% Computation of s-domain frequency reponse;Modified version
% --------------------------------------------------------------
% [db,mag,pha,w] = freqs_m(b,a,wmax);
% db = Relative magnitude in dB over 0 to wmax
% mag = Absolute magnitude over 0 to wmax
% pha = Phase reponse in radians over 0 to wmax
% w = array of 500 frequency samples between 0 to wmax
% b = numerator polynomial coefficients os Ha(s)
% a = denominator polynomial coefficients os Ha(s)
% wmax = Maximum frequency in rad/sec over whcih reponse is desired
%
w = [0:1:500]*wmax/500;
H = freqs(b,a,w);
w = (w(1:1:501))';
mag = abs(H);
db = 20*log10((mag+eps)/max(mag));
pha = angle(H);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -