Hmmm. Just thinking: how about adding an additional node that is assigned to lead back to the start node and then find a Hamiltonian circuit for this? That should work, shouldn't it? Or am I missing something.
Christian -- Christian Schulte, KTH, web.it.kth.se/~cschulte/ -----Original Message----- From: [email protected] [mailto:[email protected]] On Behalf Of serge lemouton Sent: Thursday, May 19, 2011 9:32 PM To: [email protected] Subject: [gecode-users] graph constraints and hamiltonian path Hello, Question about graph constraints: I would like to modify the the TSP example in order to find the solutions where the travelling salesman should not return to its starting point. In other terms, is it possible to use the "circuit" constraint to find an hamiltonian path instead of a circuit ? Does it require to modify the code or is it better to create another subclass of the graph class ? Thanks for any advice, Serge Lemouton _______________________________________________ Gecode users mailing list [email protected] https://www.gecode.org/mailman/listinfo/gecode-users _______________________________________________ Gecode users mailing list [email protected] https://www.gecode.org/mailman/listinfo/gecode-users
