pub struct SolverSettings {
pub xatol: Option<f64>,
pub vtol: Option<f64>,
pub batol: Option<f64>,
pub brtol: Option<f64>,
pub max_iter: Option<u32>,
pub max_feval: Option<u32>,
pub max_deval: Option<u32>,
pub rebracket: Option<bool>,
pub max_bracket_iter: Option<u32>,
}Expand description
Solver settings.
Fields§
§xatol: Option<f64>Absolute step tolerance.
The absolute step tolerance is satisfied when
(x_next - x_current).abs() <= xatol
where x_current and x_next are the current and next iterates, respectively.
vtol: Option<f64>Value tolerance.
The value tolerance is satisfied when
v_current.abs() <= vtol
where v_current is the function evaluation at the current iterate.
batol: Option<f64>Absolute bracket tolerance.
The absolute bracket tolerance is satisfied when
(b - a).abs() <= batol
where a and b are the lower and upper bounds, respectively, of the current bracketing
interval.
brtol: Option<f64>Relative bracket tolerance.
The relative bracket tolerance is satisfied when
(b - a).abs() <= brtol * (a.abs().max(b.abs()))
where a and b are the lower and upper bounds, respectively, of the current bracketing
interval.
max_iter: Option<u32>Maximum number of solver iterations allowed.
max_feval: Option<u32>Maximum number of function evaluations allowed.
max_deval: Option<u32>Maximum number of derivative evaluations allowed.
rebracket: Option<bool>true if the initial interval should be updated to ensure a sign change, false otherwise.
max_bracket_iter: Option<u32>Maximum number of bracketing iterations allowed.
Implementations§
Source§impl SolverSettings
impl SolverSettings
Sourcepub fn new(
xatol: Option<f64>,
vtol: Option<f64>,
batol: Option<f64>,
brtol: Option<f64>,
max_iter: Option<u32>,
max_feval: Option<u32>,
max_deval: Option<u32>,
rebracket: Option<bool>,
max_bracket_iter: Option<u32>,
) -> Self
pub fn new( xatol: Option<f64>, vtol: Option<f64>, batol: Option<f64>, brtol: Option<f64>, max_iter: Option<u32>, max_feval: Option<u32>, max_deval: Option<u32>, rebracket: Option<bool>, max_bracket_iter: Option<u32>, ) -> Self
Constructor.
§Arguments
xatol- Absolute step tolerance. The absolute step tolerance is satisfied when(x_next - x_current).abs() <= xatol, wherex_currentandx_nextare the current and next iterates, respectively.vtol- Value tolerance. The value tolerance is satisfied whenv_current.abs() <= vtol, wherev_currentis the function evaluation at the current iterate.batol- Absolute bracket tolerance. The absolute bracket tolerance is satisfied when(b - a).abs() <= batol, whereaandbare the lower and upper bounds, respectively, of the current bracketing interval.brtol- Relative bracket tolerance. The relative bracket tolerance is satisfied when(b - a).abs() <= brtol * (a.abs().max(b.abs())), whereaandbare the lower and upper bounds, respectively, of the current bracketing interval.max_iter- Maximum number of solver iterations allowed.max_feval- Maximum number of function evaluations allowed.max_deval- Maximum number of derivative evaluations allowed.rebracket-trueif the initial interval should be updated to ensure a sign change,falseotherwise.max_bracket_iter- Maximum number of iterations to find a bracketing interval allowed.
Trait Implementations§
Source§impl Clone for SolverSettings
impl Clone for SolverSettings
Source§fn clone(&self) -> SolverSettings
fn clone(&self) -> SolverSettings
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
source. Read more