Design a Sub-Process

A process diagram may contain not only tasks but also sub-processes. A sub-process may also be presented as a reference to an activity. When you simulate performance of such process, you simulate performance of the sub-process as well. There are some rules that should be followed in order to avoid simulation errors.

Simulate Sub-Process Performance

When you run simulation of a process diagram that has a sub-process, the simulation engine jumps to the sub-process diagram, simulates its performance and goes back to the process diagram. In order the simulation engine does it correctly, the following rules should be followed:

  1. If the process and the sub-process diagrams are both Flowcharts, then make sure that the arrow that is the input of the sub-process in the process diagram, can be found in the sub-process diagram. The same works for the arrow that is the output of the sub-process in a process diagram. It should also be displayed in the sub-process diagram, and the simulation engine will look for it.
  2. If the process and the sub-process diagrams are designed in EPC, then the simulation engine will look for the same events on both diagrams. Note that the event shapes should belong to the same object, not to different objects with the same names.
  3. If the process and the sub-process diagrams are designed in BPMN, then the simulation engine starts performance of the sub-process diagram as soon as it enters it, without looking for anything. The number of started instances equals the number of start events in the sub-process diagram. The simulation engine goes back to the process diagram every time the end event occurs in the sub-process diagram, or every time the last task ends (in case the sub-process diagram has no end events).

Boundary Events

The simulation engine may exit the sub-process diagram in case some condition is met, even though sub-process instance is not completed yet. Boundary events are used to model such situations.

Example 1

Look at Figure 1 for an example. The "New comments added" and "Contract refused" events are connected to the "Agree contract" sub-process and are of the Intermediate boundary event (Interrupting) type. The sub-process diagram contains the same events as end events (Figure 2).

Figure 1. Diagram of a process with boundary events
Figure 2. The "Agree contract" process diagram

Example 2

The "Organize shipping of goods" process diagram (Figure 3) contains the "25 days passed" event shape that is connected to the "Wait for payment" sub-process shape. The event shape is of the Intermediate boundary event (Non-interrupting) type; thus, occurrence of the simulation event instance activates the "Notify Manager" simulation task instance. At the same time performance of the "Wait for payment" simulation sub-process instance will not be interrupted and the "Submit documents to the Debt department" simulation task instance will be performed.

Figure 3. Diagram of the "Organize shipping of goods" process
Figure 4. Diagram of the "Wait for payment" sub-process

Jumping from a Process Diagram to a Sub-Process Diagram if Diagrams Are in Different Notations

The process and the sub-process diagrams can be designed in different notations. The simulation engine performs the process and as soon as it meets the sub-process, it jumps to its diagram and starts its performance immediately. The number of instances that are created, equals the number of starting points on the sub-process diagram. For Flowcharts and EPC diagrams, the starting point is an event shape that has no incoming flows. For BPMN diagrams, the starting point is the event shape of the None trigger type or the task/gateway shapes that have no incoming sequence flows. The simulation engine goes back to the process diagram as soon as all the instances of the sub-process are completed.

Look at Figure 5 for an example. The process diagram is in the Flowchart notation (Figure 5), and the sub-process diagram is an EPC (Figure 6). As soon as the simulation engine enters "Step 2", it jumps to the sub-process diagram which is in EPC, and activates the "Event 2" and "Event 3" events immediately.

Figure 5. Process diagram
Figure 6. Sub-process diagram

Simulate Performance of a Reference to Reusable Activity

To learn about reusable activities go to the Reference to Activity article.

Example:

See Figure 7 for the "Draw up list of comments on project" process diagram. It contains the "Organize project results meeting" sub-process shape that is a reference to the reusable activity, whose diagram is presented in Figure 8.

Figure 7. The "Draw up list of comments on project" process diagram
Figure 8. The "Organize project results meeting" process diagram

The process and the reusable activity diagrams can be designed in the Flowchart/EPC notations or in BPMN. The simulation engine performs the process and as soon as it meets the sub-process, it jumps to the reusable activity diagram and starts its performance immediately. The number of instances that are created, equals the number of starting points in the reusable activity diagram. For Flowcharts and EPC diagrams, the starting point is an event shape that has no incoming flows. For BPMN diagrams, the starting point is the event shape of the None trigger type or the task/gateway shapes that have no incoming sequence flows. The simulation engine goes back to the process diagram as soon as all the instances of the reusable activity are completed.

Example

See Figure 9 for the process in the Cross-functional Flowchart notation. Its diagram contains a reference to the reusable activity (Step 1) whose diagram you see in Figure 10.


Figure 9. Process diagram
Figure 10. Reusable activity diagram


Exception

In case the process and the reusable activity diagrams are both designed in the EPC notation, the simulation engine’s behavior differs.

The simulation engine enters the reusable activity diagram, but starts creating its instances only in case it finds the shape of the event that activates performance of the reference to the reusable activity in the process diagram. This event should be the start event in the reusable activity diagram and only this event is activated. The reusable activity instance ends as soon as the end event is activated in its diagram. To make the simulation engine return to the process diagram you should add the event, whose shape is used as the end event in the reusable activity diagram, to the process diagram. And it should follow the shape of the Reference to the reusable activity. The simulation engine finds this event among those that follow the Reference to the reusable activity, and activates it.

See Figures 11 and 12 for an example. The process diagram contains the "Step 1" process. This process is a reference to the activity whose diagram you see in Figure 12. Note that the "Step 1" process has the "Event 1" event as an activating event and the "Event 2" event as an event that is created as a process result. These same events you see as start and end events in the reusable activity diagram (Figure 12).

Figure 11. Process diagram
Figure 12. Reusable activity diagram
« PreviousLevel upNext »
 
Driven by DokuWiki