Sets, Functions, and Notation
Mathematical notation for sets, functions, and probability — the language of the course.
Before diving into probability theory, let's establish the mathematical notation and concepts you'll encounter throughout this course. This section provides a quick reference for the symbols, sets, and function notation used in rigorous mathematics.
If you're comfortable with undergraduate mathematics, you may skim this section as a refresher. Return here whenever you encounter unfamiliar notation.
Number Sets
Mathematics uses special symbols for commonly used sets of numbers. These appear constantly in probability theory.
| Symbol | Name | Description |
|---|---|---|
| Natural numbers | (counting numbers) | |
| Integers | ||
| Rationals | Fractions where | |
| Real numbers | All points on the number line | |
| Positive reals | Real numbers greater than 0 |
These sets form a hierarchy: . Most random variables in this course take values in or .
Set Notation
Set
A set is an unordered collection of distinct objects (elements). Sets are typically denoted with capital letters like or special symbols like .
| Symbol | Read as | Meaning |
|---|---|---|
| "x is in A" | x is an element of set A | |
| "x is not in A" | x is not an element of set A | |
| "A is a subset of B" | Every element of A is also in B | |
| "A union B" | Elements in A or B (or both) | |
| "A intersection B" | Elements in both A and B | |
| or | "A complement" | Elements not in A |
| "empty set" | The set with no elements |
Set Builder Notation
Sets can be defined by listing elements or by specifying a rule:
- — the set containing exactly 1, 2, and 3
- — the set of all real numbers greater than 0 (read: "all x in R such that x is greater than 0")
- — the set of all x whose square is less than 4 (i.e., the interval )
Explore: Set Operations
See how union, intersection, and complement work on concrete sets.
Operation:
A ∪ B
Elements in A or B (or both)
Result:
{1, 2, 3, 4, 5, 6, 7}
|A ∪ B| = 7
Set A
{1, 2, 3, 4, 5}
Set B
{4, 5, 6, 7}
Sets in Probability
In probability, sets represent events. The intersection A ∩ B means "both A and B occur". The union A ∪ B means "A or B (or both) occurs". The complement Aᶜ means "A does not occur".
Probability-Specific Sets
Sample Space
The sample space, denoted (capital omega), is the set of all possible outcomes of a random experiment.
Sample Spaces
- Coin flip:
- Die roll:
- Waiting time:
- Stock price:
An event is a subset of the sample space — a collection of outcomes we might be interested in. For example, if rolling a die, the event "roll an even number" is the set .
Function Notation
Function
A function is a rule that assigns to each element of set (the domain) exactly one element of set (the codomain).
Common function notation:
- — the output of when given input
- — defines the rule: input , output
- — alternative notation meaning the same thing
Random Variables as Functions
A random variable is actually a function from the sample space to the real numbers:
It assigns a numerical value to each possible outcome. For example, if you roll two dice, might be the sum of the faces — it converts each outcome (pair of faces) into a number.
Explore: Random Variable as a Mapping
Visualize how a random variable maps outcomes in Ω to real numbers.
Flip 3 coins, X = number of heads
Ω = {HHH, HHT, HTH, ...}
X(ω) = count of H
Hover over outcomes in Ω to see how they map to values in ℝ
The Randomness Comes From ω
A random variable X is a function — given any outcome ω, it produces a definite number X(ω). The "randomness" comes from not knowing which ω occurs, not from the function itself. Once ω is realized, X(ω) is completely determined.
Quantifiers
Mathematical statements often need to express "for all" or "there exists." These are called quantifiers.
| Symbol | Read as | Example |
|---|---|---|
| "for all" | exists | |
| "there exists" | ||
| "there exists exactly one" |
Common Abbreviations
Probability and statistics use many abbreviations. Here are the essential ones:
| Abbreviation | Stands for | Meaning |
|---|---|---|
| i.i.d. | independent and identically distributed | Random variables that don't affect each other and follow the same distribution |
| a.s. | almost surely | Happens with probability 1 (but may fail on a set of probability 0) |
| iff | if and only if | Both directions of implication hold |
| w.r.t. | with respect to | Indicates what variable we're differentiating/integrating |
| s.t. | such that | Introduces a condition |
| w.l.o.g. | without loss of generality | Making a simplifying assumption that doesn't affect the proof |
Interval Notation
Intervals are subsets of real numbers between two endpoints. The bracket type indicates whether endpoints are included:
| Notation | Name | Includes |
|---|---|---|
| Closed interval | All x with | |
| Open interval | All x with | |
| Half-open | All x with | |
| Ray | All x with |
Note: Square brackets include the endpoint; parentheses exclude it. Infinity always uses parentheses since it's not a real number.
Key Takeaways
- is the set of real numbers — the home of most random variables
- is the sample space — all possible outcomes of an experiment
- means "is an element of"; means "is a subset of"
- means is a function from set to set
- i.i.d. means random variables are independent and identically distributed