# Thread: Convolution of Exponential Random Variables

1. ## Convolution of Exponential Random Variables

Let $T_1, T_2$ be independent exponential variables with parameters $\lambda_1, \lambda_2$ respectively. Find the density function of $R = T_1 - T_2$.

I get a piecewise density function (for $r > 0, r \leq 0$):

$
f_R (r) = \frac{\lambda_1\lambda_2}{\lambda_1+\lambda_2} e^{{-\lambda_2}r}, r>0$

$f_R (r) = \frac{\lambda_1\lambda_2}{\lambda_1+\lambda_2} e^{{\lambda_1}r}, r\leq 0$

The answer given however is simply that the density function is exponential without further information. I was wondering if my answer is correct?

P.S. I can't seem to do piecewise using normal LaTeX code; is it different in these forums?

2. The first one should have $e^{-\lambda_1 r}$ I think but other than that it seems fine.

If you have problems with latex, post it in the latex subforum, 'tis working fine for me.

3. Originally Posted by h2osprey
Let $T_1, T_2$ be independent exponential variables with parameters $\lambda_1, \lambda_2$ respectively. Find the density function of $R = T_1 - T_2$.

I get a piecewise density function (for $r > 0, r \leq 0$):

$
f_R (r) = \left\{\begin{array}{c}\frac{\lambda_1\lambda_2}{\ lambda_1+\lambda_2} e^{{-\lambda_2}r}, r>0\\ \frac{\lambda_1\lambda_2}{\lambda_1+\lambda_2} e^{{\lambda_1}r}, r\leq 0\end{array}\right.$

The answer given however is simply that the density function is exponential without further information. I was wondering if my answer is correct?

P.S. I can't seem to do piecewise using normal LaTeX code; is it different in these forums?
There is a mistake in the exponents: it is $e^{-\lambda_1 r}$ when $r>0$ and $e^{-\lambda_2 r}$ else.

How to find the result with little computation (but some nontrivial knowledge): first, the probability that $T_1>T_2$ is $\frac{\lambda_2}{\lambda_1+\lambda_2}$ (classic useful computation); then, by the memoryless property of exponential distribution, conditionally to $T_2$ and to the event $\{T_1>T_2\}$, the distribution of $T_1-T_2$ is exponential with parameter $\lambda_1$ (note that since this distribution does not depend on $T_2$, it was unnecessary to condition by $T_2$). This gives the " $r>0$" part: $\frac{\lambda_2}{\lambda_1+\lambda_2}\lambda_1 e^{-\lambda_1 r}$, and symmetry gives the other part.

4. Originally Posted by Laurent
There is a mistake in the exponents: it is $e^{-\lambda_1 r}$ when $r>0$ and $e^{-\lambda_2 r}$ else.

How to find the result with little computation (but some nontrivial knowledge): first, the probability that $T_1>T_2$ is $\frac{\lambda_2}{\lambda_1+\lambda_2}$ (classic useful computation); then, by the memoryless property of exponential distribution, conditionally to $T_2$ and to the event $\{T_1>T_2\}$, the distribution of $T_1-T_2$ is exponential with parameter $\lambda_1$ (note that since this distribution does not depend on $T_2$, it was unnecessary to condition by $T_2$). This gives the " $r>0$" part: $\frac{\lambda_2}{\lambda_1+\lambda_2}\lambda_1 e^{-\lambda_1 r}$, and symmetry gives the other part.
Yes, turns out I switched the numbers while typing the problem: the original question was $R = T_2 - T_1$. However, regarding the pdf when $r \leq 0$ shouldn't there be a negative sign? If not it gets very, very large indeed..

and thanks for the LaTeX code!

5. Originally Posted by h2osprey
However, regarding the pdf when $r \leq 0$ shouldn't there be a negative sign? If not it gets very, very large indeed..
Yes, sure, it's $e^{\lambda_2 r}$ for $r<0$; the only mistake was with indices 1 and 2, due to switch them in the definition.