Opened 5 years ago

Last modified 5 years ago

#5779 new enhancement

Enable/disable root finding

Reported by: Oliver Lenord Owned by: Lennart Ochel
Priority: high Milestone: 2.0.0
Component: Backend Version:
Keywords: simulation flags, solver, events Cc:

Description

There is a simulation flag -noRootFinding:
https://openmodelica.org/doc/OpenModelicaUsersGuide/latest/simulationflags.html#simflag-norootfinding
which is according to the users guide applicable only to DASSL and IDA.

I'm currently running simulations intended for real time applications using Euler and so forth.

I'd like to see this simulation flag as a general setting applicable to all solvers but especially for the fixed step solvers:

  1. because real time applications typically have to avoid root finding as it is not deterministic.
  2. It should easy to disable this extra capability as these solvers typically do not have an advanced root finding scheme mingled with the solver iterations.

Change History (2)

comment:1 by Francesco Casella, 5 years ago

I definitely support this request. In many cases you want to use a plain fixed time step Euler and only check about events at the time steps.

The question is how we should handle event iteration, i.e. what should the solver do if the effects of an event trigger another.

One option is to iterate until convergence, as specified in appendix C of the Modelica Specification, only doing it at the approximated time step on the fixed time step grid, instead of doing it at the exact time found by zero crossing functions.

The other option is to skip event iteration, and basically let it happen one iteration at a time at each time step. I guess this is the only viable option for real time, if you want to keep a more or less deterministic execution time.

I think it would be useful to have both options in general, @olivleno what do you think?

comment:2 by Oliver Lenord, 5 years ago

In deed an event iteration would not be suitable for a real time application. Yet I believe it's an open research question how to handle event iterations in a robust and reliable way.

Having both options at hand would allow to explore this approach.

Note: See TracTickets for help on using tickets.