© Alexandre Bergel​ 2020
A. BergelAgile Artificial Intelligence in Pharohttps://doi.org/10.1007/978-1-4842-5384-7_10

10. The Traveling Salesman Problem

Alexandre Bergel1 
Santiago, Chile

The Traveling Salesman Problem (TSP) is a classical algorithm problem. It consists of identifying the shortest possible route between several connected cities. Not only is the problem relevant from an algorithmic point of view, but it also has many concrete applications, like microchip manufacturing, as you will shorty see.

The chapter incrementally builds a non-trivial solution to the problem using a genetic algorithm. The chapter begins with a naive approach to a robust, practical way of solving it.

10.1 Illustration of the Problem

Figure 10-1

Setup of the Traveling ...

Get Agile Artificial Intelligence in Pharo: Implementing Neural Networks, Genetic Algorithms, and Neuroevolution now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.