reinf3_10.m

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

M
38
字号
%%%%%%%%%% Reinforcement Problem 3.10 %%%%%%%%%%%%   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                 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%   ---- Series/parallel connection ----%cleardisp('Reinforcement Problem 3.10')Ts = 1;                            % unity sampling period%----- build G1 --------------G1 = tf([12 5 1],[24 15 6],Ts)     % G1%----- build G2 --------------pG2 = [-0.2; 0.8];                 % poles of G2 as column vectorG2 = zpk(-0.9,pG2,4,Ts)            % G2 in ZPK form%----- build G3 --------------G3 = tf(5,[1 -0.5],Ts)             % G3%----- build G4 --------------G4 = tf([3 2],[4 0 -3],Ts)         % G4(z)%---- connect the 4 blocks --------------T = G4*(G3+G2*G1)                  % overall T(z)%----- zeros, poles & gain of T -------------[zT,pT,kT] = zpkdata(T,'v')[magzT,thetazT] = xy2p(zT)[magpT,thetapT] = xy2p(pT)[resp,k] = step(T);                % pulse resp. of T(z)figureplot(k,resp,'+'); grid             % plot response with stem optiontitle('Step response for Reinforcement Problem 3.10')xlabel('Discrete time k')%%%%%%%%%%

⌨️ 快捷键说明

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