Back to all projects
Mathematics

Queuing Theory in Bank and Hospital Service Delivery: Modelling, Simulation and Optimal Staffing in Nigeria

Elijah T 0 views 0 downloadsBSc/BA

Notice: This is a sample project for study and reference. Submitting it as your own work violates most universities' academic integrity policies.

Abstract

About This Research Topic

Almost everyone in Nigeria has stood in a slow-moving line at a bank counter or sat on a crowded bench in a hospital outpatient waiting area, wondering why the wait is so long and whether anything could be done about it. The frustration is real, and so are the costs: lost working hours for customers, heavier workloads for staff, and, in a clinic, delayed care that can matter for a patient's health.

What many people do not realise is that these waits follow mathematical rules. Customers arrive at random moments, services take random lengths of time, and the interaction between the two produces queues whose behaviour can be predicted with surprising precision. The branch of mathematics that studies this is called queuing theory, and it gives managers a principled way to decide how many tellers or doctors they actually need.

This article draws on an undergraduate mathematics research project that developed three classical queuing models, checked each against computer simulation, added a cost-based staffing analysis, and applied the framework to a Nigerian hospital outpatient department. It explains the problem the study tackled, what it set out to do, and the main numerical results it reports. If you are a mathematics student looking for a model of a well-validated applied project, or a manager curious about how pooling queues and choosing staffing levels can be put on a firm quantitative footing, the sections that follow are written for you.

Main  Abstract

Managing the time that customers and patients spend waiting is a central operational concern for banks and hospitals in Nigeria. Service quality, congestion and staffing cost in both settings are driven by the same underlying random process of arrivals and service, which can be analysed formally with queuing theory. This study builds a thorough mathematical treatment of three models: the single-server M/M/1 queue, the multi-server M/M/c (Erlang C) queue and the finite-capacity M/M/c/K queue. Every analytical result is checked independently against discrete-event Monte Carlo simulation, and the framework is then applied to cost-based staffing decisions and to an original case study of a Nigerian hospital outpatient department.

For a representative single-server scenario with 8 arrivals and a service capacity of 10 customers per hour, the analytical expected queue wait was 24.0 minutes. A simulation of 1,599,887 customers reproduced it to within 0.36 percent, and Little's Law, verified directly from simulated arrival and departure records, held with comparable precision. The multi-server model revealed a strong resource-pooling effect: merging three separate single-server queues, each receiving a third of the arrivals, into one shared three-server queue cut expected waiting time by 73.0 percent.

The finite-capacity model showed blocking probability falling from 10.2 percent at a capacity of six patients to 0.5 percent at a capacity of twenty. In the staffing analysis, which balanced hourly staffing cost against the opportunity cost of waiting, four servers minimised total cost for a representative bank branch at 15,095 naira per hour, compared with 16,480 naira for three servers and 17,009 naira for five. In the hospital case study of a four-doctor outpatient department, modelled under separate peak and off-peak arrival conditions, simulation matched the analytical predictions to within 0.83 and 2.95 percent across more than 2.5 million simulated patient visits. A utilization-sensitivity analysis also showed waiting time rising sharply and nonlinearly as servers approach full capacity.

The study concludes that queuing theory, validated by simulation and extended to cost optimisation, gives Nigerian banks and hospitals a robust, practical tool for balancing service quality against staffing cost. It recommends that organisations adopt pooled, single-queue multi-server arrangements and formal cost-optimal staffing analysis in place of ad hoc staffing.

Key Results at a Glance

Analysis

Reported result

M/M/1 expected queue wait

24.0 minutes analytically; simulation of 1,599,887 customers matched within 0.36 percent

Resource pooling (M/M/c)

73.0 percent reduction in expected wait from merging three single-server queues into one three-server queue

Blocking probability (M/M/c/K)

10.2 percent at capacity six, falling to 0.5 percent at capacity twenty

Cost-minimising staffing

Four servers at 15,095 naira per hour, versus 16,480 (three servers) and 17,009 (five servers)

Hospital case study

Simulation agreed with analysis within 0.83 percent (peak) and 2.95 percent (off-peak) over 2.5 million+ visits

Chapter One Preview

Background to the Study

Waiting in line is among the most familiar and most irritating parts of dealing with any service organisation, and Nigerian banks and hospitals are no exception. Long teller queues and full outpatient waiting rooms affect customer satisfaction and staff workload, and in hospitals they can affect clinical outcomes when treatment is delayed. Behind this everyday experience sits a mature body of mathematics. Queuing theory treats the arrival of customers and the length of their service as random processes, and from those assumptions it derives exact predictions of waiting time, queue length and congestion.

The field traces back to the Danish engineer Agner Krarup Erlang, who joined the Copenhagen Telephone Company in 1908 and applied probability theory to the problem of how many lines and operators were needed to handle telephone traffic. His published work began with a paper in 1909, and the formulas that came out of it, including the Erlang C formula for multi-server systems in which customers wait, remain in everyday use in operations research, telecommunications and service management. A short account of his career is available in this biography of Erlang from the University of St Andrews.

