# Basic question related to cdf and pdf of random variables

If there are two independent random variables $X$ and $Y$ (there can have only non-negative values) with corresponding pdfs and cdfs as $f_X(x), f_Y(y)$, $F_X(x),F_Y(y)$ respectively. Then in what case the following formula is correct $$\int_0^{\infty}f_Y(y)F_X(y)dy=0$$ This question is raised from a previous question Compute the CDF of $\left[\log_2(1+X)-\log_2(1+Y)\right]^+$ . Thanks in advance.

You're asking when is $$E[F_X(Y) ] = 0$$
Since $F_X$ is a nonnegative function, we need that $F_X(Y) = 0$ almost surely, that is, that $Y <x^*$ almost surely, where $$x^* = \inf\{ x: F_X(x) > 0\}$$
Note that the independence assumption is irrelevant since $X$ appears only through its CDF $F_X$.
• This answer is incorrect. Indeed the integral is $E(F_X(Y))$ hence it is zero if and only if $F_X(Y)=0$ almost surely, that is, $Y<x^*$ almost surely, where $x^*=\inf\{x\mid F_X(x)>0\}$, that is, $P(Y'\leqslant X')=1$ for every realization $X'$ of $X$ and $Y'$ of $Y$. This is asking strictly more than the property that $P(Y\leqslant X)=1$, for example, $X$ uniform on $(0,2)$ and $Y=X-1$ are such that $P(Y\leqslant X)=1$ but $E(F_X(Y))=\frac14$. (Note to the OP: Accepting answers on the spot has the undesired consequence that less users view the page and can check it.) – Did Sep 1 '16 at 15:57
• Indeed, and the condition [$Y<x^*$ almost surely] is necessary, not only [$Y\leqslant x^*$ almost surely] as you wrote. – Did Sep 1 '16 at 20:08