Petri net applet
The following applet is made by Volker
Guth. For people not familair with Petri
nets we refer to a short tutorial.
How to use the applet:
- Push the "Place" button and click on the design window to create
places.
- Push the "Transition" button and click on the design window to
create transitions.
- After creating the desired places and transitions push the "Arc"
button. After pushing his button, arcs can be drawn between places and
transitions.
- After completing the network, add tokens by pushing the "Token"
button. After pushing this button, tokens can be added by clicking on the
places. The first number above the place indicates the number of tokens
present.
- After adding the tokens, one can start the simulation by pushing the
"Simulation - Step" button. After pushing the button, the enabled
transitions are highlighted in red and the applet is in simulation mode.
- By clicking on an enabled transition in simulation mode, the transition
will fire. The specified number of tokens are consumed/produced. The enabled
transitions are again highlighted in red, etc.
Please note that:
- Places are labeled with two numbers, e.g., 5/100. The first number
(5) indicates the current number of tokens and the second number (100)
indicates the place capacity, i.e., the maximum number of tokens in the
place.
- The capacity of a place can be changed using the buttons "Pkap auf
1" (set place capacity to 1), "Pkap +" (increase
capacity),
and "Pkap -" (decrease capacity).
- To draw multiple arcs from a place to a transitions (or vice versa),
simply draw multiple lines after pushing the "Arc" button. The
cardinality (i.e., the number of arcs) is shown by the number on the arc.
- To move nodes, push the "Mousepointer" button and simply click
and drag the nodes one by one.
- Push the button "Simulation - Step - Back" to undo a transition
firing.
- To delete tokens from a place use "delete Token" or "deleteAlltoken".
- To delete nodes (places/transitions) use "delete Place,
Transition,
..".
- To delete the entire network use "ClearScreen".
For comments, questions and suggestions we refer to Volker
Guth of the department WIWI
of the J. W. Goethe-Universität.