This project aims to replicate and implement several classic algorithms for solving the traveling salesman problem, including:
- Greedy Nearest Neighbor Algorithm
- Christofides-Serdyukov Algorithm
- Simulated Annealing Algorithm
- Genetic Algorithm
I am planning to submit this project as my homework for the "Evolutionary Computation" course at WUST.
pip install -r requirements.txt
An example is as follows:
problem = Problem('a280', verbose=True, vis=False)
solver = SimulatedAnnealing(
t=1000, eps=1e-14, alpha=0.98, time_out=1,
early_stop=problem.dimension, verbose=True)
solver.solve(problem)
print(problem.best_seen.length)