# RandomN-Policy Geo/G/1 Queue with Startup and Closedown Times

Authors: Tsung-Yin Wang
Journal: Journal of Applied Mathematics
 (2012)

---

## Abstract

This study investigates a randomN-policy Geo/G/1 queue with startup and closedown times. N is newly determined every time a new cycle begins. When random N customers are accumulated, the server is immediately turned on but is temporarily unavailable to the waiting customers. It needs a startup time before starting providing service. After all customers in the system are served exhaustively, the server is shut down by a closedown time. Using the generating function and supplementary variable technique, analytic solutions of system size, lengths of state periods, and sojourn time are derived.


---

## Body

## 1. Introduction

This paper deals with a randomN-policy Geo/G/1 queueing system in which the random variable N, the startup time, and the closedown time obey the general distributions, respectively. The system of turning on and turning off the server depends on the number N of customers in the queue.N is newly determined every time a new cycle begins. When the queue length reaches a random threshold N (N≥1), the server is instantly turned on but is temporarily unavailable to the waiting customers. The server needs the startup time before starting each of his service periods. Once the startup is over, the server immediately starts serving the waiting customers until the system is empty. As soon as the system becomes empty, the server also needs a closedown time to be shut down.It is assumed that the random thresholdN, service time B, startup time S,andclosedown time C are all general distributions with probability mass functions, means, variances and probability generating functions are as follows:
(1.1)Pr{N=i}=ni,i=1,2,…,E[N]=μN,Var[N]=σN2,E[zN]=N(z)=∑i=1∞nizi,|z|≤1;Pr{B=i}=bi,i=1,2,…,E[B]=μB,Var[B]=σB2,E[zB]=B(z)=∑i=1∞bizi,|z|≤1;Pr{S=i}=si,i=1,2,…,E[S]=μS,Var[S]=σS2,E[zS]=S(z)=∑i=1∞sizi,|z|≤1;Pr{C=i}=ci,i=1,2,…,E[C]=μC,Var[C]=σC2,E[zC]=C(z)=∑i=1∞cizi,|z|≤1.Interarrival timeA is a geometric distribution with parameter rate λ and the possible value of A is on the integers 1,2,…. In startup and closedown periods, the system allows the customers to enter the system to be served. At the instant of the end of closedown, if there are customers in the system, the service is immediately started without startup time. Arriving customers form a single waiting line based on first-come, first-served discipline. All customers arriving to the system are assumed to be served exhaustively. Furthermore, various stochastic processes are independent of each other.The controllable queueing systems possess its applications in wide fields such as manufacturing/production systems, communication networks, and computer systems. Because theN-policy is analytically easier than other policies, many researchers concentrated on this type of service policy. The N-policy M/G/1 queueing system has been well studied by many queueing researchers (see [1–4] and others). N-policy G//M/1 queues with the finite and infinite capacity have been studied by Ke and Wang [5], and Zhang and Tian [6], respectively. Some related studies on M/G/1 queueing system with a startup time have been reported (see [7–11], etc). Bisdikian [12] applied the decomposition property to derived queue size for a random N-policy M/G/1 queue in which N is a random variable. He also investigated the analytic solutions of waiting time for both the FIFO and LIFO service disciplines. On the other hand, various authors analysed queueing models under several combinations of server vacations and N-policy. The investigations of this type can be seen in [13–16]. Extending the combinations of server vacations and N-policy to server with startup can be found in [17, 18]. Recently, Arumuganathan and Jeyakumar [19] considered a bulk queue with multiple vacations, setup times with N-policy, and closedown times. After completing a service, if the queue length, N, is less than “a”, then the server performs closedown work and then takes vacations. The server returning from a vacation, if N is still less than “a”, then the server leaves for another vacation and so on, until N is greater than “b”. Ke [20] derived the distribution of various system characteristics for two different kinds of NT policy M/G/1 queueing system with breakdown, startup and closedown time. Recently, Choudhury et al. [21] investigated bulk arrival queue with N-policy by introducing a delay time for commencement of service after a breakdown. Each time a service is to start there should be at least N customers in the system. Kuo et al. [22] dealt with the optimal operation of the 〈p,N〉-policy M/G/1 queue with server breakdowns, general startup and repair times. When the number of customers in the system reaches N, turn the server on with probability p and leave the server off with probability (1-p). Such a system policy is called 〈p,N〉-policy. They developed system performance measures and provided an efficient procedure to determine the optimal threshold of (p,N) that minimized the total expected cost. Ke et al. [23] study the operating characteristics of an M[x]/G/1 queueing system withN-policy and at most J vacations.While many continuous time queueing systems withN-policy have been studied, their discrete time counterparts have received little attention in the literature. Takagi [24] derived the queue size and waiting time under the N-policy Geo/G/1 queue with batch arrival. Böhm and Mohanty [25] investigated N-policy for the Geo/Geo/1 queue involving batch arrival and batch service, respectively. Moreno [26] extended a modified N-policy issue, where the first N customers of each consecutive service period are served together and the rest of customers are served singly. She gave detailed derivations of system characteristics for a discrete time Geo/G/1 queue and developed a cost function to search the optimal operating N-policy at a minimum cost. Furthermore, Moreno [27] analyzed a discrete time single serve queue with a generalized N-policy and setup-closedown times. In [27], the author derived the formulae for various system performance measures, such as queue and system lengths, the expected length of the vacation, setup, and busy and closedown periods, and performed a numerical investigation on the expected cost function. Recently, Wang and Ke [28] discussed a discrete-time Geo/G/1 queue, in which if the customers are accumulated to N, the server operates a (p,N) policy.However, only very few works in the literature concerned withN-policy queueing systems with startup, and closedown time have been done. Especially, the researches of the discrete time N-policy queueing models with startup, and closedown time are really very rare. Moreover, in the past works of the N-policy, N is a fixed number except for Bisdikian [12]. To my best knowledge, the discrete time case of N-policy where is a random variable has never been studied. In the real situation, the server with startup and closedown times is a natural abstraction and the number N may vary depending on different instances of the operation of the system. For example, Streaming technique is used for compression of the audio/video files so they can be retrieved and played by remote viewers in real time. When a user wants to play video file and activates the streaming player, the streaming player will download and store the uncertain size of data (random N, N is newly determined every time for a new cycle beginning, depending the network bandwidth) in the buffer in advance before playing the data. The user can watch the video file before the entire video file has been downloaded. However, when the streaming player is activated for playing the video, it needs a short time to start up. It also needs a shutdown time to be closed as all received data has been played.The paper is structured as follows. In the next section, we formulate the system as an embedded three-dimensional Markov chain and provide the stationary joint distribution of system size and the server’s status. In Section3, the idle,startup, busy, and closedown periods are derived. In Section 4 the explicit forms for the mean waiting time of a customer in the system conditioned on the various states are obtained. The mean waiting time of a customer in the system is also obtained and this result confirms the Little’s formula. Section 5 gives the numerical aspects to illustrate the effect of the varying parameters on the expected length in the system.


