📄 t23disturb.m
字号:
%------------------------------------------------------------------
% This program is used to compare the step responses of Unstable System
% by Zero-pole placement method, Inner-model method
% NOTE: The 't23k1k2.m' must be executed first to produce K,T,tao3.
%------------------------------------------------------------------
Ts=60;
SetValue=0;
Tnoise=Ts+1;
Weight=0.08*Tnoise;
Anoise=0.2;
StarTime=0;
Nload=0.000005;
figure(4);
clf;
xlabel('t'); ylabel('y');
Title('The Anti-Disturbance Performance of Unstable System');
hold on
%(1)Zero-pole placement method with 'StatePIDzp.mdl'
Kp=0.1523;
Ti=1.9823;
Td=0.4842;
[t,xx,yy]=sim('StatePIDzp',Ts);
plot(t,yy);
pause
%(2)Inner-model method to solve the step response with 'StatePIDmo.mdl'
lemda=7.3;
Kp=b1/(2*lemda*K);
Ti=b1/b0;
Td=b2/b1;
Lf=lemda/2;
[t,xx,yy]=sim('StatePIDmo',Ts);
plot(t,yy);
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -