Function metaheuristics::random_search::solve [] [src]

pub fn solve<T>(problem: &mut Metaheuristics<T>, runtime: Duration) -> T

Returns an approximate solution to your optimisation problem using Random Search

Parameters

problem is the type that implements the Metaheuristics trait.

runtime is a time::Duration specifying how long to spend searching for a solution.

Examples

let solution = metaheuristics::random_search::solve(&mut problem, runtime);