Different simulation results using discrete and continous systems

I have a simple system (H(s) = 1/s^2+10s+20). I've added a proportional controller(Kp = 300) to the system to observe the step response. I used Simulink to do this (fixed-step size: 0.01, solver: ode8).
I also used the c2d function to create the z-transform (H(z)= c2d(H,0.01)) and then added the same proportional controller to observe the step response. In this case, I used both Simulink (fixed-step size: 0.01, solver: discrete) and a simple m file I wrote using the difference equation coming from the z-transform.
Now, I have three step responses. All of them have the same steady state response but the transient response is different (overshoot amplitude is different between all three).
I appreciate if someone can explain to me why this is happening.
Omid

2 comentarios

You have the continuous and discrete system, what is the third?
Omid
Omid el 30 de Oct. de 2013
Editada: Omid el 30 de Oct. de 2013
For the discrete case I'm using both simulink (z-transfer function block) and a code which implemented to do a difference equation.

Iniciar sesión para comentar.

Respuestas (1)

Azzi Abdelmalek
Azzi Abdelmalek el 30 de Oct. de 2013
Why are you expecting to get the same step response for both continuous and discrete model with the same continuous proportional controller? If you want to get the same step response you should apply c2d to the continuous model in a closed loop: Kp*H(p)/(1+Kp*H(p))

1 comentario

Thanks Azzi for your answer but the problem was something else.
I needed to use the sampling rate of 1000 Hz (i.e. c2d(H,0.001)). Also in the code I wrote, I needed to enter z-transform coefficients with 16-digit precision.

Iniciar sesión para comentar.

Preguntada:

el 30 de Oct. de 2013

Comentada:

el 26 de Nov. de 2013

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by