Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
Expand all | Collapse all

How to implement the minimum function in a constraint?

  • 1.  How to implement the minimum function in a constraint?

    Posted 10/22/16 02:20 AM

    Originally posted by: CPlex_NooBie


    Hi, I am not able to understand the implementation of the above constraint properly. Here is code which I wrote:

     

    forall(s in 3..3,j in Mach[s]){

    //      const30:
            Cmax>=phimin[j]+(alpmin[j]-1)*gammin[j]+minl(sum(i in Ij[j])taufill[i]*betamin[i]);
        }

    Mach[s] is a set which has a value of Mach[s=3]={4 2 1 9};Similarly..

    I[j]--> is a set for each value of j gives a value of {1 2 3} or {4 2} depending on j.

    other identifiers are parameters.


    #DecisionOptimization
    #OPLusingCPLEXOptimizer


  • 2.  Re: How to implement the minimum function in a constraint?

    Posted 10/22/16 04:29 AM

    Originally posted by: CPlex_NooBie


    A similar constraint which goes like:

     

    And the code is as follows:

     

    forall(i in Itransfer,b in batch:b == minl((betTransmin[i]-1),betamin[i]),bb in batch:bb==betTransmin[i],ii in last(Ipred[i])..last(Ipred[i]),s in 2..2,j in J2[i]:card(Ipred[i])>0){
    //      const16:
              Y[i][b][s][j]==Y[ii][bb][s][j+1];
        }

     

    The error which I see is :

    1.Exception from IBM ILOG Concert:IloIntCollection getSubstitutionAsIntCollection.

    2. IloIntCollection getSubstitutionAsIntCollection.

     

    I can't go around this!Thanks

     

     


    #DecisionOptimization


  • 3.  Re: How to implement the minimum function in a constraint?

    Posted 10/22/16 09:04 AM

    Hi,

    can you post your .mod and .dat ?

    regards


    #DecisionOptimization
    #OPLusingCPLEXOptimizer