# Conditional expectation, max, min of random variables

We are given two independent random variables $A, B$ with uniform distribution on $[0,1]$. We define new random variables $X = \max (A,B)$ and $Y = \min (A,B)$.

Find $\mathbb{E}(X\mid Y)$

(defined as the one, up to measure zero, random variable which satisfies $\sigma (\mathbb{E}(X\mid Y)) \subset \sigma(Y))$ and $\forall B \in \sigma(Y) : \int_B X \, dP = \int_B \mathbb{E}(X\mid Y) \, dP$).

I've done this by finding distribution function of $(X, Y)$ and then joint density function $f_{XY}(x,y)$ and then using the formula $$\mathbb{E}(X\mid Y) = \frac{1}{f_Y(Y)}\int_{\mathbb{R}}x f_{XY}(x,Y) \, dx$$

I wonder if there is a clearer, shorter, less time consuming way of dealing with this problem.

• I assume $X$, $Y$ are independent? If you got the right answer, you would see that there is a clear interpretation as a "shorter" way of doing it. – Michael May 14 '15 at 13:55
• So, what answer did you get? – Michael May 14 '15 at 14:06
• By symmetry in the independent case you can assume without loss of generality that $A$ is the min. Suppose $A=y$. Then find hte conditional PDF of $B$ given $B>y$. – Michael May 14 '15 at 14:19
• Okay, that is correct. Can you reverse-engineer that solution $(1+Y)/2$? Thinking in terms of my previous comment about the PDF of $B$ given $B>y$? – Michael May 14 '15 at 14:32
• – Michael May 14 '15 at 14:35

## 1 Answer

The case when $A$ and $B$ are independent you can do in your head. For the general dependent case, instead of finding $f_{XY}(x,y)$, you can compute $E[X|Y=y]$ by integrating $f_{AB}(a,b)$ over the line segments:
$$\{(a, y) : a\in [y,1]\}\cup \{(y,b) : b \in [y,1]\}$$

So: $$E[X|Y=y] = \frac{\int_{y}^1 af_{AB}(a,y)da + \int_{y}^1 bf_{AB}(y,b)dy}{\int_{y}^1f_{AB}(a,y)da + \int_{y}^1f_{AB}(y,b)dy}$$

If $A$ and $B$ are independent then $f_{AB}(a,b)=1$ for all $a,b \in [0,1]$ and the above integrals give $E[X|Y=y]=(1+y)/2$.

Of course, a more intuitive way in the independent case is to just observe that, given the min is $y$, the max is uniformly distributed over $[y,1]$, so its mean is the midpoint $(1+y)/2$.

• Thank you a lot for all your help and the edit! – Amith May 15 '15 at 6:00