Skip to content

Solving TSP with metaheuristic and exact algorithms.

Notifications You must be signed in to change notification settings

igorstalmach/travelling-salesman-problem

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Travelling Salesman Problem

Solution created for Efficient Algorithms Design college class.

Algorithms implemented

  • Exact algorithms
    • Branch and Bound (Least cost)
    • Brute Force
  • Metaheuristic algorithms:
    • Simulated Annealing
      • parameters: starting and final temperature, temperature reduction coefficient, stop condition (time in seconds)
    • Genetic algorithm
      • parameters: population size, crossover and mutation coefficient, crossover method (one point or two point), mutation method (one pair or two pair swap), stop condition (time in seconds)

Input

  • File with a number of cities and a matrix of distances.
    4
    0 1 1 1
    1 0 1 1
    1 1 0 1
    1 1 1 0

Output

  • Path
  • Path length
  • Execution time

Dependencies

  • Apache Commons Collections 4.4 (for brute force)

Releases

No releases published

Packages

No packages published

Languages