Phase 3. Adding Tellers
Now we will create another part of the system by adding tellers that are working at the bank. Now some clients will come to see tellers, some – to access the ATM. We can model tellers using delays in the same way as we modeled ATM. However,
modeling tellers using resources is much more convenient.
Resource
is a special unit that can be possessed by an agent. Only one agent can possess a resource at a time; therefore agents compete for resources.
Modifying the flowchart
Simulate service
- Open the
Process Modeling Library
in the
Palette
view and drag the
Service
block onto our
Main
diagram.

Service
seizes resource units for the agent, delays the agent, and releases the seized units.
- Go to the
Properties
view of the
service
block.
- Modify the object properties:
- There is one queue for all tellers. Set up
Queue capacity
to be of 20 places.
- We assume that service time is triangularly distributed with the min value of 2.5, average value of 6, and the max value of 11 minutes. Set
Delay time:
triangular(2.5, 6, 11 )

Simulate decision making
- Move the objects
queue,
ATM
and
sink
to the right to make space for one new object between
source
and
queue.

- Open the
Process Modeling Library
in the
Palette
view and add the
SelectOutput
block in the resulting space. When you place the block on the connector, it will automatically get built in.

SelectOutput
is a decision making block. The agent arrived at the block is forwarded along one of two output ports depending on the user-defined condition.
- Select
selectOutput
in the flowchart and go to its
Properties
view. Choose the option
If condition is true
for the
Select True Output
parameter. Make sure that
Condition
is
randomTrue(0.5 ).
This agent routing condition defines that the number of customers competing for ATM and teller service will be approximately equal.
-
Connect
selectOutput
and
service
with other blocks as shown in the figure:

Add resources for the service
- Open the
Process Modeling Library
in the
Palette
view and drag the
ResourcePool
block onto our
Main
diagram.
ResourcePool
block is storage for resource units.
- Place it under
service
and go to its
Properties
view.
- Name the block
tellers.

- Specify that this resource object has only four resource units, that means, define its
Capacity: 4.

-
ResourcePool
block should be connected to resource seizing and releasing objects (Service
in our case). So we need to modify the properties of the
service
block.
- Select
service
in the flowchart to open its properties. Choose the option
units of the same pool
the parameter
Seize. Then specify the resource pool we have created in the option
Resource pool. You can either click the down arrow to select the resource pool object from the drop-down list, or you can click the button, located on the right, to select the object in the graphical editor (all inappropriate objects will be greyed out).

- Now since the model has changed, we need to alter the model animation as well.
Adding space markup shapes
Now we want to draw the area for queuing and a place to get serviced for our clients.
Set up space markup for the queue to tellers
- This time we will draw a waiting area using
a rectangular node. First, open the
Space Markup
palette in the
Palette
view.
- Double-click the element
Rectangular node
to switch to
the drawing mode.
- Click in the graphical editor and drag the rectangle without releasing the mouse button. Release when you have a rectangular node of the required form. You can edit its form later as you need.
- Name the node
waitingArea.
- Switch the
Visible
control to
no. This way the markup shape will be invisible during animation at model runtime.

- Click the
service
block in the flowchart and go to its
Properties
view.
- Select the node
waitingArea
we have drawn in the
Agent location (queue)
option.

Set up space markup for the customers
- The customers need a place to stand somewhere while they are getting serviced by tellers. We will draw an area for this purpose using
a rectangular node.
- First, open the
Space Markup
palette in the
Palette
view, then double-click the element
Rectangular node
to switch to
the drawing mode.
- Click in the graphical editor and drag the rectangle without releasing the mouse button. Release when you have a rectangular node of the required form. You can edit its form later as you need.
- Name the node
customerPlaces.
- Switch the
Visible
control to
no.

- We will use
attractors
to define the customers that are getting service. Select the node
customerPlaces
and click the button
Attractors...
in its properties. In the
Attractors
window that will pop-up, specify
4
for the creation mode
Number of attractors
and click
OK. You will see that attractors appeared in the
customerPlaces
node with the even offset.

- Now we need to refer to this area in the flowchart. Click the
service
block in the flowchart and go to its
Properties
view.
- Select the node
customerPlaces
you have drawn in the
Agent location (delay)
option.

Set up space markup for the tellers
- In the previous step, we used a point node to draw the ATM. Since we have 4 tellers this time, we will use
a rectangular node
to draw this service area.
- First, open the
Space Markup
palette in the
Palette
view, then double-click the element
Rectangular node
to switch to
the drawing mode.
- Click in the graphical editor and drag the rectangle without releasing the mouse button. Release when you have a rectangular node of the required form. You can edit its form later as you need.
- Name the node
tellerPlaces.
- Set the
Visible
property to
no.

- We will use
attractors
to define the tellers. Select
tellerPlaces
and click the button
Attractors...
in its properties. In the
Attractors
window that will pop-up, specify
4
for the creation mode
Number of attractors
and click
OK.
- You will see that attractors appeared in the
tellerPlaces
node with the even offset, but they are facing wrong direction. Select all attractors by Shift clicking and go to their properties. In the section
Position and size, change the
Orientation
parameter to
180.0.

- Click the
tellers
object in the flowchart and go to its
Properties
view.
- Select the node
tellerPlaces
we have drawn in the
Home location (nodes)
parameter by clicking
.

You can run the model now and observe how some customers are getting serviced at the ATM and some go to see tellers.
Adding 3D objects
It is time to add teller 3D objects to our model. We will create a new resource type to animate tellers.
Create a new resource type
- Open the
Process Modeling Library
palette.
- Drag the element
Resource Type
into the graphical editor.

- The
New agent
wizard will open on the
Creating new agent
step. Enter
Teller
as the
Agent type name
and leave the
Create the agent type "from scratch"
selected. Press
Next.

- In the next step select
3D
as the animation type and select
Office worker
from the list of the 3D figures.

- Click
Finish. The new
Teller
diagram will open. You can find the
Office worker
3D figure in the axis origin. Switch back to
Main
diagram.
Configure flowchart to use the new resource type
- On the
Main
diagram, select the block
tellers
in the graphical editor.
- In its properties, specify
Teller
as the
New resource unit.

- Run the model and observe customers and tellers.
Add tables for the tellers
- Open the
3D Objects
palette.
- Drag four
Table
3D figures from the
Office
section of this palette onto the node shape called
tellerPlaces
in the graphical editor.
- Place them at the attractors since attractors are the places where the tellers stand.

- You can see that their orientation is wrong. Select all tables by Shift-clicking and go to the
Properties
view.
- In the section
Position, change the parameter
Rotation
to
-90.0
degrees.
- If necessary, rearrange all eight attractors and four tables so that they are reasonably lined up.

Now you can run the model and observe in 3D how some customers go to the ATM and other get service at the tellers tables.

Phase
2, Creating model animation
Phase
4, Adding statistics collection