Originally posted by: SystemAdmin
Hi Thomas!
I changed the problem type from lp to MILP. However, it still returns the same error when program try to access "getDual".
I guess it is because of my coding problem. Could you please help me to check it?
int status = 1;
CPXCENVptr Cppenv = CPXopenCPLEX (&status);
CPXLPptr lp = CPXcreateprob (Cppenv, &status, "TOPOpt");
status = CPXchgprobtype (Cppenv, lp, 1);//CPXPROB_MILP
if(status)
break;
else
TOPSolver.solve();
TOPSolver.getStatus();
cout<<"Pro "<<argv[1]<<"is "<<TOPSolver.getObjValue()<<"--------"<<endl;
/// FIND AND ADD A NEW Route ///
for (i = 0; i <effcount-1; i++)
{
price[i] = TOPSolver.getDual(Fill[i]);
}
Sincerely,
Tracy
#CPLEXOptimizers#DecisionOptimization