Transformation From Hypergraph to

                Time-line

Proposed algorithm   :

กก

Basic rules; กก

1) Attachment link a--->b,c,d

    begin(b) <- begin(a);

      begin(c) <- begin(a);

      begin(d) <- begin(a);

      end(a) <- max{end(b),end(c),end(d)};

(2) Annotation link  a--->b,c,d;

    begin(b) <- begin(a)+delay;

    begin(c) <- begin(a)+delay;

    begin(d) <- begin(a)+delay;

    end(a) <- max{end(b),end(c),end(d)};

(3) synchronization links a-->b;

     Temp: befor (a,b,delay)=>   begin(b) <- end(a)+ delay;

     Temp: meet  (a,b)      => begin(b) <-> end(a);

     Temp: equals(a,b)      => begin(b) <-> begin(a) && end(b)<->end(a);

     Temp: overlap(a,b)  => begin(b) <-> begin(a)+delay;

                         end(a)<->begin(b)+delay;

                         end(b)<-> end(a)+delay;

     Temp: during(a,b,delay1,delay2)=> begin(a) <-> begin(b)+delay1 && end(b)<->end(a)+delay2;

     Temp: co-begin(a,b,delay) => begin(a)<->begin(b)

     Temp: co-end(a,b,delay)=>    end(a)<->end(b)

  

Algorithm:

    step1: from the root node initialize the begin() and end() of each node according

      to rule one  and two, ignoring synchronization links now.

    step2: Mark each synchronization link "0";

    step3:  

    3.1) select one "0" marked syncronization link a--->b , mark it "1" and 

      compute the  begin(a),end(a),begin(b),end(b) according to rule 1),2) and 3).

    3.2) Then, we need to propagate this change to all the members in the hypergraph. 

กก

    Add all synchronization links from a if begin(a) or end(a) has   been changed and

  the time value change will cause value change of the other node in the link(i.e. 

  It is in the right part of  " <-- ")  according to rules (3) to set S1;

  

  Add all synchronization links from b if begin(b) or end(b) has   been changed and

  the time value change will cause value change of the other node in the link(i.e. 

  It is in the right part of  " <-- ")  according to rules (3) to set S2;

   

            S0=S1+S2={link_1,link_2,...link_k};

            check each link in s, if it is marked as "0", delete it;

            S={link_i| link_i is in S0 and link_i is marked as "1"};

            

            according to rule 1) and 2), begin() and end() will not only be modified by 

      synchronization links,but also by attachment links and annotation links.

            

            So we also add attachment links and annotation links of a and(or) b(if its

   begin   and end value   has been changed and the time value changed is in the right

   part of the rules in (1) and (2)) to S;

       

       If S is empty, stop!

       else For each link a-->b in S,compute the time vlaue of b from a And 

      recursivly call 3.2). 

    3.3) repeat 3.1) and 3.2) until all synchronization links have been marked "1";  

กก