Let $X_1$ and $X_2$ be independent and identically distributed exponential random variables with rate $\lambda$. Let $S_2 = X_1 + X_2$.

Q: Show that $S_2$ has PDF $f_{S_2}(x) = \lambda^2 x \text{e}^{-\lambda x},\, x\ge 0$.

Note that if events occurred according to a Poisson Process (PP) with rate $\lambda$, $S_2$ would represent the time of the 2nd event.

Alternate approaches are appreciated. The approaches provided are commonly used when learning queueing theory & stochastic processes.

Recall the Exponential distribution is a special case of the Gamma distribution (with shape parameter $1$). I've learned there is a more general version of this here that can be applied.

  • $\begingroup$ This question is a very special case (and one of the simplest possible examples) of a sum of Gamma distributions. (The Exponential is a Gamma distribution with a shape parameter of $1.$) Thus, you could apply any of the answers at stats.stackexchange.com/questions/72479. $\endgroup$ – whuber Aug 12 at 12:28
  • $\begingroup$ Thank you. I was unaware of that more general question, though I did know the Exponential is a Gamma distribution with a shape parameter of 1. I hope you'll agree this Q/A is ok as-is and shouldn't be deleted. This is a very frequent question in some engineering disciplines and is certainly more accessible than jumping straight into adding Gamma distributions. $\endgroup$ – SecretAgentMan Aug 12 at 21:38
  • $\begingroup$ @whuber I've updated the question specifically mention the more general question. Thank you. $\endgroup$ – SecretAgentMan Aug 12 at 21:40
  • $\begingroup$ For the reasons you gave, and because you have offered a clear account of solutions that work specifically in this case, I have not voted to close this as a duplicate. $\endgroup$ – whuber Aug 12 at 21:46
  • $\begingroup$ @whuber Thank you. I'll go with whatever you & the community think best. It was a honest mistake -- I didn't see the other post. FWIW, I've updated the question a bit more to highlight some context for this approach (queueing theory & stochastic processes). $\endgroup$ – SecretAgentMan Aug 12 at 21:48

Conditioning Approach
Condition on the value of $X_1$. Start with the cumulative distribution function (CDF) for $S_2$.

$\begin{align} F_{S_2}(x) &= P(S_2\le x) \\ &= P(X_1 + X_2 \le x) \\ &= \int_0^\infty P(X_1+X_2\le x|X_1=x_1)f_{X_1}(x_1)dx_1 \\ &= \int_0^x P(X_1+X_2\le x|X_1=x_1)\lambda \text{e}^{-\lambda x_1}dx_1 \\ &= \int_0^x P(X_2 \le x - x_1)\lambda \text{e}^{-\lambda x_1}dx_1 \\ &= \int_0^x\left(1-\text{e}^{-\lambda(x-x_1)}\right)\lambda \text{e}^{-\lambda x_1}dx_1\\ &=(1-e^{-\lambda x}) - \lambda x e^{-\lambda x}\end{align} $

This is the CDF of the distribution. To get the PDF, differentiate with respect to $x$ (see here).

$$f_{S_2}(x) = \lambda^2 x \text{e}^{-\lambda x} \quad\square$$

This is an Erlang$(2,\lambda)$ distribution (see here).

General Approach
Direct integration relying on the independence of $X_1$ & $X_2$. Again, start with the cumulative distribution function (CDF) for $S_2$.

$\begin{align} F_{S_2}(x) &= P(S_2\le x) \\ &= P(X_1 + X_2 \le x) \\ &= P\left( (X_1,X_2)\in A \right) \quad \quad \text{(See figure below)}\\ &= \int\int_{(x_1,x_2)\in A} f_{X_1,X_2}(x_1,x_2)dx_1 dx_2 \\ &(\text{Joint distribution is the product of marginals by independence}) \\ &= \int_0^{x} \int_0^{x-x_{2}} f_{X_1}(x_1)f_{X_2}(x_2)dx_1 dx_2\\ &= \int_0^{x} \int_0^{x-x_{2}} \lambda \text{e}^{-\lambda x_1}\lambda \text{e}^{-\lambda x_2}dx_1 dx_2\\ \end{align}$

Since this is the CDF, differentiation gives the PDF, $f_{S_2}(x) = \lambda^2 x \text{e}^{-\lambda x} \quad\square$ Figure

MGF Approach
This approach uses the moment generating function (MGF).

$\begin{align} M_{S_2}(t) &= \text{E}\left[\text{e}^{t S_2}\right] \\ &= \text{E}\left[\text{e}^{t(X_1 + X_2)}\right] \\ &= \text{E}\left[\text{e}^{t X_1 + t X_2}\right] \\ &= \text{E}\left[\text{e}^{t X_1} \text{e}^{t X_2}\right] \\ &= \text{E}\left[\text{e}^{t X_1}\right]\text{E}\left[\text{e}^{t X_2}\right] \quad \text{(by independence)} \\ &= M_{X_1}(t)M_{X_2}(t) \\ &= \left(\frac{\lambda}{\lambda-t}\right)\left(\frac{\lambda}{\lambda-t}\right) \quad \quad t<\lambda\\ &= \frac{\lambda^2}{(\lambda-t)^2} \quad \quad t<\lambda \end{align}$

  • 3
    $\begingroup$ You wrote both the question and the answer. What is your point, if I may ask? $\endgroup$ – Xi'an Oct 14 '18 at 11:58
  • 8
    $\begingroup$ @Xi'an, I thought SE encouraged asking the question and answering it...I can screenshot where SE seems to encourage that for you if you want. I've seen a lot of basic questions repeatedly asked and I've been thinking about posting some specific approaches to refer people to. I wasn't able to find something like this and I can refer people to this for a variety of things. If the CV community really hates this post that much, I will voluntarily delete it. $\endgroup$ – SecretAgentMan Oct 15 '18 at 14:31
  • 2
    $\begingroup$ @Xi'an, Respectfully, I believe you both asked and answered a question here. $\endgroup$ – SecretAgentMan Oct 15 '18 at 17:24
  • 3
    $\begingroup$ @Xi'an You may wish to read stats.stackexchange.com/help/self-answer $\endgroup$ – Sycorax Oct 15 '18 at 17:37
  • 1
    $\begingroup$ An easier solution would be to use moment generating functions $\endgroup$ – kjetil b halvorsen Nov 19 '18 at 20:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.