Matching step response from Simulink with Matlab
Mostrar comentarios más antiguos
Hi I am new to Simulink and am trying to figure out how to get correct results. I modeled a simple control loop in Matlab and Simulink to see if the step response was the same. It's not. I'm guessing this has to do with the solver settings? I used the default for this.
Can anyone help me understand how to get Simulink to give better results? Thanks!
Here is the Matlab code:
sys = tf(1,[1 1 1]);
syscl = pid(4,2,1,0);
sys2 = series(syscl,sys);
sys3 = feedback(sys2,1);
[y,t] = step(sys3);
figure(2)
plot(t,y,ScopeData.time,ScopeData.signals.values)
Here is the simulink model:

And here is a plot of the results:

Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Model-Based PID Controller Tuning en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!