II.1.3. Transitions
A transition is graphically represented in the Drawing Area by a square. To draw a transition in the Drawing Area, the user must press the Add Transition button from the Drawing Panel or select the Add Transition command from the Modeling menu. Then, the user must click only once into the desired grid cell of the Drawing Area. A second click in the same grid cell has no effect.
Once the square corresponding to a transition is drawn, a label is automatically attached to it. The default position of the label is below the square.
Fig. II.4. The uicontext menu of a transition.
The same as for a place, after drawing a transition, there are two ways to change its position in the Drawing Area while in Draw Mode and no button from the Drawing Panel is pressed. The first way is to left-click the desired transition and then drag it in the new position. The second way is to right-click the transition; as a result, a MATLAB uicontext menu (fig. II.4) appears and the command Move Transition becomes available. In both cases, the label is moved together with the transition.
For a selected transition, the uicontext menu also allows: (i) controlling the label’s visibility on the screen (View Label command), (ii) changing the position of the label (Move Label command), (iii) deleting the transition (Delete command) and (iv) opening the Edit Transition dialogue box (fig. II.5) that lets the user modify the properties of the transition as a MATLAB object (Properties command).
Fig. II.5. The Edit Transition dialogue box for modifying the properties of a transition.
The Edit Transition dialogue box can be also opened by one of the procedures (ET1) or (ET2) described below, followed by a click on the desired transition. (ET1) consists in selecting the Edit Objects command from the Modeling menu; (ET2) consists in pressing the Edit Objects button from the Drawing Panel.
Each transition is uniquely identified with an id that is automatically assigned by the PN Toolbox and cannot be changed by the user. This id appears in the title bar of the Edit Transition dialogue box.
The option Label displays the string that is used as the label of the transition. By default, this string coincides with the id of the transition. The user can modify this string (without affecting the id) if necessary.
The Message text-box contains the string that is displayed in the Message Box during the simulation of the model when firing that transition if option Displayed is checked for Transition-Firing Message in the Preferences dialogue box. By default, this string is “Firing transition x” where x is the id of that transition. The user can modify this string if necessary.
The option Color displays the color used for drawing the transition. By default, this color is black, but the user can select another one from a list of eight predefined colors. Using different colors for the transitions of a net might be helpful for complex topologies (e.g. for highlighting different phases requested by a multi-step design procedure).
In case of transition-timed PN models (see section T-timed Petri nets), the Distribution option associated with a transition allows the user to specify the probability distribution and the necessary parameter(s) which define the corresponding time-duration. This option is not available for untimed or place-timed models.
For Stochastic PN models, only exponentially distributed firing rates can be assigned to the transitions in the net. In the case of Generalized Stochastic PN models, only constant and exponentially distributed firing rates can be assigned to the transitions in the net; obviously, an instantaneously fireable transition can be modeled by setting the constant distribution to 0. For these two types of models, the user has the possibility to enable or disable the dependence between the firing rate of a transition and the marking of its input places by checking the Marking dependent option.
The Delete object button placed at the bottom of the Edit Place dialogue box lets the user delete the transition from the model.