Modelling Dynamic Traffic Loads in Multiserver Queues using G/G/k Queue.

. Operations research and marketing management have benefited greatly from the important science of queuing optimisation. We take into account a multiserver single input G/G/k queue for study. This type of queue formation occurs in factories, production facilities, logistics centres, airports, and hospitals where the inter-arrival and service times are frequently not exponentially distributed. Knowing the precise number of service providers needed to avoid congestion at the lowest possible cost would therefore be the main concern. When there are more jobs than servers in a G/G/k queue, the cost incurred by the number of jobs per unit time becomes complex, making it challenging to determine the average cost. As a result, this paper obtains the bound for the ideal number of servers that would reduce the overall cost. Interpolation technique is used to determine the precise number of servers. When there are more servers (k) than job arrivals, the G/G/k queue's optimal cost per unit time during an execution cycle is obtained. The proposed system is made up of a G/G/k queue that begins operating as soon as the first job enters the system. Due to the general distribution of job arrivals, the time interval between subsequent job arrivals is not always the same. Therefore, the study of an arrival that causes a state transition in the system is taken into account. When there are fewer servers available than job arrivals, an expression is derived to determine the optimal server count. When the number of available servers exceeds the number of jobs in the system, the optimal number of jobs that minimises the average processing cost per unit time for one job is also determined. The simulation results are obtained by simulating this system with MATLAB's SimEvents toolbox.


Introduction
A G/G/k queue with k identical servers in parallel is considered.The FIFO discipline with non-Poisson inter-arrival process and the service time having any given distributions is taken for study.In particular, the service time distributions considered are Erlang, uniform and geometric.The Gamma distribution generalizes the Erlang distribution by allowing k to be any positive real number.Note that Erlang distribution gives the distribution of the sum of k identically independent servers each having exponential distribution.This study using Erlang distribution employs Kingman's relation to obtain average waiting time in the system.Using Little's law other relative measures to be easily calculated.
The cost function is also derived and the pattern is analysed.Optimal number of servers is also obtained.The SimEvents toolbox has been used to study the G/G/k queue when the arrival and service distributions both follow (i) uniform distribution and (ii) both follow geometric distribution.The uniform distribution employment in a G/G/k model is a rare phenomenon.If the job arrivals at a service centre is based on schedule(appointment) or a predefined interval then a uniform distribution will be apt.
The geometric distribution is most suitable to represent the scenario which occur with varying inter-arrival time when idle period is followed by sudden burst of arrival.The geometric distribution is capable of capturing infrequent arrivals during the inactive periods.The sudden burst of people during COVID in need of ventilator in hospital which otherwise is a rare phenomenon would be a case of interest in current times and hence geometric distribution is taken up for studying G/G/k queues employing SimEvents toolbox.
Waiting lines are very common in day-to-day phenomenon with irregular arrival patterns.This focusses the importance of general distribution to be incorporated in queues.Moreover, most of the industries are related to production of discrete number of spare parts.For smooth and efficient production control, backlog and shortage of these should be avoided.This leads to efficient queue management systems to be incorporated in design and analysis of production systems.Mainly in electronics and mechanical part industries.Modelling floor shops using queue allows one to manage multilevel inventory efficiently.This has been a source of motivation to deal with discrete event simulation using SimEvents tool box of MATLAB to analyse the proposed G/G/k queue in addition to simulation.
Geo/Geo/1/k queue finds potential application in communication systems, production systems, transportation systems and manufacturing systems.In [1] Goswami has studied Geo/Geo/1/k queueing system using (p, F)-policy and (q, N)-policy.The inter-relationship between the two policies in discrete event queues is studied.In [2], the author discusses discrete time Geo/G/1 queue in which the server operates a random threshold policy mainly (p, N)-policy.Using generating function techniques, the system state evaluation is analyzed and the long run average cost function per unit time is developed to determine the optimal values of p and N. Chaves et.al [3], provides a new closed-form approximation for a multiserver, single-channel queue with k identical servers in parallel, using only the mean and variance of the inter-arrival and service periods.The method avoids histogram-fitting and goodness-of-fit tests for input distributions.This novel approximation is tested in various settings and compared to simulation.Additionally, a new approximation is applied to a COVID-19 ventilator case study to explore its potential for optimizing server capacity.The approximation yields inaccuracies between 1-15% and up to 31% in extreme cases which is beneficial in fast-changing systems that require quick choices.
Grassman et.al [4] present an efficient approach for determining the arithmetic GI/G/1 queue's waiting and idle time distributions.They use the Wiener Hopf factorization, which is briefly reviewed.This method seems to perform well and is faster than equivalent methods in the literature.Uniform distribution inter-arrival and service times are used to compare queues.Yang et.al [5], examined F-policy G/G/c/K queueing system with generic starting times in his study.The authors created a simulation model using ARENA software to assess system performance measures in their study.They verified the efficacy of the proposed simulation model where numerous computer experiments are used for comparative comparison.They constructed a cost function and used the OptQuest tool in ARENA software to determine the optimal threshold F to minimize predicted cost per unit time.In [6] Azabeh et.al studied tandem queue with retrial and disaster.They also optimized the proposed G/G/k tandem queue.The study comprises of 5 dimensions which includes time and system penalty due to lost customer operated cost and number of uninterrupted services provided and cost incurred in lowering the disaster arrival rate.They maximize the throughput.The paper provides a G/G/k model to optimize a disaster retrial tandem queue employing discrete time simulation for the first time.[7] is a thesis in which chapter 3 illustrates a dynamic queue length model for processor sharing.Improving cloud application predictability contributes to the main aspect of the thesis.The use of G/G/1queues and the simulation environment reveal the importance and application of waiting lines in modelling cloud congestion.The analysis is also performed on processor sharing queueing discipline.
In section 2, the model description is discussed.Section 2.1 gives the expression to calculate the timetaken for completion of a cycle and in 2.2 the cost incurred during the cycle is discussed.In 2.3 the optimal number of servers is derived.Numerical analysis is done in Section 3 by using both SimEvents toolbox and analytical method.Section 4 gives the conclusion.

