Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Alternative resources with all keyword

    Posted 06/08/12 12:27 PM

    Originally posted by: UMQX_Olfat_ELMahi


    Hello i am trying to use Alternative key word for:

    dvar interval aplAct1Pj in TAp1PktP;
    dvar interval aplAct1PRnoProcshttp://j in 0..nbTsk1P-1 optional;

    the tasks aplAct1P should do something like that:
    for all(r in 0..nbTsk1P-1)
    forall(j in TAp1PktP) (j mod nbTsk1P ==0) => alternative ( aplAct1P[j], aplAct1PRnoProcs[r])

    i understand i should use all key work but i can not figure out how ?

    can you help my with the correct syntax

    Thanks
    #DecisionOptimization
    #OPLusingCPOptimizer


  • 2.  Re: Alternative resources with all keyword

    Posted 06/08/12 12:34 PM

    Originally posted by: UMQX_Olfat_ELMahi


    i used the syntax:

    it gives no error but i am afraid if it is not correct:
    also not sure how to enforce capacity constraints now ??

    forall(i in TAp1PktP)
    alternative(aplAct1P[i], all(p in noProcs, j in 0..nbTsk1P-1: j == i mod nbTsk1P ) aplAct1PR[p][j]);
    #DecisionOptimization
    #OPLusingCPOptimizer


  • 3.  Re: Alternative resources with all keyword

    Posted 06/21/12 12:31 PM

    Originally posted by: SystemAdmin


    Hello,
    I'm not sure to understand what you want to model. Do you want to state that there are noProcs ways to execute a task aplAct1P[i] and that each of these different ways is modeled by an optional interval variable? In this case, what about:

    
    dvar interval aplAct1P [i in TAp1PktP]; dvar interval aplAct1PR[i in TAp1PktP][p in noProcs] optional;   constraints 
    { forall(i in TAp1PktP) 
    { alternative(aplAct1P[i], all(p in noProcs) aplAct1PR[i][p]); 
    } 
    }
    


    If you have capacity constraints on these optional interval variables, you can use noOverlap constraints or constraints on cumulFunctions.

    Philippe

    PS: To improve readability of the models posted on this forum, you can use "{code}" markups before and after your code.
    #DecisionOptimization
    #OPLusingCPOptimizer