Tutorial 6 - Using Loops in Simulation
When simulating a Process you should avoid infinite loops by providing a Simulation Control strategy. If you create a loop without a Simulation Control, TIBCO Business Studio reports this as an error in the Problems view. This tutorial shows how to use a loop in Process simulation.
- Open the Submit Expenses Process from the Basic Samples Project. Look at the following portion of the Process:
- Click the Submit Revised Receipts Activity. In the Properties view, click the Simulation Control tab.
- Click the Simulation control link to add a simulation control strategy.
- There are three strategies from which you can select to break out of the loop:
- Max Loop Count - after the specified number of times through it.
- Max Elapse Time - after the specified amount of simulation time has elapsed.
- Normal Distribution - based on a normal distribution of times through the loop.
In this example, select Normal Distribution with a mean of 2 and standard deviation of 0.5.
- For Decision Activity select Is Paperwork Correct?. This informs TIBCO Business Studio which Activity will be used to decide whether to end the loop.
- For To Activity, select Enqueue Payment. This informs TIBCO Business Studio which Activity to proceed with once the loop is finished.
- Save the Package containing the Process.
- Highlight the Process, right-click and select .
- For 100 cases, the finished simulation for the Activities in the loop should look like this:
Copyright © Cloud Software Group, Inc. All rights reserved.