Say I'm writing a GA to solve the travelling salesman problem. I don't know in advance what the shortest path is, so how does my GA know when to stop?If I wait until the best fitness doesn't reduce for a few generations, how do I know I'm not temporarily stuck in a local minimum, which some mutation in the next generation may help? If the best fitness goes up, how do I know this isn't just a temporary thing that will again be solved in a future generation?
How does the genetic algorithm know when to stop if the global minimum isn't known?
genetic algorithms