model = CreateSystemModel[{x1'[t] == x2[t],
x2'[t] == -9.8 x1[t] + a[t],
a[t] == 9.8 x1[t] - x2[t] - Sign[x1[t] + x2[t]], x1[0] == 1,
x2[0] == 0}, t]
sim = SystemModelSimulate[model, 10,
Method -> {"RungeKutta", "StepSize" -> 0.001}]
SystemModelPlot[sim, "a", PlotRange -> {-10, 10}, Frame -> True,
GridLines -> {Range[10], Automatic}]


仿照MATLAB进行滑模控制的一个例子,按理说在t=1s之后应该出现抖振,但却没有出现,这是怎么回事?
x2'[t] == -9.8 x1[t] + a[t],
a[t] == 9.8 x1[t] - x2[t] - Sign[x1[t] + x2[t]], x1[0] == 1,
x2[0] == 0}, t]
sim = SystemModelSimulate[model, 10,
Method -> {"RungeKutta", "StepSize" -> 0.001}]
SystemModelPlot[sim, "a", PlotRange -> {-10, 10}, Frame -> True,
GridLines -> {Range[10], Automatic}]


仿照MATLAB进行滑模控制的一个例子,按理说在t=1s之后应该出现抖振,但却没有出现,这是怎么回事?
