# Confused about how to show independent random variable $Y$ has the Poisson distribution with parameter $t\lambda$

Assume there are $$N$$ independent exponential random variable $$(X_1, X_2,\ldots, X_N)$$ with parameter $$\lambda$$. Fix a real number $$t > 0$$. Let $$Y$$ be the largest $$N$$ so that $$X_1 + X_2 + \ldots + X_N \leqslant t$$ ($$Y = 0$$ if $$X_1 > t$$). How to show independent random variable $$Y$$ has the Poisson distribution with parameter $$t\lambda$$?

Approach: I want to prove that $$P(Y \geqslant k) = 1 - \sum_{j=1}^{k-1} \frac{e^{-\lambda t}(\lambda t)^k}{k!}$$, in order to do this, I wanted to use

\begin{align} & P(Y\geqslant k) = P(X_1 + X_2 + \cdots + X_k \leqslant t) \\[8pt] = {} & \int_{x_1 =0}^t P(X_2 + X_3 + \ldots + X_k \leqslant t - x_1)f_{X_1}(x_1) \, dx_1. \end{align}

• Rather than $\sum_{j=1}^{k-1}$ you should have $\sum_{j=0}^{k-1}. \qquad$ – Michael Hardy Apr 22 at 22:53
• . . . . . and you need $\dfrac{e^{-\lambda t} (\lambda t)^j}{j!},$ i.e. with $j$ rather than $k. \qquad$ – Michael Hardy Apr 22 at 23:09

Let $$S_k:=\sum_{i=1}^k X_i$$ (note that $$S_k\sim \Gamma(k,\lambda^{-1})$$). Then
\begin{align} \mathsf{P}(Y=k)&=\mathsf{P}(S_k\le t, S_k+X_{k+1}>t)=\mathsf{E}\left[1\{S_k\le t\} \mathsf{P}(X_{k+1}>t-S_k\mid S_k)\right] \\ &=\mathsf{E}\left[1\{S_k\le t\}e^{-\lambda(t-S_k)}\right]=\int_0^t\frac{\lambda^k}{(k-1)!}x^{k-1}e^{-\lambda t}\,dx \\ &=\frac{(\lambda t)^ke^{-\lambda t}}{k!}. \end{align}
• Could you elaborate please? What is $S_k$ or S? What is equality of the first line based on? I don't really follow the step. – Chameleon_7 Mar 21 '19 at 4:58
• This one: $P(Y = k) = P(S_k \le t, S_k + X_(k+1) > t) = E[....]$. Also, I haven't learned gamma function yet... Sorry – Chameleon_7 Mar 21 '19 at 5:37
• The first equality is self-evident: $Y=k$ iff $S_k\le t$ and $S_{k+1}>t$. The second one is the law of iterated expectations: for random variables $X$ and $Y$, $\mathsf{E}[f(X)g(Y)]=\mathsf{E}[f(X)\mathsf{E}[g(Y)\mid X]]$. – d.k.o. Mar 21 '19 at 5:40
• $\Gamma(k,\lambda^{-1})$ is the gamma distribution. – d.k.o. Mar 21 '19 at 5:43
Suppose it has been shown that $$f_{X_1+\cdots+X_k}(x) \, dx = \frac 1 {(k-1)!} (\lambda x)^{k-1} e^{-\lambda x} (\lambda \, dx) \text{ for } x>0.$$ Then \begin{align} & \Pr(X_1+\cdots+X_k< t) \\[8pt] = {} & \int_0^t \frac 1 {(k-1)!} (\lambda x)^{k-1} e^{-\lambda x} (\lambda \, dx) \\[8pt] = {} & \frac 1 {(k-1)!} \int_0^{\lambda t} u^{k-1} e^{-u} \, du \\[8pt] = {} & \frac 1 {(k-1)!} \left( \Big[ {-u^{k-1}}e^{-u} \Big]_0^{\lambda t} - \int_0^{\lambda t} (k-1)u^{k-2} (-e^{-u}) \, du \right) \\ & \text{(integration by parts)} \\[8pt] = {} & -\frac{(\lambda t)^{k-1} e^{-\lambda t}}{(k-1)!} + \frac 1{(k-2)!} \int_0^{\lambda t} u^{k-2} e^{-u} \, du \end{align} That last step is valid if $$k-1\ne0.$$ Keep going until you get to the point where it is $$0.$$ That should give you the sum that you're looking for.