Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  model.lp

    Posted 07/17/11 06:25 PM

    Originally posted by: banun


    Hi,

    in my "model.lp" file I get this weird line :

    id244: >= 0

    (like something is missing from the left of ">=", it seems)

    What is that ?
    Thanks
    #CPLEXOptimizers
    #DecisionOptimization


  • 2.  Re: model.lp

    Posted 07/17/11 07:47 PM

    Originally posted by: John Cui


    Yes, you are right, the coefficients of this constraint are zero.
    0x1 + 0x2 + 0x3 + ... + 0xn >= 0
    So you need to check the coefficients of this constraint in your program.

    John Cui
    #CPLEXOptimizers
    #DecisionOptimization


  • 3.  Re: model.lp

    Posted 07/18/11 01:04 AM

    Originally posted by: SystemAdmin


    You have created a constraint with an empty left-hand side. Like John said, this is the same as constraint with all-zero coefficients:
    0x + 0y + 0z >= 0
    

    If the right-hand side is 0 then the constraint will always be satisfied and CPLEX will eliminate this constraint during presolve.
    However, since the empty left-hand side seems to be unexpected you should check your program and figure out why you created a constraint with empty left-hand side.
    #CPLEXOptimizers
    #DecisionOptimization


  • 4.  Re: model.lp

    Posted 07/18/11 03:35 AM

    Originally posted by: banun


    Thanks for you answers,

    what about this :

    i240372: id434555#259226 = 1 <-> z(82,(516,522,0)p7)#12167
              - z(84,(50,565,0)p5)#12725  = 0
    


    ?

    It looks strange too..
    #CPLEXOptimizers
    #DecisionOptimization


  • 5.  Re: model.lp

    Posted 07/18/11 03:47 AM

    Originally posted by: banun


    or is the second line a continuation of the first ??
    #CPLEXOptimizers
    #DecisionOptimization


  • 6.  Re: model.lp

    Posted 07/18/11 04:04 AM

    Originally posted by: SystemAdmin


    This is an indicator constraint. The '<->' represents "if and only if". And yes, the second line is a continuation of the first one.
    #CPLEXOptimizers
    #DecisionOptimization


  • 7.  Re: model.lp

    Posted 07/18/11 08:16 AM

    Originally posted by: banun


    another question :

    I have :
    IloIntVar va = getVar(v);
            IloIntVar var1 = getVar(first_var);
            model.add(va != var1);
    


    but in my model.lp file I don't see " != " constraint at all.
    Is it possible this constraint is converted to something like that :
    id1581088: id1581094#170096  = 0
           i151242: id1581094#170096 = 1 <-> z(64,(877,663,0)p13)#8100 - z(37,(839,667,0)p13)#4002  = 0
            0 <= id1581094#170096 <= 1
    

    (id1581094#170096 is under "Binaries")

    ?

    thanks
    #CPLEXOptimizers
    #DecisionOptimization


  • 8.  Re: model.lp

    Posted 07/18/11 02:09 PM

    Originally posted by: SystemAdmin


    Yes, that would make perfect sense. CPLEX (and integer linear programming) does not directly support "not equal" constraints. Hence such constraints must be reformulated as something that CPLEX supports. And what you have given is a reformulation of "not equal" using indicator constraints.
    #CPLEXOptimizers
    #DecisionOptimization