Skip to content

Add Safeguards to EulerCore to reduce undefined behavior for SDE models #1165

@nijawa

Description

@nijawa

Motivation / Current Behaviour

As of now SDE models have to implement checks for whether flows/derivatives result in overflows in the compartments (negative compartments or compartments greater than population size). The current implementation can also result in undefined behavior by floating point operations (see Issue #1009)

Enhancement description

Adapting the EulerCore (potentially writing a EulerMaruyamaCore) one can use vectorized functions to add those safeguards and other modifications into the core. Potential modifications are:

  • Clipping compartments to the intervall [0, population_size]
  • Setting compartments below some threshhold to zero
  • Rescaling compartments in case clipping changed total population size

Additional context

No response

Checklist

  • Attached labels, especially loc:: or model:: labels.
  • Linked to project

Metadata

Metadata

Labels

class::featureA feature to be implemented for some part of the softwareclass::performancePerformance related issuesloc::backendThis issue concerns the C++ backend implementation.model::odeThis issue concerns any kind of ODE-based model.model::sdeThis issue concerns any kind of stochastic differential equation-based model.

Type

No type

Projects

Status

Done (Total)

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions