# Clearification on Exponential Distribution

• Nov 23rd 2008, 02:37 PM
lllll
Clearification on Exponential Distribution
Assume $\displaystyle X_1$ and $\displaystyle X_2$ are independent random variables, both following a exponential distribution. Calculate $\displaystyle P\{X_1<X_2\}$

The way it's done in the book

$\displaystyle P\{X_1 < X_2\} = \int_0^\infty P\{X_1 < X_2|X_1 = x\} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ (a)

$\displaystyle = \int_0^\infty P\{ x< X_2\} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ (b)

$\displaystyle = \int_0^\infty e^{-\lambda_2x}{\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ (c)

I'm wondering is why are they putting the pdf of exponential function (the part in blue)?

in part (b) would is it $\displaystyle \int_0^\infty \frac{P\{X_1 < X_2, X=x\}}{P\{X_1=x\}} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ $\displaystyle \Longrightarrow \int_0^\infty \frac{P\{X_1 < X_2\} P\{X=x\}}{P\{X_1=x\}} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ $\displaystyle \Longrightarrow \int_0^\infty P\{ x< X_2\} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$

in part (c) isn't it $\displaystyle P\{ x< X_2\} = \lambda_2 e^{-\lambda_2x}$, therefore wouldn't it be: $\displaystyle \int_0^\infty {\color [cmyk] {0.75,0,0.75,0.45}\lambda_2}e^{-\lambda_2x}{\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$

why isn't there a $\displaystyle {\color [cmyk] {0.75,0,0.75,0.45}\lambda_2}$?
• Nov 23rd 2008, 06:41 PM
mr fantastic
Quote:

Originally Posted by lllll
Assume $\displaystyle X_1$ and $\displaystyle X_2$ are independent random variables, both following a exponential distribution. Calculate $\displaystyle P\{X_1<X_2\}$

The way it's done in the book

$\displaystyle P\{X_1 < X_2\} = \int_0^\infty P\{X_1 < X_2|X_1 = x\} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ (a)

$\displaystyle = \int_0^\infty P\{ x< X_2\} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ (b)

$\displaystyle = \int_0^\infty e^{-\lambda_2x}{\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ (c)

I'm wondering is why are they putting the pdf of exponential function (the part in blue)?

in part (b) would is it $\displaystyle \int_0^\infty \frac{P\{X_1 < X_2, X=x\}}{P\{X_1=x\}} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ $\displaystyle \Longrightarrow \int_0^\infty \frac{P\{X_1 < X_2\} P\{X=x\}}{P\{X_1=x\}} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$ $\displaystyle \Longrightarrow \int_0^\infty P\{ x< X_2\} {\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$

in part (c) isn't it $\displaystyle P\{ x< X_2\} = \lambda_2 e^{-\lambda_2x}$, therefore wouldn't it be: $\displaystyle \int_0^\infty {\color [cmyk] {0.75,0,0.75,0.45}\lambda_2}e^{-\lambda_2x}{\color{blue}\lambda_1 e^{-\lambda_1x}} \ dx$

why isn't there a $\displaystyle {\color [cmyk] {0.75,0,0.75,0.45}\lambda_2}$?

Here is how I would do it:

The joint pdf of $\displaystyle X_1$ and $\displaystyle X_2$ is $\displaystyle f(x_1, x_2) = \lambda_1 \lambda_2 e^{-\lambda_1 x_1} e^{-\lambda_2 x_2}$.

Then $\displaystyle \Pr(X_1 < X_2) = \int_{x_2 = 0}^{x_2 = +\infty} \int_{x_1 = 0}^{x_1 = x_2} f(x_1, x_2) \, dx_1 \, dx_2 = \, ....$
• Nov 23rd 2008, 10:38 PM
lllll
just out of curiosity, if you were to add a third variable $\displaystyle X_3$ which is also independent and follows an exponential distribution, and wanted to calculate

$\displaystyle P\{X_1<X_2<X_3\}$ would you simply have a triple integral such as:

$\displaystyle P\{X_1<X_2<X_3\} = \int^{x_1=+\infty}_{x_1=0} \int^{x_2=+\infty}_{x_2=x_1} \int^{x_3=+\infty}_{x_3=x_2} f(x_1,x_2,x_3) \ dx_1 \ dx_2 \ dx_3$

where $\displaystyle f(x_1,x_2,x_3) = \lambda_1 e^{-\lambda_1 x_1} \cdot \lambda_2 e^{-\lambda_2 x_2} \cdot \lambda_3 e^{-\lambda_3 x_3}$ ?
• Nov 23rd 2008, 10:41 PM
mr fantastic
Quote:

Originally Posted by lllll
just out of curiosity, if you were to add a third variable $\displaystyle X_3$ which is also independent and follows an exponential distribution, and wanted to calculate

$\displaystyle P\{X_1<X_2<X_3\}$ would you simply have a triple integral such as:

$\displaystyle P\{X_1<X_2<X_3\} = \int^{x_1=+\infty}_{x_1=0} \int^{x_2=+\infty}_{x_2=x_1} \int^{x_3=+\infty}_{x_3=x_2} f(x_1,x_2,x_3) \ dx_1 \ dx_2 \ dx_3$

where $\displaystyle f(x_1,x_2,x_3) = \lambda_1 e^{-\lambda_1 x_1} \cdot \lambda_2 e^{-\lambda_2 x_2} \cdot \lambda_3 e^{-\lambda_3 x_3}$ ?

I'd calculate it as $\displaystyle \Pr(X_2 < X_3) - \Pr(X_2 < X_1)$.
• Dec 12th 2008, 06:58 AM
Laurent
Quote:

Originally Posted by mr fantastic
I'd calculate it as $\displaystyle \Pr(X_2 < X_3) - \Pr(X_2 < X_1)$.

Not quite, since this even can be negative... It should be:
$\displaystyle P(X_1<X_2<X_3)=P(X_2<X_3)-P(X_2<X_3\mbox{ and }X_2\leq X_1)$$\displaystyle =P(X_2<X_3)-P(X_2<\min(X_1,X_3)) and it is well known that \displaystyle \min(X_1,X_3) is an exponential random variable of parameter \displaystyle \lambda_1+\lambda_3, and it is independent of \displaystyle X_2 so, in application of the result of your initial question, \displaystyle P(X_1<X_2<X_3)=\frac{\lambda_2}{\lambda_2+\lambda_ 3}-\frac{\lambda_2}{\lambda_1+\lambda_2+\lambda_3}=\f rac{\lambda_1\lambda_2}{(\lambda_1+\lambda_2)(\lam bda_1+\lambda_2+\lambda_3)} One easily checks that the integral gives the same result. By the way, the computation of the integral gives by induction the general formula: \displaystyle P(X_1<\cdots<X_n)=\frac{\lambda_1\cdots\lambda_{n-1}}{(\lambda_n+\lambda_{n-1})(\lambda_n+\lambda_{n-1}+\lambda_{n-2})\cdots(\lambda_n+\cdots+\lambda_1)} • Dec 12th 2008, 12:38 PM mr fantastic Quote: Originally Posted by Laurent Not quite, since this even can be negative... It should be: \displaystyle P(X_1<X_2<X_3)=P(X_2<X_3)-P(X_2<X_3\mbox{ and }X_2\leq X_1)$$\displaystyle =P(X_2<X_3)-P(X_2<\min(X_1,X_3))$
and it is well known that $\displaystyle \min(X_1,X_3)$ is an exponential random variable of parameter $\displaystyle \lambda_1+\lambda_3$, and it is independent of $\displaystyle X_2$ so, in application of the result of your initial question,
$\displaystyle P(X_1<X_2<X_3)=\frac{\lambda_2}{\lambda_2+\lambda_ 3}-\frac{\lambda_2}{\lambda_1+\lambda_2+\lambda_3}=\f rac{\lambda_1\lambda_2}{(\lambda_1+\lambda_2)(\lam bda_1+\lambda_2+\lambda_3)}$

One easily checks that the integral gives the same result. By the way, the computation of the integral gives by induction the general formula:
$\displaystyle P(X_1<\cdots<X_n)=\frac{\lambda_1\cdots\lambda_{n-1}}{(\lambda_n+\lambda_{n-1})(\lambda_n+\lambda_{n-1}+\lambda_{n-2})\cdots(\lambda_n+\cdots+\lambda_1)}$

Ha. Thanks for the catch. Obvious in hindsight, I'm annoyed I missed it the first time.