Git Product home page Git Product logo

Comments (5)

gkobeaga avatar gkobeaga commented on June 18, 2024 1

Note that the entries of the cost values are integers in TSPLIB, OPLIB...

Make sure you are using the ATT distance function, it is a bit different from the EUC_2D distance function.

ATT

  xd = x[i] - x[j];
  yd = y[i] - y[j];
  rij = sqrt( (xd*xd + yd*yd) / 10.0 );
  tij = dtrunc( rij );

  if ( tij < rij )
    dij = tij + 1;
  else
    dij = tij;

EUC_2D

  xd = x[i] - x[j];
  yd = y[i] - y[j];
  dij = (int) (sqrt( xd*xd + yd*yd) + 0.5);

from op-solver.

gkobeaga avatar gkobeaga commented on June 18, 2024

There must be something wrong when updating the best known solution.

The output says Visited nodes: 14. However, the objective value is 13.

 - Total nodes: 48
 - Visited nodes: 14
 - Objetive value: 13.000000
 - Cycle length: 2611.000000
 - Cycle: 0 14 23 11 15 45 43 18 7 27 35 32 12 13

@ssinad thank you very much for reporting this issue!

from op-solver.

ssinad avatar ssinad commented on June 18, 2024

There must be something wrong when updating the best known solution.

The output says Visited nodes: 14. However, the objective value is 13.


 - Total nodes: 48

 - Visited nodes: 14

 - Objetive value: 13.000000

 - Cycle length: 2611.000000

 - Cycle: 0 14 23 11 15 45 43 18 7 27 35 32 12 13

@ssinad thank you very much for reporting this issue!

Oh! That's not the issue. In this dataset, node 1 has a reward of zero. What we found has 15 visited nodes.

from op-solver.

gkobeaga avatar gkobeaga commented on June 18, 2024

You are right, 1 has reward zero, let me check what is going on.

from op-solver.

gkobeaga avatar gkobeaga commented on June 18, 2024

The solution you provided is infeasible in that instance, it has length 2661.

CP solution:
 - Total nodes: 48
 - Visited nodes: 15
 - Objetive value: 14.000000
 - Cycle length: 2661.000000
 - Cycle: 0 13 46 20 35 27 7 18 43 45 15 12 11 23 14

I will include an example of how to check the feasibility of a solution.

from op-solver.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.