Re: Problem in set configuration

Hello,

Following the previous question, to form a set where: Set of pairs of tasks of the product of the line h between which there is no precedence relationship.

where  Th:

 tuple task{
    int h;     // Líne num
    int i;      // task i
    int tt;   //task time
    int taskP;   // Predecesor task
    int taskS;  // Sucesor task
    int refH;   // reference  Line
    int j;     // task j
}
{task} Task=…;

{task} Th = { | h in H, e in Task : e.refH == h };   //  Set of tasks assigned to the product of the  line h in H.

{int} cardTaskTot[H] = [{5},{2}];    

 conjuntoPredTot:   [  [{} {1} {1 2} {1 2} {1 2 3 4}]                                    [{} {1} {1} {1} {1}]  ]

. mod

 Task = {//Line Task Time Pred  Suce  h”   j”
                < 1     1      2      0      2      1     1>,
                < 1     2      1      1      3      1     2>,
                < 1     3      3      2      0      1     3>,
                < 1     4      2      3      5      1     4>,
                < 1     5      2      4      0      1     5>,
                < 2     1      2      0      0      2     1>,
                < 2     2      4      1      0      2     1>,
               };

Can I use i and j as follows?

{int} conjPH [h in H] = { e.i,r.j  | e in Th, r in Th : h == e.h  && e.i not in conjuntoPredTot[h][r.j] && r.j not in conjuntoPredTot[h][e.i] && e.i <= r.j && e.i <= item(cardTaskTot[h],0) && r.j <= item(cardTaskTot[h],0) };

 

regards.

Source: Re: Problem in set configuration