Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  binary variables with negative values in optimal solution

    Posted 02/13/18 01:08 AM

    Originally posted by: chebz


    Dear all, 

    a have a mixed integer programming model as lp file trying to solve it in Cplex,

    Cplex gave me the optimal solution however some of the binary decision variables are either 0 or negative -0 in the solution , is this normal? or there is something wrong in the model. 

    I am attaching the solution file. 

    Thank you 


    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: binary variables with negative values in optimal solution

    Posted 02/13/18 02:29 AM

    This is normal, completely expected and has been discussed many times on this forum.

    First of all, 0 and -0 are identical in IEEE, so these are effectively the same values.

    Furthermore, CPLEX may return tiny negative numbers instead of 0. This is due to numerical roundoff and cannot be completely avoided as long as you use a solver that uses floating point arithmetic. You can try setting CPX_PARAM_EPINT to 0, that makes it a lot less likely for these roundoff problems to happen for integer variables.


    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: binary variables with negative values in optimal solution

    Posted 02/14/18 12:10 AM

    Originally posted by: chebz


    Thank you very much Daniel that was so helpful 


    #CPLEXOptimizers
    #DecisionOptimization