# Expectation with exponential random variable

If $X_i$, $i=1,2,3$ are independent exponential random variable with rates $\lambda_i$, find $$E[\max(X_i) \mid X_1<X_2<X_3]$$

I really did not understand this exercise, because if $$X_1<X_2<X_3\Rightarrow X_3=\max(X_i)$$ right?

So it should not simply be $$E[\max(X_i) \mid X_1<X_2<X_3]=E[X_3]$$ because the memorylessness?

EDIT: Let $X_{(n)}$ the maximum $$F_{X_{(n)}}=F_{X_1}(x)F_{X_2}(x)F_{X_3}(x)=(1-e^{-\lambda_1x})(1-e^{-\lambda_2x})(1-e^{-\lambda_3x})$$ $$=1-e^{-\lambda_2x}-e^{-\lambda_1x}+e^{-(\lambda_1+\lambda_2)x}-e^{-\lambda_3x}+e^{-(\lambda_2+\lambda_3)x}+e^{-(\lambda_1+\lambda_3)x}-e^{-(\lambda_1+\lambda_2+\lambda_3)x}$$ $$E[X_{(n)}]=\int_0^\infty 1-F_{X_{(n)}}dx$$ $$=\int_0^\infty e^{-\lambda_2x}+e^{-\lambda_1x}-e^{-(\lambda_1+\lambda_2)x}+e^{-\lambda_3x}-e^{-(\lambda_2+\lambda_3)x}-e^{-(\lambda_1+\lambda_3)x}+e^{-(\lambda_1+\lambda_2+\lambda_3)x}$$ $$=\frac{1}{\lambda_2}+\frac{1}{\lambda_1}-\frac{1}{\lambda_1+\lambda_2}+\frac{1}{\lambda_3}-\frac{1}{\lambda_2+\lambda_3}-\frac{1}{\lambda_1+\lambda_3}+\frac{1}{\lambda_1+\lambda_2+\lambda_3}$$

I tried some simplifications, but could not get the answer

EDIT: The book answer is $$E[\max(X_i) \mid X_1<X_2<X_3]=\frac{1}{\lambda_1+\lambda_2+\lambda_3}+\frac{1}{\lambda_2+\lambda_3}+\frac{1}{\lambda_3}$$

• $\mathbb E[\max_i X_i \mid X_1 < X_2 < X_3]$ is a random variable, not a number. Commented Jul 19, 2015 at 23:29
• It will be the expectation of the max, you wrote that down but changed your mind. Commented Jul 19, 2015 at 23:31
• If we are told that $X_1\lt X_2\lt X_3$, then we know that $X_3$ is the max. Nothing is added from knowing that $X_1\lt X_2$. The distribution, and hence expectation, of the max is not hard to calculate, find the cdf of the max. Commented Jul 19, 2015 at 23:46
• the desired quantity is equal to $$\frac{\mathbb{E}\big( \max\{ X_1, X_2, X_3\} \cdot 1_{ (X_1 < X_2 < X_3)} \big) }{ \mathbb{P}(X_1 < X_2 < X_3) } \cdot 1_{ (X_1 < X_2 < X_3)} =\frac{\mathbb{E}\big(X_3 \cdot 1_{ (X_1 < X_2 < X_3)} \big) }{ \mathbb{P}(X_1 < X_2 < X_3) } \cdot 1_{ (X_1 < X_2 < X_3)}$$ which is a random variable, not a deterministic number. Commented Jul 20, 2015 at 4:01
• @Chival: $\mathrm{E}[Y\mid A]=\mathrm{E}[Y\mathbf{1}_A]/P(A)$ for any event $A$ with $P(A)>0$. Hence you have an indicator function too much. Commented Jul 20, 2015 at 12:44

Hint: $\mathsf E(\max_i X_i \mid X_1<X_2<X_3) = \mathsf E(X_3 \;\mathbf 1_{X_3>X_2>X_1})\big/ \mathsf P(X_3>X_2>X_1) \\ = \dfrac{\int_0^\infty \int_0^{x_3}\int_0^{x_2} x_3f_{X_3}(x_3)f_{X_2}(x_2)f_{X_1}(x_1)\operatorname d x_1 \operatorname d x_2\operatorname d x_3}{\int_0^\infty \int_0^{x_3}\int_0^{x_2} f_{X_3}(x_3)f_{X_2}(x_2)f_{X_1}(x_1)\operatorname d x_1 \operatorname d x_2\operatorname d x_3}$