TSPLIB benchmark files
TSPLIB is a library containing sample problems for the TSP based on actual geographic locations of cities. The library is maintained by the Heidelberg University, and relevant examples can be found here: http://elib.zib.de/pub/mp-testdata/tsp/tsplib/tsp/.
The optimal distances for each problem can be found here: http://comopt.ifi.uni-heidelberg.de/software/TSPLIB95/STSP.html.
The TSPLIB examples are contained in text-based, whitespace-delimited data files. A typical file contains several informational lines followed by the city data. We are interested in files that contain the x, y coordinates of the participating cities, so we can plot the cities and visualize their locations. For example, the burma14.tsp file looks ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access