pub struct OdeOpts {
pub method: Symbol,
pub h: Option<f64>,
pub tol: Option<f64>,
pub max_steps: Option<usize>,
}Expand description
Options controlling an ODE-solve call.
Fields§
§method: SymbolThe ODE solver method to use, or auto to let the registry choose.
h: Option<f64>The fixed step size, for fixed-step solvers.
tol: Option<f64>The error tolerance, for adaptive solvers.
max_steps: Option<usize>An optional cap on the number of integration steps.
Implementations§
Source§impl OdeOpts
impl OdeOpts
Sourcepub fn default_adaptive() -> Self
pub fn default_adaptive() -> Self
Returns default options for an adaptive ODE solve (auto with a tolerance).
§Examples
use sim_lib_numbers_numeric::OdeOpts;
let opts = OdeOpts::default_adaptive();
assert_eq!(opts.method.to_string(), "auto");
assert!(opts.tol.is_some());
assert!(opts.h.is_none());Trait Implementations§
Auto Trait Implementations§
impl Freeze for OdeOpts
impl RefUnwindSafe for OdeOpts
impl Send for OdeOpts
impl Sync for OdeOpts
impl Unpin for OdeOpts
impl UnsafeUnpin for OdeOpts
impl UnwindSafe for OdeOpts
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