Diffusion Limits for Shortest Remaining Processing Time Queues with Multiple Customer Types

We consider a single-server queueing system with multiple customer types having bounded processing times in which users are scheduled according to the Shortest Remaining Processing Time (SRPT) discipline, with First In First Out (FIFO) as the tie-breaker. We assume that the processing times of jobs arriving in the system are bounded. We use probabilistic methods to find, under typical heavy traffic assumptions, a suitable approximation of the workload and queue length processes after a long time has passed and show that these processes are divided among the customer classes according to specific proportions, depending on their arrival rates and distributions of initial service times. Our results are confirmed by simulations.


I. INTRODUCTION
T HE SHORTEST Remaining Processing Time (SRPT)   service protocol assigns preemptive priority to the task with the smallest residual service time.It started gaining interest after Schrage had proved in [24] that it minimized the number of jobs in a single-server system.SRPT is also well known in queueing theory for minimizing the mean response time (Schrage and Miller [18]).Since then, its properties have been widely studied.Schreiber provides a summary of early work on SRPT in [25].More recent research of this protocol includes investigating fairness (e.g., Wierman and Harchol-Balter [27]) or tail behavior (Núñez-Queija [19], Nuyens and Zwart [20]).In [12], Gromoll, Kruk and Puha prove, under typical heavy traffic assumptions, a diffusion limit theorem for a measure-valued state descriptor.Another approach, approximating SRPT by the Earliest Deadline First (EDF), leads to the same result (with a slight loss of generality) in [16].The follow-up research on this topic includes obtaining diffusion limits under nonstandard spatial scaling by Puha [23] and limits for queues with heavy tailed service time distributions by Banerjee, Budhiraja and Puha in [4].Moreover, Atar, Biswas, Kaspi and Ramanan presented in [3] a unified framework for analyzing single server queueing systems under various service protocols, including SRPT.Some authors discussed the possibility of implementing the SRPT policy in practice.The main factor impeding it is its unfairness, which could potentially lead to a few tasks having much greater response times (so-called "starving").However, it has been noted in many works that large jobs are only negligibly penalized at most.For example, Agrawal, Bansal, Harchol-Balter and Schroeder in [1] and [2] propose a method of improving the performance of Web servers by implementing SRPT-based scheduling.Another study by Harchol-Balter and Schroeder ( [14]) presents the possibility of a great improvement of the performance of a Web server by changing the traditional fair scheduling policy to SRPT.There are also more recent papers concerning this topic.For example, [6] describes a way of improving the default Linux scheduler by using the existing CFS (Completely Fair Scheduler) and FIFO schedulers to approximate SRPT.
Recent studies suggest that the SRPT protocol performs well in the case of multiserver systems with a single queue.Grosof, Scully and Harchol-Balter proved in [13] that the mean response in the M/G/k queue under the SRPT discipline is asymptotically optimal in the heavy-traffic limit.Dong and Ibrahim ([8]) considered the multiserver M/G/k+G queue with impatient customers with the SRPT protocol and showed that in this setting, SRPT asymptotically maximizes the system throughput among all scheduling disciplines.However, it was also shown that the SRPT protocol can behave suboptimally in multiclass queueing networks to the extent of rendering the queueing system unstable ( [7]).
Another related field of research involves studying resource sharing networks under the SRPT service discipline.In [10], [11], a notion of minimality, related to maximizing the corresponding cumulative transmission time with respect to jobs with residual service time not greater than a given threshold, was introduced and it was shown that SRPT is minimal in this sense.Moreover, in [11], another optimality criterion, local edge minimality, was proposed and it was proved that it characterizes a certain subclass of SRPT disciplines, named strong SRPT protocols.
This paper focuses on a single-server queueing system with multiple customer classes.Previous research on this topic includes the work of Peterson ([21]) concerning heavy-traffic limit theorems for queueing networks with multiple customers classes divided into two types: high-priority ones having a preemptive priority over low-priority ones, with customers within each of these types served according to the FIFO policy.In [17], Kruk and Sokołowska establish a fluid limit theorem for a single-server queueing model with K classes of customers, served according to the SRPT protocol, with FIFO used as the tie-breaker.
In this paper, we extend the analysis of [12] and prove a diffusion limit theorem for a multidimensional measurevalued state descriptor Z(t) defined in Section II, under usual heavy traffic assumptions.More precisely, we first describe a stochastic model for a single-server queuing system with multiple customer classes.We focus on the case of bounded service times of jobs arriving in the system.In order to obtain a diffusion limit, we consider a sequence of such models and apply diffusion scaling as in (1) to follow.We make typical heavy traffic assumptions, as detailed in Section III.The main results of this paper are Theorems 1 and 2. They enable us to easily obtain results for the corresponding workload and queue length processes.This method gives us a way to approximately predict the proportions between the workloads (and queue lengths) of the customer classes in the long run.
The paper is organized as follows.In the second section, we present the mathematical model of the queueing system outlined above and introduce stochastic processes describing its state.In the third section, we introduce a sequence of such models and describe the necessary assumptions.In Sections IV and V, we state and prove the main theorems of this paper.In Section VI, we provide a brief overview of computer simulations illustrating our results.We also define the function χ(x) = x, x ∈ R + .For a function g : R + → R and T > 0, let ∥g∥ T = sup{|g(t)| : 0 ≤ t ≤ T } and ∥g∥ ∞ = sup{|g(t)| : t ≥ 0}.

