# +conditional density of sum of random variables

Let $X$ and $Y$ be two independent random variables distributed uniformly on $[0,1].$ How can I compute the following density:

$$f(X+Y|\max\{X,Y\}<a)\ \text{for}\ a\in [0,1]?$$

More generally, what is the formula for the pdf of the sum of two (independent) r.v. conditional on only knowing that the highest of the two can't exceed a given threshold?

• What happened to the other answer? I actually thought it made sense...was it incorrect? – Econ Apr 23 '15 at 13:58

EDITED HINT

In order to calcultae the density, you sometimes calculate the distribution function and then derive it, if it is possible. In our case we have a conditional density to be calculated. So we calculate the conditional cdf first. By definition, $$F_{X+Y|\max(X,Y)<a}(u)=P(X+Y<u|\max(X,Y)<a)=\frac{P(X+Y<u \cap \max(X,Y)<a)}{P(\max(X,Y)<a)}.$$ Then $$P(\max(X,Y)<a)=P(\max(X,Y)=X\cap X<a)+P(\max(X,Y)=Y \cap Y<a)=$$ $$=P(X\le Y\cap X<a)+P(Y\le X \cap Y<a).$$

Now, can you identify the the areas below? (Not the red, not the blue, Which ones?)

Then you can go ahead with the nominator being more complicated. But in that case you have the colored figures. Watch "a".

• Hint: shouldn't the two areas be equal? Hence, it is 2*blue (or 2*red). – Econ Apr 23 '15 at 13:54
• @Econ, Red=$\{x<y, \text{and } x+y<u, \text{and } y<a\}$ Blue=$\{y<x, \text{and } x+y<u, \text{and } x<a\}$. For symmetry reasons the two areas equal. Do they not look so? – zoli Apr 23 '15 at 13:59
• they do indeed! – Econ Apr 23 '15 at 14:00
• But I also would like to see the general formula. A previous answer showed but now I can't see it anymore. – Econ Apr 23 '15 at 14:15
• @Econ, don't you want to ... OK. I ... – zoli Apr 23 '15 at 17:10