The simplest and best-studied model is the M/M/1 queue. The letters describe Markovian (Poisson) arrivals, Markovian (exponential) service times and one server. It yields closed-form answers for every steady-state measure of interest, including expected queue length, expected waiting time and the full distribution of the number of customers present. Real branches and clinics, however, have several tellers or doctors working in parallel, which leads to the M/M/c model, and they have physical limits such as a finite banking hall or waiting room, which leads to the M/M/c/K model, where arrivals are turned away when the system is full.

Elegant formulas are not enough on their own. Sound applied mathematics calls for independent checking, and the usual tool is discrete-event simulation, which imitates the random arrivals and services event by event and computes performance measures from the simulated record. Because it does not use the derivation at all, it tests the analytical results from the outside. One relationship the study verifies this way is Little's Law, which links the average number of customers in a system to the arrival rate and the average time each customer spends there. John Little, who proved the result in 1961, is profiled on the MIT page on Little's Law.

This study sits firmly in that tradition. It derives the M/M/1, M/M/c and M/M/c/K models, validates each against simulation, extends the work to cost-based staffing, and applies the validated framework to a Nigerian hospital outpatient department under peak and off-peak conditions.

Statement of the Problem

Queuing theory is well established, yet many treatments within Nigerian undergraduate mathematics projects stop at the basic M/M/1 formulas applied to one illustrative example. They seldom check results against simulation, rarely extend to the multi-server and finite-capacity cases that best match real banks and hospitals, and often stop short of the cost-based staffing analysis that turns the theory from a descriptive exercise into a decision tool.

Case studies that use representative arrival and service rates for Nigerian service settings, validate them by simulation, and then move on to formal staffing optimisation and sensitivity analysis are also uncommon. Queuing is frequently treated as a formula exercise detached from any economically grounded decision. This study addresses both gaps. Stated concisely, the problem is how queuing theory, validated through discrete-event simulation and extended to cost optimisation, can be used to determine efficient, economically justified staffing levels for Nigerian bank and hospital operations.

Aim and Objectives of the Study

The aim of the study is to develop, derive analytically and rigorously validate, through discrete-event simulation, a set of queuing theory models, and to apply them to cost-based optimal staffing and to an original Nigerian hospital case study.

The specific objectives are to:

1.       Derive the steady-state performance measures of the M/M/1 queue analytically and validate them against a discrete-event Monte Carlo simulation of a large number of simulated customers.

2.       Extend the analysis to the M/M/c (Erlang C) multi-server queue and quantify the advantage of consolidating several independent single-server queues into one shared multi-server queue.

3.       Extend the analysis to the M/M/c/K finite-capacity queue and quantify the trade-off between waiting-room or banking-hall capacity and blocking probability.

4.       Formulate and solve a cost-based staffing problem that balances hourly staffing cost against the opportunity cost of customer waiting time, in order to find the cost-minimising number of servers for a representative bank branch.

5.       Apply the validated M/M/c framework, with simulation cross-validation, to an original case study of a Nigerian hospital outpatient department under separately modelled peak and off-peak arrivals.

6.       Verify Little's Law directly from discrete-event simulation records.

7.       Conduct a sensitivity analysis showing how expected waiting time responds to changes in server utilization and where a service system approaches unsustainable congestion.

Research Questions

•        How closely do the analytically derived M/M/1 performance measures match those from an independent discrete-event Monte Carlo simulation?

•        What reduction in expected waiting time is achieved by consolidating several independent single-server queues into one shared multi-server queue?

•        How does blocking probability in a finite-capacity queuing system respond to changes in waiting-room or banking-hall capacity?

•        What is the cost-minimising number of servers for a representative bank branch, balancing staffing cost against customer waiting-time cost?

•        How well do analytical M/M/c predictions match simulation results for a Nigerian hospital outpatient department under peak and off-peak conditions, and does Little's Law hold in the simulated data?

•        How does expected waiting time respond to rising server utilization, and at what level does it begin to escalate sharply?

Significance of the Study

For students of probability theory and stochastic processes, the study offers a rigorously validated treatment that goes beyond plugging numbers into formulas. By checking every analytical result against simulation, it shows that results derived on paper can and should be tested empirically instead of being accepted on the strength of the derivation alone.

For bank branch managers and hospital administrators, it demonstrates a mathematically sound and directly usable way to set staffing levels that balance service quality against cost. Its resource-pooling finding is particularly notable, because merging separate queues into one shared queue reduced waiting time with no change in total staffing, which makes it a low-cost improvement with immediate operational relevance. For healthcare researchers and policymakers, the finite-capacity blocking results and the utilization-sensitivity analysis offer quantitative guidance on the congestion risk of running outpatient departments at high utilization, which bears directly on capacity planning.

Scope of the Study