Let
For a vector a = (a 1 , ..., a K ), with either real or measurevalued elements, by a Σ we denote K i=1 a i , unless stated otherwise, where it is a weighted sum.The same notation is used for vector-valued processes.
Let M denote the set of finite, nonnegative measures on ), respectively.Moreover, we will write µ(x) instead of µ({x}) to denote the measure of a singleelement set {x}.For ξ ∈ M and a Borel measurable function g : R + → R that is integrable with respect to ξ, define ⟨g, ξ⟩ = R+ g(x)ξ(dx).
The set M is endowed with the weak topology, that is, for ξ n , ξ ∈ M, we have ξ n w → ξ if and only if ⟨g, ξ n ⟩ → ⟨g, ξ⟩ as n → ∞ for all bounded, continuous real functions g on R + .
With this topology, M is a Polish space ( [22]).We denote the zero measure in M by 0 and the measure in M that puts one unit of mass at a point x ∈ R + by δ x .For x ∈ R + , the measure δ + x is δ x if x > 0 and 0 otherwise.Let M 0 denote the set of those elements of M that do not charge the origin and have a finite first moment.
We use " d = " for equality in distribution, " → " to denote the convergence of finite-dimensional distributions of stochastic processes and " ⇒ " to denote convergence in distribution of random elements of a metric space.All stochastic processes used in this paper are assumed to have paths that are right continuous with finite left limits (r.c.l.l.).For a Polish space S, we denote by D([0, ∞), S) the space of r.c.l.l.functions from [0, ∞) into S, endowed with the Skorohod J 1 metric d x(s).

II. STOCHASTIC MODEL FOR AN SRPT QUEUE
The queueing model considered here consists of one server and K job types.Let K = {1, ..., K}.The stochastic model involves a random initial condition (Z(0), S x , x > 0), describing the system at time zero, together with a measurevalued state descriptor Z = (Z k , k ∈ K) specifying the time evolution of the system.

A. Initial condition
The initial condition for each class k ∈ K consists of the number Z k (0) of class k jobs in the queue at time zero, the initial service time for each class k job, and the functions describing the order in which the initial jobs with the same initial service time complete service.
Assume that Z k (0) is a nonnegative integer-valued and finite almost surely random variable for each k ∈ K. Initial service times for each class k are given by the sequence {ṽ j k } j∈N of strictly positive, finite random variables.The initial job with service time ṽj k , j ≤ Z k (0), is called job j for class k.The state of the system will be described by a counting measure with unit masses at the service times of the jobs present in the system.More formally, for k ∈ K we define the initial random measure Z k (0) ∈ M by For every x > 0 the number of initial jobs with initial service time x that are served to completion once t units of time have been devoted to their service is ⌊t/x⌋ ∧ k∈K Z k (0)(x).
Here we introduce processes S x k , k ∈ K, that dictate how much service is allocated across classes.In particular, let S x k (t) be the number of initial class k jobs with initial service time x that have left the system by the time that the server has devoted t units of time solely to serving jobs with this initial service time.We assume that the random functions S x k (t) satisfy the following consistency conditions: 1) S x k (0) = 0, The system (Z(0), S x , x > 0), where S x = (S x 1 , ..., S x K ), will be called the initial condition.

