tsp-solver

Crates.iotsp-solver
lib.rstsp-solver
version0.0.1
sourcesrc
created_at2023-03-24 17:03:42.812801
updated_at2023-03-25 02:58:16.788093
descriptionGenetic travelling salesman problem solver
homepage
repositoryhttps://github.com/oovm/tsp-art
max_upload_size
id819520
size18,123
SasakiSaki (oovm)

documentation

https://docs.rs/tsp-solver

README

use tsp_solver::{Point2D, TspSolver};

pub fn main() {
    let problem = Point2D::random(20, 16.0, 9.0);
    let mut solver = TspSolver::load_or_create("target/days365/", problem.view());
    for solution in solver.ant_colony_optimization(20) {
        println!("{:04}: {}", solution.best_distance, solution.best_path);
    }
}
Commit count: 1

cargo fmt