Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Options broken in MATLAB?

    Posted 01/20/14 02:18 AM

    Originally posted by: JohanLöfberg


    Trying to tweak the mip settings in MATLAB with cplex 12.6 (tried 12.5 too), and nothing seem to change. For instance, emphasis

    f     = [-1 -2 -3 -1]';
    Aineq = [-1  1  1 10; 1 -3  1  0];
    bineq = [20 30]';
    Aeq   = [0  1  0  -3.5];
    beq   =  0;
    lb    = [0;    0;   0; 2];
    ub    = [40; inf; inf; 3];
    ctype = 'CCCI';
    options = cplexoptimset('cplex');
    options.Display = 'on';
    options.emphasis.mip = 2;
    [x, fval, exitflag, output] = cplexmilp (f, Aineq, bineq, Aeq, beq,[ ], [ ], [ ], lb, ub, ctype, [ ], options);
    

    Running the code displays

    Presolve time = 0.00 sec. (0.00 ticks)
    MIP emphasis: balance optimality and feasibility.

    i.e,, the default mip emphasis of 0 is kept.


    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: Options broken in MATLAB?

    Posted 01/22/14 08:13 AM

    Originally posted by: JohanLöfberg


    Bumping the question to get a reply from product officials (as CPLEX seems to lack a more structured way to report bugs). Want to know Iif I am doing something wrong or if this is broken in CPLEX.


    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: Options broken in MATLAB?

    Posted 01/27/14 07:08 PM

    Originally posted by: Mark L. Stone


    Bumping on behalf of Johan, as I too would like to understand what's going on here.  Thanks.


    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: Options broken in MATLAB?

    Posted 01/29/14 05:00 AM

    Originally posted by: RWunderling


    Unfortunately, you hit a true bug in the handling of CPLEX parameters within the toolbox functions.  This issue is known and will be fixed for the next release. Sorry about the inconvenience.


    For the time being you can work around the issue by using parameter numbers.  Taking the mip emphasis parameter as an example, you can see from the documentation that the internal parameter number for this parameter is 2058.  You can set this using

    options.parameter2058 = 2;

    Alternatively, you can also use the CPLEX class for matlab, which provides better usability and supports model modifications with restarts.


    #CPLEXOptimizers
    #DecisionOptimization


  • 5.  Re: Options broken in MATLAB?

    Posted 01/29/14 05:14 AM

    Originally posted by: Mark L. Stone


    In light of the suggestion to use the CPLEX Class API, perhaps someone could answer the post  ' "Class API" much slower than cplexqp (and Matlab's quadprog)' https://www.ibm.com/developerworks/community/forums/html/topic?id=e379fbe3-2362-46f3-82ba-94c359303183&ps=25 .  Thanks.


    #CPLEXOptimizers
    #DecisionOptimization


  • 6.  Re: Options broken in MATLAB?

    Posted 03/22/14 03:04 PM

    Originally posted by: EdKlotz


    Here are some more details on this, from

    https://www.ibm.com/developerworks/community/forums/html/topic?id=7d401a80-4ee0-44a1-bb8e-65305ba81c7a#8aa8b62d-79ff-474b-bc2f-ee2628246896

     

     

    Here is a slightly more detailed explanation of the workaround, using the MIP gap parameter that is of interest for this particular thread.  The issue is that parameters that don't correspond to MATLAB toolbox parameters won't be properly communicated to CPLEX when using the Toolbox API.   To work around the issue, perform the following steps.

    1.  Looking up the numeric identifier of the parameter(s) of interest in the CPLEX documentation.   For the MIP gap parameter, this means the last line in the table below.

    relative MIP gap tolerance

    Sets a relative tolerance on the gap between the best integer objective and the objective of the best node remaining.

    Purpose

    Relative MIP gap tolerance

     

     

    2.   Use this number with your options structure as follows.  For a 5% MIP gap,

    options.parameter2009=.05;

     

    Then include the options structure in your cplexmilp() or other toolbox optimization function call.

     

    EdKlotz
    213 Posts

    Re: How to terminate the process using mip relative gap

    Yesterday 5:08 PM  in response to EdKlotz

    Let me just add one more bit of information to my previous post.   The problem involves only CPLEX 12.6; older versions don't have this.  

    We will do a fixpack that will address this, and we'll update the forum when it is available.

     


    #CPLEXOptimizers
    #DecisionOptimization


  • 7.  Re: Options broken in MATLAB?

    Posted 07/15/14 07:40 PM

    Originally posted by: Mark L. Stone


    That day has apparently arrived.

    Per https://delivery04.dhe.ibm.com/sar/CMA/WSA/04nlf/0/12.6.0-WS-COS-readme-fp001.html ,

    Issues addressed in the fix pack version 12.6.0.1

    ...

    RS01546  Version 12.6 of the MATLAB optimization toolbox ignores CPLEX parameter settings that lack a corresponding toolbox parameter.

    ....


    #CPLEXOptimizers
    #DecisionOptimization