© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2022
R. WienerGeneric Data Structures and Algorithms in Gohttps://doi.org/10.1007/978-1-4842-8191-8_20

20. Genetic Algorithm for TSP

Richard Wiener1  
(1)
Colorado Springs, CO, USA
 

The previous chapter presented an implementation of simulated annealing, a powerful and useful heuristic algorithm for solving TSP. We saw that this heuristic algorithm often obtains the optimum solution to the problem with relatively little computational effort.

This chapter presents another heuristic approach for TSP – genetic algorithm.

In the next section, we introduce the basis for this heuristic algorithm

20.1 Genetic Algorithm

A genetic algorithm is inspired by the biological maxim ...

Get Generic Data Structures and Algorithms in Go: An Applied Approach Using Concurrency, Genericity and Heuristics now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.