Decision Optimization

Decision Optimization

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

 View Only
Expand all | Collapse all

Mixed Integer Quadratic Programming with multiple quadratic constraints

  • 1.  Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Sun January 05, 2014 01:54 PM

    Originally posted by: Pan_Greece


    Hi,

    I have a Mixed Integer Quadratically Constrainted Quadratic problem.

    It is a large scale optimization problem where the number of the variables are more than 400 (some of them time-related) and the number of the quadratic constraints more than 70!

    I have read the relevant topics about the formulation of the Q, l and r matrixes of the constraints and I have created them successfully (there is no error about the correct size of them).

    When I run the matlab code using the CPLEX optimizer (miqcp), it simply does not come to a solution no matter how much time I let it run (more than 2 hours).

    The fact that I do not get any error nor any other warning comment, leads me to believe that there is no problem about the convexity or semi-definiteness.

    I think that maybe the problem comes from the big number of the variables and the quadratic constraints. But when I run the problem as QCP (considering the integer variables as continuous) there is a convergence within very few seconds.

    Can you think a possible reason for the so long time that it runs without converging to a solution?

    Is there something I can do to take an solution to the problem I face?

    Is there anybody who has faced a similar problem?

    Thanks in advance


    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Fri January 17, 2014 02:14 PM

    Could you please show us the log output of the solve? This may give us more clues about what your issue is.


    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Sat January 18, 2014 09:29 AM

    Originally posted by: Pan_Greece


    First of all, thanks for the reply.

    Since there is no convergence, the algorithm doesn't come to a unique solution and so there is no log output (I think). Is something I don't understand?

    Is there a way I can have the log output without having the algorithm finished? (actually I always stop it, quiting the matlab software....)

    Thanks again, I appreciate your attitude to help me.


    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Mon January 20, 2014 09:29 AM

    For CPLEX 12.6 you have to set the Display option (see here), for 12.5 and older you have to set Diagnostics option (see here).


    #CPLEXOptimizers
    #DecisionOptimization


  • 5.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Mon January 27, 2014 05:18 PM

    Originally posted by: Pan_Greece


    Thanks for the help

    Although I have searched enough, I do not find a way how to get the log file. I use Matlab (calling the function miqcp) and I do not know how to get this log file in order to send it to you.

    Setting options.Diagnostics = 'on' and options.MIPDisplay='on' (as you advised me), I see the progress of the solution on my pc monitor but I cannot get this information through a log file. Is something I can do for that?

    Pressing ctrl + c, the running code stops. The x matrix (matrix with the solution) that I get, is the optimal x matrix until that time Or is the last calculated solution and not the best until then??? I think the first is more reasonable to happen but I would like to verify it.

     


    #CPLEXOptimizers
    #DecisionOptimization


  • 6.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Wed January 29, 2014 08:59 AM

    Can't you just copy-and-paste the matlab output to a file? Or redirect that output to a file?

    If you were using the class API then you could redirect CPLEX output to anywhere using the DisplayFunc field (see here).

    You are right, the X vector returned after hitting Ctrl-C is the best solution found so far.


    #CPLEXOptimizers
    #DecisionOptimization


  • 7.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Wed January 29, 2014 03:56 PM

    Originally posted by: Pan_Greece


    Thanks again, very valuable your help.....I thought that there could be a way for Cplex for Matlab (toolbox) to get the log file like in class API.......

    Nevertherless, the matlab output (more than 400 the variables) is the following (aborting using ctrl+c):

     

    Tried aggregator 2 times.

    MIQCP Presolve eliminated 381 rows and 154 columns.

    MIQCP Presolve modified 83 coefficients.

    Aggregator did 1 substitutions.

    Reduced MIQCP has 643 rows, 621 columns, and 3228 nonzeros.

    Reduced MIQCP has 70 binaries, 70 generals, 0 SOSs, and 0 indicators.

    Reduced MIQCP has 60 quadratic constraints.

    Presolve time = 0.03 sec. (3.41 ticks)

    Probing fixed 0 vars, tightened 32 bounds.

    Probing time = 0.00 sec. (0.10 ticks)

    MIP emphasis: balance optimality and feasibility.

    MIP search method: dynamic search.

    Parallel mode: deterministic, using up to 2 threads.

    Root relaxation solution time = 0.02 sec. (1.38 ticks)

     

            Nodes                                         Cuts/

       Node  Left     Objective  IInf  Best Integer    Best Bound    ItCnt     Gap

          0     0     -265.3375     0                   -347.8054       65        

          0     0     -239.2412    50                     Cone: 1       70        

          0     0     -207.6498    50                     Cone: 2       79        

          0     0     -163.7882    53                     Cone: 3       93        

          0     0     -117.2275    50                     Cone: 4      179        

          0     0     -112.3035    41                     Cone: 5      279        

          0     0     -104.0683    45                     Cone: 6      374        

          0     0     -102.7783    48                     Cone: 7      437        

          0     0     -102.1384    46                     Cone: 8      506        

          0     0     -101.8343    45                     Cone: 9      558        

          0     0     -101.6126    47                    Cone: 10      597        

          0     0     -101.5691    48                    Cone: 11      627        

          0     0     -101.3715    49                    Cone: 12      749        

          0     0     -101.2319    47                    Cone: 13      801        

          0     0     -100.6209    48                    Cone: 14      880        

          0     0     -100.1679    43                    Cone: 15      911        

          0     0     -100.0414    43                    Cone: 16      950        

          0     0      -99.8858    45                    Cone: 17      994        

          0     0      -99.7384    46                    Cone: 18     1034        

          0     0      -99.6583    44                    Cone: 19     1071        

          0     0      -99.5322    42                    Cone: 20     1128        

          0     0      -99.4858    38                    Cone: 21     1176        

          0     0      -99.4576    43                    Cone: 22     1203        

          0     0      -99.4520    43                    Cone: 23     1231        

          0     0      -99.4420    42                    Cone: 24     1252        

          0     0      -99.4287    44                    Cone: 25     1284        

          0     0      -99.3937    45                    Cone: 26     1314        

          0     0      -99.3161    45                    Cone: 27     1350        

          0     0      -99.2095    46                    Cone: 28     1392        

          0     0      -99.1456    45                    Cone: 29     1448        

          0     0      -98.9503    45                    Cone: 30     1510        

          0     0      -98.8893    42                    Cone: 31     1555        

          0     0      -98.8568    43                    Cone: 32     1579        

          0     0      -98.8321    44                    Cone: 33     1608        

          0     0      -91.7964    64                    -91.7964     1633        

    *     0+    0                          -91.7341      -91.7964     1672    0.07%

    *     0+    0                          -91.7551      -91.7964     1706    0.04%

    *     0+    0                          -91.7577      -91.7964     1706    0.04%

    *     0+    0                          -91.7623      -91.7964     1726    0.04%

          0     2      -91.7964    64      -91.7623      -91.7958     1746    0.04%

    Elapsed time = 16.65 sec. (5038.30 ticks, tree = 0.01 MB, solutions = 4)

         20    22      -91.7884    57      -91.7623      -91.7958     2311    0.04%

         40    42      -91.7865    51      -91.7623      -91.7958     2940    0.04%

         60    62      -91.7820    47      -91.7623      -91.7958     3520    0.04%

         80    76      -91.7642    34      -91.7623      -91.7958     4023    0.04%

        100    84      -91.7631    25      -91.7623      -91.7958     4444    0.04%

        120    90      -91.7642    34      -91.7623      -91.7958     4865    0.04%

        140    94        cutoff            -91.7623      -91.7958     5296    0.04%

    *   151+   97                          -91.7641      -91.7958     5547    0.03%

        160   102        cutoff            -91.7641      -91.7958     5774    0.03%

        180    97      -91.7958    63      -91.7641      -91.7958     6236    0.03%

        200   117      -91.7837    50      -91.7641      -91.7958     6763    0.03%

    Elapsed time = 47.30 sec. (14613.58 ticks, tree = 0.02 MB, solutions = 5)

        220   137      -91.7779    45      -91.7641      -91.7958     7369    0.03%

        240   157      -91.7781    46      -91.7641      -91.7958     8049    0.03%

        260   177      -91.7658    25      -91.7641      -91.7958     8967    0.03%

        280   191        cutoff            -91.7641      -91.7958     9751    0.03%

        300   203        cutoff            -91.7641      -91.7958    10451    0.03%

        320   215      -91.7658    25      -91.7641      -91.7958    11112    0.03%

        340   231      -91.7658    25      -91.7641      -91.7958    11699    0.03%

        360   245        cutoff            -91.7641      -91.7958    12293    0.03%

        380   265      -91.7871    57      -91.7641      -91.7958    12889    0.03%

        400   285      -91.7646    39      -91.7641      -91.7958    13441    0.03%

    Elapsed time = 87.72 sec. (26875.08 ticks, tree = 0.06 MB, solutions = 5)

        420   297      -91.7793    46      -91.7641      -91.7958    13864    0.03%

     

    x =

             0

             0

             0

             0

    ……………..

    ……………...

    ……………..

             0

             0

             0

             0

             0

     

     

    fval =  -91.7644

    exitflag =     6

    output =

              cplexstatus: 113

        cplexstatusstring: 'aborted'

               iterations: 14176

                algorithm: 12

                     time: 93.3200

                  message: 'non-optimal Solution available'


    #CPLEXOptimizers
    #DecisionOptimization


  • 8.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Thu January 30, 2014 02:05 AM

    OK, your log output looks good.

    It is expected that a QCP (integrality constraints dropped) solves much faster than the corresponding MIQCP. These are just two completely different classes of problems. Solving a QCP does not require use of a branch and bound algorithm while solving an MIQCP does.

    One quick thing you could try is to play with parameter  CPX_PARAM_MIPEMPHASIS, in particular try values 3 and 4.


    #CPLEXOptimizers
    #DecisionOptimization


  • 9.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Sat February 08, 2014 11:41 AM

    Originally posted by: Pan_Greece


    Thanks for one more time for the help that you are giving me.

    So,

    • The log output looks good and
    • Running the MIQCP is slower than the QCP

    but,

    • when I run the problem as MIQP (without any quadratic constraints) the algorithm gives me the optimal solution within 1 sec (and finishes alone) and when I add only 1 quadratic constraint and I run the problem as MIQCP, the problem does not come to any solution and lasts for hours and hours and hours........Does this seem reasonable? Is possible the addition of only 1 quadratic constraint in the exactly same problem to make the problem so hard to be solved alone?

    You propose to me using the mipemphasis parameter so as to get as quickly as possible a solution close to the optimal and pressing ctrl+c to get this solution. Have I understood well your point?

    I ran the problem using mipemphasis=1,2,3 and 4 and for alla the case I take the same fval. This means something?


    #CPLEXOptimizers
    #DecisionOptimization


  • 10.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Mon February 10, 2014 05:28 AM

    Originally posted by: PierreBonami


    To reply to your question:

    when I run the problem as MIQP (without any quadratic constraints) the algorithm gives me the optimal solution within 1 sec (and finishes alone) and when I add only 1 quadratic constraint and I run the problem as MIQCP, the problem does not come to any solution and lasts for hours and hours and hours........Does this seem reasonable? Is possible the addition of only 1 quadratic constraint in the exactly same problem to make the problem so hard to be solved alone

    Yes this is absolutely possible (and even common I would say). The algorithms for MIQP and MIQCP are very different and there are many nice properties of MIQP that don't generalize even if you add only one quadratic constraint.

    Your output doesn't look so bad as after 15 second you are 0.03% away from optimality. Of course this is not optimality, and proving optimality might then take a very long time. But if you are ok to settle for slightly suboptimal solution you could increase a bit the optimality tolerance.

    Another option you could try is the miqcp strategy switch (that should be option mip.strategy.miqcpstrat in matlab). Changing it to value 1 might improve the performance (unfortunately the effect on performance is not very predictable, the default should be better in most cases but there are many exceptions that are not easy to characterize).

    Good luck!

    Pierre

     


    #CPLEXOptimizers
    #DecisionOptimization


  • 11.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Tue February 11, 2014 03:37 PM

    Originally posted by: Pan_Greece


    Thanks Pierre for the reply and the assistance,

    1. So, when I get gap=0.03%, this means that I am so close to the optimal solution? (I have read the definition of the gap on the log file but I do not fully understand how to evaluate this)

    2. If this is correct, then why the algorithm doesnt terminate since I have put options.simplex.tolerances.optimality=0.01!!! Actually the algorithm doesnt terminate even if I put options.simplex.tolerances.optimality=0.5 (50%)!!!

    3. Generally the parameters that you and Daniel advised me to put seem that do not affect the problem and even worse seem that do not work at all(i.e. options.mip.interval=20)

     

    See what I have put as parameters and the log output:

    options=cplexoptimset('cplex');

    options.Diagnostics ='on';

    options.diagnostics='on';

    options.mip.display=3;%2-default

    options.mip.interval=20;

    options.MaxTime=1000;

    options.emphasis.mip=4; %0-default,

    %options.emphasis.numerical=1; %0-default

    options.barrier.qcpconvergetol=0.01; %0.0000001-default

    options.barrier.convergetol=0.01; %0.00000001-default

    options.simplex.tolerances.optimality=0.001; %0.000001-default

    options.mip.tolerances.absmipgap=0.001; %0.000001-default

    options.mip.tolerances.mipgap=0.01; %0.0001-default

    options.mip.tolerances.objdifference=0.001; %0-default

    options.mip.strategy.search=0; %0-default, 1-traditional, 2-dynamic

    options.mip.strategy.miqcpstrat=1; %0-default, 1-QCP relaxation, 2-LP relaxation...

    options.mip.pool.relgap = 0.01;%

     

     

     

    Tried aggregator 2 times.

    MIQCP Presolve eliminated 381 rows and 154 columns.

    MIQCP Presolve modified 83 coefficients.

    Aggregator did 1 substitutions.

    Reduced MIQCP has 643 rows, 621 columns, and 3228 nonzeros.

    Reduced MIQCP has 70 binaries, 70 generals, 0 SOSs, and 0 indicators.

    Reduced MIQCP has 60 quadratic constraints.

    Presolve time = 0.02 sec. (3.41 ticks)

    Probing fixed 0 vars, tightened 32 bounds.

    Probing time = 0.00 sec. (0.10 ticks)

    MIP emphasis: balance optimality and feasibility.

    MIP search method: dynamic search.

    Parallel mode: deterministic, using up to 2 threads.

    Root relaxation solution time = 0.01 sec. (1.38 ticks)

     

            Nodes                                         Cuts/

       Node  Left     Objective  IInf  Best Integer    Best Bound    ItCnt     Gap

          0     0     -265.3375     0                   -347.8054       65        

          0     0     -239.2412    50                     Cone: 1       70        

          0     0     -207.6498    50                     Cone: 2       79        

          0     0     -163.7882    53                     Cone: 3       93        

          0     0     -117.2275    50                     Cone: 4      179        

          0     0     -112.3035    41                     Cone: 5      279        

          0     0     -104.0683    45                     Cone: 6      374        

          0     0     -102.7783    48                     Cone: 7      437        

          0     0     -102.1384    46                     Cone: 8      506        

          0     0     -101.8343    45                     Cone: 9      558        

          0     0     -101.6126    47                    Cone: 10      597         

          0     0     -101.5691    48                    Cone: 11      627        

          0     0     -101.3715    49                    Cone: 12      749        

          0     0     -101.2319    47                    Cone: 13      801        

          0     0     -100.6209    48                    Cone: 14      880        

          0     0     -100.1679    43                    Cone: 15      911        

          0     0     -100.0414    43                    Cone: 16      950        

          0     0      -99.8858    45                    Cone: 17      994        

          0     0      -99.7384    46                    Cone: 18     1034        

          0     0      -99.6583    44                    Cone: 19     1071        

          0     0      -99.5322    42                    Cone: 20     1128        

          0     0      -99.4858    38                    Cone: 21     1176        

          0     0      -99.4576    43                    Cone: 22     1203        

          0     0      -99.4520    43                    Cone: 23     1231        

          0     0      -99.4420    42                    Cone: 24     1252        

          0     0      -99.4287    44                    Cone: 25     1284        

          0     0      -99.3937    45                    Cone: 26     1314        

          0     0      -99.3161    45                    Cone: 27     1350        

          0     0      -99.2095    46                    Cone: 28     1392        

          0     0      -99.1456    45                    Cone: 29     1448        

          0     0      -98.9503    45                    Cone: 30     1510        

          0     0      -98.8893    42                    Cone: 31     1555        

          0     0      -98.8568    43                    Cone: 32     1579        

          0     0      -98.8321    44                    Cone: 33     1608        

          0     0      -91.7964    64                    -91.7964     1633        

    *     0+    0                          -91.7341      -91.7964     1672    0.07%

    *     0+    0                          -91.7551      -91.7964     1706    0.04%

    *     0+    0                          -91.7577      -91.7964     1706    0.04%

    *     0+    0                          -91.7623      -91.7964     1726    0.04%

          0     2      -91.7964    64      -91.7623      -91.7958     1746    0.04%

    Elapsed time = 18.21 sec. (5038.30 ticks, tree = 0.01 MB, solutions = 4)

          3     5      -91.7958    63      -91.7623      -91.7958     1819    0.04%

          4     6      -91.7868    61      -91.7623      -91.7958     1840    0.04%

          9    11      -91.7848    60      -91.7623      -91.7958     1960    0.04%

         13    15      -91.7931    58      -91.7623      -91.7958     2088    0.04%

         19    21      -91.7795    55      -91.7623      -91.7958     2276    0.04%

         24    26      -91.7878    56      -91.7623      -91.7958     2449    0.04%

         29    31      -91.7865    53      -91.7623      -91.7958     2617    0.04%

         36    38      -91.7865    52      -91.7623      -91.7958     2821    0.04%

         43    45      -91.7865    50      -91.7623      -91.7958     3016    0.04%

         53    55      -91.7820    47      -91.7623      -91.7958     3290    0.04%

    Elapsed time = 31.34 sec. (9085.29 ticks, tree = 0.01 MB, solutions = 4)

         79    75      -91.7732    40      -91.7623      -91.7958     4002    0.04%

        110    86      -91.7629    22      -91.7623      -91.7958     4655    0.04%

        137    95      -91.7952    62      -91.7623      -91.7958     5230    0.04%

    *   151+   97                          -91.7641      -91.7958     5547    0.03%

        167    92      -91.7881    56      -91.7641      -91.7958     5939    0.03%

        192   109      -91.7881    51      -91.7641      -91.7958     6532    0.03%

        212   129      -91.7781    46      -91.7641      -91.7958     7076    0.03%

        227   144      -91.7774    44      -91.7641      -91.7958     7611    0.03%

        244   161      -91.7759    42      -91.7641      -91.7958     8247    0.03%

        254   171      -91.7708    39      -91.7641      -91.7958     8721    0.03%

        269   186      -91.7708    39      -91.7641      -91.7958     9361    0.03%

    Elapsed time = 66.57 sec. (19262.29 ticks, tree = 0.03 MB, solutions = 5)

        276   189      -91.7708    39      -91.7641      -91.7958     9605    0.03%

        302   205      -91.7658    25      -91.7641      -91.7958    10508    0.03%

        324   217      -91.7658    25      -91.7641      -91.7958    11235    0.03%

        349   238      -91.7871    52      -91.7641      -91.7958    11945    0.03%

        371   256      -91.7832    50      -91.7641      -91.7958    12644    0.03%

     

    x =

             0

             0

             0

             0

             0

             0

             0

       -0.0004

       -0.1201

        0.2962

        0.2906

        ……………

        ………...

        1.0000

        1.0000

        1.0000

        1.0000

             0

             0

             0

             0

             0

             0

             0

             0

     

    fval =

      -91.7644

     

    exitflag =

         6

     

    output =

              cplexstatus: 113

        cplexstatusstring: 'aborted'

               iterations: 14227

                algorithm: 12

                     time: 99.4820

                  message: 'non-optimal Solution available'

     


    #CPLEXOptimizers
    #DecisionOptimization


  • 12.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Wed February 12, 2014 05:29 AM

    What version of CPLEX do you use? Setting both, 'Diagnostics' (upper case D) and 'diagnostics' (lower case d) may be a problem. Do things look better if you only set one of the two (try both)?


    #CPLEXOptimizers
    #DecisionOptimization


  • 13.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Wed February 12, 2014 12:27 PM

    Originally posted by: Pan_Greece


    Hi,

    I use CPLEX 12.5.

    So something strange is happening.........

    The diagnostics do not work at all when I use the following ( I do not see the output of the optimization procedure):

    options=cplexoptimset('cplex');
    %options.Diagnostics ='on';
    options.diagnostics='on';

     

    When I use the following (Diagnostics) the Diagnostics work but the parameters not

    options=cplexoptimset('cplex');
    options.Diagnostics ='on';
    %options.diagnostics='on';

     

    When I use the following, both Diagnostics and parameters seem to work

    options=cplexoptimset;
    %options=cplexoptimset('cplex');
    options.Diagnostics ='on';
    %options.diagnostics='on';

    But even in the last case, some parameters do not take the values that I have set

    i.e. I put options.emphasis.mip=4;

                   options.mip.strategy.search=1;

    and I take the following log file:

     

    Tried aggregator 2 times.

    MIQCP Presolve eliminated 381 rows and 154 columns.

    MIQCP Presolve modified 83 coefficients.

    Aggregator did 1 substitutions.

    Reduced MIQCP has 643 rows, 621 columns, and 3228 nonzeros.

    Reduced MIQCP has 70 binaries, 70 generals, 0 SOSs, and 0 indicators.

    Reduced MIQCP has 60 quadratic constraints.

    Presolve time = 0.03 sec. (3.41 ticks)

    Probing fixed 0 vars, tightened 32 bounds.

    Probing time = -0.00 sec. (0.10 ticks)

    MIP emphasis: balance optimality and feasibility. ("I have put 4!")

    MIP search method: dynamic search. ("I have put 1 traditional")

    Parallel mode: deterministic, using up to 2 threads.

    Root relaxation solution time = -0.00 sec. (1.38 ticks)

     

            Nodes                                         Cuts/

       Node  Left     Objective  IInf  Best Integer    Best Bound    ItCnt     Gap

          0     0     -265.3375     0                   -347.8054       65        

          0     0     -239.2412    50                     Cone: 1       70        

          0     0     -207.6498    50                     Cone: 2       79        

          0     0     -163.7882    53                     Cone: 3       93        

          0     0     -117.2275    50                     Cone: 4      179        

          0     0     -112.3035    41                     Cone: 5      279        

          0     0     -104.0683    45                     Cone: 6      374        

          0     0     -102.7783    48                     Cone: 7      437        

          0     0     -102.1384    46                     Cone: 8      506        

          0     0     -101.8343    45                     Cone: 9      558        

          0     0     -101.6126    47                    Cone: 10      597        

          0     0     -101.5691    48                    Cone: 11      627        

          0     0     -101.3715    49                    Cone: 12      749        

          0     0     -101.2319    47                    Cone: 13      801        

          0     0     -100.6209    48                    Cone: 14      880        

          0     0     -100.1679    43                    Cone: 15      911        

          0     0     -100.0414    43                    Cone: 16      950        

          0     0      -99.8858    45                    Cone: 17      994        

          0     0      -99.7384    46                    Cone: 18     1034        

          0     0      -99.6583    44                    Cone: 19     1071        

          0     0      -99.5322    42                    Cone: 20     1128        

          0     0      -99.4858    38                    Cone: 21     1176        

          0     0      -99.4576    43                    Cone: 22     1203        

          0     0      -99.4520    43                    Cone: 23     1231        

          0     0      -99.4420    42                    Cone: 24     1252        

          0     0      -99.4287    44                    Cone: 25     1284        

          0     0      -99.3937    45                    Cone: 26     1314        

          0     0      -99.3161    45                    Cone: 27     1350        

          0     0      -99.2095    46                    Cone: 28     1392        

          0     0      -99.1456    45                    Cone: 29     1448        

          0     0      -98.9503    45                    Cone: 30     1510        

          0     0      -98.8893    42                    Cone: 31     1555        

          0     0      -98.8568    43                    Cone: 32     1579        

          0     0      -98.8321    44                    Cone: 33     1608        

          0     0      -91.7964    64                    -91.7964     1633        

    *     0+    0                          -91.7341      -91.7964     1672    0.07%

    *     0+    0                          -91.7551      -91.7964     1706    0.04%

    *     0+    0                          -91.7577      -91.7964     1706    0.04%

    *     0+    0                          -91.7623      -91.7964     1726    0.04%

          0     2      -91.7964    64      -91.7623      -91.7958     1746    0.04%

    Elapsed time = 17.03 sec. (5038.30 ticks, tree = 0.01 MB, solutions = 4)

         20    22      -91.7884    57      -91.7623      -91.7958     2311    0.04%

         40    42      -91.7865    51      -91.7623      -91.7958     2940    0.04%

         60    62      -91.7820    47      -91.7623      -91.7958     3520    0.04%

         80    76      -91.7642    34      -91.7623      -91.7958     4023    0.04%

        100    84      -91.7631    25      -91.7623      -91.7958     4444    0.04%

        120    90      -91.7642    34      -91.7623      -91.7958     4865    0.04%

        140    94        cutoff            -91.7623      -91.7958     5296    0.04%

    *   151+   97                          -91.7641      -91.7958     5547    0.03%

        160   102        cutoff            -91.7641      -91.7958     5774    0.03%

     

    x =

             0

             0

     ……………

             0

             0

     

    fval =  -91.7641

    exitflag =     6

    output =

              cplexstatus: 113

        cplexstatusstring: 'aborted'

               iterations: 6311

                algorithm: 12

                     time: 46.0510

                  message: 'non-optimal Solution available'

     

    My Matlab version is 7.9.

    And again even if I have options.simplex.tolerances.optimality=0.5 the algorithm does not terminate......

     

    May I send you my Matlab code? I think that the problems do not end..........

     

     


    #CPLEXOptimizers
    #DecisionOptimization


  • 14.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Thu February 13, 2014 02:37 AM

    I think the problem is that you are mixing Toolbox and CPLEX options. Can you please try this:

       opts = cplexoptimset('cplex');
       opts.diagnostics = 'on';
       opts.mip.strategy.search = 1;

    Does this work any better? Since you are using CPLEX options, avoid using Toolbox options such as MaxNodes, MaxTimes, ... (with "Toolbox options" I mean the options listed as "Options corresponding to the MATLAB Optimization Toolbox"  here). Instead use the equivalent CPLEX options.


    #CPLEXOptimizers
    #DecisionOptimization


  • 15.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Thu February 13, 2014 02:38 AM

    I think the problem is that you are mixing Toolbox and CPLEX options. Can you please try this:

       opts = cplexoptimset('cplex');
       opts.diagnostics = 'on';
       opts.mip.strategy.search = 1;

    Does this work any better? Since you are using CPLEX options, avoid using Toolbox options such as MaxNodes, MaxTimes, ... (with "Toolbox options" I mean the options listed as "Options corresponding to the MATLAB Optimization Toolbox"  here). Instead use the equivalent CPLEX options.


    #CPLEXOptimizers
    #DecisionOptimization


  • 16.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Sun February 16, 2014 04:55 PM

    Originally posted by: Pan_Greece


    Thanks a lot for everything,

    that exactly was the problem (confusion between cplex and Matlab toolbox parameters).....now everything has been solved with the parameters.......

     

    something last I would like to ask......when I get gap=0.03% on the log file, this means that I am so close (0.03%) to the optimal solution? (I have read the definition of the gap on the log file but I do not fully understand how to evaluate this)

     

    Thanks again


    #CPLEXOptimizers
    #DecisionOptimization


  • 17.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Tue February 18, 2014 12:39 AM

    gap=0.03% means that the best feasible solution CPLEX currently has (the "incumbent") is at most 0.03% away from the optimal solution. This does not mean that there actually is a solution that is 0.03% better. It only means that if there are better solutions than the incumbent then they are at most 0.03% better. It can well be that the incumbent already is the optimal solution but CPLEX just has not proved that yet.

    So yes, in a sense this means that you are very close to the optimal solution.


    #CPLEXOptimizers
    #DecisionOptimization


  • 18.  Re: Mixed Integer Quadratic Programming with multiple quadratic constraints

    Posted Fri February 21, 2014 01:44 PM

    Originally posted by: Pan_Greece


    Thanks again for the help and the quick replies, you really helped me very much


    #CPLEXOptimizers
    #DecisionOptimization