Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't get TSP example "numberOfViolatedConstraints.setAttribute(solution,nonConnectedLinks-numberOfCities+9)" #12

Open
bronzels opened this issue Jun 19, 2021 · 0 comments

Comments

@bronzels
Copy link

I tried to write a problem myself by referring to TSP as it is easier to understand, but don't get this line.

To me nonConnectedLinks is just the number of violations to constraint(non connected city are set next to each other), why add "-numberOfCities+9"?

jmetalsp-problem\src\main\java\org\uma\jmetalsp\problem\tsp\DynamicMultiobjectiveTSP.java

numberOfViolatedConstraints.setAttribute(solution,nonConnectedLinks-numberOfCities+9);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant