The standard TSP problem attempts to find a minimum length cycle that visits all points in a provided set of points. Say our set of points is: { A, B, C, ā¦, Z }.
Another way to phrase this, if we want to start/end at point A, is: A -> { B, C, ā¦, Z } -> A.
So our task is to find an ordering of the set between the Aās ( { B, C, ā¦, Z } ) that minimizes the total distance travelled. This is the TSP problem.
If we remove the requirement to return to the start point (make a cycle), then it becomes:
A -> { B, C, ā¦, Z }
This is technically not the TSP problem. A minimum distance solution for this problem may not be the same as that for the true TSP problem. But, it should be clear that the size of the space we are searching to optimize ( { B, C, ā¦, Z } ) remains unchanged. So the problem is not easier.
In terms of EVE, I donāt think itās a minimum Hamiltonian path problem (MHP) either (although similar). Our shortest paths from any one point to another may go through another point in the list, which could technically violate the MHP problem. Also, MHP is NP-complete, so itās not easier than TSP.
I donāt have time at the moment to fully trace the logic of your code, but at a glance I find it hard to believe that you are guaranteeing an optimal path. Have you checked your results against those provided in-game for routes of 10-12 waypoints? For an implementation that takes arbitrary length sets of waypoints I expect to see recursive function calls (maybe I just missed that?). I have no experience writing programs to interface with EVE in this way, so maybe you are outsourcing part of the algorithm to the server in a way I missed. A description/reference of the algorithm you are using would be easier to understand.
If your program is completing on waypoint lists of 20+, itās almost certainly not guaranteeing an optimal result.