Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am given a joint probability density function for X, Y, defined as $f(x, y) = 1,$ for $0 \leq x \leq 1, 0 \leq y \leq 1,$ and $0$ elsewhere. I need to find $P(X-Y \leq \frac{1}{2})$, $P(XY \leq \frac{1}{4}),$ and $P(X^2 + Y^2 \leq 1).$ I solved these using the geometric approach for uniform distributions, but can someone show how to do this with double integrals? I tried, but kept messing up the limits of the integration.

share|cite|improve this question
up vote 1 down vote accepted

If $x$ and $y$ are positive, then $xy\le 1/4$ is the same as $x \le 1/(4y)$. We also need $x\le 1$, so $x \le 1\text{ or }1/(4y)\text{, whichever is less}$. Now $1/(4y)\le 1$ precisely if $y\ge1/4$. So if $y$ is between $0$ and $1/4$, then $x$ goes from $0$ to $1$, but if $y$ is between $1/4$ and $1$, then $x$ goes from $0$ to $1/(4y)$. So inside of $\displaystyle\int_0^{1/4}\cdots dy$, where the "$\cdots$" appears, put $\displaystyle\int_0^1 1\;dx$. Then to that you add $\displaystyle\int_{1/4}^1\cdots dy$, and inside that you have $\displaystyle\int_0^{1/(4y)} 1\;dx$.

If $x,y\ge0$ then $x^2+y^x \le 1$ is the same as $y\le \sqrt{1-x^2}$, so inside the integral $\displaystyle\int_0^1 \cdots dx$ you can put $\displaystyle\int_0^\sqrt{1-x^2} 1\;dy$.

If $x,y\ge0$ and $\le 1$, then $x-y \le 1/2$ can be viewed like this: for $x$ between $0$ and $1/2$, $y$ goes all the way from $0$ to $1$, but for $x$ between $1/2$ and $1$, $y$ goes from $x-1/2$ to $1$. So inside of $\displaystyle \int_0^{1/2}\cdots dx$ you have $\displaystyle\int_0^1 1\; dy$, and to that you add $\displaystyle\int_{1/2}^1 \cdots dx$, and inside it you have $\displaystyle\int_{x-1/2}^1 1\;dy$.

share|cite|improve this answer
thanks, but I have less than or equal to 1/4, not 4 – problm12 Oct 31 '11 at 2:22

Just one: $$ \mathrm P(XY\leqslant1/4)=\int\limits_0^{1/4}\int\limits_0^1\mathrm dy\ \mathrm d x+\int\limits_{1/4}^1\int\limits_0^{1/(4x)}\mathrm dy\ \mathrm d x=\int\limits_0^{1/4}\mathrm d x+\int\limits_{1/4}^1\frac{\mathrm d x}{4x}=\left[x\right]_{x=0}^{x=1/4}+\frac14\left[\log x\right]_{x=1/4}^{x=1}, $$ hence $\mathrm P(XY\leqslant\frac14)=\frac14-\frac14\log\frac14=\frac14+\frac12\log2$.

The other answers are $\mathrm P(X-Y\leqslant\frac12)=\frac78$ (thanks to a similar decomposition into two integrals, one over $x\leqslant\frac12$ and the other over $x\geqslant\frac12$) and $\mathrm P(X^2+Y^2\leqslant1)=\frac\pi4$ (no decomposition).

share|cite|improve this answer
Thank you, but could you explain me how you got there? I can't see how the two integrals come up. I think I did only the second one, and that's why my answer was wrong. – problm12 Oct 31 '11 at 2:26
and in general, how to think of these problems would be very helpful – problm12 Oct 31 '11 at 2:29
You want to integrate the density, which is $1$ on the square and $0$ elsewhere, on the domain where $xy\leqslant1/4$. Hence you are interested in the region defined by $0\leqslant x\leqslant1$, $0\leqslant y\leqslant1$, and $xy\leqslant1/4$, which you can rewrite as $0\leqslant x\leqslant 1$ and $0\leqslant y\leqslant\min\{1,1/(4x)\}$. After that, you wonder where $1\leqslant1/(4x)$, and there the condition on $y$ is $0\leqslant y\leqslant1$, and where $1/(4x)\leqslant1$, and there the condition on $y$ is $0\leqslant y\leqslant1/(4x)$. – Did Oct 31 '11 at 2:44
thank you so much! – problm12 Oct 31 '11 at 6:06

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.