Skip to main content

Module integrator

Module integrator 

Source
Expand description

Initial-value integrators: the adaptive Dormand–Prince 5(4) pair with dense output, and the classical fixed-step fourth-order Runge–Kutta method.

Integrator::advance takes accepted steps from the current time toward a stop time and returns at the stop time, at the first events on the way, or when the system asks to stop. A stop time is always a step boundary, so a caller puts discontinuities there (burnout, a thrust-curve knot, a phase change) and never lets one fall inside a step (Loft lesson L23: Loft let burnout fall inside steps). The system declares its events and sees each accepted step, with its dense output, through OdeSystem’s provided methods.

  • Dormand–Prince 5(4) (Method::DormandPrince54): the pair of J. R. Dormand and P. J. Prince, “A family of embedded Runge-Kutta formulae”, J. Comput. Appl. Math. 6 (1980) 19–26, advancing with the fifth-order solution (local extrapolation). The coefficients, the error norm, the PI step-size controller, the starting step and the fourth-order continuous extension follow E. Hairer and G. Wanner’s DOPRI5 (version of 2004, BSD-2-Clause, pinned as hairer-dopri5 in validation/refs.lock.toml), which implements Hairer, Nørsett and Wanner, Solving Ordinary Differential Equations I, 2nd ed., Springer, 1993, §II.4–II.6, and §IV.2 of volume II. The port is noted in THIRD-PARTY-NOTICES.md.
  • RK4 (Method::Rk4): Kutta’s classical method (HNW I, §II.1, table 1.2) with a fixed step and cubic Hermite dense output from the derivatives at both ends.

Method, tests and limits: docs/physics/integration.md.

Structs§

Adaptive
Settings for the adaptive Dormand–Prince 5(4) method.
Integrator
A stateful integrator for an N-component system.
Stats
Work counters since the integrator was built.
Step
One accepted step and its dense output.

Enums§

Advance
How Integrator::advance returned.
IntegrationError
Why an integration stopped short. The integrator stays at its last accepted step, and a later Integrator::advance may resume from there.
Method
The integration method.
SettingsError
A setting or initial value the integrator can’t use.

Constants§

DEFAULT_STEP_LIMIT
The default step limit.

Traits§

OdeSystem
A first-order system y' = f(t, y) with N components, its events and its step observer.