Conditional expectation of $\max(X,Y)$ and $\min(X,Y)$ when $X,Y$ are iid and exponentially distributed I am trying to compute the conditional expectation $$E[\max(X,Y) | \min(X,Y)]$$ where $X$ and $Y$ are two iid random variables with $X,Y \sim \exp(1)$. 
I already calculated the densities of $\min(X,Y)$ and $\max(X,Y)$, but I failed in calculating the joint density. Is this the right way? How can I compute the joint density then? Or do I have to take another ansatz? 

For two independent exponential distributed variables $(X,Y)$, the joint distribution is
$$
   \mathbb{P}(x,y) = \mathrm{e}^{-x-y} \mathbf{1}_{x >0 } \mathbf{1}_{y >0 } \, \mathrm{d} x \mathrm{d} y
$$
Since $x+y = \min(x,y) + \max(x,y)$, and $\min(x,y) \le \max(x,y)$ the joint distribution of 
$(U,V) = (\min(X,Y), \max(X,Y))$ is
$$
   \mathbb{P}(u,v) = \mathcal{N} \mathrm{e}^{-u-v}  \mathbf{1}_{v \ge u >0 } \, \mathrm{d} u \mathrm{d} v
$$
The normalization constant is easy to find as
$$
   \int_0^\infty \mathrm{d} v \int_0^v \mathrm{d} u \,\, \mathrm{e}^{-u-v} = 
   \int_0^\infty \mathrm{d} v \,\, \mathrm{e}^{-v} ( 1 - \mathrm{e}^{-v} ) = 1 - \frac{1}{2} = \frac{1}{2} = \frac{1}{\mathcal{N}}  
$$
Thus the conditional expectation we seek to find is found as follows (assuming $u>0$):
$$
   \mathbb{E}(\max(X,Y) \vert \min(X,Y) = u) = \frac{\int_0^\infty v \mathrm{d} P(u,v)}{\int_u^\infty \mathrm{d} P(u,v)} = \frac{\int_u^\infty  \mathcal{N} v \mathrm{e}^{-u-v} \mathrm{d} v}{\int_u^\infty  \mathcal{N} \mathrm{e}^{-u-v} \mathrm{d} v} = 1 + u
$$ 
