Skip to main content

Module response_ode

Module response_ode 

Expand description

Zero-Heap 4D RK4 Driven Spring & Thermal ODE Response Kernel (response_ode.rs).

Consolidates DrivenSpring, SpringState, step_spring, ThermalTargets, and step_thermal with a self-contained zero-heap 4-state 4th-order Runge–Kutta integrator Rk4Integrator4D.

Structs§

DrivenSpring
Stiffness and damping per unit mass: stiffness * (target - position) - damping * velocity.
ODEState4D
4-state ODE snapshot.
Rk4Integrator4D
Zero-heap 4th-order Runge–Kutta ODE integrator with fixed [f64; 4] state.
SpringState
1D spring position and velocity state.
ThermalTargets
Two-channel driven thermal reservoir targets and relaxation rates ($s^{-1}$).

Enums§

ResponseOdeError
Error type returned by Rk4Integrator4D, step_spring, and step_thermal.

Traits§

ODEFunction4D
4-state ODE derivative trait for Rk4Integrator4D.

Functions§

step_spring
Steps a DrivenSpring over dt (0.0..=0.05 s), substepped at $\le 1/240$ s via Rk4Integrator4D.
step_thermal
Steps two thermal channels toward targets over dt (0.0..=0.05 s) via Rk4Integrator4D.

Type Aliases§

ResponseOdeResult
Result alias for ODE response kernels.