How to simulate the TSP(Travelling salesman problem) with Wallacei?

Can Wallacei X simulate the TSP ? I have been thinking about this for a long time, but I have no idea.

yes… Wallacei can solve for any problem that requires the optimisation of a fitness function (or in more simple terms, making a number as small as possible)… you’ll just need to create the TSP in a grasshopper definition…

considering the definition of the TSP problem:

Given a list of cities and the distances between each pair of cities, what is the shortest possible route that visits each city and returns to the origin city? (cf. wikipedia )

You can create a set of points in 2d and calculate a path between them (according to the above) and optimise for the shortest path.

if you create the definition do post it here… would love to see your results (and im sure there are others who would enjoy to have their hands on a TSP in grasshopper).

What I simulate describe below:


However, every seed is a random value which will cause a random result, which should not be heuristic in my opinion. How do you think?