Decision Optimization

Decision Optimization

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


#Analytics
#DecisionOptimization
#DecisionOptimization
 View Only
  • 1.  Time0 Machine Status

    Posted 07/28/15 09:54 PM

    Originally posted by: Kyle_Wang


    Hi Dear Friend

        here is a brief introduction of my problem.  i am scheduling products to run different machines. different product requires different machine configuration. for example Product A--> Machine configure A; Product B --> Machine configure B. Machine configure A to Machine configure B will trigger conversion cost.   each machine has their own start state of configuration (time0). do you some suggestion to me to handle this ?  


    #DecisionOptimization
    #OPLusingCPOptimizer


  • 2.  Re: Time0 Machine Status

    Posted 07/29/15 03:13 AM

    Originally posted by: PhilippeLaborie


    Hello,

    You should use the notion of "transition distance" to model sequence-dependent setup times on your machines.

    I suggest you have a look at distributed examples sched_setup and sched_sequence. In OPL a transition distance is modeled as a set of triplets <i,j,tij> where i and j are the (integer) types representing the configuration of two consecutive tasks and tij is the setup time. Integer types can be associated with each interval variable in a sequence at the construction of the sequence variable. Then this transition distance can be passed to a noOverlap constraint.

    If you want setup costs instead of setup times, you need to use expressions typeOfNext/Prev that return the type of the previous/next interval of a given interval variable in a sequence. See delivered example sched_tcost.

    Hope it helps,

    Philippe


    #DecisionOptimization
    #OPLusingCPOptimizer


  • 3.  Re: Time0 Machine Status

    Posted 07/29/15 09:30 PM

    Originally posted by: Kyle_Wang


    Hi Philippe

       thanks for your response. maybe i did not explain my question clearly.  let me explain in another way.  


    #DecisionOptimization


  • 4.  Re: Time0 Machine Status

    Posted 07/30/15 03:22 AM

    Originally posted by: PhilippeLaborie


    using CP;
    
    int ProdA = 0;
    int ProdB = 1;
    int ProdC = 2;
    int ProdD = 3;
    int ProdE = 4;
    
    tuple TTime { int prod1; int prod2; int delay; }
    {TTime} TT = { 
      <ProdA, ProdB, 2>,  <ProdA, ProdC, 7>,  <ProdA, ProdD, 9>,  <ProdA, ProdE, 1>,
      <ProdB, ProdA, 5>,  <ProdB, ProdC, 6>,  <ProdB, ProdD, 2>,  <ProdB, ProdE, 7>,
      <ProdE, ProdA, 12>, <ProdE, ProdB, 11>, <ProdE, ProdC, 15>, <ProdE, ProdD, 14>, <ProdE, ProdE, 10> };
    
    tuple Op { int product; int duration; }
    {Op} ops = { 
      <ProdE, 0>, // Initial operation
      <ProdA, 10>,  <ProdC, 21>,  <ProdE, 13>,  <ProdD, 25>,  <ProdD, 28>, 
      <ProdB, 24>,  <ProdA, 17>,  <ProdA, 12>,  <ProdC, 18> };
    
    dvar interval act[o in ops] size o.duration;
    
    dvar sequence machine 
       in    all(o in ops) act[o]
       types all(o in ops) o.product;
    
    minimize max(o in ops) endOf(act[o]);
    subject to {
      endOf(act[first(ops)])==0;
      noOverlap(machine, TT, true);
    }
    


    #DecisionOptimization