## 2. Model Formulation and Stationary Distribution

In continuous time queues an arrival and a departure never happen simultaneously (i.e., the probability of an arrival and a departure occurring simultaneously is zero) hence the order of an arrival and a departure can be easily distinguishable. However, in discrete-time system, time is treated as a discrete variable (slot), and an arrival and a departure can only occur at boundary epochs of time slots (i.e., an arrival and a departure may occur concurrently in a slot). If we want to compute the number of customers in the system at time slotn and let it has a precise meaning, the order of the arrivals and departures must be stated. Whether an arrival or a departure is recorded into the number of customers in the system at time slot n, there are two different agreements: one is called the late arrival system (LAS) if a potential arrival occurs within (n-,n) and a potential departure occurs within (n,n+); the other is called the early arrival system (EAS) if a potential departure occurs within (n-,n) and a potential arrival occurs within (n,n+). These concepts and other related ones can be found in Takagi [24] and Hunter [29]. The event occurring in (n-,n) denotes the event occurring immediately before slot n boundary and the event occurring in (n,n+) denotes that it is occurring immediately after slot boundary. Figure 1 depicts time epochs for the LAS and the EAS. LAS has two variants: LAS with immediate access and LAS with delayed access. The difference between them is when a customer arrives late in the nth slot during the server which is free, the service is started in the nth slot (LAS with immediate access) or the service is started in the (n+1)st slot (LAS with delayed access). Because the management policy of LAS with immediate access has no obvious applications to computer and communication systems, we adopt the LAS policy with delayed access in the presented model and for any real number x∈[0,1], we denote x-=1-x. Figure 2 depicts time epochs under a natural extension of the LAS for the present model.Time epochs for the LAS and the EAS.
(a)
arrival epoch
(b)
departure epochFigure 2
Time epochs in the slotsn and n+1 under the LAS.LetΓn denote the server state at time n+:
(2.1)Γn={(0,j),iftheserverisidleandthethresholdisj,j≥1,1,iftheserverisundersetup,2,iftheserverisbusy,3,iftheserverisunderclosedown.And letγn be a supplementary random variable defined as follows:
(2.2)γn={remainingstartuptimeatn+,ifΓn=1,remainingservicetimeatn+,ifΓn=2,remainingclosedowntimeatn+,ifΓn=3.Let the random variableLn indicate the number of customers in the system at n+. The sequence of {(Γn,Ln,γn)} is a Markov chain whose state spaceis as follows:
(2.3){((0,j),k):j≥1,0≤k≤j-1}∪{(j,k,i):j=1,2,k≥1,i≥1}∪{(3,k,i):k≥0,i≥1}.Let us define the following limiting probabilities:(2.4)π~j,k=limn→∞Pr[Γn=(0,j),Ln=k],j≥1,0≤k≤j-1;π˙k,i=limn→∞Pr[Γn=1,Ln=k,γn=i],k≥1,i≥1;π¨k,i=limn→∞Pr[Γn=2,Ln=k,γn=i],k≥1,i≥1;π⃛k,i=limn→∞Pr[Γn=3,Ln=k,γn=i],k≥0,i≥1.The steady-state Kolmogorov equations are given by(2.5)π~j,k=λ-π~j,k+δ0,kλ-njπ⃛0,1+(1-δ0,k)λπ~j,k-1,j≥1,0≤k≤j-1;(2.6)π˙k,i=λsiπ~k,k-1+λ-π˙k,i+1+(1-δ1,k)λπ˙k-1,i+1,1≤k,i≥1;(2.7)π¨k,i=λbiπ¨k,1+(1-δ1,k)λπ¨k-1,i+1+λ-π¨k,i+1+λ-biπ¨k+1,1+(1-δ1,k)λbiπ˙k-1,1+λbiπ˙k,1+λ-biπ⃛k,1+λbiπ⃛k-1,1,k≥1,i≥1;(2.8)π⃛k,i=λ-π⃛k,i+1+δ0,kλ-ciπ¨1,1+λ(1-δ0,k)π⃛k-1,i+1,k≥0,i≥1,
where
(2.9)δa,b={1,ifa=b0,else.The left-hand sides in (2.5)–(2.8) represent the steady-state probabilities that states observed immediately after the current slot boundary changes to states observed immediately after the next slot boundary. For example, the left-hand side, π~j,k, of (2.5) denotes the probability from the current state transiting to the next state where the server is idle, the threshold is j and there are k customers in the system. It should be noted that the next state depends only on the current state. From the current state transiting to the next state, there are three cases. (a) Given the current state that the server is idle, the threshold is j, and there are k customers in the system, the probability of no customer arriving from the current state to the next state is λ-. The probability that the server is idle, the threshold is j, and there are k customers in the system at current state is π~j,k. Hence the joint probability is λ-π~j,k. (See the first term of right-hand side for (2.5)). (b) Given the current state that the server is during closedown period, there are nocustomers in the system, and the remaining closedown time is one slot at current, the probability that no customers arrive at the next state and the threshold is j is δ0,kλ-nj. The probability that the server is during closedown period, there are no customers in the system, and the remaining closedown time is one slot is π⃛0,1. Therefore, the joint probability is δ0,kλ-njπ⃛0,1. (See the second term of right-hand side for (2.5)). (c) Given the current state that the server is idle, there are k-1 customers in the system, and the threshold is j, the probability that a customer arrives from the current state to the next state is (1-δ0,k)λ. Hence the unconditional probability is (1-δ0,k)λπ~j,k-1. (See the third term of right-hand side for (2.5)). By using the similar approach, we can obtain (2.6)–(2.8) for denoting the next state that the server is startup, the next state that the server is busy, and the next state that the server is closedown, respectively.Define the following generating functions:(2.10)G0(z)=∑j=1∞π~j,0+∑j=2∞∑k=1j-1zkπ~j,k,G1(x,z)=∑k=1∞∑i=1∞zkxiπ˙k,i,φ1(z)=∑k=1∞zkπ˙k,1,G2(x,z)=∑k=1∞∑i=1∞zkxiπ¨k,i,φ2(z)=∑k=1∞zkπ¨k,1,G3(x,z)=∑k=0∞∑i=1∞zkxiπ⃛k,i,φ3(z)=∑k=0∞zkπ⃛k,1,
where |z|≤1 and |x|≤1.From (2.5), when j≥1 and k=0, we have
(2.11)π~j,0=λ-njλπ⃛0,1,j≥1,∑j=1∞π~j,0=λ-λπ⃛0,1.Forj≥2 and 1≤k≤j-1 in (2.5) it yields that
(2.12)π~j,k=π~j,k-1,j≥2,1≤k≤j-1.From (2.11) and (2.12), we get
(2.13)π~j,k=λ-njλπ⃛0,1,j≥1,0≤k≤j-1.Hence, the generation function of an idle server is given by(2.14)G0(z)=∑j=1∞π~j,0+∑j=2∞∑k=1j-1zkπ~j,k=λ-(1-N(z))λ(1-z)π⃛0,1.Multiplying (2.6) by zk and summing over k after multiplying (2.6) by xi and summing over i, we obtain
(2.15)x-(λ-+λz)xG1(x,z)=λ-N(z)S(x)π⃛0,1-(λ-+λz)φ1(z).Applying the same procedure to (2.7) and (2.8), respectively, we obtain
(2.16)x-(λ-+λz)xG2(x,z)=(λ-+λz)(B(x)-z)zφ2(z)+B(x)[(λ-+λz)(φ1(z)+φ3(z))-λ-(π¨1,1+π⃛0,1)],(2.17)x-(λ-+λz)xG3(x,z)=-(λ-+λz)φ3(z)+λ-C(x)π¨1,1.Insertingx=λ-+λz in (2.15), (2.16), and (2.17) yields
(2.18)φ1(z)=λ-N(z)S(λ-+λz)(λ-+λz)π⃛0,1,(2.19)φ2(z)=zB(λ-+λz)[(λ-+λz)(φ1(z)+φ3(z))-λ-(π¨1,1+π⃛0,1)](λ-+λz)[z-B(λ-+λz)],(2.20)φ3(z)=λ-C(λ-+λz)λ-+λzπ¨1,1,(2.21)G1(x,z)=xλ-N(z)(S(x)-S(λ-+λz))x-(λ-+λz)π⃛0,1,(2.22)G2(x,z)=xz(B(x)-B(λ-+λz))[x-(λz+λ-)](z-B(λ-+λz))[(λ-+λz)(φ1(z)+φ3(z))-λ-(π¨1,1+π⃛0,1)],(2.23)G3(x,z)=xλ-(C(x)-C(λ-+λz))x-(λ-+λz)π¨1,1.Settingz=0 in (2.20) and φ3(z)=∑k=0∞zkπ⃛k,1 yields
(2.24)π¨1,1=π⃛0,1C(λ-).Substituting (2.18), (2.20), and (2.24) into (2.22) and (2.23) yields
(2.25)G2(x,z)=λ-xz(B(x)-B(λ-+λz))[x-(λ-+λz)](z-B(λ-+λz))[N(z)S(λ-+λz)+C(λ-+λz)-1C(λ-)-1]π⃛0,1,(2.26)G3(x,z)=xλ-(C(x)-C(λ-+λz))(x-(λ-+λz))C(λ-)π⃛0,1.LetL denote the system size. Following (2.14), (2.21), (2.25) and (2.26), the probability generating function (p.g.f.) is given by
(2.27)L(z)=λ-B(λ-+λz)(1-N(z)S(λ-+λz)-((C(λ-+λz)-1)/C(λ-)))λ(B(λ-+λz)-z)π⃛0,1.


### 2.1. The Derivation ofπ⃛0,1

Using the normalization condition,L(1)=1, yields
(2.28)π⃛0,1=λ(1-ρ)λ-(μN+λμS+(λμC/C(λ-))),
where ρ=λμB.Substituting (2.28) into (2.27) gives
(2.29)L(z)=Lo(z)×1-N(z)S(λ-+λz)-((C(λ-+λz)-1)/C(λ-))(1-z)(μN+λμS+(λμC/C(λ-))),
where Lo(z) is the p.g.f. of the system size in the classical Geo/G/1 queue and
(2.30)Lo(z)=(1-ρ)(1-z)B(λ-+λz)B(λ-+λz)-z.


### 2.2. Stationary Distribution of the Server State

Let us define the following:P0≡
the probability that the server is idle;P1≡ the probability that the server is startup;P2≡ the probability that the server is turned on (working);P3≡ the probability that the server is shut down;Pempty≡ the probability that the system is empty.Substituting (2.28) into (2.14), (2.21), (2.25), and (2.26) yields
(2.31)P0=G0(1)=(1-ρ)μNμN+λμS+(λμC/C(λ-)),(2.32)P1=G1(1,1)=λ(1-ρ)μSμN+λμS+(λμC/C(λ-)),(2.33)P2=G2(1,1)=ρ,(2.34)P3=G3(1,1)=λμC(1-ρ)C(λ-)(μN+λμS+(λμC/C(λ-))).Settingx=1 and z=0 in G3(x,z)=∑k=0∞∑i=1∞zkxiπ⃛k,i and using (2.26) yield
(2.35)∑i=1∞π⃛0,i=λ-(1-C(λ-))λC(λ-)π⃛0,1.Hence, the probability that the system is empty is given by(2.36)Pempty=∑j=0∞π~j,0+∑i=1∞π⃛0,i=(1-ρ)C(λ-)(μN+λμS+(λμC/C(λ-))).


### 2.3. The Expected System Size

DifferentiatingL(z) in (2.29) and setting z=1, we note that the numerator and denominator are both 0. Based on L’Hospital’s rule twice, the expected system size is given by
(2.37)E[L]=ρ+λ2σB2+ρ2-λρ2(1-ρ)+(σN2+μN2-μN)+2λμNμS+λ2(σS2+μS2-μS+((σC2+μC2-μC)/C(λ-)))2(μN+λμS+(λμC/C(λ-))),
where ρ+((λ2σB2+ρ2-λρ)/2(1-ρ)) is the expected system size in the system for the classical Geo/G/1 queue.


## 2.1. The Derivation ofπ⃛0,1

Using the normalization condition,L(1)=1, yields
(2.28)π⃛0,1=λ(1-ρ)λ-(μN+λμS+(λμC/C(λ-))),
where ρ=λμB.Substituting (2.28) into (2.27) gives
(2.29)L(z)=Lo(z)×1-N(z)S(λ-+λz)-((C(λ-+λz)-1)/C(λ-))(1-z)(μN+λμS+(λμC/C(λ-))),
where Lo(z) is the p.g.f. of the system size in the classical Geo/G/1 queue and
(2.30)Lo(z)=(1-ρ)(1-z)B(λ-+λz)B(λ-+λz)-z.


## 2.2. Stationary Distribution of the Server State

Let us define the following:P0≡
the probability that the server is idle;P1≡ the probability that the server is startup;P2≡ the probability that the server is turned on (working);P3≡ the probability that the server is shut down;Pempty≡ the probability that the system is empty.Substituting (2.28) into (2.14), (2.21), (2.25), and (2.26) yields
(2.31)P0=G0(1)=(1-ρ)μNμN+λμS+(λμC/C(λ-)),(2.32)P1=G1(1,1)=λ(1-ρ)μSμN+λμS+(λμC/C(λ-)),(2.33)P2=G2(1,1)=ρ,(2.34)P3=G3(1,1)=λμC(1-ρ)C(λ-)(μN+λμS+(λμC/C(λ-))).Settingx=1 and z=0 in G3(x,z)=∑k=0∞∑i=1∞zkxiπ⃛k,i and using (2.26) yield
(2.35)∑i=1∞π⃛0,i=λ-(1-C(λ-))λC(λ-)π⃛0,1.Hence, the probability that the system is empty is given by(2.36)Pempty=∑j=0∞π~j,0+∑i=1∞π⃛0,i=(1-ρ)C(λ-)(μN+λμS+(λμC/C(λ-))).


## 2.3. The Expected System Size

DifferentiatingL(z) in (2.29) and setting z=1, we note that the numerator and denominator are both 0. Based on L’Hospital’s rule twice, the expected system size is given by
(2.37)E[L]=ρ+λ2σB2+ρ2-λρ2(1-ρ)+(σN2+μN2-μN)+2λμNμS+λ2(σS2+μS2-μS+((σC2+μC2-μC)/C(λ-)))2(μN+λμS+(λμC/C(λ-))),
where ρ+((λ2σB2+ρ2-λρ)/2(1-ρ)) is the expected system size in the system for the classical Geo/G/1 queue.


## 3. The Idle, Startup, Busy, and Closedown Periods

This section studies the idle, startup, busy, and closedown periods. An idle period starts at the departure instant of a customer which leaves the system empty and terminates when accumulated customers reachN, where N may be 1,2,… with probability Pr{N=j}=nj. A startup period begins at the end of an idle period and terminates at the beginning of a service. A busy period starts at the beginning of a service and terminates when a service is completed and the system is empty. A closedown period begins at the end of a busy period and ends at the completion of closedown time.Define the following:Q0≡ the length of an idle period;Q1≡ the length of a startup period;Q2≡ the length of a busy period;Q3≡ the length of a closedown period.


### 3.1. The Idle Period

According to the definition, the p.g.f. ofQ0 is given by
(3.1)Q0(x)=∑k=1∞∑ℓ=1∞nkCk-1ℓ-1λkλ-ℓ-kxℓ=∑k=1∞nk(λx1-λ-x)k=N(λx1-λ-x),
and the mean length of idle period is
(3.2)E[Q0]=μNλ.


### 3.2. The Startup Period

Next, we derive the startup period. A startup period is the amount of time to start up the server and ends when the startup expires. The p.g.f. and mean length ofQ1 are given by Q1(x)=S(x) and
(3.3)E(Q1)=μS.


### 3.3. The Busy Period

LetΨ(z) be the p.g.f. of busy period of classical Geo/G/1 with late arrival delay access. From Takagi [24], we have Ψ(z)=B(λzΨ(z)+λ-z). To derive the p.g.f. of the length of the busy period for the present model, we consider the following.Case 1.
The probability that there arek arrivals at the end of idle period and the server is ready to serve is nk, k=1,2,…. The p.g.f. for the length of the busy period extended by these k arrivals is
(3.4)Φ(z)=∑k=1∞nk∑j=1∞bjzj∑ℓ=0jCℓjλℓλ-j-ℓ(Ψ(z))ℓ+k-1=N(Ψ(z)).Case 2.
The p.g.f. for the number of arrivals that arrive during startup time isS(λ-+λz). Therefore, the p.g.f. for the length of the busy period extended by these arrivals is S(λ-+λΨ(z)).Case 3.
The p.g.f. for the number of arrivals that arrive during a closedown period with arrivals is given by(C(λ-+λz)-C(λ-))/(1-C(λ-)) and the number of closedowns in a cycle obeys the geometric distribution with parameter C(λ-). Therefore, we can obtain the p.g.f. for the number of customers that arrive during the closedown period with arrivals:
(3.5)∑k=1∞(C(λ-+λz)-C(λ-)1-C(λ-))k-1C(λ-)(1-C(λ-))k-1=C(λ-)1-C(λ-+λz)+C(λ-).
Consequently, the p.g.f. for the length of the busy period extended by these arrivals is given by(3.6)C(λ-)1-C(λ-+λΨ(z))+C(λ-).Because the arrivals in idle period, startup period, busy period and closedown period are independent. Hence, the p.g.f. for the length of the busy period is given by(3.7)Q2(z)=N(Ψ(z))×S(λ-+λΨ(z))×C(λ-)1-C(λ-+λΨ(z))+C(λ-),
and the mean length is
(3.8)E[Q2]=(μN+λμS+(λμC/C(λ-)))μB1-ρ.


### 3.4. The Closedown Period

The probabilities of no customer and at least one customer in the system at the completion of a closedown areC(λ-) and 1-C(λ-), respectively. This process is Bernoulli process. Hence, the distribution of the number of shutdowns in a cycle is a geometric distribution with parameter C(λ-). Besides, the p.g.f. for the length of a shutdown time is C(x). Consequently, the p.g.f. of Q3 is given by
(3.9)Q3(x)=∑k=1∞(C(x))k×C(λ-)(1-C(λ-))k-1=C(λ-)C(x)1-C(x)(1-C(λ-)),
and the mean length of Q3 is given by
(3.10)E[Q3]=μCC(λ-).From (3.2), (3.3), (3.8), and (3.10), the mean length of the service cycle, Q, is given by
(3.11)E[Q]=E[Q0]+E[Q1]+E[Q2]+E[Q3]=μN+λμS+(λμC/C(λ-))λ(1-ρ).


## 3.1. The Idle Period

According to the definition, the p.g.f. ofQ0 is given by
(3.1)Q0(x)=∑k=1∞∑ℓ=1∞nkCk-1ℓ-1λkλ-ℓ-kxℓ=∑k=1∞nk(λx1-λ-x)k=N(λx1-λ-x),
and the mean length of idle period is
(3.2)E[Q0]=μNλ.


## 3.2. The Startup Period

Next, we derive the startup period. A startup period is the amount of time to start up the server and ends when the startup expires. The p.g.f. and mean length ofQ1 are given by Q1(x)=S(x) and
(3.3)E(Q1)=μS.


## 3.3. The Busy Period

LetΨ(z) be the p.g.f. of busy period of classical Geo/G/1 with late arrival delay access. From Takagi [24], we have Ψ(z)=B(λzΨ(z)+λ-z). To derive the p.g.f. of the length of the busy period for the present model, we consider the following.Case 1.
The probability that there arek arrivals at the end of idle period and the server is ready to serve is nk, k=1,2,…. The p.g.f. for the length of the busy period extended by these k arrivals is
(3.4)Φ(z)=∑k=1∞nk∑j=1∞bjzj∑ℓ=0jCℓjλℓλ-j-ℓ(Ψ(z))ℓ+k-1=N(Ψ(z)).Case 2.
The p.g.f. for the number of arrivals that arrive during startup time isS(λ-+λz). Therefore, the p.g.f. for the length of the busy period extended by these arrivals is S(λ-+λΨ(z)).Case 3.
The p.g.f. for the number of arrivals that arrive during a closedown period with arrivals is given by(C(λ-+λz)-C(λ-))/(1-C(λ-)) and the number of closedowns in a cycle obeys the geometric distribution with parameter C(λ-). Therefore, we can obtain the p.g.f. for the number of customers that arrive during the closedown period with arrivals:
(3.5)∑k=1∞(C(λ-+λz)-C(λ-)1-C(λ-))k-1C(λ-)(1-C(λ-))k-1=C(λ-)1-C(λ-+λz)+C(λ-).
Consequently, the p.g.f. for the length of the busy period extended by these arrivals is given by(3.6)C(λ-)1-C(λ-+λΨ(z))+C(λ-).Because the arrivals in idle period, startup period, busy period and closedown period are independent. Hence, the p.g.f. for the length of the busy period is given by(3.7)Q2(z)=N(Ψ(z))×S(λ-+λΨ(z))×C(λ-)1-C(λ-+λΨ(z))+C(λ-),
and the mean length is
(3.8)E[Q2]=(μN+λμS+(λμC/C(λ-)))μB1-ρ.


## 3.4. The Closedown Period

The probabilities of no customer and at least one customer in the system at the completion of a closedown areC(λ-) and 1-C(λ-), respectively. This process is Bernoulli process. Hence, the distribution of the number of shutdowns in a cycle is a geometric distribution with parameter C(λ-). Besides, the p.g.f. for the length of a shutdown time is C(x). Consequently, the p.g.f. of Q3 is given by
(3.9)Q3(x)=∑k=1∞(C(x))k×C(λ-)(1-C(λ-))k-1=C(λ-)C(x)1-C(x)(1-C(λ-)),
and the mean length of Q3 is given by
(3.10)E[Q3]=μCC(λ-).From (3.2), (3.3), (3.8), and (3.10), the mean length of the service cycle, Q, is given by
(3.11)E[Q]=E[Q0]+E[Q1]+E[Q2]+E[Q3]=μN+λμS+(λμC/C(λ-))λ(1-ρ).


## 4. Sojourn Time in the System

When a customer enters a service system, one of his most concerning issues is his sojourn time in the system. The sojourn time in the system of an arrival depends on the server status at the arrival epoch. Let us define the following p.g.f.s:W0(z∣idle)≡ the p.g.f. of the sojourn time in the system of a customer (that arrives at an arbitrary slot) conditioning that the server state is idle;W1(z∣startup)≡ the p.g.f. of the sojourn time in the system of a customer (that arrives at an arbitrary slot) conditioning that the server state is startup;W2(z∣busy)≡ the p.g.f. of the sojourn time in the system of a customer (that arrives at an arbitrary slot) conditioning that the server state is busy;W3(z∣closedown)≡ the p.g.f. of the sojourn time in the system of a customer (that arrives at an arbitrary slot) conditioning that the server state is closedown;W(z)≡ the unconditional p.g.f. of the sojourn time in the system of a customer (that arrives at an arbitrary slot).There are four situations of the server at the epoch of a tagged arrival.Case 1.
Suppose the server is idle will go into startup state ifj customers are accumulated in the queue. A tagged customer arrives and finds k customers (k≥0) in the system at that moment the server is idle. The sojourn time in the system of this tagged customer consists of (i) the time of waiting j-k-1 arrivals for the server going into startup state; (ii) the startup time; (iii) the total service time of the preceding k customers; (iv) the service time of the tagged customer:
(4.1)W0(z∣idle)=1P0∑j=1∞∑k=0j-1π~j,k(λz1-λ-z)j-1-kS(z)(B(z))k+1=λ-S(z)B(z)(1-λ-z)(N(λz/(1-λ-z))-N(B(z)))λP0[λz-(1-λ-z)B(z)]π⃛0,1.Case 2.
A tagged customer arrives during startup period and findsk (k≥1) customers in the system. The tagged customer’s sojourn time in the system is the remaining startup time plus the service time of the k+1 (including himself) customers:
(4.2)W1(z∣startup)≡1P1∑k=1∞∑i=1∞π˙k,izi-1[B(z)]k+1=λ-B(z)N(B(z))(S(z)-S(λ-+λB(z)))P1[z-(λ-+λB(z))]π⃛0,1.Case 3.
A tagged customer arrives while the server is busy and findsk customers in the system. In this case, his sojourn time in the system consists of (i) the remaining service time of the customer being served; (ii) the service time of the k customers (including himself). Hence, we have
(4.3)W2(z∣busy)=∑k=1∞∑i=1∞π¨k,izi-1[B(z)]kP2=λ-B(z){N(B(z))S(λ-+λB(z))+[(C(λ-+λB(z))-1)/C(λ-)]-1}P2[z-(λ-+λB(z))]π⃛0,1.Case 4.
A tagged customer arrives while the server is during the closedown period and findsk (k≥0) customers in the system. In this case, the sojourn time in the system of the customer consists of the remaining closedown time, and the service time of the k+1 customers:
(4.4)W3(z∣closedown)≡1P3∑k=0∞∑i=1∞π⃛k,izi-1[B(z)]k+1=λ-B(z)(C(z)-C(λB(z)+λ-))P3(z-(λB(z)+λ-))C(λ-)π⃛0,1.By unconditioning (4.1)–(4.4), the sojourn time in the system of an arbitrary customer is given by
(4.5)W(z)=P0W0(z∣idle)+P1W1(z∣startup)+P2W2(z∣busy)+P3W3(z∣closedown)=[S(z)(1-λ-z)(N(λz/(1-λ-z))-N(B(z)))λ[λz-(1-λ-z)B(z)]+N(B(z))S(z)+((C(z)-1)/C(λ-))-1[z-(λ-+λB(z))]]λ-B(z)π⃛0,1.Finally, we obtain(4.6)W(z)=Wq(z)×B(z),
where
(4.7)Wq(z)={S(z)(1-λ-z)(N(λz/(1-λ-z))-N(B(z)))λ[λz-(1-λ-z)B(z)]+(N(B(z))S(z)+((C(z)-1)/C(λ-))-1)[z-(λ-+λB(z))]}λ-π⃛0,1
is the p.g.f. of the customer’s waiting time in the queue.From (4.6), the expected sojourn time in the system is given by
(4.8)E[W]=μB+λ(σB2+μB2)-ρ2(1-ρ)+[((σN2+μN2-μN)/λ)+2μNμS+λ(σS2+μS2-μS+((σC2+μC2-μC)/C(λ-)))]2(μN+λμS+(λμC/C(λ-)))
which is in accordance with E[L]/λ and this result confirms Little’s formula.


## 5. Numerical Examples

In this section, we present some numerical examples to compare the mean length in the system of the presented model with respect to no startup, no closedown, and both no startup and no closedown. From (2.37), we can easily obtain the mean lengths in the system with no startup, no closedown, and both no startup and no closedown as follows:(i)
no startup:(5.1)ρ+λ2σB2+ρ2-λρ2(1-ρ)+(σN2+μN2-μN)+λ2((σC2+μC2-μC)/C(λ-))2(μN+(λμC/C(λ-)));(ii)
no closedown:(5.2)ρ+λ2σB2+ρ2-λρ2(1-ρ)+(σN2+μN2-μN)+2λμNμS+λ2(σS2+μS2-μS)2(μN+λμS);(iii)
no startup and no closedown:(5.3)ρ+λ2σB2+ρ2-λρ2(1-ρ)+(σN2+μN2-μN)2μN.We assume that the startup time and the closedown time are geometric distributions with parameter rates 0.4 and 0.5, respectively, and consider the following four cases. For convenience, if a randomX has a geometric distribution with parameter β, we denote X~Geo(β). Similarly, if a random X has a discrete uniform distribution on the integers from β1 to β2, we denote X~Du(β1,β2).Case 1.
Letλ=0.3, N~Du(1,5), and B~Geo(α) the values of the parameter α vary from 0.52 to 096 by the increment 0.04.Case 2.
Letλ=0.3, N~Geo(0.3), and B~Geo(α) the values of the parameter α vary from 0.52 to 096 by the increment 0.04.Case 3.
LetN~Du(1,5), B~Geo(0.7), and vary the values of λ from 0.3 to 0.5 by the increment 0.02.Case 4.
LetN~Geo(0.3), B~Geo(0.7), and vary the values of λ from 0.3 to 0.5 by the increment 0.02.Cases1–4 are depicted in Figures 3–6, respectively. Figures 3 and 4 display that the mean length in the system decreases in service rate and Figures 5–6 display that the mean length in the system increases in arrival rate. In Figure 3 (also see Figure 5), the mean length in the system with startup and closedown is always greater than the mean length in the system with no startup and no closedown. But in Figure 4 (also see Figure 6), the mean length in the system with no startup and no closedown is always greater than the mean length in the system with no startup. This is because we choose the different threshold distributions. Because the server needs a startup time before starting to serve customers, the startup time will increase number of customers in the system. Moreover,  the system allows the customers to enter the system in closedown period and the server immediately serves the customers in the system without startup time. Comparing it with the system with no startup time and no closedown, it is efficient in decreasing the customers in the system. Hence, we observe the phenomenon that the mean length in the system without closedown is greater than the others and the mean length in the system without startup is smaller than the others.Figure 3
Plot of mean length in the system versus service rate withλ=0.3, N~Du(1,5), S~Geo(0.4), C~Geo(0.5), and B~Geo(α), the values of service rate α varying from 0.52 to 096 by the increment 0.04.Figure 4
Plot of mean length in the system versus service rate withλ=0.3, N~Geo(0.3), S~Geo(0.4), C~Geo(0.5), and B~Geo(α), the values of service rate α varying from 0.52 to 096 by the increment 0.04.Figure 5
Plot of mean length in the system versus arrival rate withN~Du(1,5), S~Geo(0.4), B~Geo(0.7), and C~Geo(0.5), the values of arrival rate λ varying from 0.3 to 0.5 by the increment 0.02.Figure 6
Plot of mean length in the system versus arrival rate withN~Geo(0.3), S~Geo(0.4), C~Geo(0.5), and B~Geo(0.7), the values of arrival rate λ varying from 0.3 to 0.5 by the increment 0.02.


## 6. Conclusions

In this work, we investigated a randomN-policy Geo/G/1 queue with startup and closedown times. The analytical results of mean lengths of the system size, idle period, startup period, busy period, and closedown period were derived. The most careful thing of a customer entering a service system, his sojourn time in the system, is also derived. We obtained the steady-state distributions of the waiting time of a customer in the system conditioned on the various states. The analytic solution of unconditional mean waiting time was also obtained and the result showed that Little’s formula still holds.



---

*Source: 793801-2012-11-10.xml*