I am not a statistician, and just try to understand a concept. According to Wikipedia,
A random variable is defined as a function that maps outcomes to numerical quantities (labels), typically real numbers. In this sense, it is a procedure for assigning a numerical quantity to each physical outcome, and, contrary to its name, this procedure itself is neither random nor variable. What is random is the unstable physics that describes how the coin lands, and the uncertainty of which outcome will actually be observed.
My understanding is,
The domain of a random variable is the set of possible outcomes, and the range of a random variable is whatever we set it to be. For instance, if $\mathcal{X}$ was a random variable for the coin tossing random process, both of the followings would still be proper to define: $$\mathcal{X}: > \{\text{head,tail}\}\rightarrow \{0,1\}\ \ \ \text{OR} \ \ \ > \mathcal{X}: \{\text{head,tail}\}\rightarrow \{102,321312\}.$$ Random variables are the starting block for doing computations. That's all they do!
Is this correct?
Now, I am trying to understand the following statement from this paper:
Suppose we are given a positive function $f : \{1 ... m\} \rightarrow > R^+$, which describes the unnormalized mass of a discrete random variable $I$,
$P(I\in B) = \sum_{i\in B}\frac{f(i)}{\sum_j^m f(j)}, \text{ where } > B\subset\{1...m\}$
My immediate reaction when I hear the term function
is to assume an infinite vector. In this case the $f$ vector length is bounded by $m$, and it encodes in each cell of the vector a positive real number. This can be considered as an unnormalized probability vector of a discrete random variable $I$, whose domain is $\{1 ... m\}$, and board is $R^+$. So far, this is fine.
Now, what I don't understand is the notation in the $P(I\in B)$. What does it mean? How can a function $I$ be a member of set of integers from $\{1 ... m\}$? From what I understand $I$ is not a single value, but is a function. It seems the designed interpretation is that we assume a particular input of $I$, which means $P(I\in B)$ implicitly means $P(I(i\in{B}))$, which then can be rewritten as $\sum_{i\in B}P(I(i))$. Now, since we assumed $f$ to be the unnormalized probability vector representing $I$, we can use it to compute the probability of each of the $i$ assignments by just normalizing it $$\sum_{i\in B}P(I(i))=\sum_{i\in B}\frac{f(i)}{\sum_{j\in B}f(j)}.$$
So, subject to some refinements, I can understand the notation $P(I\in B)$, but I am not sure if what I described is accurate.