Script which solves the Travelling Salesman Problem (TSP) for rectangular grid

Script which solves the Travelling Salesman Problem (TSP) for rectangular grid
295 Downloads
Updated 10 Aug 2015

View License

The script MinimizeSuccessiveTilts.m solves the Travelling Salesman Problem (TSP) for rectangular grid. After solution the script will display interactively the result of solution. In this script Nx and Ny are integer numbers for dimensions of the grid. i0 and j0 are the starting points for salesman on the rectangular grid (x and y coordinates). After execution the script will print the elapsed time for solution itself, the edge will the maximum length of the step between two successive cites on the grid, the algorithm which gives the best result and the total elapsed time. The solution is based on heuristic search. The script can be adjusted in such a way that it minimizes the total length of the path. For that just uncomment one commented line in the script.

Cite As

Dmitry Tyutyunnikov (2024). Script which solves the Travelling Salesman Problem (TSP) for rectangular grid (https://www.mathworks.com/matlabcentral/fileexchange/52432-script-which-solves-the-travelling-salesman-problem-tsp-for-rectangular-grid), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2014a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Tags Add Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.0.0.0

The picture changed.