pub struct DynSystemIntegrator {
pub solver: OdeSolver,
pub system: SharedOdeSystem,
}Expand description
Solver plus a shared, runtime-typed system.
The flexibility variant, kept by maintainer decision: the system type need
not be known where the integrator is built, and the same system can be
shared by several integrators. Prefer TypedStateIntegrator when the type
is known — it dispatches statically.
Fields§
§solver: OdeSolverWhich stepper advances the state.
system: SharedOdeSystemThe system being integrated, shared by Arc. Cloning the integrator
shares the system rather than duplicating it.
Implementations§
Source§impl DynSystemIntegrator
impl DynSystemIntegrator
Sourcepub fn new(system: SharedOdeSystem, solver: OdeSolver) -> Self
pub fn new(system: SharedOdeSystem, solver: OdeSolver) -> Self
Pair a shared system with a solver.
Sourcepub fn solve_step(
&mut self,
x: &mut f64,
y: &mut Vec<f64>,
dx_try: &mut f64,
) -> Result<(), OdeError>
pub fn solve_step( &mut self, x: &mut f64, y: &mut Vec<f64>, dx_try: &mut f64, ) -> Result<(), OdeError>
Trait Implementations§
Source§impl Clone for DynSystemIntegrator
impl Clone for DynSystemIntegrator
Auto Trait Implementations§
impl !RefUnwindSafe for DynSystemIntegrator
impl !UnwindSafe for DynSystemIntegrator
impl Freeze for DynSystemIntegrator
impl Send for DynSystemIntegrator
impl Sync for DynSystemIntegrator
impl Unpin for DynSystemIntegrator
impl UnsafeUnpin for DynSystemIntegrator
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more