Non-optimal solutions when solving an aTSP with Gurobi
AnsweredHi, I'm trying to solve an Asymmetric Travelling Salesman Problem using the following formulation:
GRBEnv env = new GRBEnv(true);
env.Start();
GRBModel model = new GRBModel(env);
//Gurobi Parameters
model.Parameters.TimeLimit = 3600;
//Variables
GRBVar[,] x = new GRBVar[numberOfNodes, numberOfNodes];
GRBVar[] u = new GRBVar[numberOfNodes];
for (int i=0; i<numberOfNodes; i++)
{
if (i > 0)
{
u[i] = model.AddVar(1, numberOfNodes - 1, 0, GRB.INTEGER, "u");
}
for(int j=0; j<numberOfNodes; j++)
{
if (i != j)
{
x[i, j] = model.AddVar(0, 1, distancematrix[i, j], GRB.BINARY, "x");
}
}
}
//Objective
model.ModelSense = GRB.MINIMIZE;
//Constraints
for(int i=0; i<numberOfNodes; i++)
{
GRBLinExpr edgesIn = new GRBLinExpr();
GRBLinExpr edgesOut = new GRBLinExpr();
for(int j=0; j<numberOfNodes; j++)
{
if (i != j)
{
edgesIn.AddTerm(1, x[j, i]);
edgesOut.AddTerm(1, x[i, j]);
if(i>0 && j > 0)
{
model.AddConstr(u[i] - u[j] + numberOfNodes * x[i, j], GRB.LESS_EQUAL, numberOfNodes - 1, "subtourElimination1");
}
}
}
model.AddConstr(edgesIn, GRB.EQUAL, 1, "edgesIn");
model.AddConstr(edgesOut, GRB.EQUAL, 1, "edgesOut");
}
model.Optimize();
}
Although it works for most cases, there are instances for which Gurobi suggests a non-optimal solution (but declares it as optimal). For example, when handing Gurobi the following distance parameters as "distancematrix" (sorry for the messy visualization):
{ {0,43618,43620,43628,43615,43616,43617,43624,43627,43629,43632,43611,43616,43620,43622,43629,43620,43621,43612,43618,43606,43609,43610,43613,43616,43617,43618,43619,43620,43621,43605,43617,43619,43608,43612,43613,43616,43617,43619,43622,43613,43614,43615,43617,43618,43620,43629,43614,43615,43616,43618,43624,43633},
{43615,0,43609,43617,0,43600,43600,43609,43612,43614,43617,43606,43600,43615,43617,43600,43621,43622,43619,43625,43600,43622,43623,43626,43629,43630,43631,43632,43600,43632,43618,43630,43600,43600,43625,43600,43629,43630,43632,43635,43626,43627,43628,43630,43631,43600,43600,43627,43628,43600,43631,43637,43600},
{43624,43616,0,43622,43609,43608,43607,0,43603,43605,43608,43600,43620,43624,43622,43615,43624,43600,43600,43600,43628,43600,43600,43631,43600,43600,43626,43600,43624,43623,43600,43633,43631,43630,43634,43635,43638,43600,43600,43600,43635,43636,43637,43600,43600,43642,43633,43600,43600,43638,43600,43644,43635},
{43627,43619,43621,0,43612,43611,43610,43603,0,43600,43600,43618,43623,43600,43600,43612,43600,43620,43629,43623,43631,43632,43631,43600,43625,43624,43600,43622,43621,43600,43630,43600,43628,43633,43600,43638,43600,43636,43634,43631,43600,43600,43600,43642,43641,43639,43630,43639,43640,43641,43643,43600,43632},
{43616,43600,43610,43618,0,0,43600,43608,43611,43613,43616,43607,43600,43616,43618,43600,43622,43623,43620,43626,43600,43623,43624,43627,43630,43631,43632,43633,43600,43631,43619,43631,43600,43600,43626,43600,43630,43631,43633,43636,43627,43628,43629,43631,43632,43600,43600,43628,43629,43600,43632,43638,43600},
{43617,43600,43611,43619,43600,0,0,43607,43610,43612,43615,43608,43600,43617,43619,43600,43623,43624,43621,43627,43600,43624,43625,43628,43631,43632,43633,43632,43600,43630,43620,43632,43600,43600,43627,43600,43631,43632,43634,43637,43628,43629,43630,43632,43633,43600,43600,43629,43630,43600,43633,43639,43600},
{43616,43600,43616,43624,43600,43600,0,43620,43623,43623,43620,43605,0,43604,43606,43600,43622,43623,43620,43626,43600,43623,43624,43627,43630,43629,43628,43627,43600,43625,43619,43631,43600,43600,43626,43600,43630,43631,43633,43636,43627,43628,43629,43631,43632,43600,43600,43628,43629,43600,43632,43638,43600},
{43611,43609,43600,43619,43606,43607,43608,0,43618,43620,43623,0,43605,43609,43611,43618,43617,43600,43600,43600,43615,43600,43600,43622,43600,43600,43627,43600,43629,43630,43600,43626,43628,43617,43621,43622,43625,43600,43600,43600,43622,43623,43624,43600,43600,43629,43638,43600,43600,43625,43600,43633,43642},
{43629,43621,43623,43600,43614,43613,43612,43605,0,0,43600,43620,43623,43600,43600,43610,43600,43618,43627,43621,43633,43630,43629,43600,43623,43622,43600,43620,43619,43600,43632,43600,43626,43635,43600,43638,43600,43634,43632,43629,43600,43600,43600,43640,43639,43637,43628,43641,43642,43643,43645,43600,43630},
{43632,43624,43622,43600,43617,43616,43615,43608,43600,0,0,43623,43620,43600,43600,43607,43600,43615,43624,43618,43630,43627,43626,43600,43620,43619,43600,43617,43616,43600,43635,43600,43623,43638,43600,43635,43600,43631,43629,43626,43600,43600,43600,43637,43636,43634,43625,43644,43645,43644,43642,43600,43627},
{43620,43618,43620,43600,43615,43616,43617,43624,43600,43600,0,43609,43604,0,43600,43609,43600,43621,43624,43624,43624,43627,43628,43600,43626,43625,43600,43623,43622,43600,43623,43600,43629,43626,43600,43631,43600,43635,43635,43632,43600,43600,43600,43635,43636,43638,43631,43632,43633,43634,43636,43600,43633},
{43621,43625,43600,43625,43622,43623,43624,43600,43620,43618,43615,0,43623,43621,43619,43612,43601,0,43600,43600,43625,43600,43600,43622,43600,43600,43617,43600,43615,43614,43600,43624,43622,43627,43631,43632,43631,43600,43600,43600,43632,43633,43634,43600,43600,43633,43624,43600,43600,43635,43600,43635,43626},
{43629,43600,43625,43617,43600,43600,43600,43615,43612,43610,43607,43618,0,43609,43607,0,43613,43612,43621,43615,43600,43624,43623,43620,43617,43616,43615,43614,43600,43612,43632,43622,43600,43600,43633,43600,43629,43628,43626,43623,43638,43637,43636,43634,43633,43600,43600,43641,43642,43600,43639,43633,43600},
{43622,43620,43622,43600,43617,43618,43619,43622,43600,43600,43600,43611,43606,0,0,43607,43600,43619,43626,43622,43626,43629,43630,43600,43624,43623,43600,43621,43620,43600,43625,43600,43627,43628,43600,43633,43600,43635,43633,43630,43600,43600,43600,43637,43638,43638,43629,43634,43635,43636,43638,43600,43631},
{43620,43624,43626,43600,43621,43622,43623,43624,43600,43600,43600,43617,43622,43600,0,43613,0,43601,43624,43618,43624,43627,43626,43600,43620,43619,43600,43617,43616,43600,43623,43600,43623,43626,43600,43631,43600,43631,43629,43626,43600,43600,43600,43635,43636,43634,43625,43632,43633,43634,43636,43600,43627},
{43606,43600,43624,43632,43600,43600,43600,43628,43631,43633,43630,43615,43600,43624,43626,0,43624,43625,43616,43622,0,43603,43604,43607,43610,43611,43612,43613,43600,43615,43609,43621,43600,43600,43616,43600,43620,43621,43623,43626,43617,43618,43619,43621,43622,43600,43600,43618,43619,43600,43622,43628,43600},
{43613,43629,43631,43600,43626,43627,43628,43631,43600,43600,43600,43622,43627,43600,43600,43620,0,43622,43623,43619,43607,43604,43603,0,43603,43604,43600,43606,43607,43600,43616,43600,43618,43619,43600,43624,43600,43626,43624,43621,43600,43600,43600,43628,43629,43629,43620,43625,43626,43627,43629,43600,43622},
{43612,43622,43600,43632,43619,43620,43621,43600,43629,43627,43624,43600,43620,43624,43626,43621,43624,0,0,43600,43616,43600,43600,43623,43600,43600,43620,43600,43618,43617,43600,43627,43625,43618,43622,43623,43626,43600,43600,43600,43623,43624,43625,43600,43600,43630,43627,43600,43600,43626,43600,43634,43629},
{43618,43628,43600,43628,43625,43626,43627,43600,43623,43621,43618,43600,43626,43624,43622,43615,43618,43600,0,0,43622,43600,43600,43619,43600,43600,43614,43600,43612,43611,43600,43621,43619,43624,43628,43629,43628,43600,43600,43600,43629,43630,43631,43600,43600,43630,43621,43600,43600,43632,43600,43632,43623},
{43609,43625,43600,43635,43622,43623,43624,43600,43632,43630,43627,43600,43623,43627,43629,43624,43627,43600,43600,0,43603,0,43600,43604,43600,43600,43609,43600,43611,43612,43600,43624,43622,43615,43619,43620,43623,43600,43600,43600,43620,43621,43622,43600,43600,43627,43624,43600,43600,43623,43600,43631,43626},
{43620,43600,43634,43626,43600,43600,43600,43624,43621,43619,43616,43629,43600,43622,43620,43600,43616,43615,43618,43612,0,43611,43610,43607,43604,43603,43602,43601,0,43601,43623,43613,43600,43600,43624,43600,43620,43619,43617,43614,43629,43628,43627,43625,43624,43600,43600,43632,43633,43600,43630,43624,43600},
{43610,43626,43600,43636,43623,43624,43625,43600,43631,43629,43626,43600,43624,43628,43630,43623,43626,43600,43600,43600,43604,0,0,43603,43600,43600,43608,43600,43610,43611,43600,43623,43621,43616,43620,43621,43624,43600,43600,43600,43621,43622,43623,43600,43600,43628,43623,43600,43600,43624,43600,43632,43625},
{43616,43632,43600,43630,43629,43630,43631,43600,43625,43623,43620,43600,43630,43626,43624,43617,43620,43600,43600,43600,43610,43600,0,43603,0,43600,43602,43600,43604,43605,43600,43617,43615,43622,43626,43627,43624,43600,43600,43600,43627,43628,43629,43600,43600,43626,43617,43600,43600,43630,43600,43628,43619},
{43618,43634,43636,43600,43631,43632,43633,43626,43600,43600,43600,43627,43628,43600,43600,43615,43600,43617,43620,43614,43612,43609,43608,0,43602,43601,0,43601,43602,43600,43621,43600,43613,43624,43600,43625,43600,43621,43619,43616,43600,43600,43600,43627,43626,43624,43615,43630,43631,43632,43632,43600,43617},
{43617,43633,43600,43629,43630,43631,43632,43600,43624,43622,43619,43600,43629,43625,43623,43616,43619,43600,43600,43600,43611,43600,43600,43604,0,0,43601,43600,43603,43604,43600,43616,43614,43623,43627,43626,43623,43600,43600,43600,43628,43629,43630,43600,43600,43625,43616,43600,43600,43631,43600,43627,43618},
{43619,43635,43600,43627,43632,43633,43632,43600,43622,43620,43617,43600,43627,43623,43621,43614,43617,43600,43600,43600,43613,43600,43600,43606,43600,0,43601,0,43601,43602,43600,43614,43612,43625,43625,43624,43621,43600,43600,43600,43630,43629,43628,43600,43600,43623,43614,43600,43600,43633,43600,43625,43616},
{43621,43635,43633,43600,43632,43631,43630,43623,43600,43600,43600,43630,43625,43600,43600,43612,43600,43614,43617,43611,43615,43612,43611,43600,43605,43604,0,43602,43601,0,43624,43600,43610,43627,43600,43622,43600,43618,43616,43613,43600,43600,43600,43624,43623,43621,43612,43633,43632,43631,43629,43600,43614},
{43605,43621,43600,43631,43618,43619,43620,43600,43630,43632,43635,43600,43619,43623,43625,43632,43623,43600,43600,43600,43609,43600,43600,43616,43600,43600,43621,0,43623,43624,0,43612,43614,43605,43609,43610,43613,43600,43600,43600,43610,43611,43612,43600,43600,43617,43626,43600,43600,43613,43600,43621,43630},
{43619,43600,43637,43633,43600,43600,43600,43631,43628,43626,43623,43628,43600,43629,43627,43600,43623,43622,43625,43619,43600,43622,43621,43618,43615,43614,43613,43612,0,43610,43614,43602,0,43600,43623,43600,43621,43620,43618,43615,43624,43625,43626,43626,43625,43600,43600,43625,43626,43600,43629,43625,43600},
{43617,43633,43635,43600,43630,43631,43632,43633,43600,43600,43600,43626,43631,43600,43600,43622,43600,43624,43627,43621,43621,43624,43623,43600,43617,43616,43600,43614,43613,0,43612,0,43602,43617,43600,43622,43600,43622,43620,43617,43600,43600,43600,43626,43627,43625,43616,43623,43624,43625,43627,43600,43618},
{43617,43633,43600,43641,43630,43631,43632,43600,43636,43634,43631,43600,43631,43635,43635,43628,43631,43600,43600,43600,43621,43600,43600,43626,43600,43600,43621,43600,43619,43618,0,43622,43620,43609,43605,43604,43601,0,43600,43600,43616,43617,43618,43600,43600,43623,43616,43600,43600,43619,43600,43627,43618},
{43612,43628,43630,43600,43625,43626,43627,43634,43600,43600,43600,43621,43626,43600,43600,43633,43600,43631,43622,43628,43616,43619,43620,43600,43626,43627,43600,43625,43624,43600,43609,0,43623,43604,0,43601,43600,43605,43607,43610,43600,43600,43600,43615,43616,43618,43621,43612,43613,43614,43616,43600,43623},
{43608,43600,43626,43634,43600,43600,43600,43630,43633,43635,43638,43617,43600,43626,43628,43600,43626,43627,43618,43624,43600,43615,43616,43619,43622,43623,43624,43625,43600,43627,43605,43617,0,0,43604,43600,43608,43609,43611,43614,43607,43608,43609,43611,43612,43600,43600,43608,43609,43600,43612,43618,43600},
{43613,43600,43631,43639,43600,43600,43600,43635,43638,43638,43635,43622,43600,43631,43633,43600,43631,43632,43623,43629,43600,43620,43621,43624,43627,43626,43625,43624,43600,43622,43610,43622,43600,0,43601,0,43603,43604,43606,43609,43612,43613,43614,43616,43617,43600,43600,43613,43614,43600,43617,43623,43600},
{43616,43632,43634,43600,43629,43630,43631,43638,43600,43600,43600,43625,43630,43600,43600,43629,43600,43631,43626,43628,43620,43623,43624,43600,43624,43623,43600,43621,43620,43600,43613,43600,43621,43608,0,43603,0,43601,43603,43606,43600,43600,43600,43619,43620,43622,43617,43616,43617,43618,43620,43600,43619},
{43620,43600,43638,43644,43600,43600,43600,43642,43639,43637,43634,43629,43600,43638,43638,43600,43634,43633,43630,43630,43600,43627,43628,43629,43626,43625,43624,43623,43600,43621,43617,43625,43600,43600,43618,0,43622,43623,43623,43620,43607,43606,43605,43603,43602,0,43600,43614,43615,43600,43618,43624,43600},
{43613,43629,43631,43600,43626,43627,43628,43635,43600,43600,43600,43622,43627,43600,43600,43638,43600,43632,43623,43629,43617,43620,43621,43600,43627,43628,43600,43630,43629,43600,43610,43600,43624,43607,43600,43612,0,43616,43618,43621,0,43600,43600,43604,43605,43607,43616,43607,43608,43609,43611,43600,43622},
{43619,43635,43600,43639,43632,43633,43634,43600,43634,43632,43629,43600,43633,43635,43633,43626,43629,43600,43600,43600,43623,43600,43600,43624,43600,43600,43619,43600,43617,43616,43600,43620,43618,43611,43607,43606,43603,0,0,43600,43618,43619,43620,43600,43600,43623,43614,43600,43600,43621,43600,43625,43616},
{43622,43638,43600,43636,43635,43636,43637,43600,43631,43629,43626,43600,43636,43632,43630,43623,43626,43600,43600,43600,43626,43600,43600,43621,43600,43600,43616,43600,43614,43613,43600,43617,43615,43614,43610,43609,43606,43600,0,0,43621,43622,43623,43600,43600,43620,43611,43600,43600,43624,43600,43622,43613},
{43617,43633,43600,43643,43630,43631,43632,43600,43642,43640,43637,43600,43631,43635,43637,43634,43635,43600,43600,43600,43621,43600,43600,43628,43600,43600,43627,43600,43625,43624,43600,43626,43626,43611,43615,43616,43619,43600,43600,0,43604,43603,43602,0,43600,43603,43612,43600,43600,43613,43600,43621,43618},
{43614,43630,43632,43600,43627,43628,43629,43636,43600,43600,43600,43623,43628,43600,43600,43637,43600,43633,43624,43630,43618,43621,43622,43600,43628,43629,43600,43629,43628,43600,43611,43600,43625,43608,43600,43613,43600,43617,43619,43622,0,0,43600,43603,43604,43606,43615,43608,43609,43610,43612,43600,43621},
{43615,43631,43633,43600,43628,43629,43630,43637,43600,43600,43600,43624,43629,43600,43600,43636,43600,43634,43625,43631,43619,43622,43623,43600,43629,43630,43600,43628,43627,43600,43612,43600,43626,43609,43600,43614,43600,43618,43620,43623,43600,0,0,43602,43603,43605,43614,43609,43610,43611,43613,43600,43620},
{43624,43640,43642,43600,43637,43638,43639,43644,43600,43600,43600,43633,43638,43600,43600,43633,43600,43635,43634,43632,43628,43631,43632,43600,43628,43627,43600,43625,43624,43600,43621,43600,43625,43618,43600,43623,43600,43627,43625,43622,43600,43600,0,43621,43622,43624,43615,43610,43609,43608,43606,0,43609},
{43618,43634,43600,43644,43631,43632,43633,43600,43641,43639,43636,43600,43632,43636,43638,43633,43636,43600,43600,43600,43622,43600,43600,43629,43600,43600,43626,43600,43624,43623,43600,43627,43625,43612,43616,43617,43620,43600,43600,43600,43605,43604,43603,0,0,43602,43611,43600,43600,43614,43600,43622,43617},
{43614,43630,43600,43640,43627,43628,43629,43600,43639,43641,43644,43600,43628,43632,43634,43641,43632,43600,43600,43600,43618,43600,43600,43625,43600,43600,43630,43600,43632,43633,43600,43623,43625,43608,43612,43613,43616,43600,43600,43600,43607,43608,43609,43600,0,43614,43623,0,43600,43602,43600,43610,43619},
{43629,43600,43643,43635,43600,43600,43600,43633,43630,43628,43625,43638,43600,43631,43629,43600,43625,43624,43627,43621,43600,43624,43623,43620,43617,43616,43615,43614,43600,43612,43626,43616,43600,43600,43621,43600,43617,43616,43614,43611,43616,43615,43614,43612,43611,0,0,43623,43624,43600,43621,43615,43600},
{43616,43600,43634,43642,43600,43600,43600,43638,43641,43643,43644,43625,43600,43634,43636,43600,43634,43635,43626,43632,43600,43623,43624,43627,43630,43631,43632,43633,43600,43631,43613,43625,43600,43600,43614,43600,43618,43619,43621,43624,43609,43610,43611,43613,43614,43600,0,43602,43601,0,43602,43608,43600},
{43615,43631,43600,43641,43628,43629,43630,43600,43640,43642,43645,43600,43629,43633,43635,43642,43633,43600,43600,43600,43619,43600,43600,43626,43600,43600,43631,43600,43633,43632,43600,43624,43626,43609,43613,43614,43617,43600,43600,43600,43608,43609,43610,43600,43600,43615,43624,0,0,43601,43600,43609,43618},
{43618,43634,43600,43644,43631,43632,43633,43600,43643,43645,43642,43600,43632,43636,43638,43639,43636,43600,43600,43600,43622,43600,43600,43629,43600,43600,43632,43600,43630,43629,43600,43627,43629,43612,43616,43617,43620,43600,43600,43600,43611,43612,43613,43600,43600,43618,43621,43600,0,43602,0,43606,43615},
{43633,43600,43645,43637,43600,43600,43600,43635,43632,43630,43627,43642,43600,43633,43631,43600,43627,43626,43629,43623,43600,43626,43625,43622,43619,43618,43617,43616,43600,43614,43630,43618,43600,43600,43623,43600,43619,43618,43616,43613,43622,43621,43620,43618,43617,43600,43600,43619,43618,0,43615,43609,0},
{43620,43602,0,43608,43609,43610,43611,43600,43621,43623,43622,43600,43616,43620,43622,43625,43626,43600,43600,43600,43624,43600,43600,43631,43600,43600,43636,43600,43634,43633,43600,43635,43637,43626,43630,43631,43634,43600,43600,43600,43631,43632,43633,43600,43600,43638,43643,43600,43600,43634,0,43642,43645},
{43628,43610,43608,0,43617,43618,43619,43622,43600,43600,43600,43619,43624,43600,43600,43617,43600,43625,43632,43628,43632,43635,43636,43600,43630,43629,43600,43627,43626,43600,43631,43600,43633,43634,43600,43639,43600,43641,43639,43636,43600,43600,43600,43643,43644,43644,43635,43640,43641,43642,43644,0,43637},
{43618,0,43602,43610,43600,43600,43600,43616,43619,43621,43624,43609,43600,43618,43620,43600,43624,43625,43622,43628,43600,43625,43626,43629,43632,43633,43634,43635,43600,43635,43621,43633,43600,43600,43628,43600,43632,43633,43635,43638,43629,43630,43631,43633,43634,43600,43600,43630,43631,43600,43634,43640,0} }
Gurobi comes up with a solution of 174428 with a node sequence of:
[0,30,37,38,39,43,44,47,48,50,2,7,11,17,18,19,21,22,24,25,27,34,36,40,41,42,51,3,8,9,10,13,14,16,23,26,29,31,35,45,46,49,52,1,4,5,6,12,15,20,28,32,33]
However, there is a better tour with length 174426 following this path:
[0,23,26,29,31,34,36,40,41,42,51,3,8,9,10,13,14,16,21,22,24,25,27,30,37,38,39,43,44,47,48,50,2,7,11,17,18,19,20,28,32,33,35,45,46,49,52,1,4,5,6,12,15]
While solving, Gurobi prints the following output:
Gurobi Optimizer version 9.1.2 build v9.1.2rc0 (win64)
Thread count: 4 physical cores, 8 logical processors, using up to 8 threads
Optimize a model with 2758 rows, 2808 columns and 13468 nonzeros
Model fingerprint: 0x1f287d8a
Variable types: 0 continuous, 2808 integer (2756 binary)
Coefficient statistics:
Matrix range [1e+00, 5e+01]
Objective range [4e+04, 4e+04]
Bounds range [1e+00, 5e+01]
RHS range [1e+00, 5e+01]
Presolve time: 0.02s
Presolved: 2758 rows, 2808 columns, 13468 nonzeros
Variable types: 0 continuous, 2808 integer (2756 binary)
Found heuristic solution: objective 2268296.0000
Root relaxation: objective 8.721515e+04, 119 iterations, 0.00 seconds
Nodes | Current Node | Objective Bounds | Work
Expl Unexpl | Obj Depth IntInf | Incumbent BestBd Gap | It/Node Time
0 0 87215.1538 0 9 2268296.00 87215.1538 96.2% - 0s
H 0 0 392507.00000 87215.1538 77.8% - 0s
0 0 147580.462 0 61 392507.000 147580.462 62.4% - 0s
H 0 0 174494.00000 147580.462 15.4% - 0s
0 0 147580.462 0 62 174494.000 147580.462 15.4% - 0s
0 0 174410.000 0 63 174494.000 174410.000 0.05% - 0s
0 0 174410.000 0 59 174494.000 174410.000 0.05% - 0s
0 0 174410.000 0 34 174494.000 174410.000 0.05% - 0s
0 0 174410.000 0 48 174494.000 174410.000 0.05% - 0s
H 0 0 174446.00000 174410.000 0.02% - 0s
H 0 0 174438.00000 174410.000 0.02% - 0s
0 0 174410.000 0 8 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 9 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 46 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 42 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 71 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 58 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 8 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 34 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 19 174438.000 174410.000 0.02% - 0s
0 0 174410.000 0 33 174438.000 174410.000 0.02% - 1s
0 0 174410.000 0 19 174438.000 174410.000 0.02% - 1s
0 0 174410.000 0 12 174438.000 174410.000 0.02% - 1s
0 0 174411.222 0 48 174438.000 174411.222 0.02% - 1s
0 0 174412.000 0 79 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 68 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 30 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 9 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 42 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 81 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 97 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 82 174438.000 174412.000 0.01% - 1s
0 0 174412.000 0 86 174438.000 174412.000 0.01% - 1s
H 0 0 174434.00000 174412.000 0.01% - 1s
0 0 174412.000 0 10 174434.000 174412.000 0.01% - 1s
0 0 174412.000 0 10 174434.000 174412.000 0.01% - 1s
0 0 174412.000 0 9 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 70 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 61 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 40 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 40 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 40 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 40 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 25 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 8 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 35 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 40 174434.000 174412.000 0.01% - 2s
0 0 174412.000 0 8 174434.000 174412.000 0.01% - 2s
0 2 174412.000 0 8 174434.000 174412.000 0.01% - 2s
H 4 4 174428.00000 174412.150 0.01% 59.8 2s
Cutting planes:
Learned: 1
Gomory: 7
MIR: 6
Inf proof: 1
Zero half: 4
Relax-and-lift: 6
Explored 6 nodes (8776 simplex iterations) in 2.49 seconds
Thread count was 8 (of 8 available processors)
Solution count 7: 174428 174434 174438 ... 2.2683e+06
Optimal solution found (tolerance 1.00e-04)
Best objective 1.744280000000e+05, best bound 1.744121496876e+05, gap 0.0091%
Does anyone have any idea what causes this problem (too large numbers in the distance matrix, rounding errors, ...)? Any help is appreciated!
Best,
Constantin
-
Official comment
This post is more than three years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum, or try Gurobot, our chatbot interface offering instant, expert-level support. -
The last line of the output shows
Best objective 1.744280000000e+05, best bound 1.744121496876e+05, gap 0.0091%
The default MIPGap is 1e-4 and Gurobi stops if this gap is reached. You can set it to 0, then you should get the best solution.
0
Post is closed for comments.
Comments
2 comments