Trait Minimizer

Source
pub trait Minimizer<F: ?Sized> {
    type Solution: Evaluation;

    // Required method
    fn minimize(
        &self,
        function: &F,
        initial_position: Vec<f64>,
    ) -> Self::Solution;
}
Expand description

Defines an optimizer that is able to minimize a given objective function F.

Required Associated Types§

Source

type Solution: Evaluation

Type of the solution the Minimizer returns.

Required Methods§

Source

fn minimize(&self, function: &F, initial_position: Vec<f64>) -> Self::Solution

Performs the actual minimization and returns a solution that might be better than the initially provided one.

Implementors§