Simulink model problem. Input depending on its output
4 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hello, I have a slight problem with my model: the input of my model is depending on the output of it. To make it easy I started with a simple model (only ramp and constant) and to solve this I had the following structure in mind: (ramp goes from 0 to 9 and the treshold of the switch is 0.5).
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/161683/image.png)
However this appears to be not working. It either outputs only the constant, either the simulations doesn't even start. I have no idea why and how to solve it because I don't see a mistake in my model. Can someone explain me or tell me how to modify the structure. Thank you in advance.
0 comentarios
Respuestas (1)
Joachim Schlosser
el 18 de Abr. de 2016
The solver is trying to solve the system that you specified at time 0. So in order to get to to work, you need some sort of delay before feeding the comparison back into the switch. See https://www.mathworks.com/help/simulink/ug/algebraic-loops.html for learning about algebraic loops.
Second, what you are trying could also be described with an easier construct without feedback, by placing the comparison directly after the ramp block.
0 comentarios
Ver también
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!