Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Both sides next revision
pn2mc:rtcpn_modelling [2014/11/20 21:57]
jbiernacki [Places]
pn2mc:rtcpn_modelling [2021/09/23 08:51] (current)
Line 2: Line 2:
  
 This chapter covers RTCP-nets modelling in CPN Tools environment.  This chapter covers RTCP-nets modelling in CPN Tools environment. 
-This approach to the modelling of RTCP-nets was originally introduced in master's thesis of Joanna Woźniak entitled "Modelowanie RTCP-sieci z wykorzystaniem środowiska CPN-Toolsin 2014. With her permission, excerpts of her work here will be used to explain the principles of RTCP-nets modelling in the CPN Tools application.+This approach to the modelling of RTCP-nets was originally introduced in master's thesis of Joanna Woźniak entitled 'Modelowanie RTCP-sieci z wykorzystaniem środowiska CPN-Toolsin 2014. With her permission, excerpts of her work here will be used to explain the principles of RTCP-nets modelling in the CPN Tools application.
  
 ---- ----
Line 79: Line 79:
   * The type of port.   * The type of port.
  
-Marking of an RTCP-net has adopted the following format: ''i(c)'', where //i// is an amount and //c// is the value (colour) of the token. +Marking of an RTCP-net has adopted the following format: ''i(c)'', where ''i'' is an amount and ''c'' is the value (colour) of the token. 
-Tokens are of different values are concatenated using the '//+//' operator. +Tokens are of different values are concatenated using the '' '+' '' operator. 
-eg. the expression 2 (a) + (b) denotes that 2 tokens of value //a// and one token of value //b//+eg. the expression ''2 (a) + (b)'' denotes that 2 tokens of value ''a'' and one token of value ''b''
 An example of a RTCP-net created in the CPN Tools is presented in the figure below. An example of a RTCP-net created in the CPN Tools is presented in the figure below.
  
 {{:pn2mc:rtcp_cpntools:rtcp_cpntools2.png?400|}} {{:pn2mc:rtcp_cpntools:rtcp_cpntools2.png?400|}}
  
-The net contains places: //A////B////C// and //D//. Places //A// and //B// do have an initial marking. Since the initial marking of places //C// and //D// is omitted, they both start with empty sets of tokens. Place //A// is of type //ab// and has two +The net contains places: ''A''''B''''C'' and ''D''. Places ''A'' and ''B'' do have an initial marking. Since the initial marking of places ''C'' and ''D'' is omitted, they both start with empty sets of tokens. Place ''A'' is of type ''ab'' and has two 
-tokens of value //a// while place B is of type //abc// and has four tags: //(a, a)////(b, b)////(a, b)// and +tokens of value ''a'' while place ''B'' is of type ''abc'' and has four tags: ''(a, a)''''(b, b)''''(a, b)'' and 
-//(b, a)//. Places do not have time stamp values - their default value is 0. +''(b, a)''. Places of this net do not have time stamp values explicitly assigned - their default value is 0.  
 + 
 + 
 +The value of the local clock is not supported by the CPN-Tools. Its value is placed on the model in the following notation:  
 + 
 +''(marking)@local_clock_value''
 + 
 +The figure below shows the net on which to ''A'' place time value (1) has been added. The initial marking of place ''A'' changes from ''2(a)'' to ''2(a)@1''
 + 
 +{{:pn2mc:rtcp_cpntools:rtcp_cpntools3.png?400|}} 
 + 
 + 
 +An example of a fusion is shown in the figure below. It's the fusion of places ''B'' and ''C''. They are of the same 
 +type and have equivalent initialization functions. 
 + 
 +{{:pn2mc:rtcp_cpntools:rtcp_cpntools4.png?400|}} 
 + 
 + 
 +In the next example  hierarchical net consisting of two pages is considered.  
 +The transition T is a substitution transition, and the page containing it is a superpage. 
 + 
 +{{:pn2mc:rtcp_cpntools:rtcp_cpntools5.png?400|}} 
 + 
 + 
 +In figure below is a subpage. 
 +  
 +{{:pn2mc:rtcp_cpntools:rtcp_cpntools6.png?400|}} 
 + 
 +Socket ''A'' of the superpage corresponds to the  port ''A'' of the subpage, and socket ''B'' 
 +corresponds to port ''B''. These two couples have the same types and the equivalent initial marking. 
 + 
 + 
 +==== Transitions ==== 
 + 
 +RTCP-net transitions are described by the following parameters: 
 + 
 +  * Name, 
 +  * Priority, 
 +  * Guard, 
 +  * An indication of the hierarchy. 
 + 
 +The RTCP-nets, in cotrast to the colored nets, time is not associated with transitions. In the model presented in the figure below, there are two transitions: ''T1'' and ''T2'' with priority values 2 and 1 respectively. Two guards were also defined: ''x = a'' for transitions ''T1'' and ''x = b'' for the transition ''T2''
 + 
 +{{:pn2mc:rtcp_cpntools:rtcp_cpntools7.png?400|}} 
 + 
 +==== Arcs ==== 
 + 
 +Arcs in the RTCP-nets may be unidirectional or bidirectional (equivalent of a pair of arcs). 
 +In the second case two expressions are assocaited with the arc: the input expression defining tokens added to the place and the output expression specifying tokens removed from it. These expressions can optionally contain time expressions. Therefore, to the arc can be assigned following parameters: 
 + 
 +  * Input expression, 
 +  * Output expression, 
 +  * Time input expression, 
 +  * Time output expression. 
 + 
 + 
 +CPN Tools allows users to associate only one expression. To assign to two expressions to one arc the following format of the label was invented: 
 + 
 +''in_exp @ time_in_exp | out_exp @ time_out_exp'' 
 + 
 +Parts ''time_in_exp'' and ''time_out_exp'' can be omitted. 
 + 
 +In the figure below the arc connected to place A has value ''b'' assigned. It means that ''b'' token is added to this place after firing of transition ''T''. Variable ''x'' represents the token removed from place ''A''. The output expression has time value assigned and equal to 2. It denotes that the transition can be fired after 2 time units. The arc connecting the transition with place ''B'' contains expressions determining a token added to place ''B'' (the value of ''x'' variable) and the value of the local clock of place ''B'' (it will be set to 1). 
 + 
 +{{:pn2mc:rtcp_cpntools:rtcp_cpntools8.png?400|}} 
 **[[:pn2mc:manual|Go back]]** **[[:pn2mc:manual|Go back]]**