1

People arrive at rate $\lambda$.

There are $s$ servers, with service time distributed with rate $\mu$.

At $t=0$ all servers are busy, nobody is in the waiting line.

Question: What is the probability that exactly $k$ people arrive before one of the servers finishes service?

I know that $P(X=k)=e^\lambda \lambda^k/k!$ Since there are $s$ servers, the first one will finish at $\min [s_1,s_2,...,s_s]$ which happens at rate $s\mu$, so waiting time is $1/s\mu$.

However I can't figure out how to compute them together.

GRS
  • 2,495

2 Answers2

3

Let $T_1,\ldots,T_s$ be the finish times of each server. As you noted, $T_{\min}:=\min\{T_1,\ldots,T_s\}$ follows the exponential distribution with parameter $s\mu$, i.e. $p_{T_{\min}}(t) = s\mu e^{-s\mu t}$.

Conditioning on $T_{\min}$ gives \begin{align} \mathbb{P}(X_{T_{\min}} = k) &= \int_0^\infty \mathbb{P}(X_t = k \mid T_{\min} = t) p_{T_{\min}}(t) \mathop{dt}\\ &= \int_0^\infty e^{-\lambda t} \frac{(\lambda t)^k}{k!} s \mu e^{-s\mu t} \mathop{dt}\\ &= \frac{s\mu\lambda^k}{k!} \int_0^\infty t^k e^{-(\lambda+s\mu)t} \mathop{dt}\\ &= \frac{s\mu\lambda^k}{k!} \frac{1}{(\lambda+s\mu)^{k+1}} \int_0^\infty u^k e^{-u} \mathop{du} & u = (\lambda+s\mu)t\\ &= \frac{s\mu\lambda^k}{k!} \frac{k!}{(\lambda+s\mu)^{k+1}}\\ &= \frac{s\mu}{\lambda+s\mu} \left(\frac{\lambda}{\lambda+s\mu}\right)^k, \end{align} so $X_{T_{\min}}$ follows a geometric distribution.

angryavian
  • 89,882
  • Thanks, wouldn't the first line be $\int_0^\infty \mathbb{P}(X_{T_{\min}} = k \mid T_{\min} = t) p_{T_{\min}}(t) \mathop{dt}=\int_0^\infty \mathbb{P}(X_t = k) p_{T_{\min}}(t) \mathop{dt} $? – GRS Mar 24 '16 at 01:23
1

The time until a server opens up is a random variable $T$ distributed as an exponential random variable. The number of people that have arrived by time $t$ is distributed as a $\text{Pois}(t\lambda)$ random variable. So you are asking for the probability that a $\text{Pois}(T\lambda)$ random variable takes the value $k$.

The PDF of $T$ is $s\mu \ e^{-s\mu t}$, so therefore the probability is $$ \int_0^{\infty}\lambda^k e^{-\lambda t}\frac{t^k}{k!}\ s\mu \ e^{-s\mu t}\ dt. $$ By integration by parts (or properties of the Gamma function), the integral $\int_0^{\infty}t^k e^{-xt}\ dt$ is known to take the value $k! \ x^{-k-1}$. Substituting $x=\lambda+s\mu$ yields $$ \left(\lambda+s\mu\right)^{-k-1}\lambda^{k}s\mu $$

pre-kidney
  • 30,223
  • Thanks a lot :) I hope you don't mind me accepting the other answer. This is also very clear – GRS Mar 24 '16 at 01:25