# Existence of a random variable given a cdf

For every real function F which can be a CDF (so has the properties that $F(+\infty)=1$, $F(-\infty)=0$, and F is non-decreasing and right continuous), does there exist a random variable on a probability space with this function as it's CDF?

Seems rather trivial (I may be misunderstanding something here) but I would like to prove it.

If the probability space is not rich enough (for example if $$\Omega$$ is finite), the result won't hold.
But if we can find a random variable $$U$$ on $$\Omega$$ whose distribution function is uniform, then given a c.d.f. $$F$$, we may find a random variable $$X$$ on $$\Omega$$ whose distribution function is $$F$$: define $$X:=F^{-1}(U)$$ where $$F^{-1}$$ is the generalized inverse of $$F$$, that is, $$F^{-1}(u)=\inf\left\{ x\in\mathbf R\mid F(x)\geqslant u\right\}.$$
• Thanks. Would the below argument also work? Here we choose the appropriate probability space as well, rather than assuming it is given to us. There is a theorem (due to Lebesgue) which states that for such given F, there exists a unique Borel probability measure $\mu_F$ on R s.t. $\mu((-\infty,x])=F(x)$ for all real x. So consider the probability space $(\mathbb{R},B(\mathbb{R}),\mu_F)$, and take $X(w)=w$ for all $\omega \in \mathbb{R}$ to be the random variable – a.e. Mar 26 '15 at 11:27
• It seems that there is a typo in the generalized inverse $F^{-1}.$ Should it be $F^{-1}(u)=\inf\{x\in\mathbb{R}\mid F(x)\geq u\}$, where $u\in(0,1)$? For $u\in(0,1)$, the set $\{x\in\mathbb{R}\mid F(x)\leq u\}$ is not bounded from below and we always have $\inf\{x\in\mathbb{R}\mid F(x)\leq u\}=-\infty$, which does not make sense. – Danny Pak-Keung Chan Jun 5 at 17:37