Discrete random variables are equal

discrete mathematicsprobability distributionsprobability theory

We have continuous random variables $X$ and $Y$. Our goal is to find the distribution of $X$, such that for any suitable function $g$, the distributions $g(X)$ and $Y$ have the same distribution. We could solve
$$E(\phi(g(X)))=\int \phi(g(x))f_X(x)dx = \int \phi(y)f_Y(y)dy=E(\phi(Y))$$
for $f_X$ with $\phi$ being an arbitrary suitable function. Substitution $g(x)=y$ gives us that the pdf of $X$ is
$$f_X(x)=f_Y(g(x))|g'(x)|.$$
The question is, what if $X$ and $Y$ are discrete? What would be the alternative to the change of variable to find the pmf of $X$? Could we use the same approach or is it fundamentally a different problem?

Best Answer

Let me try to answer one interpretation of your question. This should at least be useful to clarify your requirements. Let $Y$ be a discrete random variable with range $y_1,\ldots,y_m$ and $P(Y=y_j)=p_j$, where $p_j>0.$ Let $g$ be the "suitable function". For consistency you need $X=g^{-1}(Y)$.

Now define for each $y_j$ $n_j$ disjoint sets $x_{i,j}$ inside the domain of $g$ such that: $$ \bigcup_{i \leq n_j} x_{i,j}=g^{-1}(y_j).$$ Next choose any set of positive numbers $q_{i,j}$ with $$ \sum_{i\leq n_j} q_{i,j}=p_j \text{ for all } j=1\ldots, m.$$

Each $q_{i,j}$ defines the mass of the component $x_{i,j}$, i.e. $P(x_{i,j})=q_{i,j}$ and you can distribute the mass within each $x_{i,j}$ as you wish.

Following this recipe ensures: $$ P(g(X)=y_j)=P(X=g^{-1}(y_j))=P(\bigcup_{i \leq n_j} x_{i,j})=\sum_{i\leq n_j} P(x_{i,j})=p_j.$$