Description
The busy period of the proposed system consists of a G/G/k queue which is initiated with the arrival of the first job to the system.The system incurs a cost of C per unit time for a job in the system.The expression to obtain the optimum number of servers when the number of available servers is less than the number of job arrivals or vice versa is derived.The optimum value of the number of jobs that minimizes the average processing cost per unit time for one job when the number of available servers exceeds the job count in the system is also derived.Here, A(l), T(l) and C(l) denotes the unit cost per unit time, the time taken for the completion of one cycle and the cost incurred for completing one execution cycle respectively.

Case 1:
The arrival rate is assumed to be high enough so that all the servers are busy for a finite interval of time.

Time Taken for Completion of a Cycle T(l)
Let T(l) denote the starting time from the first job entering the system till the l th job finishes service and leaves the system.This interval of time includes sum of the time spent by the jobs in the system and the time gap between two successive arrivals to the system.Therefore,

E[T(k)] =kE[Tk] + [sum of the time gap between successive arrivals]
The service times are independent independent of the order of service.Hence the distribution of Tk is the same as that of the busy period of the system.The time gap between successive job arrivals is unpredictable as the job arrivals follow general distribution.For the computation of E[T(k)] an arrival to the system which causes a state transition is considered.Hence the time gap between successive arrivals and the time gap between state transitions is one and the same.A 'continuous time Markov chain' representation is provided for the proposed model.This is possible as there are only a finite number (k) of state transitions.The time for state change is considered to follow exponential distribution, the only continuous distribution with memoryless property."In a continuous parameter Markov chain, the time between successive state changes is mutually independent and exponentially distributed".Thus, during the busy period interval Tk there are k independent identically distributed stochastic variables.The sum of the stochastic variables follows an Erlang or Gamma distribution based on the time parameter t which is the required distribution given by This is obtained using successive approximation method with the parameters  and x.Therefore, The time taken for completion of one cycle is given by where SCV = 2 , SCV1 and SCV2 is the squared coefficient of variation of the job arrivals and the service rate respectively.This approximation is known as Kingman equation/relation between the general distributed queues and Erlang queues.

Cost Incurred During the Cycle C(k)
When there are l-k customers in the queue waiting to be served the idle time of the individual servers is zero.Total cost incurred is the sum of the cost due to the jobs in the system + cost due to the jobs waiting in the queue.The cost incurred during a cycle which starts with (l-k) in the queue and ends when (k-l), are the only jobs in the system where (l-k) < k is given by Ck.This condition gives rise to idle servers during a busy period.
If A(k) denotes average cost per unit time it is a function of k.Hence optimizing, k becomes complex.Therefore, the bound for the optimum number of servers that would minimize the total cost is obtained.The arrival and service rates of the G/G/k queue is assumed to be fixed.The optimum number of servers k is extracted from the cost function Tc(k)= Pk + C0N(k) where P is the cost per server per unit time, C0 holding cost per server per unit time and N(k) is the average number of jobs in the general distribution setup when there are s active servers.The product of the arrival rate and average waiting time of the arrival gives the average number of jobs in the setup N(k).
where L(k) is the average number of jobs in an M/M/k queuing system with k active servers.k is discrete.The method of finite differences is employed to get the bounds of Tc(k).

