# Proof about how to get a uniform random variable from a generic one

Consider real random variable $X \in \mathbb{R}$. I know that if I consider r.v. $U = F_X(X)$ where $F_X(x)$ is $X$'s CDF, we get a uniform r.v. in $[0,1]$. So the following holds:

$$U \sim \text{Unif}(0,1)$$

How can this be proved?

-
First figure out the possible values of $U=F_X(X)$. Then ask yourself "What is the probability that $U \leq a$?" and try and figure out what are the possible values of $X$ that will make $F_X(X)$ have value less than $a$. If $F_X(X) \leq a$ for all $X \in B_a$ where $B_a$ is a set that is determined by your choice of $a$, then $$P\{U \leq a\} = P\{F_X(X)\leq a\} = P\{X \in B_a\}.$$ So now all you got to do is figure out $P\{X \in B_a\}$. Go on, try it for yourself. Take $a=0.5$ for starters and see if you can get the answer. Then try $a=0.4$, $a=0.6$ etc till you see a pattern emerging. – Dilip Sarwate Mar 31 '13 at 22:30

First of all, $X$ needs to be a continuous random variable, as if it was discrete, then any its function, in particular $F_X(X)$, would be discrete.
Let $t\in [0,1]$, and $(\Omega,P)$ be the probability space. We have \begin{align} P(U<t)&=P(\{\omega\,\mid\,F_X(X\omega)<t\}) \\ &=P(\{\omega\,\mid\,P(X<X\omega)\,<t\}) \end{align} So, let $A:=\{\omega\,\mid\,P(X<X\omega)\,<t\}$, and we want to prove that its measure (probability) is exactly $t$. For this, observe that $$A=\bigcup_{a\in\Bbb R\,:\,P(X<a)<t} (X\le a) \,.$$ (For $\subseteq$ consider $a:=X\omega$, and the inclusion $\supseteq$ goes as follows: say $\omega\in (X\le a)$, that is, $X\omega\le a$, then $P(X<X\omega)\le P(X<a)<t$.)
Finally, by continuity of $X$, i.e. of $F_X$, we get a $z\in\Bbb R$ such that $F_X(z)=t$ (take the minimal among them), then we can conlcude $A=(X<z)$.
And thus, indeed $$P(U<t)=P(A)=t\,.$$
Following Dilip Sarwate's thought in the comment, probably it would be enough to consider only the supremum $z$ of those $a\in\Bbb R$ values for which $P(X<a)<t$, and prove directly that $A=(X<z)$.. – Berci Mar 31 '13 at 23:09