The study is confined to Markovian queuing models, namely M/M/1, M/M/c and M/M/c/K, in which inter-arrival and service times are exponentially distributed, equivalent to Poisson arrivals. This is a standard simplification and a reasonable approximation for many practical systems. Non-Markovian models with general service or inter-arrival distributions, priority disciplines in which some customers such as emergency patients are served first, and queuing networks of interconnected service stations all lie outside the scope, although they are noted as directions for further research.

The applied case study uses representative arrival and service rate data for a stylised Nigerian hospital outpatient department, not primary data gathered from a particular named hospital.

Operational Definition of Terms

Term

Operational Definition

Queuing theory

The mathematical study of waiting lines, modelling the random arrival and service of customers to predict measures such as waiting time and queue length.

M/M/1 queue

A queuing system with Poisson (Markovian) arrivals, exponential (Markovian) service times and a single server.

M/M/c queue

A generalisation of the M/M/1 queue to c parallel servers sharing a single queue.

M/M/c/K queue

An M/M/c queue with a finite total system capacity K, beyond which arriving customers are blocked, meaning turned away.

Server utilization (traffic intensity)

The fraction of time a server is busy, equal to the arrival rate divided by the total service capacity.

Erlang C formula

The formula giving the probability that an arriving customer in an M/M/c queue must wait because all servers are busy. It originates in the work of A. K. Erlang.

Little's Law

The queuing relationship stating that the expected number of customers in a system equals the arrival rate multiplied by the expected time a customer spends in the system. See the MIT profile of John Little.

Resource pooling

Consolidating several separate service queues into one shared queue served by multiple servers, which generally lowers average waiting time compared with separate queues.

Blocking probability

In a finite-capacity queue, the probability that an arriving customer finds the system full and is turned away.

Discrete-event simulation

A computational technique that models a system's operation as a sequence of discrete events, such as arrivals and service completions, occurring at specific points in simulated time.

Conclusion

Queues are not just a nuisance to be endured; they are a mathematical system that can be understood, tested and improved. This study shows that analytical models, once verified against large-scale simulation, give reliable answers about waiting time, congestion and cost. Its three clearest practical messages are that pooling queues sharply reduces waiting, that adding capacity in a finite system quickly reduces the chance that customers are turned away, and that the cheapest staffing level is not necessarily the lowest one, since waiting has a cost too. Because the case study uses representative rather than field-collected data, organisations should replace the illustrative parameters with their own measured rates and costs before acting. For students and managers alike, the work is a clear template for turning a familiar frustration into a quantified, defensible decision.

Frequently Asked Questions

1. What is queuing theory in simple terms?

Queuing theory is the mathematical study of waiting lines. It models how customers arrive and how long they take to be served, then predicts quantities such as average waiting time, queue length and the chance that a server is busy.

2. What do the letters in M/M/1, M/M/c and M/M/c/K mean?

The first M stands for Markovian (Poisson) arrivals and the second M for Markovian (exponential) service times. The number or letter after them gives the number of servers: one in M/M/1, c in M/M/c. In M/M/c/K, the final K is the maximum number of customers the system can hold.

3. How was the M/M/1 result validated?

The study compared the analytical expected queue wait of 24.0 minutes with a discrete-event simulation of 1,599,887 customers. The simulation reproduced the analytical value to within 0.36 percent.

4. What is Little's Law and why does it matter?

Little's Law states that the average number of customers in a system equals the arrival rate multiplied by the average time each spends in the system. It holds across a very wide range of queuing systems, so verifying it in simulated data is a useful check that the simulation is internally consistent.

5. What is resource pooling and how much did it help?

Resource pooling means replacing several separate queues with one shared queue feeding all the servers. In this study, merging three single-server queues into one shared three-server queue reduced expected waiting time by 73.0 percent without adding any staff.

6. What is blocking probability?

It is the probability that an arriving customer finds the system full and is turned away. The study found it fell from 10.2 percent at a capacity of six patients to 0.5 percent at a capacity of twenty.

7. How many servers minimised cost in the bank branch example?

Four servers. They produced a total hourly cost of 15,095 naira, lower than the 16,480 naira for three servers and the 17,009 naira for five servers, once staffing cost and the opportunity cost of waiting were both counted.

8. Why does waiting time rise so fast when utilization is high?

As servers approach full capacity, even small random bursts of arrivals cannot be absorbed, so queues build up and take a long time to clear. The study's utilization-sensitivity analysis showed this sharp, nonlinear escalation in waiting time.

9. Were real hospital data used?

No. The case study uses representative, illustrative arrival and service rates for a stylised four-doctor outpatient department, modelled under separate peak and off-peak conditions, rather than primary data from a named hospital.

10. What are the main limitations of the study?

The models assume exponentially distributed service times, a single patient class with no priority triage, and constant arrival rates within each peak or off-peak scenario. The cost parameters are also illustrative, so real organisations would need to substitute their own measured data and costs.

Purchase to unlock the full material.