Simulink model crashes during simulation before reaching Stop Time without any error

27 次查看(过去 30 天)
I am simulating a complex simscape multibody (Gen 1) model, with multiple joints, actuators, 6 DOF motions etc. The issue I am encountering is that the model simulates only for a limited amount of time and not till Stop Time. Simulink seems to crash or end the simulation before Stop Time. Moreover, changing certain value of the parameters affects how long the simulation simulates.
For instance I have a transport delay block. If the values of that is 1e-3 [s], the model is simulated for about 0.05 [s]. However if I change it to lets say 0.2e-3 [s] or 0 [s], the model simulates only for 0.002 [s] and 0 [s], respectively. In all cases Stop Time was 0.1 [s].
So, I am not sure if this has something to do with the solver or some other thing. All in all I am not sure how to debug this issue since Simulink is not generating any error report or giving out any error. One thing to mention will be that for whatever time the model simulates, the results look to be correct in my understanding and according to my expectations.
Any type of guidance will be much appreciated. Thanks in advance.

回答(1 个)

Steve Miller
Steve Miller 2022-11-19
Here are some typical reasons the model stops (or appears to stop) before the Stop Time.
  1. The model contains a Stop Block whose input signal is changing to a nonzero value before the stop time.
  2. The model is running to the stop time, but the settings for how the data should be logged prevents the final value(s) from being logged. The model did run to completion, but it isn't showing you the final values.
--Steve

类别

Help CenterFile Exchange 中查找有关 Troubleshooting 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by