# How to use joint probability function to find probabilities

If $f(X_1,X_2) = x_1 x_2$ where $0 < x_1 < x_2 < 1$, find the $P(X_1+X_2\le 1)$. I am having a hard time setting this integral up. How do you do these type of problems.

Attempt:

I know the limits for $x_2$ in the integral are $x_1$ to $1-x_1$ but I am stuck here. I cannot visualize this.

-
Well, to begin with, do you think this $f$ is a density function? – Did Feb 21 '12 at 16:37
@lord12: You are missing a constant. – André Nicolas Feb 21 '12 at 16:43
If you mean $f(x_1,x_2) = x_1 x_2$ please don't write $f(X_1,X_2) = x_1 x_2$. If you want to consider something like $\Pr(X_1 \le x_1)$, the difference between the capital letter and the lower-case letter is crucial. – Michael Hardy Feb 21 '12 at 16:57

Note, as Didier Piau implies in the comments, your function is not a density. I believe you want $f(x_1,x_2)=8 x_1x_2$ for $0<x_1<x_2<1$ and $f(x_1,x_2)=0$, otherwise. Note that the density is $0$ below the line $\color{gray}{x_2=x_1}$.

To find the probability that $X_1+X_2\le1$, sketch the region first. It's the region beneath the line $\color{darkgreen}{x_2=1-x_1}$ (the pink and green regions in the diagram below). But since the density is 0 beneath the line $\color{gray}{x_2=x_1}$, we may just consider the pink region shaded below (over the green region, we're integrating to zero function).

So, to set up the integral over the pink region, let's think of that region as being generated by the line segments $\color{darkgreen}{\ell_{x_1}}$ that "sweep" across it from $x_1=0$ to $x_1=1/2$.
The inner integral corresponds to integrating over a fixed line segment, $\color{darkgreen}{\ell_{x_1}}$ , with respect to $x_2$. The lower limit is the bottom of the line segment and the upper limit is the top of the line segment. Make sure the limits of integration are in terms of $x_1$: $$\int_{x_1}^{1-{x_1}} f(x_1,x_2)\,dx_2.$$ Then you integrate the above expression as the line segments range from $x_1=0$ to $x_1=1/2$: $$\int_0^{1/2}\int_{x_1}^{1-{x_1}} f(x_1,x_2)\,dx_2\, dx_1.$$

-
24?    – Did Feb 21 '12 at 17:12
@DidierPiau Thank you. 8 might be better (unless I miscalculated again...) – David Mitra Feb 21 '12 at 17:34
@David Mitra: I computed in two different ways, and got $8$ each time. But it would not be the first time that I made two different mistakes. – André Nicolas Feb 21 '12 at 17:40
The reason why the density is 0 under the green section is because x2 < x1 which is not in our support? – lord12 Feb 21 '12 at 20:55
@lord12 Yes, that's correct. – David Mitra Feb 21 '12 at 20:58