Professional Documents
Culture Documents
OSProject Report
OSProject Report
net/publication/353120834
CITATIONS READS
0 2,946
1 author:
SEE PROFILE
All content following this page was uploaded by Kong Hao Yang on 09 July 2021.
KongHaoYangA19EC0065(Leader)
SchoolofComputing,FacultyofEngineering,UniversityofTeknologiMalaysia
BrynardBryanEdmundA19EC0029
SchoolofComputing,FacultyofEngineering,UniversityofTeknologiMalaysia
MostafaMusabNaveedA19EC4017
SchoolofComputing,FacultyofEngineering,UniversityofTeknologiMalaysia
ABSTRACT
The normality of long queues of customers at banks can increase the risk of COVID-19
infection
during
this
period
of
COVID-19
pandemic.
Thus,
We
as a team
propose
to
develop
a
Customer
Queue
Management
Program
that
can
manage
the
queue
of
customers
in
a more
efficient way by applying the concepts of CPU process scheduling as well as Shortest
Job
First (SJF), Shortest Remaining Time First (SRTF) and
priority.
By
using
this
program,
the
waiting time and turnaround time for a customer to obtain their services at banks can be
minimized and this can indirectly increase
the
efficiency
of
the
bank
and
also
minimize
the
risk
of
COVID-19
infection.
The
development
of
the
program
will
be
conducted
in
stages
as
planned. Among the three algorithms applied, the average waiting time and average
turnaround time of SRTF is the shortest among them and thus SRTF is the most efficient
algorithmamongthem.
1. INTRODUCTION
During
this
period
of COVID-19
pandemic
all
over
the
world,
social
distancing
is
one
of the important measures that can be taken to minimize the risk of COVID-19 infection.
However,
social
distancing
is
hard
to
implement
at
the
bank
as
most
of
the
banking
services
still need to be done physically at the bank even though some of the banking services are
accessible
via
online.
This
will
result
in
a situation
where
there
is
a long
queue
of
customers
1
formed
at
the
bank
in
order
to
obtain
services
from
the
staff
and
this
will
increase
the
chance
ofphysicalcontactamongcustomerswhiletheyarewaitinginaqueue.
Therefore, in
order
to
solve
this
situation,
our
team
would
like
to
propose
a program
that can help the staff of a bank to manage the queue of customers more efficiently while
reducing the risk of COVID-19 infection among customers when queuing. The program
is
Customer Queue Management Program (CQMS) and it is a program that applies the three
different
algorithms of
CPU
process
scheduling
which
are
the
algorithms of
Shortest
Job
First
(SJF), Shortest Remaining Time First (SRTF) and priority when managing the queue of
customers.
Process
scheduling
is
the
activity
of
the
process
manager
that
handles
the
removal of
the running process from the CPU and the selection of another process on the basis of a
particular strategy. Process scheduling follows different algorithms. (Tutorialspoint, 2021)
Shortest job
first
is
a scheduling
algorithm
in
which
the
process
with
the
smallest
execution
time is selected for execution next. Shortest job first can be either preemptive or
non-preemptive
(Techopedia,
2021).
Shortest
Remaining
Time
First(SRTF) is
the
preemptive
version of the SJF algorithm.
The
process
with
the
least
amount
of
time
until
completion
is
chosen
first
to
run
(Studytonight,
2021).
Priority
Scheduling
is
a way
of
scheduling
processes
based on priority (Guru99, 2021). The processes with the highest importance should be
executedfirst.
Based on the above algorithm, this program can schedule the queue of customers
based on
the
types
of
banking
services
that
wish
to
perform,
estimated
required
time
for
the
services
and
also
the
priority
of
the
services. Besides
that,
this
program
can
also
reduce
the
waitingtimeandturnaroundtimeforacustomerwhoobtainsservicesatthebank.
2. PROBLEMSTATEMENT
The main cause of the long queue of customers at banks is due to lack of proper
scheduling for the customers
which
focuses
on
minimizing
the
waiting
time
and
turnaround
time
for
each
customer.
The
current
management
of
the
queue
of
customers
is
inefficient
and
resultsinlongwaitingtimeforcustomerstoobtaintheirbankingservices.
2
3. RESEARCHOBJECTIVES
● To
obtain
the
waiting
time and
turnaround
time
for
customers
in
queue
using
different
algorithmsofprocessscheduling
● Todeterminethemostefficientalgorithmamongthethreealgorithms.
4. SCOPEOFRESEARCH
● Thecustomerthatwentinthebankwillbethetargetaudience.
● TheprogramwillbedevelopedinC++programminglanguage.
● Datathatcustomersenterwillbeusedforanalysisforthebestoutcometoqueue.
5. SIGNIFICANCEOFTHERESEARCH
● The findings of this research will contribute to how a queue can be formed to
minimisethewaitingtimeandturnaroundtimeofcustomersthatwentintothebank.
● Itincreasestheefficiencyofbankstoservetheircustomers.
● Thegapbetweencustomerwaitingtimecanbegreatlyreduced.
● The waiting time of customers is reduced and it indirectly lowers the chances of
gettinginfectedbycovid-19asthequeuedoesnotpileup.
● The turnaround time of customers can be minimized to make the banking services
moreefficient.
6. RESEARCHMETHODOLOGY
The project will be divided into several phases to make sure we are going in the right
direction. These phases contain their own deliverables and guide the project members to
moveontothenextstepofphasestepbystep.
● Phase1:ProjectPlanning
● Phase2:Identifytheconstant,manipulatedandrespondingvariables.
● Phase3:Applicationdesigning
● Phase4:Applicationdevelopment
● Phase5:Dataanalysisanddiscussion
● Phase6:Conclusion
3
7. DESIGN&IMPLEMENTATION
FlowChart
1. MainFunction
MainFunctionURL
Figure1:Flowchartformainfunction
4
2. Menufunction
MenufunctionURL
Figure2:Flowchartformenufunction
5
3. SJFimplementation
SJFimplementationURL
Figure3:FlowchartforSJFimplementation
6
4. SRTFimplementation
SRTFimplementationURL
Figure4:FlowchartforSRTFimplementation
7
5. PriorityScheduling(Non-preemptive)implementation
PrioritySchedulingImplementationURL
Figure5:Flowchartforpriorityschedulingimplementation
8
8. RESULTS&DISCUSSION
Burst
time
and
arrival
time
are
the
necessary
data
required for
both
Shortest
Job
First
and Shortest Remaining Time First algorithms to schedule CPU processes, while priority
scheduling algorithm
requires 3 types of
data
which
are
burst
time,
arrival time
and priority to
schedule processes. And, our system will read the required inputs for the algorithms from
users
and
those
inputs
are operation
time
representing
burst
time,
arrival time
and
category
of
membership
representing
priority.
After
that,
these
inputs
will
be
used
to
schedule
the
queue
of customers by computing the completion time, waiting time and
turnaround
time
of
each
customerarrivingatthebank.
Let’s
assume
a daily
scenario
at
a random
bank.
Generally,
banks open
at
9.00
am.
So,
if any person enters the bank
at
exactly
9.00
am
he
will
put
0 as
his
arrival
time.
If
anyone
enters
at
9.10
am,
the
arrival
time
would
be
10.
Now
we
will
assume
the
details
of 6 random
persons who enter the bank at random times with different membership cards for
different
purposestotestourCustomerQueueManagementSystem.
<<<MenuOptions>>>
Pleasethefollowingoperations
1)Addcustomerintoqueue
2)Viewcustomer'squeue
3)Terminatethesystem
<<<Typeofbankingservicesrequiredtobeperformed>>>
1)TransactionServices
2)Consultation
3)Debit&CreditCardsRelatedServices
4)Insurance
5)WealthManagement
6)AccountOpening&ClosingServices
7)Loan&FinancingServices
8)AccountSecurityIssue
9
<<<Thecategoryofyourmembership>>>
1)Diamond
2)Platinum
3)Gold
4)Silver
5)Copper
6)Basic
The 1st person who comes to the bank at exactly 9.00am, first needs to select the kind of
service
he
wants
to
get.
Suppose
he
wants
to
perform
account
opening
& closing
services
so
he
selects
the
option
from
the
menu.
The
system
then
asks
an
estimated
operation
time
from
him. So, he enters 50 minutes as this amount of time is enough for making a transaction.
Now,
the
system
will
ask
to
enter his
arrival
time.
He
entered
0 as
he
came
at
exactly
9.00am.
After
that,
the
system
will
ask
for
his membership
category.
Let’s
assume
this
person
belongs
to
the
diamond
category.
So,
he
chooses
from
the
option.
And
after
that
our
system
will add
thecustomertothequeue.Nowwewouldassumeentriesforanother5persons.
CustomerID Type
of
banking
OperationTime ArrivalTime Priority
services (Membership
Category)
Table1:Inputsfor6differentcustomers
10
Based on the above scenario, we can obtain three different outputs for the three different
algorithmsasfollows.
1)ShortestJobFirst(SJF)
2)ShortestRemainingTimeFirst(SRTF)
3)Priority
11
For
Shortest
Job
First
(SJF),
the
average
waiting
time
and
average
turnaround
time
are
64.83
and 99.17 in minutes respectively, while for Shortest Remaining Time First (SRTF), the
average
waiting
time
and
average
turnaround
time
are
52.5
and
86.83
in
minutes
respectively.
Besides
that,
the
average
waiting time
and
average
turnaround
time of
priority
scheduling
are
64.83and99.17minutesrespectively.
Based
on
the average waiting
time and
average
turnaround
time
of
these
3 algorithms,
we
can
clearly
observe
that
SRTF
has
the
shortest
average
waiting
time and
turnaround
time
among
the
three
algorithms,
while
SJF
and
priority
algorithms
have
the
same
average
waiting
time and average turnaround time. Thus, we can conclude that SRTF is the most efficient
algorithm
in
increasing
the
efficiency
of
customer
queue
management
as
well
as
reducing the
waitingtimeandturnaroundtimeofcustomersinqueue.
9. CONCLUSION
Banking
services
are
essential
services
in
our
daily
life
and
due to
its
importance,
it
is
barely
possible
to
avoid
social
contact
among
customers
when
they
queue
up
to
get banking
services
at banks. Thus, it is
necessary
to
take
measures
to
make
the queue
of
customers
more
efficient with minimum amount of waiting time and turnaround time so that the risk of
COVID-19 infection can be minimized when customers are waiting in a queue. And, our
Customer Queue Management
System
is
designed
to
handle
this
problem
as
it
can
schedule
the queue of customers based on their estimated
required
time
for
the
services
and
also
the
priority of the services by applying the algorithms of
SJF,
SRTF
and
priority.
Based
on
the
analysis of the results of this research,
different
algorithms
used
in
queue
management
will
affect the completion time, waiting time
and
turnaround
time
of
a customer
in
the
queue
as
well as the
average
waiting
time
and
average
turnaround
time
for
all
customers.
Among
the
three
algorithms
studied,
we
found
that
the
Shortest
Remaining
Time First
(SRTF)
algorithm
is the most efficient algorithm as it has the shortest average waiting time and average
turnaroundtimecomparedtotheothertwoalgorithms.
12
View publication stats
10. REFERENCES
Guru99. (2021). Priority Scheduling Algorithm: Preemptive, Non-Preemptive EXAMPLE.
Guru99.com. Retrieved 17 June 2021, from
https://www.guru99.com/priority-scheduling-program.html.
Studytonight. (2021). Shortest Remaining Time First Scheduling Algorithm - Studytonight.
Studytonight.com. Retrieved 17 June 2021, from
https://www.studytonight.com/operating-system/shortest-remaining-time-first-scheduling-alg
orithm.
Techopedia. (2021). What is Shortest Job First (SJF)? - Definition from Techopedia.
Techopedia.com. Retrieved 17 June 2021, from
https://www.techopedia.com/definition/22053/shortest-job-first-sjf.
Tutorialspoint. (2021). Operating System - Process Scheduling - Tutorialspoint.
Tutorialspoint.com. Retrieved 17 June 2021, from
https://www.tutorialspoint.com/operating_system/os_process_scheduling.htm.
13