Sub topic 1
Sample Spaces and Events
Probability measures how likely an outcome is. Every probability problem starts with two ideas: the sample space and the event.
Prerequisites
This chapter assumes you can simplify fractions, count outcomes with the multiplication principle, and read a Venn diagram.
Sample spaces and events
A sample space is the set of all possible outcomes of an experiment. An event is any subset of the sample space. For one fair six-sided die, the sample space is {1, 2, 3, 4, 5, 6}. The event "the roll is even" is {2, 4, 6}.
For two dice, the sample space has 6 × 6 = 36 ordered outcomes. Order matters, so (1, 2) and (2, 1) are different outcomes.
Probability as favorable over total outcomes
When every outcome is equally likely, the probability of an event is:
P(event) = favorable outcomes / total outcomes
For example, the outcomes where two dice sum to 7 are (1,6), (2,5), (3,4), (4,3), (5,2), and (6,1). That is 6 outcomes, so P(sum is 7) = 6/36 = 1/6.
from itertools import product
from fractions import Fraction
space = list(product(range(1, 7), repeat=2)) # 36 ordered outcomes
favorable = [o for o in space if sum(o) == 7]
print(len(space)) # 36
print(Fraction(len(favorable), len(space))) # 1/6The complement rule
The complement of event A, written "not A", is everything in the sample space outside A. Event A and its complement together cover every outcome exactly once, so:
P(not A) = 1 - P(A)
For the sum-7 event, P(not 7) = 1 - 1/6 = 5/6. Complements are often faster than direct counts.
Compound events: "and" and "or"
A compound event combines two events.
- "A and B" means both events happen in the same trial.
- "A or B" means at least one of them happens.
On the GRE, "or" is inclusive. The outcome (6,6) satisfies "first die is 6 or second die is 6" and counts once.
Mutually exclusive events
Two events are mutually exclusive when they cannot happen together. Their overlap is empty. The events "first die is 1" and "first die is 6" cannot both occur in one roll.
Exercise
Two fair dice are rolled. What is P(sum is not 11)?
Show answer
Two outcomes give a sum of 11, (5,6) and (6,5), so P(sum is 11) = 2/36 = 1/18. Then P(not 11) = 1 - 1/18 = 17/18.