Skip to content

mgrosmaninho/The-Traveling-Salesman-Problem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

The Traveling Salesman Problem (TSP)

Coursework from University of Hertfordshire

Task

The Travelling Salesman Problem (TSP) asks the following question: Given a list of cities and the distances between each pair of cities, what is the shortest possible route that visits each city exactly once and returns to the original city?

I completed a program in Python that is capable of:

  1. Randomly generating a map of locations
  2. Calculating the distance between those locations
  3. Generating a visiting order to find the shortest path
  4. Visualising the path.

The program implements two algorithms, the Nearest Neighbour Algorithm, and the Genetic Algorithm. The Nearest Neighbour algorithm is used to calculate an optimized travel route between all of the locations returning to the starting point. Whereas the Genetic Algorithm is used to solve small datasets (less than 100).

Contact me!

For more information about this project, please email me at mgrosmaninho@hotmail.com

About

Coursework from University of Hertfordshire

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages