📊 Discrete Random Variables
1. What is a Random Variable?
A random variable is a variable whose value is determined by the outcome of a random experiment. Think of it as a function that assigns a numerical value to each outcome.
A discrete random variable can only take specific, countable values (like 0, 1, 2, 3, etc.). These are different from continuous random variables, which can take any value in a range.
• X = number of heads when flipping 3 coins (possible values: 0, 1, 2, 3)
• Y = number of defective items in a batch of 10 (possible values: 0, 1, 2, ..., 10)
• Z = sum of two dice rolls (possible values: 2, 3, 4, ..., 12)
• W = number of customers arriving in an hour (possible values: 0, 1, 2, 3, ...)
Let X = sum of two dice. What are the possible values?
Answer: X can be 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, or 12
This is a discrete random variable because it only takes specific integer values.
📝 Practice Question
2. Probability Distributions
A probability distribution lists all possible values of a discrete random variable along with their probabilities. It shows us the complete picture of how probability is distributed across all outcomes.
Let X = number of heads
| X (# of heads) | 0 | 1 | 2 |
|---|---|---|---|
| P(X) | 1/4 | 1/2 | 1/4 |
• Each probability must be between 0 and 1: 0 ≤ P(X) ≤ 1
• The sum of all probabilities must equal 1: ΣP(X) = 1
• Every possible value must be listed
📝 Practice Question
3. Expected Value (Mean)
The expected value (also called the mean) of a discrete random variable is the average value we would expect if we repeated the experiment many times. It's denoted as E(X) or μ.
Sum of (each value × its probability)
A game costs $5 to play. You roll a die and win money based on the result:
• Roll 6: win $20
• Roll 4 or 5: win $10
• Roll 1, 2, or 3: win $0
What is the expected winnings?
Solution Steps:
• Expected value is NOT necessarily a possible value of X
• It represents the long-run average
• Useful for decision-making and comparing options
📝 Practice Question
4. Variance and Standard Deviation
While expected value tells us the center of a distribution, variance and standard deviation tell us about the spread or variability.
Or equivalently: Var(X) = E(X²) - [E(X)]²
Standard Deviation: σ = √Var(X)
• Variance (σ²): Average squared distance from the mean
• Standard Deviation (σ): Typical distance from the mean (in original units)
• Higher values = more spread out / more variability
• Lower values = more concentrated around the mean
Let X = number of heads in 2 coin flips. We found E(X) = 1.
| X | 0 | 1 | 2 |
|---|---|---|---|
| P(X) | 0.25 | 0.50 | 0.25 |
Calculating Variance:
📝 Practice Question
5. Binomial Distribution
The binomial distribution is one of the most important discrete probability distributions. It models the number of successes in a fixed number of independent trials.
Binomial Distribution Requirements:
• Each trial has only two outcomes: success or failure
• Probability of success (p) is the same for each trial
• Trials are independent
• We count the number of successes (X)
• Mean: E(X) = n × p
• Variance: Var(X) = n × p × (1-p)
• Standard Deviation: σ = √[n × p × (1-p)]
A basketball player makes 70% of free throws. She takes 5 shots. What's the probability she makes exactly 3?
Solution:
Expected makes: E(X) = 5 × 0.7 = 3.5 shots
📝 Practice Question
6. Geometric Distribution
The geometric distribution models the number of trials needed to get the first success. It answers questions like "How many times do I need to try before I succeed?"
Geometric Distribution
• Same probability of success (p) each time
• We count trials until the FIRST success
• X can be 1, 2, 3, 4, ... (unlimited)
• Mean: E(X) = 1/p
• Variance: Var(X) = (1-p)/p²
What's the probability that you need exactly 4 rolls to get your first 6?
Solution:
Expected rolls until first 6: E(X) = 1/(1/6) = 6 rolls
A quality inspector tests items until finding a defective one. If 5% of items are defective, how many items should they expect to test on average?
Solution:
E(X) = 1/p = 1/0.05 = 20 items
📝 Practice Question
🎯 Lesson Summary
Excellent work! You've mastered discrete random variables. Here's what you learned:
- ✅ Random variables: Assign numerical values to outcomes
- ✅ Probability distributions: Show all values and their probabilities
- ✅ Expected value: E(X) = Σ[x · P(x)] - the long-run average
- ✅ Variance & std dev: Measure spread and variability
- ✅ Binomial distribution: Fixed trials, count successes; E(X) = np
- ✅ Geometric distribution: Count trials until first success; E(X) = 1/p
Next lesson: We'll explore continuous probability distributions!