I'm using simulink with an optimization method to fit a dynamic model.
My model is extremely stiff and for some parameters that set by the optimization, the simulation crash, but the simulation still running forever unless I manually interrupt with ctrl+C and my optimization still run.
Because of that, i need something to limite the real elapsed time of the simulation that interrupt automatically the simulation. I found only blocks that computes the simulation time (Clock or Digital Clock).