B. Stochastic primitives
Let E k be the exogenous arrival process for class k ∈ K.For t ≥ 0, E k (t) is the number of class k arrivals to the system in the time interval (0, t].For each k it is a (possibly delayed) renewal process with rate α k > 0 such that the interarrival times have standard deviation a k ≥ 0. Let E(t) = (E 1 (t), ..., E K (t)), α = (α 1 , ..., α K ) and a = (a 1 , ..., a K ).In particular, α Σ is the total arrival rate.For t ≥ 0 and k Then job j of class k arrives at time T j k = inf{t ≥ 0 : A k (t) ≥ j}.For k ∈ K and j ∈ N a random variable v j k represents the service time of the (Z k (0) + j)th job of class k.We assume that the random variables {v j k } j∈N are strictly positive and form an independent and identically distributed sequence with common distribution ν k on R + for each k ∈ K.For k ∈ K let the sequences {v j k } j∈N be mutually independent.Assuming that the mean ⟨χ, ν k ⟩ > 0 and the standard deviation is a mixture of service time distributions.It may be thought of as the distribution of the initial service time of a randomly chosen customer.Let ρ = α Σ ⟨χ, ν Σ ⟩ be the traffic intensity.
It will be convenient to combine the stochastic primitives for job classes into measure-valued load processes

C. Basic performance processes, service protocol
For j ∈ N, k ∈ K and t ≥ T j k let w j k (t) denote the residual service time of job j in class k at time t.Thus, w j k decreases at rate one when the job j of class k is in service and is constant otherwise.In particular, w j k is identically equal to zero after the departure of the job j from the system.
Customers are served using the SRPT service protocol, which gives preemptive priority to the job with the shortest residual service time.In case of a tie, FIFO is used as a tiebreaking rule.When both the service times and the arrival times of two or more jobs are the same, we break the tie in an arbitrary manner.
The state of the system at time t will be described by a Kdimensional vector of counting measures with unit masses at the residual service times of the jobs of each class still present in the system.More formally, for t ≥ 0 and k ∈ K, the state descriptor of class k is defined as follows:

III. DIFFUSION LIMIT
We define a sequence of systems to which the diffusion scaling is applied.Let R be a sequence of positive real numbers increasing to infinity.Consider an R-indexed sequence of stochastic models, each defined as in Section II.For each r ∈ R there is an initial condition k , p r k and ρ r , for each class k ∈ K.We also have arrival processes A r with arrival times {T r,j k } j∈N , k ∈ K a state descriptor Z r and processes W r , Q r .The stochastic elements of each model are defined on a probability space (Ω r , F r , P r ) with expectation operator E r .
A diffusion scaling is applied to each model in the Rindexed sequence as follows.For each r ∈ R and t ≥ 0, let A fluid scaling is applied to functions S r,x .For each r ∈ R, x > 0 and t ≥ 0, let We make the following asymptotic assumptions for the sequence of stochastic primitives.Assume that as r → ∞, where E * is a K-dimensional Brownian motion starting from zero with drift zero and covariance matrix Σ = [σ ij ] such that ROBERT GIEROBA, ŁUKASZ KRUK: DIFFUSION LIMITS FOR SHORTEST REMAINING PROCESSING TIME QUEUES 121 Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
and b = (b 1 , ..., b K ).In addition, assume the heavy traffic condition that for some γ ∈ R For the sequence of service time distributions, we assume that ν r = ν, i.e., ν r does not depend on r.Then β r = β, p r k → p k := α k αΣ as r → ∞, where α is given by ( 2), ρ r → 1 as r → ∞ and b r = b.Define We assume that x * < ∞.
For the sequence of diffusion scaled initial conditions {(Z r (0), S r,x , x > 0)} r>0 we assume that as r → ∞ where W * 0 is some random variable.It is well known ( [15]) that from ( 2), ( 3), ( 4), the fact that service time distributions ν r do not depend on r and that SRPT is a work conserving discipline, it follows that as r → ∞ where x * .Before we proceed, we state a standard result, as presented in [12].Proposition 1.For each r ∈ R, let {x r k } ∞ k=1 be an independent and identically distributed sequence of nonnegative random variables on a probability space (Ω r , F r , P r ) with finite mean µ r and standard deviation σ r , independent of a (possibly delayed) rate α r > 0 renewal process B r such that the standard deviation of the interarrival times equals a r ≥ 0. Assume that Br ⇒ B * as r → ∞, where and B * is a one-dimensional Brownian motion starting from zero with drift zero and variance a 2 α 3 per unit time.Suppose that for some finite nonnegative constants µ, σ, and positive α, a we have that µ r → µ, σ r → σ, α r → α and a r → a as r → ∞.Further assume that for each ε > 0, x r k and Xr (t) = X r (⌊r 2 t⌋) − ⌊r 2 t⌋µ r r .
Then, as r → ∞, ( Br , Xr ) ⇒ (B * , X * ), where X * is a Brownian motion starting from zero with drift zero and variance σ 2 per unit time, independent of where for each r ∈ R and t ≥ 0, and α(t) = αt.
The results in this section require all the assumptions made in Section 3. To simplify the notation, we will write S r k and Sr k instead of S r,x * k and Sr,x * k and similarly S r and Sr instead of S r,x * and Sr,x * . and Then A. Proof of Theorem 1 The general idea of the proof of Theorem 1 is to first show that in the diffusion limits all jobs with service times less than x * are prioritized so that their corresponding workload and queue length processes vanish.This implies that the processes Ẑr Σ converge weakly to a multiple of δ x * .Then we use functional limit theorems and the fact that FIFO is the tiebreaking rule to prove that in the diffusion limit the queue lengths and the workloads of job classes are divided according to the proportions in the statement of the theorem.In the proof, we follow the ideas of Peterson [21], with customers having the residual service times not less than x * regarded as the low priority (L) ones with necessary modifications.The most important difference is that in [21] the priority of a job cannot change.In our setting however, the priority of a job can change from low to high (H).It happens every time a job with service time x * receives some service and hence its residual service time is decreased.Consequently, our problem requires a somewhat more careful approach, described below in more detail.

1) Additional notation: For
In general, subscript "H" stands for high priority jobs, i.e. jobs with residual processing times strictly lower than x * and subscript "L" indicates low priority jobs, i.e. those with residual service times greater than or equal to x * .Recall that in our notation and similarly, Let L r (t) denote the number of units of service dedicated to jobs with initial service times equal to x * by time t ≥ 0 in the r-th system.Observe for future reference that S r k (L r (t)) is the number of fully served initial class k jobs with initial service time x * by time t in the r-th system.
2) Concentration of the mass at x * : We will first show that Observe that (10) implies For r ∈ R and t ≥ 0, let which equals zero by definition if Then for r ∈ R and t ≥ 0 Indeed, the inequality above follows from the fact that clearly τ r (t) ≤ t, so we can bound the (diffusion scaled) number of high priority customers in the system at time t from above by an analogous number of customers at time τ r (t) increased by the number of external arrivals in this time interval.The addition of 1 on the right-hand side of the inequality is needed because of a possibility that there is no job with service time less than x * at time r 2 τ r (t) in the system and a job with service time x * is chosen for processing at this time, which immediately increases the number of jobs with residual processing times less than x * by 1.
Fix r ∈ R and t ≥ 0. By (1), we have which, together with the fact that the process Therefore, By ( 2), ( 15) and the fact that E * Σ is continuous almost surely, we obtain (see [5], Section 17) that for t ≥ 0 as r → ∞ Since the space M K × (D[0, ∞)) K × R is separable, we can apply the Skorohod representation theorem ([5], Theorem 6.7) and assume that all the random elements in ( 6)-( 8) are defined on a common probability space (Ω, F, P), on which as r → ∞ in Fix such an ω.In this paragraph, all the random elements under consideration are evaluated at this ω.Observe that from the consistency conditions for functions S x k listed in Section II-A it follows that, for a given r, Sr . By (17), there exists a finite constant C such that Ẑr Σ (0)(x * ) ≤ C for all r ∈ R.This means that all the functions Sr k as well as the functions D k are constant on [Cx * , ∞).In this case, convergence in the Skorohod topology to a continuous limit implies convergence in the uniform topology as well ( [5], Section 12).Hence, by (17) This, together with ( 6), ( 7), (17), gives us which in turn, together with (2), ( 13), ( 14), ( 16) implies (10).
Therefore it remains to prove (14).For each r ∈ R and t ≥ 0, we examine the behavior of W r Σ,H on time intervals of the form (r 2 τ r (t), r 2 t] to derive an expression that relates Ŵ r Σ,H (t) and θ r (t).In particular, since for each r ∈ R and t ≥ 0, Q r Σ,H (s) ̸ = 0 for all s ∈ (r 2 τ r (t), r 2 t] and the service discipline is SRPT, it follows that for each r ∈ R and t ≥ 0, Again, the addition of x * on the right-hand side of the inequality is needed because of a possibility that there are only jobs with service time greater than or equal to x * at time r 2 τ r (t) in the queue.
3) Proportional breakdown: For r ∈ R let σ r (t) be the time of arrival to the rth system of the job with service time x * which most recently completed service before time t (if none has yet completed we define it as 0).Let σr (t) = 1 r 2 σ r (r 2 t), t ≥ 0. We will now prove that σr ⇒ e, where e(t) = t for t ≥ 0. For t ≥ 0 we have where u r (t) denotes the partial service (if any) that has been performed in the time interval [σ r (t), t) on the next job with service time x * .Recall that S r Σ (L r (t)) is the number of fully served initial jobs with initial service time x * by time t in the rth system, so the last term is the workload of initial low priority jobs still present in the system at time t.The fact that (23) holds is a consequence of the FIFO discipline among the jobs with the same residual service time.Notice that u r (t) ≤ x * .On the other hand, we also have that for t ≥ 0 124 PROCEEDINGS OF THE FEDCSIS.WARSAW, POLAND, 2023 where V r Σ,L (0−) = V r Σ,L (0) = 0 by convention.The last term in (24) takes into account possible initial jobs with processing times greater than x * .Under the diffusion scaling Ŵ r Σ,L (t) = 1 r W r Σ,L (r 2 t) we have Ŵ r Σ,L = Ŵ r Σ − Ŵ r Σ,H and by ( 5) and (11), Under the diffusion scaling, since Z r Since σ r (t) ≤ t, (26) gives us after rearranging Let T > 0. Since convergence in the Skorohod topology to a continuous limit implies convergence in the uniform topology, we have (27) after taking norms gives Define the continuous functions h r : R → R and h : R → R by h r (x) = x r and h(x) = 0, x ∈ R.Then, by Theorem 2.7 of [5] Thus the right hand side above converges in probability to zero, which in turn implies that σr ⇒ e by Theorem 3.1 of [5].
Using Proposition 1, one can prove (see [12]) that where V * Σ,L is a Brownian motion starting from zero with zero drift and finite variance per unit time.From ( 28)-(29), using ( 25), ( 30)-( 31), the fact that σr ⇒ e and the Random Time Change Theorem ( [5], Theorem 14.4) we have that We can now obtain the desired breakdown for the workload processes.For t ≥ 0, k ∈ K we have the following inequalities, analogous to ( 23)-( 24): where u r k (t) denotes the partial service (if any) that has been performed in the time interval [σ r (t), t) on the next job of class k with service time x * .Notice that u r k (t) ≤ x * for all k ∈ K.
Under diffusion scaling, (33) yields Suppose that for each k ∈ K, r ∈ R Using this, ( 35)-( 37), the fact that σr ⇒ e and the Random Time Change Theorem, we can write that From Section IV-A2 and (30) it follows that Ẑr Σ ⇒ Ŵ *
Recall from (2) that α r → α as r → ∞ and that by the Skorohod representation theorem we may assume that all the random elements in ( 6)-( 8) are defined on a common probability space (Ω, F, P) such that (17)  Authorized licensed use limited to the terms of the applicable license agreement with IEEE.Restrictions apply.
every ω ∈ Ω.In what follows, all the random elements are evaluated at such an ω.Using an analogous line of reasoning as the one that led us to (18) we obtain that, as r → ∞, and, similarly, Observe that By (7), so by (40), Similarly, by ( 8) and ( 41) as r → ∞, which implies that the limits as r → ∞ of I r k and αΣνΣ(x * ) I r coincide and, by (32), proves (38).V. THE CASE OF ν Σ (x * ) = 0 In this case we take a seemingly different approach.We start from modeling an exogeneous arrival process E Σ common for all jobs.When a job arrives at the system, we randomly assign it to a class 1, ..., K with probabilities p 1 , ..., p K correspondingly 1 .We also assume that there are no customers in the system at time 0. This is described more formally below.
Let (Ω, F, P) be the probability space on which the stochastic elements of the model are defined.Let E Σ be the exogenous arrival process, i.e. for t ≥ 0, E Σ (t) is the number of arrivals to the system in the time interval (0, t].It is a delayed renewal process with rate α Σ > 0 such that the interarrival times have standard deviation a Σ ≥ 0. Then job j arrives at time Let {ϕ i } i∈N be i.i.d.random vectors, independent of E Σ such that for each i ϕ i = (ϕ i,1 , ..., ϕ i,K ), where ϕ i,k = 1 if job i belongs to class k and ϕ i,k = 0 otherwise.We assume that P(ϕ i = e k ) = p k , where e k is the kth unit vector in R K and p k ∈ (0, 1) for each k ∈ K, In words, Φ k (n) is the number of class k jobs among the first n jobs which arrived in the system.We can now define We define the 1 As we will see, this is a special case of the approach considered in Sections 1-4, with the exogeneous arrival process E having dependent coordinates.processes Z, W , Q and V analogously as in Section II.We assume that Z k (0) = 0 for each k ∈ K.
Let v i represent the initial service time of the ith job in the system.We assume that (ϕ i , v i ) i≥1 are i.i.d.random vectors independent of E and that ν k is the conditional distribution of v i under the condition of ϕ i = e k , k ∈ K.We put ν Σ = k∈K p k ν k .For j ∈ N, k ∈ K and t ≥ T j let w j (t) denote the residual service time of job j at time t.As before, the SRPT protocol is used.
We apply diffusion scaling for a sequence of systems similarly as in Section III.Let R be a sequence of positive numbers increasing to infinity.Consider an R-indexed sequence of stochastic models presented in the previous paragraph.For each r ∈ R, there are stochastic primitives The stochastic elements of each model are defined on a probability space (Ω r , F r , P r ) with expectation operator E r and variance operator Var r .We also have arrival times {T r,j } j∈N , a state descriptor Z r and processes W r , Q r , V r .
A diffusion scaling is applied to each model in the Rindexed sequence as in (1).Furthermore, for each r ∈ R and t ≥ 0, let We make the following asymptotic assumptions for the sequence of stochastic primitives.Assume that as r → ∞, where E * Σ is a Brownian motion starting from zero with drift zero and variance a 2 Σ α 3 Σ per unit time.Moreover, we assume that ν r = ν, i.e., ν r does not depend on r.
We will now determine the limits of processes Φr and Êr as r → ∞.We first apply Proposition 1 to the processes Φr = Φr k , r = 1, ..., K .Fix k ∈ K.For each r ∈ R, {ϕ r i,k } i∈N are independent Bernoulli distributed random variables such that P r (ϕ r i,k = 1) = p r k .Hence E r ϕ r i,k = p r k and Var r ϕ r i,k = p r k (1 − p r k ).Using the fact that p r k → p k and Proposition 1, we obtain where Φ * k is a Brownian motion starting from zero with drift zero and variance p k (1 − p k ) per unit time.By using the Cramer-Wold device, multidimensional central limit theorem and Prohorov theorem, we can generalize this to joint convergence Φr ⇒ Φ * , where Φ * is a K-dimensional Brownian motion starting from 0 with drift 0 and covariance matrix C = [c ij ] i,j such that c ii = p i (1 − p i ), c i,j = −p i p j for i ̸ = j (cf.[26], proof of Theorem 4.3.5).Moreover, this convergence is joint with (42) and Φ * is independent of E * Σ .
Now we use Proposition 1 again to obtain the limit of the process Êr = Êr k , r = 1, ..., K .Fix k ∈ K. Observe that Therefore, by Proposition 1, Note that E * k is a Brownian motion starting from 0 with drift 0 and variance per unit time Therefore, by an analogous argument as in the previous paragraph, we obtain joint convergence Êr ⇒ E * , where E * (t) = Φ * (α Σ t) + pE * Σ (t), t ≥ 0. Note that E * is a K-dimensional Brownian motion starting from 0 with drift 0 and covariance matrix D Before we proceed, we present a general property of the SRPT protocol, which will be used in the following proofs.
Lemma 1.Consider a single-server queueing system with customers served according to the SRPT protocol.Let t ≥ 0 and let i, j be two jobs present in the system at time t with initial processing times v i , v j and residual processing times w i (t), w j (t) respectively.Then the intervals (w i (t), v i ) and (w j (t), v j ) are disjoint.
Proof.Suppose that (w i (t), v i ) ∩ (w j (t), v j ) ̸ = ∅.First, consider the case when neither of the intervals is a subset of the other.Without loss of generality we may assume that w This means that the job j, even though its initial processing time was not less than v i , was partially served so that its residual processing time is lower than the initial processing time of the job i.Since the system uses the SRPT protocol, this is possible only when v i = v j or when i arrived after j.In the first case, the start of the processing immediately breaks the tie so i cannot be partially processed before j gets fully serviced, thus w i (t) = v i and therefore this case is impossible.In the second case, let t 1 be the time of the arrival of the job i.If w j (t 1 ) > v i , then for any t ≥ t 1 the job j could only be chosen for processing after i had been fully serviced, which means that this case is impossible.If w j (t 1 ) ≤ v i , then for any t ≥ t 1 the job i could only be chosen for processing after j is fully serviced, which means that this case is impossible as well.
Finally, consider the case when one of the intervals is a subset of the other.Without loss of generality we can assume that w j (t) ≤ w i (t) < v i ≤ v j .Arguing as above, we can obtain that this is also impossible.This leads to a contradiction, therefore the intervals (w i (t), v i ) and (w j (t), v j ) are disjoint.
We are now ready to formulate the main theorem in the case under consideration.Theorem 2. Let x * < ∞, ν Σ (x * ) = 0. Assume that for every k ∈ K the limit where f k is the Radon-Nikodym derivative of the measure ν k with respect to ν Σ , exists.Under the assumptions of this section, we have that, as r → ∞, and that, for any x ∈ (0, x * ) (47) This is done similarly as in the first part of the proof of Theorem 1.
Fix t > 0 and ε > 0. Let {i r j } j be the sequence of jobs present in the system r and having residual processing time in (x * − ε, x * ] at time t, i.e. such that w r ij (t) > x * − ε.In what follows, we will simply write i j instead of i r j when the system in question can be inferred from the context.Let n r (t) be the number of such jobs (of all classes) in the rth system at time t.Notice that We claim that Indeed, by Lemma 1, the intervals of the form (w r ij (t), v r ij ) are pairwise disjoint.All of these intervals are contained in (x * − ε, x * ] by the definition of the sequence {i r j } j , therefore the sum of their lengths cannot exceed ε. By ( 5) and ( 47)-(49) we obtain that as r → ∞ Observe that for r ∈ R and almost every (with respect to ν Consider the sequence {v r ij ϕ r ij ,k } j .Obviously ϕ r ij ,k = 1 if the job i r j belongs to the class k and ϕ r ij ,k = 0 otherwise.Similarly as before we can show that the limits of Ŵ r k (t) and 1 r n r (r2 t) j=1 v r ij ϕ r ij ,k coincide.By (47) and the fact that If n r (r 2 t) is of the order less than r, then by ( 47)-(48) and the bound v i ≤ x * for all i, Ŵ r Σ (t) is asymptotically negligible.On the other hand, if n r (r 2 t) is large, using the law of large numbers, we get, and by ( 51), ( 44), 52)-( 54) and (42) it follows that, as r → ∞, any weak limiting distribution of a subsequence of the sequence is stochastically bounded from below by the distribution of )) and stochastically bounded from above by the distribution of ).By letting ε ↓ 0 and taking (46), (50) into account we obtain the desired breakdown and convergence of one-dimensional distributions.It is easy to extend this result to convergence of finite-dimensional distributions.

VI. SIMULATIONS
In this section we present the results of our computer simulations.We simulated the system described in Section II with two user classes.The times between arrivals of jobs of each class are exponentially distributed with parameters α 1 , α 2 correspondingly.
Let us add an initial condition consisting of 25 jobs in each of two classes, with the same service time distributions as jobs arriving in the system in the corresponding class.Notice that their workloads are not even approximately distributed according to the asymptotic proportions stated in Theorem 1.The results are shown in Figure 2. Now, let us change the initial condition.It still consists of 25 jobs in each class, but their processing times are distributed uniformly on [0, 3], which is even further from the assumptions on the initial condition in Theorem 1.The results are shown in Fig. 3. Now let us consider the case when ν Σ (x * ) = 0. Assume that α 1 = 1, α 2 = 0.6.Then α Σ = 1.6.The initial service times are uniformly distributed in the interval [0, 1] and [2/3, 1] correspondingly.This gives us x * = 1, ρ = 1, p 1 = 0.625, p 2 = 0.375, γ 1 = 4/7 and p 1 γ 1 = 5/14 ≈ 0.357.We assume that there are no customers in the system at time 0. The results are shown in Fig. 4.
We add an initial condition consisting of 25 jobs in each of two classes, with the same service time distributions as jobs arriving in the system in the corresponding class.The results are shown in Fig. 5.
Let us summarize the results.In Fig. 1 we can observe in the left chart that the proportion of workload of class 1 to the total workload in the system stabilizes at p 1 ν 1 3 2 /ν Σ 3 2 = 1/4 after a long time has passed, which confirms that Theorem 1 holds true.Moreover, we can notice that the blue graph in the right chart illustrating the predicted workload of class 1 obtained by applying Theorem 1 "lies close" to the red graph presenting the actual workload of class 1.The prediction at a given time is more accurate, if there are more tasks in the system at this time.
Adding an initial condition in the simulation in Fig. 2 does not noticeably change the situation, even though at time 0 a large amount of workload is not distributed between the two classes according to the proportions required by the assumptions in Theorem 1.We can also observe less instability in the left chart, since with such a number of initial tasks the queue lengths remains at higher levels, where the proportions are more stable.However, in Fig. 3 we can see that an initial condition consisting of tasks greatly different from those arriving in the system results in a notably slower convergence.While the decreasing trend is still visible in the left chart, it is very small in magnitude and in the simulated time horizon the system did not manage to stabilize.Therefore, applying Theorem 1 to predict the proportion of class 1 workload to the total workload in the system gives us an inaccurate approximation and the assumptions for the initial conditions cannot be omitted.
In Fig. 4-5 we can see that if ν(x * ) = 0, we also obtain similar results as above and can make analogous observations.This indicates that Theorem 2 (and even its generalized form, without assuming a zero initial condition) holds true.

