Page 1
1
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Project name: Simulation for Bank Teller System
Southern New Hampshire University
Subject: Computer Simulation/Modeling 13TW1
IT-630-G1703_13TW1: IT-630-G1703
Ahmed Al Salih [email protected]
Page 2
2
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Table of Contents Base Model ............................................................................................................................. 3
Background ............................................................................................................................. 3
Objective ................................................................................................................................. 3
Key Performance Measures .................................................................................................... 3
Key Decision Variables .......................................................................................................... 3
Problem statement. .................................................................................................................. 4
System and Simulation Specifications .................................................................................... 4
Conceptual Model/ Object Flow Diagram (OFD) ................................................................ 10
Simulation Implementation ................................................................................................... 13
Alternative model 1............................................................................................................... 15
Model Validation .................................................................................................................. 21
What-if questions .................................................................................................................. 23
Simulation Results ................................................................................................................ 24
Calculate Number of Model Replications............................................................................. 26
Output Analysis .................................................................................................................... 29
Alternative Model 2 ............................................................................................................ 132
The objects design: ............................................................................................................... 32
The logic design .................................................................................................................... 32
Object Flow Diagram (ODF) ................................................................................................ 34
Simulation Implementation ................................................................................................... 35
What-if questions .................................................................................................................. 38
Alternative Model 2 Validation ............................................................................................ 38
Output Analyses .................................................................................................................... 41
Summary report for Alternative model 2 .............................................................................. 42
Group Queue Results Comparison........................................................................................ 43
Statistic by individual object ................................................................................................. 44
Statistic by individual object Results Comparison ............................................................... 48
Cost Benefit Analysis ........................................................................................................... 48
Conclusions and Recommendations ..................................................................................... 50
Page 3
3
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Simulate the throughput of a bank teller system
Base Model
Background:
Bank Brach manager want to manage the salary for the tellers the work during the day.
The bank buildings have 4 windows for tellers and he wants us to balance the expense of paying for
teller personnel with customer satisfaction.
Simulation is being used to test concepts for setting up a new bank teller system in operation.
Objective
The objective of this modeling and analysis projects is to investigate how many tellers should be
active in a bank during the course of a typical business day; we want to balance the expense of
paying for teller personnel with customer satisfaction.
Key performance measure:
The time customer wait to be served by Teller
Server work load
Key decision variables:
Number of Teller should be active during the shift according to the collecting data that
descript the following distribution of customer arrival times.
Number of servers that serve The Teller’s Widow.
Page 4
4
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Problem statement:
The problem here for that project it’s for manage the number of teller they should be active
during a full business day as well the simulation should not affect the customer satisfactions that mean
the waiting time to long.
System and Simulation Specifications:
In this section describe the system simulation component and the logic parts to simulate the bank
case.
The objects design:
As we got told that the “iterance door” is in one side and the “exit door” in the other side.
1. We create a Source Fixed Resource that have name “Front Door” for generate the
customers as item flow into the bank.
2. And create a Sink Fixed Resource that have name “Exit” for exit door to the customer.
3. Queue to accumulate the flow items (customers) from the source and send the flow items
to the processors “Tellers” and I implement the Queue as a “Reception”
4. I have four Processors they implements the Teller windows, have names :
Teller 1, Teller 2, Teller 3 and Teller 4.
5. Create Queue for each server that collect the request from the teller to the server that
have name “ServerQueue1”, “ServerQueue2”, “ServerQueue3”and“ServerQueue4”
6. Processor the process the customer’s transaction, get the input from the “ServerQueue”,
after it done the process send the item flow (customer) to the sink (Exit door) that have
name “server1”, “server2”, “server3” and “server4”.
The Logic design:
1. We collect the data from the bank for the entry per hour and we got the info bellow
a. Peak AM: 09:00-10:00 - 0.33 customer/minute
b. 10:00 AM - 11:30 - 0.10 customer/minute
c. Peak lunch time: 11:30-1:30 – 0.25 customers/minute
d. 1:30 PM - 4:00 PM - 0.10 customer/minute
e. Peak closing time: 4:00-5:00 – 0.5 customers/minute
Page 5
5
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
So we create in our system a Global Table called “EntryRates”
That has the information about the people rate to enter to the bank during the day.
Bank business day start from 9:00AM to 5:00PM,
As we see the collected data for the entry it is not hourly so we divide the 8 Hour to 16 sections
of 30 mints to make the simulation more specific calculation and accurately as we see in the
picture bellow:
2. Source inter-arrival time : I used in the simulation :
exponential(0,getlabelnum(current,"PeopleCycle"),1)/**/;
Page 6
6
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Location = 0
Scale = getlabelnum(current,"PeopleCycle")
Stream = 1
Her I got the value to the Scale from Label name “PeopleCycle”.
“PeopleCycle” label his value get change from the Global Table “EntryRates” every 30 mint , and
that happen after we set a trigger.
3. Labels : I create two labels :
a. PeopleRate: That shows the people rate per minute such as 0.33 customers per
min.
b. PeopleCycle: That shows the time to release or create item flow (one customer
enter the Bank per amount of time),
4. Triggers
a. OnMessage /**set new rate*/
Page 7
7
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
treenode current = ownerobject(c);
int timeframe = 1+ msgparam(3);
if(timeframe < 17)
{
setlabelnum(current,"PeopleRate",gettablenum("EntryRates",timeframe,1));
setlabelnum(current,"PeopleCycle",30/(30 * gettablenum("EntryRates",timeframe,1)));
//setlabelnum(current,"PeopleCycle",1/ gettablenum("EntryRates",timeframe,1));
}
else {
setlabelnum(current,"PeopleCycle",0);
setlabelnum(current,"PeopleRate",0);
}
senddelayedmessage(current,30,current,0,0,timeframe);
This trigger responds to get the value from the global table and set the new value to the label.
By get the table using the method:
gettablenum(tablename,rownum,colnum)
gettablenum("EntryRates",timeframe,1))
The timeframe increase by one every time the trigger fire as long as less than 17 : the numbers of
rows from the EntryRates table.
To do the math such if we take the first col and row 1,1 = gave us 0.33 as given from the
collected data that mean it is the rate of people per mint , we set the label of people rate
setlabelnum(current,"PeopleRate",gettablenum("EntryRates",timeframe,1));
and the people cycle PeopleCycle that we do some math if we have the PeopleRate = 0.33
0.33 * 60 = 19.8 customer per 60 mints
But we work per 30 mints so it will be
0.33 * 30 = 9.9 customer per 30 mints
And
30 / 9.9 = 3.03 that mean 1 customer per 3.03 mints
So all that implement in this line
setlabelnum(current,"PeopleCycle",30/(30 * gettablenum("EntryRates",timeframe,1)));
and that trigger will fire every 30 min by using this method
Page 8
8
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
senddelayedmessage(current,30,current,0,0,timeframe);
The form for that code or method:
senddelayedmessage(toobject,delaytime,fromobject,parameter1,parameter2,parameter3)
This causes the message trigger of the object to fire after a certain delay time
b. OnReset
/**set intial people rate*/
treenode current = ownerobject(c);
setlabelnum(current,"PeopleRate",gettablenum("EntryRates",1,1));
setlabelnum(current,"PeopleCycle",30 * gettablenum("EntryRates",1,1)); // this is time between arrivals
senddelayedmessage(current,0,current,0,0,0);
If we push the reset bottom in the simulation program this trigger will fire and set the two labels
to the first value from the table.
The four Tellers they have process time = 0
Page 9
9
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
And I make the flow start with the source to one queue 4 Tellers 4 Queue
4 Server Sink.
Page 10
10
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Conceptual Model/ Object Flow Diagram (OFD)
Object flow diagram shows the basic structure and outline of a system in a schematic manner and how the
objects flow through the system.
Various Symbols used in the OFD
This symbol is used to represent the source to create the items in the flow.
This symbol is used to represent the fixed resource in the system.
This symbol is used to represent the process in the system.
This symbol is used to represent the decision rule in the system.
This symbol is used to represent the performance measure in the system.
This symbol is used to define downtimes.
Page 11
11
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
This symbol is used to show links between the objects that involves information and messages.
This symbol is used to represent the sink. It destroys the items that flow through the model.
The object flow diagram shown below provides a conceptual representation of the Base model.
Page 12
12
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Object Flow Diagram
Teller 4
Teller 1
Process time = 0
Teller 2
Teller 3
Reception
Wait Time
QueueServer 2
Wait Time Utilization
Process time = 0
Process time = 0
Process time = 0
Throughput
Utilization
Utilization
Utilization
Cust
omer
Custom
er
Customer
Customer
Customer transaction
Exit
QueueServer1
Wait Time
QueueServer3
Wait Time
QueueServer4
Wait Time
Process time
Server 1
Utilization
Process time
Server 4
Utilization
Process time
Server 2
Utilization
Process time
Server 3
Utilization
Customertransaction
Customertransaction
Customertransaction
Customertransaction
Customertransaction
Customertransaction
Customertransaction
Customertransaction
Time BetweenArrivals
TBD TTR
Customer transaction
Customer transaction
Custom
er tra
nsact
ion
Service Time
Service Time
Service Time
Service Time
Serv
edcu
stom
er
Served
customer
Wai
ting
cust
omer
tran
sact
ion
TBD TTR
Utilization
TBD TTR
TBD TTR
Utilization
Serv
edcu
stom
er
Waiti
ng custo
mer
transa
ctio
n
TBD TTR
Utilization
TBD TTR
TBD TTR
TBD TTR
Front Door
Operator
Operator
Operator
Operator
References
Below textbook has been used as reference.
Beaverstock, M., Greenwood, A., Lavery, E., & Nordgren, W. (2012). Applied Simulation Modeling and
Analysis Using FlexSim (Third ed.). Oren, Utah: FlexSim Software Products,Inc.
Page 13
13
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Simulation Implementation
Simulation Basic Units of Measure
1 grid unit = 1 meters
1 time unit = 1 minute
Simulation model default speed = 4 grid unit/ time unit = 4 meters/minute .
Abbreviations and Acronyms
We have not used any special abbreviations and acronyms in our base model.
Modeling Simplifications/ Assumptions None
Fixed Resources – Basic Properties
Name Description Capacity MTBF/MTTR
Front Door Source used to create the Customers
Reception Queue to distribute the customers to the available
Teller’s windows open 100 none
Teller 1 Processor get the input from the Reception Queue
and send the customer transaction to QueueServer1 1 none
Teller 2 Processor get the input from the Reception Queue
and send the customer transaction to QueueServer2 1 none
Teller 3 Processor get the input from the Reception Queue
and send the customer transaction to QueueServer3 1 none
Teller 4 Processor get the input from the Reception Queue
and send the customer transaction to QueueServer4 1 none
QueueServer1 Queue which is used for arrange the customers
from source to Teller 1 100 none
QueueServer2 Queue which is used for arrange the customers
from source to Teller 2 100 none
QueueServer3 Queue which is used for arrange the customers
from source to Teller 3 100 none
QueueServer4 Queue which is used for arrange the customers
from source to Teller 4 100 None
Server1 Processor used to process the customer transaction
for Teller1 to Sink 1 normal(100, 10, 1)/10
Page 14
14
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Server2 Processor used to process the customer transaction
for Teller2 to Sink 1 normal(100, 10, 1)/10
Server3 Processor used to process the customer transaction
for Teller3 to Sink 1
normal(100, 10, 1) /
10
Server4 Processor used to process the customer transaction
for Teller4 to Sink 1
normal(100, 10, 1) /
10
Exit Sink to terminate the Customers 1 none
Fixed Resources – Operation Details
Name Setup Time Process Time
Teller 1 None 0
Teller 2 None 0
Teller 3 None 0
Teller 4 None 0
Server1 None 10
Server2 None 10
Server3 None 10
Server4 None 10
Visual Tools
Object name Description
Security Visual Tool to record the input customer into the global table and
close the source input at 5:00pm
Time_display Display the time in system starting from 9:00 am Wednesday till
the Bank finish process the last customer
Average time in system Display the Average time of customers in system.
Average Waiting Time Display the Average waiting time in QueueServer1,
QueueServer2, QueueServer3, QueueServer4
Fluid Objects
No fluid objects are used in the model.
Network Node Diagram
No networks are used in the model.
Page 15
15
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Alternative model 1
User Interfaces
Simulation operates using standard Flexsim interfaces.
Model Views
A model view of the alternate model 1 is provided below.
Fixed Resources – Basic Properties
Use the same fixed resources that have been used in basic model and same MTTF/MTTR.
Fixed Resources – Operation Details
Name Setup Time Process Time
Teller 1 None 0
Teller 2 None 0
Page 16
16
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Teller 3 None 0
Teller 4 None 0
Server1 None getlabelnum(current,"processServer");
and the label get value from global table
Server2 None getlabelnum(current,"processServer");
and the label get value from global table
Server3 None getlabelnum(current,"processServer");
and the label get value from global table
Server4 None getlabelnum(current,"processServer");
and the label get value from global table
Global Tables
Global tables named “gt_EntryRates” has been used with the percentage for IAT to the customer
per every 30 minuts.
Page 17
17
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Global tables named “gt_serverUtilization” has been used to set the server Utilization for every
30 minutes. The sever can get the process speed from that global table.
Global tables named “gt_Output” has been used to account the number of
a- customer input
These values from the Source trigger OnExit
int TotalInput = (getoutput(current) + 1);
settablenum("gt_Output",1,1,TotalInput);
b- customer output
These values from the Sink trigger OnEntry //Get the total number of items leaving the system
double TotalOutput = getinput(current); settablenum("gt_Output",1,2,TotalOutput);
c- Total TIS
These values from the Sink trigger OnEntry
double TotalTIS = 0.0;
//Determine item's time in system
double TIS = time() - getcreationtime(item);
Page 18
18
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
//Update total time in system
TotalTIS= TotalTIS + TIS;
settablenum("gt_Output",1,4, TotalTIS);
d- Avg TIS
These values from the Sink trigger OnEntry double AvgTIS=TotalTIS/TotalOutput;
settablenum("gt_Output",1,3, AvgTIS);
Time Tables
TT_Teller1,3
It is responsible to close teller 1 and teller 3 windows till 1:00 pm
After 240 minutes
Page 19
19
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
TT_Teller2,4
Close the teller windows 2 and 4, from 1:00 pm to 4:00 pm
Custom Objects
Security Visual Tool to record the input customer into the global table
and close the source input at 5:00pm
Use a trigger code to open the source and close it at 5:00pm
OnReset
senddelayedmessage(current,0, current, 0,1,0); // Start machine
OnNessage
switch(msgparam(2))
{
case 1:
sendmessage(centerobject(current,1),current,0,1,0); // start message
senddelayedmessage(current,480, current, 0,2,0); //time to send the msg to stop the input into the system.
break;
case 2:
sendmessage(centerobject(current,1),current,0,2,0); // stop message
break;
}
Page 20
20
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
We get the msgparam(2)) from OnReset to pass it to the switch function to run the case 1
case 1:
sendmessage(centerobject(current,1),current,0,1,0); // start message
senddelayedmessage(current,480, current, 0,2,0); //time to send the msg to stop the input into the system.
case 1
Send message to the source to run the case 1 in Source
case 1: // start mahine
openinput(current);
colorgreen(current);
break;
Here will open the input and set the source color to green
After 480 minutes “at 5:00 pm” will send delay message to case 2
And
Case 2
case 2:
sendmessage(centerobject(current,1),current,0,2,0); // stop message
break;
Will send a message to the source to run the case 2 in Source
case 2: // Stop the input
closeoutput(current);
colorred(current);
break;
and the last will close the input and set the source color to red
Model Validation
Validation Plan
1. Control the number of teller’s windows open during the day.
Page 21
21
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
2. Increase the server process time during the starting and the rush hour to decrease the customer
waiting time
The actual validation:
1. Time table added to control the open teller windows to reduce the teller employee
expensive “salary”
Time Table :
a. TT_Teller1,3
b. TT_Teller2,4
2. Speed up the processor and control the speed for every 30 minutes.
By creating a label name: processServer
And the Process Time get its value from that label.
double value = getlabelnum(current,"processServer");
and the label get its value from the Global Table:
The server trigger OnReset: /**set start up*/
treenode current = ownerobject(c);
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",1,1));
colorgreen(current);
senddelayedmessage(current,30, current,0,0,1);
it is set the first label value from the first column/row from the global table name: gt_serverUtilization
And send a delay message to OnMessage trigger to the same server
The server trigger OnMessage:
treenode current = ownerobject(c);
/**Control the server speed*/
int stepnum = msgparam(3);
switch(stepnum)
{
case 1:
colorgreen(current);
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",2,1));
senddelayedmessage(current,30, current,0,0,2);
break;
case 2:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",3,1));
senddelayedmessage(current,30, current,0,0,3);
break;
case 3:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",4,1));
Page 22
22
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
senddelayedmessage(current,30, current,0,0,4);
break;
case 4:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",5,1));
senddelayedmessage(current,30, current,0,0,5);
break;
case 5:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",6,1));
senddelayedmessage(current,30, current,0,0,6);
break;
case 6:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",7,1));
senddelayedmessage(current,30, current,0,0,7);
break;
case 7:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",8,1));
senddelayedmessage(current,30, current,0,0,8);
break;
case 8:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",9,1));
senddelayedmessage(current,30, current,0,0,9);
break;
case 9:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",10,1));
senddelayedmessage(current,30, current,0,0,10);
break;
case 10:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",11,1));
senddelayedmessage(current,30, current,0,0,11);
break;
case 11:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",12,1));
senddelayedmessage(current,30, current,0,0,12);
break;
case 12:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",13,1));
senddelayedmessage(current,30, current,0,0,13);
break;
case 13:
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",14,1));
senddelayedmessage(current,30, current,0,0,14);
break;
case 14:
colorred(current);
setlabelnum(current,"processServer",gettablenum("gt_serverUtilization",15,1));
break;
default:
msg("Error", "Invalid Case value at Machine");
stop();
}
This long code it’s just a switch that get the parameter from message msgparam(3);
And whatever it have number it will run the Case # and send a delay message after 30
minutes to the next case to set the label value so the server process can use this value to set his
own processing speed.
Page 23
23
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
What-if questions
What if we add extra server for each teller?
Answers: it will add extra cost and we want to reduce the cost
What if we add extra queue per teller?
Answer: there are no effects because we have zero waiting time per queue for teller
The waiting time always in Server Queue.
Performance metrics of interest
Analysis Questions
Definition of Performance Measures
The average and maximum length of the queues for each customer.
The average wait-time for each server queue.
The average number of customers served per hour (throughput).
The average utilization of a server.
Description of Analysis Process/Methodology
Technical Information
Initial conditions: Queue lines are empty and the server is 10 percent.
Run length and basis: 480 minutes based on one business day of Simulation hours
Number of replications and basis: 1
Length of warm-up period and basis: No warm-up time used.
Page 24
24
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Simulation Results
The following results were obtained for 480 minutes run of the simulation. For basic model
Total /
Average
Number of customers served 101
Throughput(customers per hour) 12
Average waiting time in
QueueServer1
4.9
Average waiting time in
QueueServer2
4.1
Average waiting time in
QueueServer3
4.4
Average waiting time in
QueueServer4
4.8
The following results were obtained for 480 minutes run of the simulation. For Alternative model
Total /
Average
Number of customers served 101
Throughput(customers per hour) 12
Average waiting time in
QueueServer1
1.3
Average waiting time in
QueueServer2
2.5
Average waiting time in
QueueServer3
1.7
Average waiting time in
QueueServer4
1
Input Analysis
We have used exponential statistical distributions for inter arrival times and get the value from
the global table as describe at the beginning of the report
Page 25
25
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
The processing time for tellers is zero.
The processing times for server is changeable depend on the busy time and the rush hour, it gets
the value from the global table as well and it is changeable if needed.
Output Analyses
Basic model
1. The time that keep the bank open after close the entrance “input source” at 5:00 pm
Average is at 515.01 minutes that mean at 5:35 pm.
That gives us 515 – 480 = 35 late to close the bank.
2. The four tellers are working.
Basic model Summary report
Alternative model
1. The time that keep the bank open after close the entrance “input source” at 5:00 pm
Average is at 480.85 minutes almost at 5:02 pm.
Page 26
26
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
The Bank will close at 5:02 pm
2. Not all the tellers work in same time only on the last hour “the rush hour” to avoid any
bank closing late and customer late
Alternative model Summary report
Calculate Number of Model Replications
Initial Observations with 10 Replications:
The Performance Measure I used Statistic by group.
Page 27
27
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
And there is group the include the four server queue
Queue_Server_Grp: is a group that contain
1. QueueServer1
2. QueueServer2
3. QueueServer3
4. QueueServer4
So I can experimental on the Queue group
After we use the Flexsim Experimenter on our model for 10 replications, we got the results
The confidence interval (CI) is the range between (mean- hw) and (mean+ hw).
Page 28
28
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Calculations for New Number of Replications
Above to calculate the number of replications we need to reduce the Confidence Interval by
50%.
= [ (tn-1, α/2)*s / (√n) ]
α=0.05
n=10
s=1.25
tn-1, α/2= 2.262
=[(2.262)* 1.25/(√10)]= 2.827/3.162=0.894
Because we needed to reduce the Confidence Interval by 50% =0.89/2 =0.44
=10, =0.894, 0.44
= *[
] = *[
] = 40
In order to reduce the Confidence Interval by 50% we need 40 replications.
Page 29
29
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Output Analysis
Observations with 40 Replications for Base Model:
Queue_Server_Grp: is a group that contain
1. QueueServer1
2. QueueServer2
3. QueueServer3
4. QueueServer4
As long we build and collect some statistic using the Dashboard Statistics tool.
After running the Experimenter for 40 replications you can click on the upper tab that called
Dashboard Statistics and choose and statistic you want to view for any replications number you
want that you already build before in the Dashboard.
For example this is the replication number 11 and you can see any replication result you want.
Page 30
30
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
For more details click Experimentation Report
Or open it manual from the project directory inside directory name “reports” file name:
Queue_Server_Grp_basic.htm
Observations with 40 Replications for Alternative Model:
For Queue_Server_Grp: is a group that contain
1. QueueServer1
2. QueueServer2
3. QueueServer3
4. QueueServer4
Page 31
31
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
For more details click Experimentation Report
Or open it manual from the project directory inside directory name “reports” file name:
Queue_Server_Grp_Alternative.htm
Results Comparison
Model Type
CI - Average Stay Time
Queue_Server_Grp
Base Model 2.89 <3.6 < 4.32
Alternate Model 1.74 <2.13 < 2.53
Based on the above results we noticed that there is no overlap for the CI for the Average stay time in the
group Queue_Server_Grp that include all Server Queue
Page 32
32
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Alternative Model 2
The objects design:
As we got told that the “iterance door” is in one side and the “exit door” in the other side.
1. We create a Source Fixed Resource that have name “Front Door” for generate the
customers as item flow into the bank.
2. And create a Sink Fixed Resource that have name “Exit” for exit door to the customer.
3. 4 Queue to accumulate the flow items (customers) from the source and send the flow
items to the processors “Tellers” and I implement the Queue as a “QueueServer1”,
“QueueServer2”, “QueueServer3” and “QueueServer4”
4. I have four Processors they implements the Teller windows, have names :
Server1, Server2, Server 3 and Server 4.
The Logic design:
1. Source: The IAT use the same data collected that I used to simulate the bank problem
with deferent inter arrival time per time as data collected.
That all in the Source fixed resource “Front Door”.
2. Security: is a virtual tool that respond to
a) Control the open input at 9:00 am / close input at 5:00 pm for the source
By sending a message case 1:
sendmessage(centerobject(current,1),current,0,1,0); // start message
senddelayedmessage(current,480, current, 0,2,0); //time to send the msg to it selfe at 5:00pm
break;
case 2:
// stop message send to the source tpstop the input into the system.
sendmessage(centerobject(current,1),current,0,2,0);
break; b) Record the inference customer’s number to global table.
After send message to open the input in source trigger OnExit start send the number
of iterance to the global table “gt_Output”.
int TotalInput = (getoutput(current) + 1) ;
settablenum("gt_Output",1,1,TotalInput);
3. QueueServer (1,2,3 and 4): open input as a Time Table setting
a) QueueServer1 open input at time 240 after 4 hours at 1:00 pm
b) QueueServer2 open input at time 240 after 4 hours at 1:00 pm
c) QueueServer3 close input at time 240 for 180 minutes = 3 hours
Page 33
33
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
From 1:00 pm to 4:00pm
d) QueueServer4 close input at time 240 for 180 minutes = 3 hours
From 1:00 pm to 4:00pm
4. Teller (1,2,3and 4): implement as person have process time zero “0”
5. Server (1,2,3 and 4): the processor that process the customer’s transaction and they are
implemented as processor have a shape of Teller disk or Rack for teller embedded with
server to process the transaction.
6. Sink: to terminate the flow items “customer” after finish the work in the model
implement with the “Exit”
Page 34
34
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Object Flow Diagram (OFD)
QueueServer 2
Wait Time
Throughput
Custom
er
Customer
Customer
Customer
Customer
Exit
QueueServer1
Wait Time
QueueServer3
Wait Time
QueueServer4
Wait Time
Process time
Server 1
Utilization
Process time
Server 4
Utilization
Process time
Server 2
Utilization
Process time
Server 3
Utilization
Customer
Customer
Customer
Customer
Time BetweenArrivals
TBD TTR Customer
Customer
Custom
er
Service Time
Service Time
Service Time
Service Time
Serv
edcu
sto
mer
Served
customerW
aitin
g cu
stom
er
tran
sact
ion
TBD TTR
Utilization
TBD TTR
TBD TTR
Utilization
Serv
edcu
sto
mer
Wai
ting c
ustom
er
transa
ctio
n
TBD TTR
Utilization
TBD TTR
TBD TTR
TBD TTR
Front Door
Operator
Operator
Operator
Operator
Page 35
35
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Simulation Implementation
Simulation Basic Units of Measure
1 grid unit = 1 meters
1 time unit = 1 minute
Normal run speed for system is 4 unit / time
Abbreviations and Acronyms
We have not used any special abbreviations and acronyms in our base model.
Modeling Simplifications/ Assumptions None
Fixed Resources – Alternative Model 2 Properties
Name Description Capacity MTBF/MTTR
Front Door Source used to create the Customers
QueueServer1 Queue which is used for arrange the
customers from source to Teller 1
100 none
QueueServer2 Queue which is used for arrange the
customers from source to Teller 2
100 none
QueueServer3 Queue which is used for arrange the
customers from source to Teller 3
100 none
QueueServer4 Queue which is used for arrange the
customers from source to Teller 4
100 None
Exit Sink to terminate the Customers 1 none
Server1 Processor used to process the customer
transaction for Teller1 to Sink
1 normal(100, 10, 1)/10
Server2 Processor used to process the customer
transaction for Teller2 to Sink
1 normal(100, 10, 1)/10
Server3 Processor used to process the customer
transaction for Teller3 to Sink
1 normal(100, 10, 1) / 10
Server4 Processor used to process the customer
transaction for Teller4 to Sink
1 normal(100, 10, 1) / 10
Page 36
36
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Fixed Resources – Operation Details
Name Setup Time Process Time
Server1 None Speed control =5 if over the Threshold in Queue, do SpeedUp by
multiply by 0.9
Server2 None Speed control =5 if over the Threshold in Queue, do SpeedUp by
multiply by 0.9
Server3 None Speed control =5 if over the Threshold in Queue, do SpeedUp by
multiply by 0.9
Server4 None Speed control =5 if over the Threshold in Queue, do SpeedUp by
multiply by 0.9
Visual Tools
Object name Description
Security Visual Tool to record the input customer into the global table and
close the source input at 5:00pm
Time_display Display the time in system starting from 9:00 am Wednesday till
the Bank finish process the last customer
Average time in system Display the Average time of customers in system.
Average Waiting Time 1 Display the Average waiting time in QueueServer1
Average Waiting Time 2 Display the Average waiting time in QueueServer2
Average Waiting Time 3 Display the Average waiting time in QueueServer3
Average Waiting Time 4 Display the Average waiting time in QueueServer4
OutPerHourT1 Display Output per Time from server 1”Teller’s window 1”
OutPerHourT2 Display Output per Time from server 1”Teller’s window 2”
OutPerHourT3 Display Output per Time from server 1”Teller’s window 3”
OutPerHourT4 Display Output per Time from server 1”Teller’s window 4”
Other visual tools For simulate the bank life style.
Fluid Objects
No fluid objects are used in the model.
Recorders
Object name Description
State of Server 1 Displays process state for server 1
State of Server 2 Displays process state for server 2
State of Server 3 Displays process state for server 3
State of Server 4 Displays process state for server 4
Page 37
37
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Flow Node
There are 8 flow nodes to manage the customer walk in and out to the bank that have speed
unit/time we assume the normal walk in bank each 1 meter takes 2 seconds 60 / 3 = 20
The speed of node will be 20 meters/minutes.
The last two flow nodes set next to the Exit door have speed of 40 meters/minutes. Because the
customer will walk half of the speed that walk into the street.
The regular walk in street equal 80 Meters/Minutes but it will reduce more than third in bank or
store.
Reference: http://en.wikipedia.org/wiki/Walking_distance_measure
Global Tables
Added the Global tables named “gt_Operations” has been used assign the Maximum value in
Queue for Threshold if it goes more than that number will increase the process speed
automatically.
User Interfaces
Simulation operates using standard Flexsim interfaces.
Model Views A model view of the alternate model 2 is provided below.
Page 38
38
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
What-if questions
1. In the first Alternative model we make the process change his process speed an fixed
time during the day depend on the collected data and we set the in global table and the
processor use a switch with mutable case to set a deferent number to the label
“processServer” and the process time get its value from that changeable label.
The question what if we got some change by the IAT even if its minor change what we
will do for the waiting time and the process time
2. We have dead time from 1:30 PM - 4:00 PM - 0.10 customer/minute !
Do we really need to keep two teller’s windows open and pay for them ???
Alternative Model 2 Validation 1. Change the strategy of the process time that make it more sensitive depend on the Queue
content, and start compare the queue content with the Threshold value and this value are
predefine in global table name is "gt_Operations”.
This value I initial it to 3 I will explain in details how its work:
The code not in the trigger this time but in the process time
//Obtain base service time
double ServiceTime = 5;
//Obtain the speed up threshold
int Threshold=gettablenum("gt_Operations",1,1);
//Determine current number in queue
int NumberInQueue = content(inobject(current,1));
Page 39
39
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
//Default values
double SpeedUp = 1.0;
colorgreen(current);
//Test to see if threshold is exceeded
if (NumberInQueue>=Threshold)
{
SpeedUp=0.9;
colorred(current);
}
return ServiceTime*SpeedUp;
a) Set the ServiceTime = 5. double ServiceTime = 5;
b) Second step Obtain the speed up threshold. int Threshold=gettablenum("gt_Operations",1,1);
c) Third step to Determine current number in queue that send the flow item to the
processor. int NumberInQueue = content(inobject(current,1));
d) Initial the speedUp to 1 , that mean no change because we will multiply the
ServiceTime by the SpeedUp and color green ,
Here the color will no change because we import extra shape but I leave as a
reference if we need to go back to original processor shape double SpeedUp = 1.0;
colorgreen(current);
e) Test to see if threshold is exceeded to compare if the number in queue more than the
threshold value or not.
If the condition exist will change the value of the speedup to 0.9 and change the color
to red to indicate that we get overload in this window and we had to change the Speed
value to 0.9 if (NumberInQueue>=Threshold)
{
SpeedUp=0.9;
colorred(current);
}
f) return ServiceTime*SpeedUp;
if it is normal “no load in queue will multiply by 1, if not will multiply by 0.9 to
reduce the Service Time value.
2. From 1:30 PM - 4:00 PM we keep only one teller’s window open and we add some extra
code that when Intuit for over load in queue for teller 1, will push a bottom and call for
assistance from the customer service person to open another teller’s window.
And this rarely happens.
by sending a message with message parameter 1 msgparam(1) = 1 ,= “1,0,0” senddelayedmessage(centerobject(current,1),10, current,1,0,0);
Page 40
40
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
That will be in the process time code when checking for over load in queue teller 1
if (NumberInQueue>=Threshold)
{
SpeedUp=0.9;
colorred(current);
sendmessage(centerobject(current,1),current,1,0,0);
}
This message will send to the visual tool "Call for assistance"
This virtual tool have code OnMessage if get msgparam(1) = 1 int callassis = msgparam(1);
switch(callassis)
{
case 1:
colorred(current);
sendmessage(centerobject(current,2),current,2,0,0);
break;
Will change the color to the text to red and send a message to QueueServer2 that connect to
central port 2 (centerobject(current,2), to open input the code will be in QueueServer2 OnMessage
that have msgparam(1) = 2 .
The code in QueueServer2 OnMessage:
case 2:
colorgray(current);
openinput(current);
break;
and if everything goes normal and there is not too much in QueueServer1 that mean when
processer “Server1” for Teller have no load and goes back to normal process time with no need
to speed Up will send a message to the virtual tool but will take 10 minute to not interrupt the
customer service teller or the manager that open teller two window. //Default values
double SpeedUp = 1.0;
colorgreen(current);
senddelayedmessage(centerobject(current,1),10, current,2,0,0);
And the virtual tool "Call for assistance" will send a message to QueueServer2 to close
the input after 20 minutes to get the total of 30 minutes the default amount when request
assistance. case 2:
colorgreen(current);
senddelayedmessage(centerobject(current,2),20, current,1,0,0);
break;
The Trigger OnMessage in QueueServer2 will be: case 1:
colorred(current);
stopinput(current);
break;
To set the color back to red and close the input.
Page 41
41
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Output Analyses
Simulation Results
The following results were obtained for 480 minutes run of the simulation. For Alternative model 2
Basic
model
Alternative
1
Alternative
2
Number of customers served 101 101 96
Throughput(customers per
hour)
12 12 12
Average waiting time in
QueueServer1
4.9 1.3 2.85
Average waiting time in
QueueServer2
4.1 2.5 0.00
Average waiting time in
QueueServer3
4.4 1.7 1.67
Average waiting time in
QueueServer4
4.8 1 2.80
Page 42
42
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Summary report for Alternative model 2
The summery report for the Alternative model 2 Click here
Or open it manual from the project directory inside directory name “Reports” file name:
summaryreport_Alternative2.csv
Note: the Bank will close in average after 8-10 minutes from closing the entrance door around
5:08 pm. It is acceptable to the customers and employees.
Observations with 40 Replications for Alternative 2 Model:
For Queue_Server_Grp: is a group that contain
1. QueueServer1
2. QueueServer2
3. QueueServer3
4. QueueServer4
Page 43
43
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
For more details click Experimentation Report
Or open it manual from the project directory inside directory name “Reports” file name:
Queue_Server_Grp_Alternative2.htm
Group Queue Results Comparison
Model Type
CI - Average Stay Time
Queue_Server_Grp
Base Model 2.89 < 3.6 < 4.32
Alternate Model 1 1.74 < 2.13 < 2.53
Alternate Model 2 2.07 < 2.4 < 2.73
Based on the above results we noticed that there is no overlap for the CI for the Average stay time in the
group Queue_Server_Grp that include all Server Queue between the Alternate Model 2 VS Base Model
And we do have overlap between the Alternate Model 1 VS Alternate Model 2. We should take into
consideration the Alternate Model 2 more close to the reality because it has the customer walk time. And
still we have the Cost Benefit Analysis to decide which one will give us more benefit.
The Mean of Base Model = 3.6 Std dev S = 2.21 α = 0.05
The Mean of Alternate Model 1 = 2.13 Std dev S =1.21 P = 0.05
The Mean of Alternate Model 2 = 2.4 Std dev S =1.02
Paired-t is also used quite often in simulation modeling and analysis. It uses the following hypothesis:
H0: µ1 = µ2 → µ1 - µ2 → = 0 → µ12 = 0
H1: µ1 ≠ µ2 → µ1 - µ2 → ≠ 0 → µ12 = 1
If H0 (the null hypothesis) is rejected, then it is concluded that there is a significant difference in the mean of the
two populations that represent the two alternatives.
Hw0 = (tn-1, α/2)*S / (√n) = (t40-1, 0.05/2)* 2.21/( 40) = (t39,0.025)*2.21/(6.32) = 2.0227 * 0.3496 = 0.7071 (X - hw) = 3.6 – 0.7071= 2.8929 (X + hw) = 3.6 + 0.7071 = 4.3071 Therefore, the 95% CI is the range from (2.8929) to (4.3071).
Hw2 = (tn-1, α/2)*S / (√n) = (t40-1, 0.05/2)* 1.02/( 40) = (t39,0.025)*1.02/(6.32) = 2.0227 * 0.1613= 0.3262 (X - hw) = 2.4 – 0.3262 = 2.0738 (X + hw) = 2.4 + 0. 3262 = 2.7262 Therefore, the 95% CI is the range from (2.0738) to (2.7262).
H0 not equal h2 we reject the haypothisis and we accept the alternative model 2
Page 44
44
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Statistic by individual object Now will do experimenter for Statistic by individual object for the three models:
Observations with 40 Replications for Basic Model:
1.
Object: "QueueServer1"
Statistic: AverageStaytime
2.
Object: "QueueServer2"
Statistic: AverageStaytime
3.
Object: "QueueServer3"
Statistic: AverageStaytime
4.
Object: "QueueServer4"
Statistic: AverageStaytime
Page 45
45
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Observations with 40 Replications for Alternate Model 1:
1.
Object: "QueueServer1"
Statistic: AverageStaytime
2.
Object: "QueueServer2"
Statistic: AverageStaytime
3.
Object: "QueueServer3"
Statistic: AverageStaytime
Page 46
46
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
4.
Object: "QueueServer4"
Statistic: AverageStaytime
Observations with 40 Replications for Alternate Model 2:
1.
Object: "QueueServer1"
Statistic: AverageStaytime
2.
Object: "QueueServer1"
Statistic: AverageStaytime
Page 47
47
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
3.
Object: "QueueServer1"
Statistic: AverageStaytime
4.
Object: "QueueServer1"
Statistic: AverageStaytime
Page 48
48
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Statistic by individual object Results Comparison
Model Type QueueServer1 QueueServer2 QueueServer3 QueueServer4
Base Model 2.98 < 3.67 < 4.35 3.02 < 3.67 < 4.32 2.84 < 3.61 < 4.38 2.85 < 3.67 < 4.5
Alternate Model 1 1.33 < 1.91 < 2.49 1.52 < 2.08 < 2.65 1.68 < 2.44 < 3.19 1.57 < 2.11 < 2.64
Alternate Model 2 3.93 < 4.82 < 5.7 0 < 0 < 0 1.85 < 2.46 < 3.07 1.88 < 2.33 < 2.78
Cost Benefit Analysis
First we collect some statistics about the regular bank teller salary in Manchester NH
And we get the average salary is 29.00 $ per hour for each teller.
Reference: http://www.indeed.com/salary?q1=Bank+Teller&l1=manchester+
Cost per basic model calculate
Base Model Cost Benefit Analysis: has 4 teller’s window open for all the business hour per day.
29.00 * 4 = 116 $ per one hour for 4 tellers
116*8 = 928 $ per one day
Alternate Model 1 Model Cost Benefit Analysis:
Two teller’s window opens (Teller2 and Teller 4) from 9:00 am to 1:00 pm = 4 hours
29.00 * 2 = 58$ per one hour for two tellers
Page 49
49
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
For first four hours cost will be 232 $
Two teller’s window opens (Teller1 and Teller 3) from 1:00 pm to 5:00 pm = 4 hours
232 $
Plus (Teller2 and Teller 4) will open in the last hour to avoid the busy time in the rush hour
=58$
For the last four hours cost will be 232+58 = 290 $
The cost for one business day 232 $ + 290 $ = 522 $
Alternate Model 2 Model Cost Benefit Analysis:
Two teller’s window opens (Teller3 and Teller 4) from 9:00 am to 1:00 pm = 4 hours
29.00 * 2 = 58$ per one hour for two tellers
For first four hours cost will be 232 $
One teller (Teller1) open from 1:00 pm to 5:00 pm and will keep teller’s window 2 available if
the bank got busy, the Teller1 can call for assistance from the “MOD” manager on duty or the
customer service person and that will don’t add extra charge on the tellers salaries budget.= 116$
Plus the (Teller3 and Teller 4) will open the last hour to make sure they can cover the rush hour.
=58 $
The last four hours cost will be 116 $ + 58 $ = 174
The Total cost for one business day = 232 + 174 = 406 $
From the cost results that we have, will show Cost Benefit Analysis comparison for the three
models.
Cost Benefit Analysis
Base Model Alternate Model 1 Alternate Model 2
Total salary Per week 928*5 = 4,640 $ 2,610 $ 2030 $
Total salary Per month 4,640*4 = 18,560 $ 10,440 $ 8,120 $
Total salary Per year 18,560*12= 222,720 $ 125,280 $ 97,440 $
The bank will save:
222,720 $ – 125,280 $ = 97,440 $ every year by using Alternate Model 1
222,720 $ – 97,440 $ = 125,280 $ every year by using Alternate Model 2
Page 50
50
Ahmed Al Salih
IT-630-G1703_13TW1
Southern New Hampshire University
Conclusions and Recommendations
Alternate Model 2 did not have any balked customers and this model has been found to be the most cost
effective compared to Base Model and Alternate Model 1. There are no customers balked even in the
Alternate Model 1 but this will cost around 1.5 times more to the business compared to the Alternate
Model 2. With respect to the Average stay time in the Queue, Alternate Model 1 has best values
compared to the Base Model and Alternate Model 2. Alternate Model 2 Average Stay times are
significantly better compared to the Base Model. From this analysis we recommend Alternate Model 2 as
the optimum solution.