Expectation of Function of Discrete Random Variable
From ProofWiki
Theorem
Let $X$ be a discrete random variable.
Let $E \left({X}\right)$ be the expectation of $X$.
Let $g: \R \to \R$ be a real function.
Then:
- $\displaystyle E \left({g \left({X}\right)}\right) = \sum_{x \in \Omega_X} g \left({x}\right) \Pr \left({X = x}\right)$
whenever the sum is absolutely convergent.
Proof
Let $\Omega_X = \operatorname{Im} \left({X}\right) = I$.
Let $Y = g \left({X}\right)$.
Thus $\Omega_Y = \operatorname{Im} \left({Y}\right) = g \left({I}\right)$.
So:
| \(\displaystyle \) | \(\displaystyle E \left({Y}\right)\) | \(=\) | \(\displaystyle \sum_{y \in g \left({I}\right)} y \Pr \left({Y = y}\right)\) | \(\displaystyle \) | |||
| \(\displaystyle \) | \(\displaystyle \) | \(=\) | \(\displaystyle \sum_{y \in g \left({I}\right)} y \sum_{ {x \in I} \atop {g \left({x}\right) = y} } \Pr \left({X = x}\right)\) | \(\displaystyle \) | Probability Mass Function of Function of Discrete Random Variable | ||
| \(\displaystyle \) | \(\displaystyle \) | \(=\) | \(\displaystyle \sum_{x \in I} g \left({x}\right) \Pr \left({X = x}\right)\) | \(\displaystyle \) |
From the definition of expectation, this last sum applies only when the last sum is absolutely convergent.
$\blacksquare$
Sources
- Geoffrey Grimmett and Dominic Welsh: Probability: An Introduction (1986): $\S 2.4$: Theorem $2 \ \text{B}$