# Conditional expectation of three exponential distributed r.v.

1. Aug 27, 2010

### Ego7894612

I've been struggling with this problem for more than 4 days now:

Let A, B and C be exponential distributed random variables with parameters lambda_A, lambda_B and lambda_C, respectively.

Calculate E [ B | A < B < C ] in terms of the lambda's.

I always seem get an integral which is impossible to calculate...

Who has a suggestion how to solve this problem?

2. Aug 28, 2010

### bpet

That's how I'd try to do it too, can you show us what you got and where you were stuck?

3. Aug 29, 2010

### Ego7894612

First a remark: we may assume that A, B and C are independent random variables (this may help a lot).

$$E [ B | A < B < C ] = \int_{0}^\infty E [ B \, | \, A < B < C, A = a ] \; f_{A} ( a ) \; da$$
$$= \int_{0}^\infty \int_{0}^\infty E [ B \, | \, A < B < C, A = a, C=c ] \; f_{A} ( a ) \; f_{C} ( c ) \; da \; dc.$$
(Along with all that follows, this integral is only to be considered over R_+^2 and for c>a.)
$$= \int_{0}^\infty \int_{0}^\infty E [ B \, | \, a < B < c, A = a, C=c ] \; f_{A} ( a ) \; f_{C} ( c ) \; da \; dc$$
(by independence)
$$= \int_{0}^\infty \int_{0}^\infty E [ B \, | \, a < B < c ] \; f_{A} ( a ) \; f_{C} ( c ) \; da \; dc$$

We want to compute $$E [ B \, | \, a < B < c ].$$

First note that
$$E [ B \, | \, a < B < c ] = \frac{ \int_a^c t f_{B} (t) dt }{P( B \in [a,c])}.$$

We have$$\int_a^c t f_{B} (t) dt = ... = (a e^{- \lambda_B a} - c e^{- \lambda_B c}) + \frac{1}{\lambda_B} ( e^{- \lambda_B a} - e^{- \lambda_B c} )$$
and
$$P(B \in [a,c]) = F_B (c) - F_B (a) = ... = e^{- \lambda_B a} - e^{- \lambda_B c}.$$

Hence
$$E [ B \, | \, a < B < c ] = \frac{ (a e^{- \lambda_B a} - c e^{- \lambda_B c}) + \frac{1}{\lambda_B} ( e^{- \lambda_B a} - e^{- \lambda_B c} ) }{e^{- \lambda_B a} - e^{- \lambda_B c}},$$
$$E [ B \, | \, a < B < c ] = \frac{ a e^{- \lambda_B a} - c e^{- \lambda_B c} }{e^{- \lambda_B a} - e^{- \lambda_B c}} + \frac{1}{\lambda_B}.$$

So
$$E [ B | A < B < C ] = \int_{0}^\infty \int_{0}^\infty \left( \frac{ a e^{- \lambda_B a} - c e^{- \lambda_B c} }{e^{- \lambda_B a} - e^{- \lambda_B c}} + \frac{1}{\lambda_B} \right) \; f_{A} ( a ) \; f_{C} ( c ) \; da \; dc$$
$$= \int_{0}^\infty \int_{0}^\infty \left( \frac{ a e^{- \lambda_B a} - c e^{- \lambda_B c} }{e^{- \lambda_B a} - e^{- \lambda_B c}} \right) \lambda_A e^{- \lambda_A a} \; \lambda_C e^{- \lambda_C c} \; da \; dc +$$
$$\int_{0}^\infty \int_{0}^\infty \frac{1}{\lambda_B} \lambda_A e^{- \lambda_A a} \; \lambda_C e^{- \lambda_C c} \; da \; dc$$

Here's my problem: I can't compute the first of these integrals... And even then I'm not sure if what I'm doing here is correct... Is my calculation right, or is it wrong!? Is there perhaps a better way to calculate this? Etc.

Last edited: Aug 29, 2010
4. Aug 29, 2010

### bpet

I'm not sure about this line - the marginals of the conditional distribution aren't necessarily exponential. Another approach is to apply directly the definition of conditional probabilities, so that

$$E[B|A<B<C] = E[B.I(A<B<C)]/P[A<B<C]$$

which is a ratio of integrals that should both be tractable.

Hope this helps.

5. Aug 29, 2010

### Ego7894612

Isn't this just the "law of total expectation"?

I don't really understand your point I'm afraid.

EDIT: Yes, we can also go by the second approach.

Then how to calculate $$E[B.I(A<B<C)]$$ exactly ? (I'm not sure how to start with this integral.)

6. Aug 29, 2010

### Ego7894612

I now understand what you mean by "I'm not sure about this line (...)": you're completely right, it's wrong!

7. Aug 29, 2010

### bpet

Ok, this can be simplified to

$$\int_R b.f_A(a).f_B(b).f_C(c)da.db.dc$$

where R is the region a<b<c.