资源简介

资源里面一共有九个例程,程序比较简单,适合新手学习使用

资源截图

代码片段和文件信息

function [sysx0strts] = spacemodel(txuflag)
switch flag
case 0
    [sysx0strts]=mdlInitializeSizes;
case 3
    sys=mdlOutputs(txu);
case {249}
    sys=[];
otherwise
    error([‘Unhandled flag = ‘num2str(flag)]);
end
function [sysx0strts]=mdlInitializeSizes
sizes = simsizes;
sizes.NumContStates  = 0;
sizes.NumDiscStates  = 0;
sizes.NumOutputs     = 1;
sizes.NumInputs      = 5;
sizes.DirFeedthrough = 1;
sizes.NumSampleTimes = 0;
sys = simsizes(sizes);
x0  = [];
str = [];
ts  = [];
function sys=mdlOutputs(txu)
zd=u(1);
dzd=0.1*pi*cos(pi*t);
ddzd=-0.1*pi*pi*sin(pi*t);

x1=u(2);
x2=u(3);
fx=u(4);
gx=u(5);
c1=35;c2=35;

z1=x1-zd;
alfa1=-c1*z1+dzd;
z2=x2-alfa1;
dz1=x2-dzd;

ut=(-fx-c2*z2-z1-c1*dz1+ddzd)/(gx+0.001);
sys(1)=ut;

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2018-08-06 18:42  Backstepping_example\
     文件         790  2007-02-07 11:48  Backstepping_example\chap6_1ctrl.m
     文件        2274  2018-08-06 18:41  Backstepping_example\chap6_1plant.m
     文件         296  2007-02-07 11:34  Backstepping_example\chap6_1plot.m
     文件       10247  2007-08-13 19:57  Backstepping_example\chap6_1sim.mdl
     文件        2815  2004-08-17 16:18  Backstepping_example\chap6_2ctrl.m
     文件        1081  2004-08-16 09:41  Backstepping_example\chap6_2plant.m
     文件         385  2007-08-13 20:02  Backstepping_example\chap6_2plot.m
     文件       10468  2007-08-13 20:22  Backstepping_example\chap6_2sim.mdl
     文件        2752  2006-10-31 10:41  Backstepping_example\chap6_3ctrl.m
     文件        1253  2007-03-20 17:40  Backstepping_example\chap6_3plant.m
     文件         628  2007-03-20 17:27  Backstepping_example\chap6_3plot.m
     文件       11246  2007-08-13 20:04  Backstepping_example\chap6_3sim.mdl
     文件        1339  2006-07-14 11:43  Backstepping_example\chap6_4ctrl.m
     文件        1327  2006-07-14 11:47  Backstepping_example\chap6_4input.m
     文件         969  2006-07-14 11:50  Backstepping_example\chap6_4plant.m
     文件         190  2006-07-14 11:41  Backstepping_example\chap6_4plot.m
     文件        9165  2007-08-13 20:25  Backstepping_example\chap6_4sim.mdl
     文件        2676  2007-08-18 09:15  Backstepping_example\chap6_5ctrl.m
     文件        1052  2007-08-17 23:05  Backstepping_example\chap6_5plant.m
     文件         290  2007-08-18 09:11  Backstepping_example\chap6_5plot.m
     文件       11919  2007-08-18 09:34  Backstepping_example\chap6_5sim.mdl
     文件        1380  2007-02-26 09:42  Backstepping_example\chap6_6ctrl.m
     文件         961  2007-08-13 20:09  Backstepping_example\chap6_6plant.m
     文件       10394  2007-08-13 20:11  Backstepping_example\chap6_6sim.mdl
     文件        2141  2007-02-26 09:29  Backstepping_example\chap6_7ctrl.m
     文件         961  2007-08-13 20:12  Backstepping_example\chap6_7plant.m
     文件         328  2006-11-20 12:04  Backstepping_example\chap6_7plot.m
     文件        9999  2007-08-13 20:11  Backstepping_example\chap6_7sim.mdl
     文件         774  2007-08-13 20:16  Backstepping_example\chap6_8plant.m
     文件         520  2007-05-13 23:54  Backstepping_example\chap6_8plot.m
............此处省略9个文件信息

评论

共有 条评论