[Math] Poisson arrivals during an exponentially distributed interval

probabilityprobability distributionsprobability theoryrandom variables

This is a marked homework question, so please try not to write complete solutions here:

The number of customers that arrive at a service station during a time t is a Poisson random variable with parameter $\beta t$. The time required to service each customer is an exponential random variable with parameter $\alpha$. Identify the distribution of the number of customers $N$ that arrive during the service time $T$ of a specific customer by (a) finding the PMF of $N$ directly (b) finding the MGF of $N$.

My understanding is that we have $P(N=n|T=t)\tilde{}Poisson(\beta t)$ i.e. a Poisson process with rate $\beta$, $P(T=t)\tilde{}exp(\alpha)$, and the question is asking for $P(N=n)$. I tried to find this using marginal distribution, but one random variable is discrete and the other is continuous and I don't know how to take marginal distribution in that case.

Another idea was to find $P(N=n)=P(Y_n<T)=\int_0^\infty\int_0^tf_{Y_n}(y)f_T(t) dydt$ where $Y_n$ denotes time to $n^{th}$ arrival which is $\tilde{}Erlang(n)$. But that looks like overcomplicating it and it certainly doesn't involve MGFs.

Best Answer

For every $n\geqslant0$, $$ P(N=n)=\int_\mathbb RP(N=n\mid T=t)\,f_T(t)\,\mathrm dt=\int_0^\infty\mathrm e^{-\beta t}\,\frac{(\beta t)^n}{n!}\,\alpha\,\mathrm e^{-\alpha t}\,\mathrm dt. $$ The change of variable $s=(\alpha+\beta)t$ yields $$ P(N=n)=\frac{\beta^n\alpha}{(\alpha+\beta)^{n+1}}\int_0^\infty\frac{s^n}{n!}\,\mathrm e^{-s}\,\mathrm ds=(1-p)p^n, $$ where the parameter $p$ in $(0,1)$ is defined by $$ p=\frac{\beta}{\alpha+\beta}. $$ Thus, the distribution of $N$ is geometric with parameter $p$ (of course, this result has a pretty neat "physical" interpretation based on the conditioning properties of the exponential distributions at the basis of Poisson processes).