Skip to content

Reproduce the ant colony optimization algorithm to solve the traveling salesman problem.

Notifications You must be signed in to change notification settings

abdenourbarache/ant-colony-optimization-traveling-salesman-problem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Python Ant Colony Algorithm Applied To Traveling Salesman Problem

This small project aims to reproduce the ant colony optimization algorithm to solve the traveling salesman problem. This problem consists in finding the best path (tour with the minimum total length) for the travelling salesman, where he passes by all the cities once.

This project was inspired from : https://link.springer.com/chapter/10.1007/0-306-48056-5_9

Description

This project is built in Python and consist of three files :

  • data.py, contains three graphes examples ( default one is the benchmark GR17 which is a set of 17 cities, from TSPLIB ).
  • functions.py, which have the essential functions used in the ACO algorithm.
  • aco.py, the main file which contains the ACO algorithm and global parameters.

Dependencies

  • Python 3

Executing program

  • You can change the graph or the global parameters in the file (aco.py) first.
  • Simply run aco.py
python aco.py

About

Reproduce the ant colony optimization algorithm to solve the traveling salesman problem.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages