Zhach's Implementation and Optimization of the TSP problem
The main goal is to combine some TSP solutions together in C++ and try to compare them.
I want to make a structure where I can read in a graph, choose and algorithm with a group of enums, and then it can run said algorithm.
The idea is really just to have a plug an play option with algorithms. All I need to do is send them is a "Graph" structure and then I expect either a string of the shortest path or an error with the graph (like it's not a completed graph).
The structure is simple enough.
- Read in arguments
- Parse in graph file into an object
- Send graph to chosen algorithm
- Time the algorithm
- Get result and print out path and time it took
I want to take a look at a few listed in Traveling Salesman Problem: An Overview of Applications, Formulations, and Solution Approaches:
- Brute force (check all permutations)
- Held–Karp algorithm
- Closest neighbor hueristic
- Shortest edge hueristic
- Subtour hueristic
- Genetic algorithm
- Ant colony
- Christofide heuristic