Random Variables as Measurable Functions
Random variables are functions from outcomes to numbers whose level sets are events, so every threshold has a probability.
Why Does This Exist?
Notation like hides a question: what set has probability here? The answer is a preimage , and it must be an event before can touch it. Without measurability, thresholds have no probabilities.
Defining as a measurable map makes every Borel threshold an event. Distributions, expectations and limits then inherit measure theory for free.
This page gives the definition and the distribution it induces. Event structure is in measure spaces and working distributions in probability distributions.
The one idea you need first
For and , the preimage is . Measurability demands for every Borel .
Think of It Like This
A thermometer with labelled zones
Outcomes are weather states. The thermometer assigns each state a number. Asking for collects all states whose readings land in the hot zone and measures that collection.
The zone must be a recognized event; otherwise the question is malformed. Where the analogy stops: thermometers are continuous by physics, while random variables need only measurability, so jumps and thresholds are allowed.
How It Actually Works
is a random variable when for all Borel . Its distribution is . Its CDF is . Expectation is when .
Discrete takes countable values with . Continuous has a density with .
Worked example
Two fair coin flips: , counts heads. Values: . Then , . Preimage is an event. Expectation .
Watch Out For
Treating every function of outcomes as a random variable
Symptom: defining via choice on non-measurable sets, then has no value and simulations disagree with theory. Fix: build from continuous pieces, limits and arithmetic on measurable maps, which preserve measurability.
Confusing the variable with its distribution
Symptom: "two variables are equal" claimed from equal histograms, while couplings and joint behaviour differ. Fix: equality in distribution is ; almost-sure equality is and is strictly stronger.
The Quick Version
- A random variable is a measurable function whose threshold preimages are events.
- Its distribution pushes forward onto numbers via .
- Discrete sums and continuous densities are two readings of the same definition.
- Two flips counting heads gives and mean .
- Equality in law is weaker than almost-sure equality.