Originally posted by: SystemAdmin
Hi All,
if would be great if any of you can help me writing the following constraint in JAVA concert.
// creating integer variable , shows how many times a route is selected
IloIntVar[] route_selected = RMPcplex.intVarArray(RRC.Route_Cost.size(), 0, 10);
// First constraint for checking the weight of the order delivered or not
IloLinearNumExpr order_weight = RMPcplex.linearNumExpr();
for(int i = 0; i < RO11.Order11.size(); i++ ){
order_weight.addTerm(RMPcplex.sum(
for(int j =0; j<RRO.Route_Order.size(); j++)
{
if(RO11.Order11.getcutomerid(i)= RRO.Route_Order.getcutomerid(j) && RO11.Order11.ot(i)= RRO.Route_Order.ot(j))
{
RMPcplex.prod(route_selected[RRO.Route_Order.getroute(j), weight[j]);
}
}
)
}
I am not getting how can i put this matching if condition in JAVA, which is very simple in OPL studio.
Please help me to reformulate.
Thanks
Arun Lila
#CPLEXOptimizers#DecisionOptimization