Originally posted by: zhd87
Hi, Paul!
Thank you very much for your kindly reply!
Yes, I agree with you on the second point after one day's re-thinking.
Would you mind to give an example with OPL on the third point you mentioned?
I want to adopt this, but sorry that as a beginner, I don't know how to do it with OPL languages in Cplex...
I mean, how to define the binary variable with OPL language and use it to accomplish the constraint that x[1,j] + x[2,j] <= 1 in Cplex.
I've defined my traffic demand matrix and arc information with{fromnode, tonode, supply} value as follows:
//define the arcs
tuple arc
{
key int fromnode;
key int tonode;
float NumWave;
}
{arc} Arcs = ...;
//define the dems
int Dem[nodes] = ...;
dvar float+ F[a in Arcs] in 1..a.NumWave;
dexpr float TotalFlow = sum (a in Arcs) F[a];
minimize TotalFlow;
but I don't know how to combine them together with binary variable...
Second, in my model, the same arc cannot be included in working and backup path of one request,
but it can be used by different request.
That is, for instance, arc 1 can not be included, at the same time, in working and backup path of request 1(or request 2),
but it can be included in working(or backup) path of request 1 and working(or backup) path of request 2.
Thank you!
#CPLEXOptimizers#DecisionOptimization