Skip to content

Refactor time steppers to be able to reconfigure their tolerancesΒ #222

@alexander-novo

Description

@alexander-novo

Summary

Right now, tolerances are:

  1. Hard coded

  2. Decided by the system being simulated, not the solver

It would be nice if these tolerances could become reconfigured by modifying the solver.

Rationale

Ideologically, the current system where tolerances are decided by the system being simulated and then given to the solver is somewhat backwards:

  • The system/components shouldn't need to make use of these tolerances - they are purely for the solver to use, and changing these tolerances shouldn't change the properties of the simulation being solved.
  • The system currently makes some assumption about the solver being used to solve them: fixed step solvers won't use tolerances, and adaptive step solvers use different tolerances depending on the step size controller being used (it's possible more extravagant controllers won't simply make use of abs_tol and rel_tol - they'll have different tolerances)

For comparing fixed v.s. adaptive step size, it's necessary to re-run these simulations at multiple different tolerances, and right now this is somewhat cumbersome to do.

Description

set_tolerances should be removed from Evaluator and instead rel_tol_ and abs_tol_ should be stored as properties in Ida, which can maybe be configured by user with a call to set_tolerances in Ida.

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions