Keywords

1 Introduction

Inventory models had received significant attention in academic research. While numerous classical models assume negligible or no time for the inventory to be served, real-world scenarios often demand considerations of the time to serve the inventory. Pioneering the exploration of Inventory models with positive service time were Berman et al. [12] and Sigman et al. [14]. Comprehensive insight into studies by various authors in this direction can be found in the survey articles by Krishnamoorthy et al. [8, 9].

Unexpectedly, there have been relatively few prior studies exploring models where the service time and/or inter-arrival time are contingent upon the inventory level. This stands in contrast to the significant emphasis placed on queueing models with state-dependent arrival and service processes in the existing literature. S. K. Gupta [4] analyzed such a model with a finite queue size. In his investigation, both arrival and service rates were treated as arbitrary functions of the number of customers in the system. Other pioneering works in a similar direction were done by Hiller et al. [6] as well as Conway et al. [3]. Later, Bekker et al. [2] provided detailed descriptions of both M/G/1 and G/G/1 models incorporating workload-dependent arrival and service rates.

However, there are classical models (with zero service time) that have analyzed inventory models with stock dependent demands. These models are derived from the observation that maintaining abundant inventory has a favourable impact on demand.

Customers are often enticed to make purchases by prominently displaying a considerable amount of inventory in stores. Larson et al. [10] coined the term “psychic stock” for this displayed inventory. Hadley et al. [5], Wolfe [16], T L Urban [15] and Johnson [7] are among the researchers who have investigated the stimulating impact of inventory level on demand. The influence of inventory level on demand is evident in cases involving distinct inventory items, such as ornaments or clothing materials. A diverse assortment of these items offers customers a wider choice, consequently elevating demand. Another instance is when there’s an abundance of inventory or when dealing with perishable items. In these situations, sellers may introduce special offers to entice buyers and clear out excess/old stock, resulting in a notable increase in demand.

Queueing models with interdependent arrival and service processes are introduced by Ranjith et al. [13]. Much before that Guy Latouche [11] derived interdependent phase type processes by a semi Markovian point process. He constructed this by considering a finite state irreducible Markov chain. In this paper we follows a similar approach. But with the difference that our focus is not on the dependence between these processes, but on the interdependence between the state of the embedded Markov chain and the phase type distribution constructed.

Using this method, this paper analyses an \(s-S\) inventory model with no lead time and positive service time. In this model both the service and arrival processes depend on the inventory level. The structure of the paper is in the following manner. Section 2 presents the description of the underlying Markov chains for the service and arrival processes. In Sect. 3, the marginal distribution of the service time and inter arrival time are found. In Sect. 4, a continuous-time Markov chain is employed to model a queueing-inventory model with inventory dependent arrival and service processes. It also covers the condition for stability of the system. Section 5 focuses on the steady state analysis and evaluation of the key system performance measures. Furthermore, we conduct a comprehensive numerical investigation of the system in Sect. 6. Finally, in Sect. 7 we conclude the discussion.

2 Semi-Markovian Service and Arrival Processes Depending on Inventory Level

To construct Semi-Markovian point processes suitable for modeling arrival and service processes of a queueing-inventory model in which these two processes depend on the level of inventory, we proceed as follows:-

Consider an irreducible Markov chain \(\mathcal {X}=\{X_i| i=0,1,2,3,...\}\) with state space \(\{1,2,3,...,r\}\). Let \(P^X= \begin{bmatrix} p^X_{ij} \end{bmatrix} \) where

$$\begin{aligned} p^X_{ij}={\left\{ \begin{array}{ll} 1 \text { if } j=i-1, 2\le i \le r\\ 1 \text { if } i=1, j=r\\ 0 \text { otherwise. } \end{array}\right. } \end{aligned}$$

be the transition probability matrix of the chain \(\mathcal {X}\).

Assume that the transitions of the chain \(\mathcal {X}\) occur at random epochs \(\gamma _i, i=1,2,3,...\) . Let \(\tau _i\) be the interval of time between the successive transitions.

$$\begin{aligned} \mathbf {\tau }_i= {\left\{ \begin{array}{ll} \gamma _{i}-\gamma _{i-1}, \text { if } i=2,3,...\\ \gamma _{1} \text { if } i=1 \end{array}\right. } \end{aligned}$$

For each i, if \(X_{i-1}=j\), assume that \(\mathbf {\tau }_i\) follows a Phase type distribution \(F_j(.)\) with representation \((\alpha _j,D_j)\), where \(D_j\) is an \(n_j\times n_j\) matrix. Thus we have a semi-Markov Process \(\{Z_X(t) | t\ge 0\}\) defined by

$$Z_X(t)=X_{i}, \gamma _i\le t <\gamma _{i+1}, i=0,1,2,...$$

In the present study, states of the chain \(\mathcal {X}\) are the inventory levels and each state transition corresponds to a service completion. \(\gamma _i, i=1,2,3,...\) are the epochs of completion of \(i^{\text {th}}\) service, \(Z_X(t)\) represents the inventory level at time t and the distribution of duration of the service happening at time t is \(F_{Z_X(t)}(.).\)

For the arrival process, we proceed as follows:- Consider the phase type distributions \(G_i(.)\) with representations \((\beta _i, T_i), i=1,2,..,r\) where \(T_i\) is a square matrix of order \(m_i\). Define a Markov chain \(\mathcal {Y}=\{Y_i| i=0,1,2,3,...\}\) with state space {0,1,2,...}, \(Y_0=0\) and having the transition probability matrix \(P^Y= \begin{bmatrix} p^Y_{ij} \end{bmatrix} \) where

$$\begin{aligned} p^Y_{ij}={\left\{ \begin{array}{ll} 1 \text { if } j=i+1, i\ge 0\\ 0 \text { otherwise. } \end{array}\right. } \end{aligned}$$

Starting from time \(t=0\), let \(\nu _i\) be the epoch at which the chain \(\mathcal {Y}\) makes the \(i^{\text {th}}\) transition, \(i=1,2,3,...\). Let \(\varphi _i\) be the inter occurrence time \(\nu _{i}-\nu _{i-1}\) between the \(i-1^{\text {th}}\) and \(i^{\text {th}}\) transitions of the chain \(\mathcal {Y}.\) Assume that \(\varphi _i\) follows the distribution \(G_j(.)\) where \(j=Z_X(\nu _{i-1}).\) Hence we have a semi Markov Process

$$Z_Y(t)=Y_i,\nu _{i}\le t <\nu _{i+1}, i=0,1,2,... $$

We may take the states of the chain \(\mathcal {Y}\) to be the number of arrivals. The distribution of the inter arrival times are then determined by the inventory level at the epochs of the preceding arrivals.

3 Marginal Distributions of Service Times and Inter-arrival Times

Consider the continuous parameter Markov chain

$$\mathcal {N}_1 = \{(N_1(t), I_X (t), J_{\tau } (t)) |t \ge 0\}$$

where \(N_1(t)\) is the number of transitions occurred during the time interval (0, t] of the chain \(\mathcal {X}\), \(I_X (t)\) is the state of the chain \(\mathcal {X}\) and \(J_{\tau } (t)\) is the phase of the distribution of the ongoing service process at time t. The state space of this process is

$$\bigcup \limits _{i=1}^{r} \{(n, i, j)|n = 0, 1, 2, ..., j = 1, 2, 3, ..., n_i\}$$

Since in the steady state all the states of the chain \(\mathcal {X}\) are equally likely, the initial probability distribution of the chain \(\mathcal {N}_1\) is given by \(\frac{1}{r}\tilde{\alpha }\), where \(\tilde{\alpha }=\left( \alpha _1, \alpha _2, ..., \alpha _r\right) \) The infinitesimal generator of the chain \(\mathcal {N}_1\) is

$$Q_s=\begin{bmatrix} U& U^0& 0& 0& ...\\ 0& U& U^0& 0& ...\\ 0& 0& U& U^0& ...\\ .& .& .& .& ...\\ .& .& .& .& ... \end{bmatrix}$$

where

$$U=diag(D_1,D_2,...,D_r)$$

and

$$U^0=\begin{bmatrix} 0& 0& 0& ...& 0& 0& D_1^0\alpha _1\\ D_2^0\alpha _2& 0& 0& ...& 0& 0& 0\\ 0& D_3^0\alpha _3& 0& ...& 0& 0& 0\\ .& .& .& ...& .& .& .\\ .& .& .& ...& .& .& .\\ 0& 0& 0& ...& 0& D_r^0\alpha _r& 0 \end{bmatrix}$$

Here \(D_i^0=-D_ie, i=1,2,...,r.\)

The service time \(\tau _i\) of the \(i^{\text {th}}\)customer is the time taken by the chain \(\mathcal {N}_1\) for the transition from level i to level \(i+1\). From the infinitesimal generator of \(\mathcal {N}_1\) it follows that \(\tau _i\)’s are identically distributed and that their common marginal distribution F(t) is of phase type with representation \(\left( \frac{1}{r}\tilde{\alpha },U\right) \).

Therefore,

$$\begin{aligned} F(t)&=1-\frac{1}{r}\tilde{\alpha } exp(Ut)e\\ &=1-\frac{1}{r}\sum _{i=1}^{r}\alpha _i exp(D_it)e \end{aligned}$$

where e is a column vector of 1’s of appropriate order and the density function is

$$f(t)=\frac{1}{r}\sum _{i=1}^{r}\alpha _i exp(D_it)D_i^0=\frac{1}{r}\sum _{i=1}^{r} F_i'(t)$$

Thus in the steady state, marginal density of the service time is the mixture of the densities \(F_1'(.), F_2'(.),...,F_r'(.).\)

To determine the marginal distribution of the inter arrival time, we consider the Markov chain

$$\mathcal {N}_2=\left\{ \left( N_2(t),I_X(\nu ),I_X(t),J_\varphi (t)\right) |t\ge 0\right\} $$

where \(N_2(t)\) is the number of transitions of the chain \(\mathcal {Y}\) occurred in the interval (0, t], \(I_X(\nu )\) and \(I_X(t)\) are the states of the chain \(\mathcal {X}\) at time \(\nu \) and t respectively where \(\nu =max\{\nu _j\in (o,t]\}\) and \(J_\varphi (t)\) is the phase of the ongoing arrival process at time t. Note that \(N_2(t)\) is the total number of arrivals in (0, t] and \(Z_X(\nu )\) is the inventory level at the epoch of previous arrival. This chain has the state space

$$\bigcup \limits _{i=1}^r\left\{ (n,i,k,j)| n=0,1,2,...,k=1,2,...,r, j=1,2,3,...,m_i\right\} $$

and the infinitesimal generator

$$Q_V=\begin{bmatrix} V& V^0& 0& 0& ...\\ 0& V& V^0& 0& ...\\ 0& 0& V& V^0& ...\\ .& .& .& .& ...\\ .& .& .& .& ... \end{bmatrix}$$

where

$$V=diag(V_1,V_2,...,V_r)$$

and

$$V^0=\begin{bmatrix} V^0_1\\ V^0_2\\ \vdots \\ V^0_r \end{bmatrix}$$

in which

$$V_i=\begin{bmatrix} T_i-\mu _1I_{m_1}& 0& 0& ...& 0& \mu _1I_{m_1}\\ \mu _2I_{m_2}& T_i-\mu _2I_{m_2}& 0& ...& 0& 0\\ .& .& .& ...& .& .\\ .& .& .& ...& .& .\\ 0& 0& 0& ...& \mu _rI_{m_r}& T_i-\mu _rI_{m_r} \end{bmatrix},$$

\(\mu _i=-\alpha _iD_i^{-1}e\) and \(V_0^i\) is a block matrix of order \(r\times r^2\) with \(T_i^0\beta _i\) at positions \(\left( j,(j-1)r+j\right) \) and zero matrices at every other positions.

Hence in the steady state, the distribution G(.) of the inter arrival time is a Phase type distribution with representation \((\frac{1}{r}\tilde{\beta }\otimes \zeta , V)\) where \(\tilde{\beta }=\left( \beta _1,\beta _2,\ldots ,\beta _r\right) \) and \(\zeta =\left( \frac{1}{r},\frac{1}{r},...\frac{1}{r}\right) \) is the stationary probability vector of the chain \(\mathcal {X}\). Therefore, we have

$$\begin{aligned} G(t)&=1-\left( \frac{1}{r}\tilde{\beta }\otimes \zeta \right) exp(Vt)e\\ &=1-\frac{1}{r}\sum _{i=1}^{r}(\beta _i\otimes \zeta ) exp(V_it)e \end{aligned}$$

and the density function is

$$g(t)=\frac{1}{r}\sum _{i=1}^{r}(\beta _i\otimes \zeta ) exp(V_it)\left( T_i^0\otimes e_r\right) $$

where \(e_r\) is a column vector of 1’s of dimension \(r\times 1\). Thus in the steady state, marginal distribution of the service time is the mixture of the phase type distributions with representations \(\left( (\beta _i\otimes \zeta ), V_i \right) , i=1,2,...,r. \)

A simplified version of the model we discussed so far may be obtained by assuming that \(D_i\)’s and \(D_j\)’s are linearly dependent and so are \(T_i\)’s and \(T_j\)’s. This is made by taking \(D_i=\epsilon _iD\), \(\alpha _i=\alpha \) and \(T_i=\delta _iT\), \(\beta _i=\beta \), where \((\alpha ,D)\) and \((\beta ,D)\) represents two phase type distributions. This assumption gives us the freedom to switch to the process \((\beta _{i},T_{i})\) from \((\beta _{i+1},T_{i+1})\), even before the absorption of the latter, whenever there is a state transition occurs in the chain \(\mathcal {X}\). Such a model is introduced in the next section.

4 A Queueing-Inventory Model with Inventory Dependent Arrival and Service Processes

Consider a single server inventory model. The inventory is instantaneously replenished according to \((s-S)\) policy. At any time t, the arrival of customers is according to the inventory level at that time. When the inventory level is \(s+i\), the distribution of the inter-arrival time is phase-type with representation \((\beta ,\delta _iT)\) where T is a square matrix of order n and \(\delta _i\) is a real number, \(i=1,2,...,r=S-s\). The service time distributions too are determined by the inventory level. While the inventory level is \(s+i\), the service time distribution is phase type with representation \((\alpha , \epsilon _iD)\). Here D is of order \(m\times m\), \(\epsilon _i\) are real numbers \(i=1,2,..,r\) and \(\alpha \) is the initial distribution.

Let N(t) be the number of customers in the system, I(t) be the inventory level, \(J_1(t)\) and \(J_2(t)\) be the states of arrival and service processes respectively at time t. Then the system under discussion can be modelled by the continuous time Markov chain

$$\mathcal {N}=\left\{ \left( N(t),I(t),J_1(t),J_2(t)\right) /t\ge 0\right\} $$

with state space

figure a

The infinitesimal generator of the chain \(\mathcal {N}\) is given by

$$Q=\begin{bmatrix} A_{00}& A_{01}& 0& 0& 0& & ...\\ A_{10}& A_1& A_0& 0& 0& & ...\\ 0& A_2& A_1& A_0& 0& & ...\\ 0& 0& A_2& A_1& A_0& & ...\\ .& .& .& .& .& & ...\\ .& .& .& .& .& & ... \end{bmatrix}$$

where

$$\begin{aligned} A_{00}&=\varDelta \otimes T\\ A_{01}&=\varDelta \otimes T^0\beta \otimes \alpha \\ A_{10}&=E^\perp \otimes I_n\otimes D^0\\ A_0&=\varDelta \otimes T^0\beta \otimes I_m \\ A_1&=\varDelta \otimes T\otimes I_m+E\otimes I_n\otimes D\\ A_2&=E^\perp \otimes I_n\otimes D^0\alpha \end{aligned}$$

Here

$$\begin{aligned} \varDelta &=\text {diag}(\delta _1,\delta _2,...,\delta _r)\\ E &=\text {diag}(\epsilon _1,\epsilon _2,...,\epsilon _r)\\ E^\perp &=\begin{bmatrix} 0& 0& 0& ...& 0 & \epsilon _1\\ \epsilon _2& 0& 0& ...& 0& 0\\ 0& \epsilon _2& 0& ...& 0& 0\\ .& .& .& ...& .& .\\ .& .& .& ...& .& .\\ 0& 0& 0& ...& \epsilon _r& 0 \end{bmatrix} \end{aligned}$$

Now let \(\pi \) and \(\theta \) be the stationary probability vectors of \(T+T^0\beta \) and \(D+D^0\alpha \) respectively and

$$A=A_0+A_1+A_2=\varDelta \otimes (T+T^0\beta )\otimes I_m+E \otimes I_n\otimes D+E^\perp \otimes I_n\otimes D^0\alpha .$$

For any row vector \(\varphi \) of length r such that \(\varphi E^\perp =\varphi E\),

$$\begin{aligned} \left( \varphi \otimes \pi \otimes \theta \right) A&=\varphi E\otimes \pi \otimes \theta D+\varphi E^\perp \otimes \pi \otimes \theta D^0\alpha \\ &=\varphi E\otimes \pi \otimes \theta \left( D+D^0\alpha \right) \\ &=\textbf{0}. \end{aligned}$$

Thus we have the following lemma.

Lemma 1

For any row vector \(\varphi \) of length r such that \(\varphi E^\perp =\varphi E\), \(\left( \varphi \otimes \pi \otimes \theta \right) \) is a null vector of A.

Choose \(\phi =\left( \frac{1}{\epsilon _1},\frac{1}{\epsilon _2},...,\frac{1}{\epsilon _r} \right) \). For this \(\phi \), \(\phi E^\perp =\phi E\). Hence by lemma 1, \(\left( \phi \otimes \pi \otimes \theta \right) \) is a null vector of A. Therefore \(\varPi =\frac{1}{\phi .e}\left( \phi \otimes \pi \otimes \theta \right) \) is the stationary probability vector of A.

Now

$$\varPi A_2e =\frac{r}{\phi e}\theta D^0=\frac{r}{\phi e}\mu $$

and

$$\varPi A_0 e =\frac{1}{\phi e}\left( \sum _{i=1}^{r}\frac{\delta _i}{\epsilon _i}\right) \pi T^0=\frac{1}{\phi e}\left( \sum _{i=1}^{r}\frac{\delta _i}{\epsilon _i}\right) \lambda $$

Hence we have the following theorem.

Theorem 1

The continuous parameter irreducible Markov chain \(\mathcal {N}\) is positive recurrent if and only if

$$\left( \sum _{i=1}^{S-s}\frac{\delta _i}{\epsilon _i}\right) \lambda < (S-s)\mu $$

Note that when \(\delta _i=\epsilon _i\forall i\), the condition for stability reduces to \(\lambda < \mu \). In particular if \(\delta _i=\epsilon _i=1\forall i\), inventory level and the arrival and service processes are independent.

5 Stationary Distribution of the Markov Chain \(\mathcal {N}\)

The stationary probability vector \(\textbf{z}=\left( \textbf{z}_0, \textbf{z}_1,\textbf{z}_2\ldots \right) \) is given by

$$\begin{aligned} &\textbf{z}_i=\textbf{z}_1R^{i-1}, i=2,3,4...\end{aligned}$$
(1)
$$\begin{aligned} &\textbf{z}_0\left( \varDelta \otimes T\right) +\textbf{z}_1\left( E^\perp \otimes I_n\otimes D^0\right) =0\end{aligned}$$
(2)
$$\begin{aligned} &\textbf{z}_0\left( \varDelta \otimes T^0\beta \otimes \alpha \right) +\textbf{z}_1\left( \varDelta \otimes T\otimes I_m+E\otimes I_n\otimes D\right) +\textbf{z}_2\left( E^\perp \otimes I_n\otimes D^0\alpha \right) =0 \end{aligned}$$
(3)

where the matrix R is the minimal solution of the matrix quadratic equation

$$R^2\left( E^\perp \otimes I_n\otimes D^0\alpha \right) +R\left( \varDelta \otimes T\otimes I_m+E\otimes I_n\otimes D\right) +\left( \varDelta \otimes T^0\beta \otimes I_m \right) =0$$

From Eq. (2),

$$\begin{aligned} \textbf{z}_0\left( \varDelta \otimes T^0\right) =\textbf{z}_1\left( E^\perp \otimes e_n\otimes D^0\right) \end{aligned}$$

So that

$$\begin{aligned} \textbf{z}_0\left( \varDelta \otimes T^0\beta \otimes \alpha \right) &=\textbf{z}_0\left( \varDelta \otimes T^0\right) \left( I_r\otimes \beta \otimes \alpha \right) \nonumber \\ &=\textbf{z}_1\left( E^\perp \otimes e_n\otimes D^0\right) \left( I_r\otimes \beta \otimes \alpha \right) \nonumber \\ &=\textbf{z}_1\left( E^\perp \otimes e_n\beta \otimes D^0\alpha \right) \end{aligned}$$
(4)

Using Eqs. (3) and (4), we get

$$\begin{aligned} \textbf{z}_1\left[ E^\perp \otimes e_n\beta \otimes D^0\alpha +\varDelta \otimes T\otimes I_m+E\otimes I_n\otimes D+R\left( E^\perp \otimes I_n\otimes D^0\alpha \right) \right] =0 \end{aligned}$$
(5)

Therefore the vector \(z_1\) can be uniquely determined up to a multiplicative constant. This constant can be found by normalizing the total probability to one.

We partitioned each steady state vector \(z_i\) as \(z_i=\left( z_{i1},z_{i2},\ldots ,z_{ir}\right) \) where \(z_{0j}=\left( z_{0j1}, z_{0j2},\ldots ,z_{0jn}\right) \), \(z_{ij}=\left( z_{ij11},z_{ij12},\ldots ,z_{ij1m},\ldots ,z_{ijn1},z_{ijn2}\ldots ,\right. \left. z_{ijnm}\right) \), \( j=1,2,\ldots ,r, i=1,2,3,\ldots \) in which \(z_{0jk}\) and \(z_{ijkl}, k=1,2,\ldots ,n, l=1,2,\ldots ,m\) are scalars.

Some of the important system characteristics in the steady state are as follows.

  1. 1.

    Probability that the server is idle \(=z_0e_{rn}.\)

  2. 2.

    For \( k>0\), Probability that there are k customers in the system,

    $$P\left( N=k\right) =z_ke_{rnm}.$$
  3. 3.

    Expected number of customers in the system, \(E\left( N\right) =\sum \limits _{i=1}^{n}iz_ie_{rnm}.\)

  4. 4.

    Probability that the inventory level is j, \(P\left( I=j\right) =z_{0j}e_n+\sum \limits _{i=1}^{\infty }z_{ij}e_{nm}.\)

  5. 5.

    Expected inventory level, \(E\left( I\right) =\sum \limits _{j=1}^{r}jP\left( I=j\right) .\)

5.1 Expected Waiting Time

Consider a customer who joins the queue as the \(k^{\text {th}}\) customer. The waiting time \(W_k\) of this customer in the queue is the time until absorption of the Markov chain

$$W(t)=\{(r(t),I(t),J_s(t))/t\ge 0\}$$

where r(t) is the position of the particular customer in the queue, I(t) is the inventory level and \(J_s(t)\) is the state of the ongoing service process at time t. The infinitesimal generator of this chain is

$$\tilde{Q}=\begin{bmatrix} Q_w& -Q_we\\ 0& 0 \end{bmatrix}$$

where

$$Q_w=\begin{bmatrix} E\otimes D& E^{\perp }\otimes D^0\alpha & 0& 0& 0& ... & 0\\ 0& E\otimes D& E^{\perp }\otimes D^0\alpha & 0& 0& ... & 0\\ 0& 0& E\otimes D& E^{\perp }\otimes D^0\alpha & 0& ... & 0\\ 0& 0& 0& E\otimes D& E^{\perp }\otimes D^0\alpha & ... & 0\\ .& .& .& .& .& & ...\\ 0& 0& .& .& .& & E\otimes D \end{bmatrix}$$

Hence \(W_k\) follows a Phase type distribution with representation \(\left( \psi _w, Q_w\right) \) where \(\psi _w=\left( \psi _k,\textbf{0},\textbf{0},..\textbf{0}\right) \) in which \(\psi _k\) is a vector of length rm. The \(ij^\text {th}\) entry of \(\psi _k\) is the conditional probability that the chain is in a state with inventory level i and service phase j given that it is in level k in the steady state.

Hence, when the system is in the steady state, the expected waiting time of this customer is

$$\begin{aligned} W_k&=-\psi _w Q_w^{-1}e\\ &=\psi _k\left[ \sum _{i=0}^k (-1)^i\left[ (E\otimes D)^{-1}(E^\perp \otimes D^0\alpha )\right] ^i\right] \left[ E\otimes D\right] ^{-1}e\\ &=\psi _k\left[ I+\left( \sum _{i=1}^k (I^\perp )^k\right) \otimes e\alpha \right] \left[ E\otimes D\right] ^{-1}e.\\ &\text { where } I^\perp =E^{-1}E^\perp . \end{aligned}$$

Hence the Expected waiting time of an arbitrary customer in the steady state is given by

$$E(W)=\sum _{k=1}^{\infty } P(N=k)W_k$$

6 A Sample Problem on Cost Optimization and Numerical Analysis of the Chain \(\mathcal {N}\)

In this section we present an example of a cost optimization problem that arises in queueing-inventory situations with interdependent arrival and service processes. In this example we assumed that the demand increases with the inventory level according to the relation \(\rho i^{1-\kappa }\), where \(\rho \) and \(0<\kappa < 1 \) are constants and i is the inventory level. Baker et al. [1] used such a functional to model a situation with inventory level dependent demand which is for a relatively short season. Also we take the service rate to be proportional to the inventory level with \(\sigma \) as the proportionality constant.

6.1 A Cost Optimization Problem

We assumed that the multipliers \(\epsilon _i\) and \(\delta _i, i=1,2,\ldots r\) are related to the inventory level i by the relation \(\delta _i=\rho i^{1-\kappa }\) and \(\epsilon _i =\sigma i\) where \(\rho \) and \(\sigma \) are two positive parameters.

This illustration encompasses four distinct cost categories. The initial type involves the cost associated with providing the service at inventory level i, represented as c(i). The second, denoted as \(c_0\), refers to the cost of maintaining the server in a state of readiness during idle periods. Additionally, there are holding costs, denoted as \(c_h\), incurred to ensure customer comfort within the system, along with the cost \(c_s\) associated with preserving the integrity of the inventory. All these costs are calculated per unit time.

Taking all these costs into account, we construct the cost function, \(Cost=c_h\times E(N)+c_s\times E(I)+\sum _{1}^{n}c(i) P(I=i)+c_0\times P\left( N=0\right) \) where E(N) is the expected number of customers in the system, E(I) is the expected inventory level, \(P(I=i)\) is the probability that the inventory level is i and \(P\left( N=0\right) \) is the probability that the system is idle.

For illustration, we choose \(\rho =0.7\), \(\kappa =0.4\), \(c_h=2\), \(c_s=0.5\), \(c(i)=E(i,i)\), \(c_0=6.\) \(T=\begin{bmatrix} -12& 4& 6\\ 3& -10& 5\\ 4& 3& -9 \end{bmatrix}\), \(D=\begin{bmatrix}-7& 1& 2& 1\\ 3& -11& 2& 3\\ 2& 2& -10& 3\\ 5& 3& 4& -15\end{bmatrix}\), \(\beta =(0.4,0.35,0.25)\) and \(\alpha =(0.2,0.3,0.4,0.1)\).

Fig. 1.
figure 1

Variation of cost wrt \(\kappa \)

Our objective is to determine the rate at which the service rate should increase with the inventory level in order to minimize the incurred cost. That is we would like to find the value of the proportionality constant \(\sigma \) that optimizes the cost function. Figure 1 depicts the cost function plotted against \(\sigma \). The convex nature of the curve indicates the presence of a minimum cost. Specifically, the cost reaches its minimum value when \(\sigma \) equals 0.54, with the minimal cost being 15.5280. Consequently, by exerting control over the service process, we ensure system stability even in the presence of heightened arrival rates, and we achieve this at the lowest possible cost.

Our numerical analysis demonstrates that it is possible to adjust the service rate based on the inventory level, thereby enabling control over the system’s characteristics.

6.2 Numerical Analysis of the Chain \(\mathcal {N}\)

For the specified parameter values, we computed the expected number of customers E(N), system idle probability \(P(N=0)\), expected inventory level E(I) expected waiting time E(W) for various values of \(\sigma \) and the results are displayed in Figs. 2, 3 4 and 5. The calculated values are given in Table 2 in Appendix.

As \(\sigma \) increases, the service rates corresponding to each inventory level also rise. The escalation in service rate provides support for the growth in the arrival rate, stemming from increased inventory levels. This leads to a decrease in the expected number of customers in the system. With higher \(\sigma \) values, the traffic intensity decreases. Consequently, the system idle probability increases. For a small value of \(\sigma \), service is delivered at a reduced rate when the inventory level is low. Consequently, it takes more time to complete a service and subsequently replenish the low inventory. As a result, the system experiences prolonged periods with low inventory levels. In contrast, higher values of \(\sigma \) increase the probability that the system is in a state with a higher inventory level.

Fig. 2.
figure 2

Expected number of customers

Fig. 3.
figure 3

Idle probability

Fig. 4.
figure 4

Inventory level

Fig. 5.
figure 5

Expected Waiting time

6.3 A Comparison Between Proposed Model and One with Stock Dependent Arrival Process and Independent Service Process

The model under discussion (Model 1) is compared with a similar one where the service rate remains unaffected by the inventory level (Model 2) giving the following values to the parameters. \(\varDelta =diag(0.7000, 1.0610, 1.3532, 1.6082, 1.8386), \) and

\(D=\begin{bmatrix} -12& 1& 2& 2\\ 3& -16& 2& 4\\ 2& 3& -15& 3\\ 6& 3& 4& -20 \end{bmatrix}, T=\begin{bmatrix} -10-d& 4& 2\\ 3& -8-d& 1\\ 1& 3& -8-d \end{bmatrix}\) where d varies from 0 to 2 in increments of 0.1, \(r=5, n=3, m=4, \alpha =(.2,.3,.4,.1), \beta =(0.4,0.35,0.25), E=diag(0.4567,0.9133,1.3700,1.8267, 2.2833)\)

Fig. 6.
figure 6

Copmarison of two models

In Model 2, the service rate remains the same, while the arrival rate escalates with the inventory level. A comparison of the expected number of customer in both systems is presented in Fig. 6. The numerical results are tabulated in Table 1 in the Appendix. Notably, Model 2 experiences a higher inflow of customers compared to Model 1. In both systems, the arrival rate increases with the inventory level. When the inventory level is high, the arrival rate is also elevated. In the case, where the service rate is constant, the inventory level has nearly a uniform change, resulting in approximately equal probabilities for all inventory levels. This, in turn, leads to a high average arrival rate, causing the system to quickly burst out.

Conversely, in Model 1, the service rate diminishes as the inventory level decreases. Consequently, when the inventory level is low, service occurs at a slow pace. Since an increase in inventory level through replenishment occurs only after these long service periods, the system spends a considerable proportion of time in a state of low inventory. Consequently, at these times the expected arrival rate will be low. Therefore, even with higher demand v, the effective arrival rate will be moderate, ensuring the stability of the system.

In scenarios where there is high demand for the inventory, opting for stock-dependent service processes becomes advantageous in regulating the inflow of customers and maintaining system stability. This proves particularly useful in contexts such as ration distribution systems or the distribution of essential commodities to a large population. In such situations, the arrivals increase with the available stock. Consequently, we can exert control over the arrival rate by managing the inventory level. Our numerical study indicates that an effective method to achieve this control is by employing stock-dependent service processes.

7 Conclusion

In our investigation, we delved into a queueing inventory model incorporating interdependent arrival and service processes, along with the inventory level, utilizing two semi-Markov processes. The marginal distributions of both service time and inter-arrival times were identified as mixtures of phase-type distributions. Further analysis focused on a specific instance of this model, with the derivation of conditions for system stability. The stationary distribution was determined numerically. We also explored the distribution of waiting time, its expected value, and other critical system performance measures. This model has the potential for extension to more complex scenarios involving positive lead time. Examining the impact of replenishment time on system performance would be particularly intriguing in such cases.