Case 2:
Here the available number of server's k is more than the job arrivals l.Then the number of idle servers is (k-l).The cost of processing a single job under the proposed setup is C, then C(l) = l C2+ cost due to idle period of the individual servers during a single cycle.C(l) is the cost incurred for one cycle of execution and C2 is the cost due to the idle period of one single server.Then we get Cost due to idle period of k-l servers =  (1 + 2 + ⋯ .+( − ) Therefore, the cost per unit of time on average when there is atleast one idle server is given by 3 Numerical Simulation

Simulation by SimEvents
A G/G/k queueing model is simulated in MATLAB using the SimEvents toolbox, with two distinct distribution options: uniform and geometric.When modelling irregular pattern of events, such as arrivals, the geometric distribution is a good choice because it captures the time between these irregular events.This is especially true in scenarios with inconsistent customer arrivals.The Uniform distribution, on the other hand, is defined by its minimum and maximum values and is appropriate for systems with relatively consistent variability in event occurrences.Hence the arrival variance and service variance are used in calculating the waiting time using SimEvents toolbox.In the case of geometric distribution, the first order moment mean is used for this purpose.This parameterization simplification can be especially useful when the precise arrival and service time distributions have not yet been determined, streamlining the simulation configuration within the SimEvents toolbox.Figure 1 illustrates the simulation conducted through SimEvents using a uniform distribution, while Figure 2 depicts the simulation employing a geometric distribution.The output of figure 1 has been summarized in table 1.It is observed that the utilization improves significantly as the waiting time decreases.Table 1 shows the improvement based on setting a time stop of up to 10000 seconds.The graph for uniform distribution is stable from 4000 seconds.When considering scenarios involving uniform arrival and service variances, the analysis of data depicted in Figures 3a and 3b reveals a unique observation: the fluctuation in average waiting times maintains a state of stability once the time span reaches the 4000-seconds.In contrast, using the geometric distribution produces a distinct pattern of growth resembling a step function.This growth, which contrasts sharply with the smoother behaviour of the uniform distribution, highlights the differences between these two models.
When the geometric mean of arrival and service times is taken into account, an interesting trend emerges.The progression of average waiting times takes a more gradual path, with stability appearing around 5000-seconds.It is important to note that, in this context, the uniform distribution model is the epitome of stability, exhibiting consistent performance that outperforms its geometric counterpart.

Analytical simulation
In order to do analytical simulations, we have utilised the Erlang distribution to represent the arrival and service times of the suggested G/G/k model.The Kingman relation is used for the analysis of the findings so that direct simulation can be performed.It has been found that the amount of inaccuracy that takes place is really insignificant.Thus, Kingman relation provides an easy and reliable solution in the study of G/G/k queues.Figure 4 demonstrates that the only time when the A(k) displays a sharp increase is when the number of servers surpasses 10 with  = 0.5 and  = 1 per unit time.Also, the graph of E[C(k)] illustrates a consistent trend of rising costs when the number of servers exceeds 10; more specifically, the slope of the graph becomes increasingly steep after n=10 in this graph.The mean number of servers showing maximum utilization ranges from two to four, with server two being heavily or largely utilised in the figure.In addition, E[C(k)] does not provide a significant amount of cost variance when the number of servers ranges from 2 to 4.

Conclusion
This study focuses on the complex domain of G/G/k queues, which represent multi-server queues.Applications for these configurations include CPU time optimisation, inventory, floor shop designs, and any discrete event process requiring an appointment.When arrivals are scheduled, uniform distribution functions are the optimal fit.Likewise, a geometric distribution is used to analyse an irregular arrival pattern.Literature reveals that most general distribution queues utilise Erlang for the proposed models.Consequently, the model proposed in this paper has considered these three distributions.Simulation techniques and SimEvents were used to graphically represent the result.It has been determined that costs rise as the number of servers exceeds 10.Future research on the model could focus on bulk arrivals employing vacation policies.

Fig. 1 .
Fig. 1.The Simulation Model G/G/k Queue with Uniform Arrival and Service Time Created in SimEvents.

Fig. 2 .
Fig. 2. The Simulation Model G/G/k Queue with Geometric Arrival and Service Time Created in SimEvents.

Fig. 4 .Fig. 5 .
Fig. 4. Average Cost in Relation to The Quantity of Servers

Table 1 .
The Improvement Based on Setting a Time Stop of up to 10000 Seconds