reinf2_5.m

来自「离散控制系统设计的MATLAB 代码」· M 代码 · 共 27 行

M
27
字号
%%%%%%%%%%% Reinforcement Problem 2.5 %%%%%%%%%%%%   Discrete-Time Control Problems using        %%       MATLAB and the Control System Toolbox   %%   by J.H. Chow, D.K. Frederick, & N.W. Chbat  %%         Brooks/Cole Publishing Company        %%                September 2002                 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%	--- Third-order System ---%cleardisp('Reinforcement Problem 2.5')% Do partial-fraction expansion and unit delta responsenumG = [0.2 1.1 0.5];                % define numerator of G(z)denG = [1 0.7 0.5 0.1];              % define denominator of G(z)% Build G(z) as TF object with sampling time 1 sG  = tf(numG,denG,1)              [zz,pp,kk] = zpkdata(G,'v')          % zeros, poles, & gain of G(z)[mag_pp,theta_pp] = xy2p(pp)	     % polar form of the poles[rGoz,pGoz,otherGoz] = ...		residue(numG,[denG 0])       % residues & poles of G(z)/z[mag_rGoz,theta_rGoz] = xy2p(rGoz)   % residues in polar form[y,k] = impulse(G);                  % compute unit delta responsefigurestem(k,y,'filled')                   % plot responsegridtitle('Impulse Response for Reinforcement Problem 2.5')%%%%%%%%%%

⌨️ 快捷键说明

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