Discrete Random Variables (9709 Paper 5, Section 5.4)
Hello future statisticians! This chapter marks your official entry into the world of formal probability distributions. Discrete random variables might sound complicated, but they are just variables whose values you can count.
We will learn how to describe these counts mathematically, figure out the average outcome (Expectation), and measure how spread out the results are (Variance). These tools are essential for modelling everything from coin tosses to quality control in manufacturing!
1. What is a Discrete Random Variable (DRV)?
A Random Variable, usually denoted by a capital letter like \(X\), is a variable whose value is a numerical outcome of a random phenomenon.
Key Definitions
- Discrete Random Variable (DRV): A random variable that can only take specific, separate values. These values are usually integers (whole numbers).
- Analogy: Think of counting people (you can have 1, 2, or 3 people, but not 2.5 people).
- Possible Values (The Domain): If you roll a die, \(X\) could be {1, 2, 3, 4, 5, 6}. If you count the number of heads in 4 coin tosses, \(X\) could be {0, 1, 2, 3, 4}.
1.1 The Probability Distribution Table (PDT)
A DRV is defined entirely by its Probability Distribution. This is a list of all possible values (\(x\)) the variable can take, along with the probability of each value, \(P(X=x)\).
The distribution is often shown in a table:
| \(x\) | \(x_1\) | \(x_2\) | \(x_3\) | ... |
| \(P(X=x)\) | \(p_1\) | \(p_2\) | \(p_3\) | ... |
Rules for any Probability Distribution:
- All probabilities must be non-negative: \(P(X=x) \ge 0\) for all \(x\). (You can't have a negative chance of something happening!)
- The sum of all probabilities must equal 1: \(\sum P(X=x) = 1\). (Something must happen!)
Example: A bag contains 2 red (R) and 3 blue (B) balls. You draw two balls without replacement. Let \(X\) be the number of red balls drawn. \(X\) can take values 0, 1, or 2.
P(X=0) = P(BB) = (3/5) * (2/4) = 6/20
P(X=1) = P(RB or BR) = (2/5)*(3/4) + (3/5)*(2/4) = 12/20
P(X=2) = P(RR) = (2/5) * (1/4) = 2/20
Check: \(6/20 + 12/20 + 2/20 = 20/20 = 1\). The table is valid.
2. Expectation (Mean) and Variance
Once you have the PDT, you can calculate the two most important characteristics of the DRV: the average result and the spread of the results.
2.1 Expected Value, \(E(X)\) (The Mean)
The Expected Value, or Expectation, \(E(X)\) (also often denoted by \(\mu\)), represents the long-run average value of the random variable. It's what you expect to get if you ran the random experiment many times.
Formula for Expectation:
$$E(X) = \sum x P(X=x)$$
Step-by-Step Trick: Simply multiply each value (\(x\)) by its corresponding probability (\(P(X=x)\)), and then add up all those products.
2.2 Variance, \(Var(X)\) (The Spread)
The Variance, \(Var(X)\) (or \(\sigma^2\)), measures how spread out the values are from the mean. A higher variance means the outcomes are more widely scattered.
The standard method for calculation uses the following relationship:
Formula for Variance:
$$Var(X) = E(X^2) - [E(X)]^2$$Where \(E(X^2)\) is the Expected Value of \(X^2\), calculated as: $$E(X^2) = \sum x^2 P(X=x)$$
Quick Review: Calculating \(Var(X)\)
- Calculate \(E(X) = \sum x P(X=x)\).
- Calculate \(E(X^2) = \sum x^2 P(X=x)\) (Square the \(x\) values before multiplying by the probability).
- Substitute into the variance formula: \(Var(X) = E(X^2) - [E(X)]^2\).
The Standard Deviation is simply \(\sqrt{Var(X)}\).
Common Mistake Alert! Do NOT forget the brackets in the variance formula! It is \( [E(X)]^2 \), meaning you square the final mean, not the individual \(x\) values.
3. The Binomial Distribution \(B(n, p)\)
The Binomial Distribution is a specific type of DRV distribution used when we have a fixed number of identical trials, and we are interested in the total number of successes.
We write the notation as \(X \sim B(n, p)\), where \(n\) is the number of trials and \(p\) is the probability of success in any single trial.
3.1 Conditions for a Binomial Model
A situation can be modelled by the Binomial Distribution only if it meets all four conditions. Use the mnemonic BITZ to remember them:
- Binary: Only two outcomes are possible per trial (Success or Failure).
- Independent: The outcome of one trial does not affect the outcome of others.
- Trials fixed (\(n\)): The number of trials is constant and predetermined.
- Zero change in \(p\): The probability of success (\(p\)) is constant for every trial.
3.2 The Binomial Probability Formula
If \(X \sim B(n, p)\), the probability of getting exactly \(r\) successes in \(n\) trials is given by:
$$P(X=r) = \binom{n}{r} p^r (1-p)^{n-r}$$
Where:
- \(\binom{n}{r}\) (read as "n choose r") calculates the number of ways \(r\) successes can occur in \(n\) trials. Use your calculator's nCr function.
- \(p^r\) is the probability of those \(r\) successes.
- \((1-p)^{n-r}\) is the probability of the remaining \((n-r)\) failures.
Did you know? \((1-p)\) is often written as \(q\). The formula simply combines the ways to get the result with the probability of that specific outcome sequence.
3.3 Expected Value and Variance for \(B(n, p)\)
For the binomial distribution, calculating the mean and variance is straightforward using dedicated formulae (these are provided in the MF19 list):
Expectation (Mean):
$$E(X) = np$$Variance:
$$Var(X) = np(1-p)$$Example: If you toss a fair coin 100 times (\(n=100\), \(p=0.5\)), you expect \(E(X) = 100 \times 0.5 = 50\) heads. The variance is \(100 \times 0.5 \times 0.5 = 25\).
4. The Geometric Distribution \(Geo(p)\)
The Geometric Distribution models the probability of having to wait until the first success occurs. It is an extension of the Binomial idea, but with no fixed number of trials.
We write the notation as \(X \sim Geo(p)\), where \(p\) is the probability of success in any single trial. The possible values for \(X\) are \(r=1, 2, 3, \ldots\) (since the first success must happen eventually).
4.1 Conditions for a Geometric Model
The Geometric Distribution requires the first three BITZ conditions, but replaces the fixed number of trials with a variable "waiting time":
- Binary: Only two outcomes (Success or Failure).
- Independent: Trials are independent.
- Zero change in \(p\): Probability of success (\(p\)) is constant.
Analogy: You are flipping a coin until you get the first head. \(X=5\) means you had 4 tails followed by 1 head (FFFFH).
4.2 The Geometric Probability Formula
If \(X\) is the trial number on which the first success occurs, then for \(r = 1, 2, 3, \ldots\):
$$P(X=r) = (1-p)^{r-1} p$$This formula means that before the success on the \(r\)th trial, there must have been \((r-1)\) failures.
Example: If \(p=0.2\), the probability of the first success being on the 4th trial (\(r=4\)) is:
\(P(X=4) = (1-0.2)^{4-1} \times 0.2 = (0.8)^3 \times 0.2 = 0.1024\)
4.3 Expected Value for \(Geo(p)\)
The Expectation, \(E(X)\), for the Geometric distribution tells you the average number of trials you need to wait until the first success.
Expectation (Mean):
$$E(X) = \frac{1}{p}$$Example: If the probability of getting a bullseye is \(p=0.1\), you expect to wait an average of \(E(X) = 1/0.1 = 10\) throws to hit your first bullseye.
(Note: The variance formula for the Geometric distribution is not required knowledge for P5, only the expectation).
Quick Review & Study Tips
- DRV Basics: Remember the two rules for any probability distribution: probabilities must sum to 1, and they must be non-negative.
- Moment Calculation: Always calculate \(E(X)\) first. When finding \(E(X^2)\), square the \(x\) value *before* multiplying by \(P(X=x)\).
- Binomial vs. Geometric:
- Binomial: Fixed trials, counting total successes. (BITZ)
- Geometric: Variable trials, waiting for the first success. (Waiting time model)
- Formula Sheet (MF19): The expectation and variance formulae for both Binomial and Geometric distributions are provided. Focus on understanding *when* to use them.
Don't worry if calculating the variance seems tricky. Organize your table carefully by adding columns for \(xP(X=x)\) and \(x^2 P(X=x)\). Structure leads to success!