What kind of a solver do I need to select for solving Simscape models combined with normal simulink models?

1 view (last 30 days)
Presently I am using ode23t, this seems to work, but other solvers give me an error. Whats the criteria for selecting solvers, do I need to know in depth the properties of these solvers and their solving methods?

Answers (1)

Sebastian Castro
Sebastian Castro on 16 Jul 2015
Simscape models are generally stiff systems -- that is, they have a combination of high and low frequencies. All the solvers that say "stiff" on them are therefore best suited for models containing Simscape blocks. These include ode23t, ode15s, ode14x, etc.
Also, if you want the Simulink piece of your model to use a different, you could always split up your model using model referencing. The model containing Simscape blocks could use ode23t and the other model(s) could use other solvers such as ode45.
... of course, the problem could be deeper. Maybe your model has some issues with the way it's made and ode23t is the "lucky" solver in which the simulation still works. We could take a look into that if you think that may also be the case.
Best, Sebastian

Products

Community Treasure Hunt

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

Start Hunting!