pub struct NelderMead {
pub initial_step: f64,
pub tolerance: f64,
pub max_iterations: usize,
}Expand description
Options for nelder_mead.
initial_step sizes the starting simplex: each coordinate of the
start point is moved by initial_step times its absolute value (a
relative step), or by initial_step itself when that absolute value is
below 1, so a start at or near zero still gets a simplex of useful
size. initial_step must be finite and larger than tolerance, or the
starting simplex could already pass the convergence test; otherwise
nelder_mead does not search. The search has converged when the spread of the
simplex’s values is within tolerance times max(1, |best value|) and
every vertex is within tolerance times max(1, |best x|) of the best
one in each coordinate. max_iterations counts simplex moves over both
passes (see nelder_mead).
use prospicio_math::optimize::NelderMead;
let options = NelderMead { tolerance: 1e-12, ..NelderMead::default() };
assert_eq!(options.initial_step, 0.1);Fields§
§initial_step: f64Size of the starting simplex, relative to each coordinate of absolute value 1 or more.
tolerance: f64Convergence tolerance on both the values and the simplex diameter.
max_iterations: usizeMost simplex moves allowed in total.