# Set of a random variable's range is an event in the sample space?

My book has the following definition for the range of a random variable.

Since a random variable is defined on a probability space, we can calculate these probabilities given the probabilities of the sample points. Let $a$ be any number in the range of a random variable $X$. Then the set $\{\omega \in \Omega :X(\omega)=a\}$ is an event in the sample space (simply because it is a subset of $\Omega$).

I think I'm misunderstanding the provided notation but to me this expression:

$$\{\omega \in \Omega :X(\omega)=a\}$$

seems to be saying "For each sample point $\omega$ in the sample space $\Omega$, compute $X(\omega)$ and store the result $a$ in the set". If the above expression is saying what I think it says how can we say that a set of $\{X(\omega_1), X(\omega_2),\ldots,X(\omega_{|\Omega|})\}$ is an event in the sample space? Aren't events a subset $\{ \omega_1, \omega_2, \ldots\}$ of $\Omega$ ?

• The thing you quote is certainly not an attempt to give a definition of the range. – Michael Hardy May 16 '17 at 2:05

$\{\omega \in \Omega :X(\omega)=a\}$ means the sets of points of $\Omega$ such that every point is mapped to the value of $a$ by the random variable $X: \Omega \mapsto \mathbb R$.

$\{X(\omega_1), X(\omega_2),\ldots,X(\omega_{|\Omega|})\}$ is better to be noted as $X(\Omega)$, as $\omega_{|\Omega|}$ sometimes does not make sense if $\Omega$ is not finite. But you are right that it is not an event, because it is a subset of $\mathbb R$.

But some times we write $X$ directly as a presentation/notation. For example, we write $u<X\leq v$ as a short form to represent the event of $\{\omega \in \Omega: u < X(\omega) \le v\}$. We always focus on subsets of $\Omega$ as events, because the probability is defined over the measurable subsets of $\Omega$, which is in a $\sigma$-algebra.

The first part of the constructor indicates from where the elements are drawn.   The second part of the constructor indicates the criteria for acceptance.

Thus $\{\omega \in \Omega : X(\omega)=a\}$ reads: "the set of outcomes in the sample space, $\Omega$, whose $X$-measure equals $a$".

That is, examine each outcome from the sample space, but only accept it if the $X$ value equal $a$, else discard it.

The same way, a circle is $\{(x,y)\in\Bbb R^2: x^2+y^2=c^2\}$; read as-"the set of points in the real plane whose sum of squares equals $c^2$".

Events are measurable subsets of $\Omega$ and $\Omega$ is the domain, not the range, of the random variable. What is defined in the quoted passage is a subset of $\Omega,$ i.e. a subset of the set of all inputs to $X$ not of the set of all outputs.

For example, suppose you throw a pair of dice and each gives you a number in the set $\{1,2,3,4,5,6\}.$ Your probability space is the set $$\Omega = \left\{ \begin{array}{cccccc} (1,1) & (1,2) & (1,3) & (1,4) & (1,5) & (1,6) \\ (2,1) & (2,2) & (2,3) & (2,4) & (2,5) & (2,6) \\ (3,1) & (3,2) & (3,3) & (3,4) & (3,5) & (3,6) \\ (4,1) & (4,2) & (4,3) & (4,4) & (4,5) & (4,6) \\(5,1) & (5,2) & (5,3) & (5,4) & (5,5) & (5,6) \\ (6,1) & (6,2) & (6,3) & (6,4) & (6,5) & (6,6) \end{array} \right\}.$$ Let $X$ be the sum of the two numbers in the pair.

Then the event $X=10$ is the set $$\{\omega\in\Omega : X(\omega) = 10\} \quad = \quad \{ (4,6),\ (5,5),\ (6,4) \}.$$ That is a set of three of the $36$ points in $\Omega.$

You refer to "the following definition for the range of a random variable". But the statement you quote is certainly not an attempt to define the range. The range is the set $\{X(\omega) : \omega\in\Omega\}.$

The notation $\{\omega \in \Omega :X(\omega)=a\}$ certainly does not mean "for each $\omega\in\Omega$ compute $X(\omega)$ and store the result in $a$." In the first place, the expression as a whole should be read as a noun. It names a particular set. It does not instruct you to do something (with that set or otherwise). The object called $a$ is pre-supposed to be already defined before the definition can make sense; it's not telling you to store anything in $a$ and it's not saying "Let $a=\text{something}.$" Rather, it identifies certain elements of $\Omega$ and excludes others.

• Very nice example, well explained! (+1) – Yujie Zha May 16 '17 at 2:23
• @YujieZha : Thank you. – Michael Hardy May 16 '17 at 2:26

In the question, the expression $$\{\omega \in \Omega :X(\omega)=a\}$$ is interpreted as follows:

For each sample point $\omega$ in the sample space $\Omega$, compute $X(\omega)$ and store the result $a$ in the set.

One fundamental misunderstanding here is the notion that the expression on the right-hand side of the colon contributes any values to the set at all. The only values that can be placed in the set are the values named $\omega$ on the left side of the colon. The formula $\omega \in \Omega$ says that every value $\omega$ that is a member of the set $\{\omega \in \Omega :X(\omega)=a\}$ must also be a member of $\Omega.$ That is practically the definition of a subset.

What the expression on the right-hand side does is to select the subset of $\Omega$ as follows:

For each sample point $\omega$ in the sample space $\Omega$, compute $X(\omega),$ compare it to the value $a$, and if the two values match then that value of $\omega$ belongs to the set $\{\omega \in \Omega :X(\omega)=a\}.$

In this procedure, $a$ is value that was already selected from the range of $X$ before we even started to write $\{\omega \in \Omega :X(\omega)=a\}$; during the entire definition of an particular subset $\{\omega \in \Omega :X(\omega)=a\}$ of $\Omega$ only that one single value of $a$ is ever used.