Decision Optimization

Decision Optimization

Delivers prescriptive analytics capabilities and decision intelligence to improve decision-making.


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  How to clear expr faster

    Posted 11/14/17 05:33 AM

    Originally posted by: Emmaqwy


     IloRange[] rows;

    rows = lp.getRanges();

    rows[row].clearExpr();

    I want to clear some rows's expression , I called IloRange.clearExpr() , but it is not efficient.

    Anyone knows a faster function to clear constraint expression?


    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: How to clear expr faster

    Posted 11/14/17 08:46 PM

    Originally posted by: Emmaqwy


    I also try to use IloLPMatrix::removeRows, call one time , and remove about 11496 rows, but it cost about  5 min. Still need to find a faster way... 


    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: How to clear expr faster

    Posted 11/15/17 02:22 AM

    Did you try removing the IloLPMatrix instance from the IloCplex instance before modifying it?

    What is the percentage of rows you keep? Maybe it is faster to just remove everything and then re-add the things you want to keep.

    Can you share an example code that illustrates this slow removal?


    #CPLEXOptimizers
    #DecisionOptimization