Originally posted by: SystemAdmin
[Sylvain said:]
I found the origin of my problem.
There seem to be a bug in the implementation of precedence graphs for continuous reservoirs.
Consider the following simple program :
IloModel model(env);
IloContinuousReservoir res(env, 100);
res.setInitialLevel(50);
IloActivity act1(env, 1);
IloActivity act2(env, 1);
model.add(act1.startsAt(0));
model.add(act2.startsAt(0));
model.add(act1.consumes(res, 200));
model.add(act2.produces(res, 200));
IloSolver solver(model);
IlcScheduler scheduler(solver);
res.setPrecedenceEnforcement(IloBasic);
if(solver.solve(IloGoalTrue(env)))
cout << "Feasible" << endl;<br /> else
cout << "Infeasible" << endl;<br />
res.setPrecedenceEnforcement(IloMediumHigh);
if(solver.solve(IloGoalTrue(env)))
cout << "Feasible" << endl;<br /> else
cout << "Infeasible" << endl;<br />
The results is :
Feasible
Infeasible
With a precedence enforcement greater than IloMediumHigh, the precedence graph constraint is posted and makes the solver fail with no reason.
This should be corrected in future releases...
#ConstraintProgramming-General#DecisionOptimization