VII. CONCLUSION
In this paper, we have proved a diffusion limit theorem for the measure-valued state descriptor for a single-server queuing system with multiple job classes and bounded processing times of arriving jobs.In particular, we have shown that, under suitable assumptions, the workload and the queue length in the   diffusion limit are divided between these classes according to specific proportions.This result can be applied in practiceit can be used to approximate proportions between workloads of different classes in the long run.The simulations presented in the last section indicate that it should be possible to further generalize Theorem 2 by removing the zero initial condition requirement.
N denote the set of positive integers, let R denote the set of real numbers and let R + = [0, +∞).For a, b ∈ R, we write a ∨ b (a ∧ b) for the maximum (minimum) of a and b and ⌊a⌋ for the largest integer not greater than a.By convention, a sum over the empty set of indices equals zero.The sets (a, b), [a, b) and (a, b] are empty for a, b ∈ [0, ∞] with a ≥ b.The Borel σ-field on R + will be denoted by B(R + ).For B ∈ B(R + ), we denote the indicator of the set B by I B .

Fig. 1 .
Fig. 1.Simulation in the case of x * < ∞, ν Σ (x * ) > 0. The left chart illustrates the proportion of workload of class 1 to the total workload in the system as a function of time.The right chart presents the predicted workload of class 1 obtained as a result of applying Theorem 1 (blue) and the actual workload of class 1 (red).

Fig. 2 .
Fig. 2. Simulation in the case of x * < ∞, ν Σ (x * ) > 0 with a non-zero initial condition.The interpretations of charts is the same as in Fig. 1.
holds for almost ROBERT GIEROBA, ŁUKASZ KRUK: DIFFUSION LIMITS FOR SHORTEST REMAINING PROCESSING TIME QUEUES 125