CriticalTransitions.jl icon indicating copy to clipboard operation
CriticalTransitions.jl copied to clipboard

New types for simulation data

Open reykboerner opened this issue 2 years ago • 0 comments

Currently the main structure of CriticalTransitions.jl is the StochSystem, and the typical syntax for methods is function(sys::StochSystem, args; kwargs...).

A typical workflow for numerically studying critical transitions could look like this:

  1. Investigate system properties (fixed points, stability, basins of attraction, flow field, quasipotential, instanton, ...)
  2. Generate sample trajectories (direct simulation, rare event/importance sampling, pathspace Langevin MCMC sampling, ...)
  3. Analyze the statistical properties of samples (mean transition path, residence time distribution/scaling, invariant measure, ...)
  4. Relate these sample properties to the dynamical system properties (boundary crossing point, transition indicators, quasipotential height differences, ...)
  5. (what else would be of interest?)

The StochSystem structure is convenient for points 1 and 2 of this workflow. To deal with sampling data in a unified and practical way, it could be useful to define new structures:

  • Trajectory and TrajectoryEnsemble
  • Transition and TransitionEnsemble (subtypes of Trajectory and TrajectoryEnsemble, respectively)

These structures could be abstract types with fields. For example, Transition.path could output the path as a matrix of size (D x N), where D is the system dimension and N the number of path points.

Functions for analyzing transition samples could then follow the general syntax function(tr::TransitionEnsemble, args; kwargs...) or function(sys::StochSystem, tr::TransitionEnsemble, args; kwargs...).

Would this be a good way to structure the functionality?

reykboerner avatar Nov 06 '22 18:11 reykboerner