Introduction to Probability
Learning goals
- Treat an event as a subset and divide favorable by total when outcomes are equally likely
- Apply the complement rule for at least one
- Subtract the overlap in the addition rule
- Shrink the sample space to compute
- Multiply by to find
- Separate mutually exclusive from independent, which usually conflict
Events are sets, and probability counts them
Roll a fair six-sided die. There are six possible results, and every one of them is equally likely because the die is fair. Suppose you care whether the roll comes up even: that is three of the six results, namely , , and . Since three of the six equally likely results fit what you asked about, the probability of an even roll is .
Every idea in this lesson is a more careful version of that one calculation, so here is the vocabulary for it. An experiment is any procedure whose result is uncertain, such as rolling the die. The set of all possible results is the sample space, written ; for the die, . One element of is an outcome. An event is any subset of the sample space, such as , “the roll is even”:
Every member of is also a member of , so : an event is just the part of the sample space you are asking about. That single word, subset, is the whole level-up. Once events are sets, the set operations you know already become the ways of combining events, and they translate straight into English:
- , the complement, is everything in that is not in . In words, ” does not happen”.
- , the union, is everything in or in or in both. In words, ” happens or happens”.
- , the intersection, is everything in both. In words, ” and both happen”.
- , the empty set, is the impossible event, and itself is the certain event.
Now attach a number to each set. Write for the number of outcomes in . If the sample space is finite and its outcomes are equally likely, then
Three facts fall out immediately, with no work. Since , every probability satisfies . The impossible event has because . The certain event has because the quotient equals .
Check your understanding
A bag holds 3 green marbles, 5 yellow marbles, and 2 purple marbles. One marble is drawn at random. What is the probability it is green?
The sample space is the whole bag, not just the green marbles, so count every marble.
Three of those ten are green, so . The value comes from comparing green only to the non-green marbles, which leaves out the green marbles themselves from the total.
What “equally likely” actually claims
Read that definition again and notice where the mathematics stops. The formula does not prove that a coin is fair; it assumes it. “Equally likely” is a claim about the world, not a theorem, and no amount of algebra can establish it. A physical die might be weighted, a shuffled deck might be badly shuffled, and a “random” sample of people might quietly exclude everyone without a phone. What mathematics gives you is a conditional promise: if the outcomes of are equally likely, then is the fraction of them lying in . Checking the if is your job, and it is done with physics, with care in the design of the experiment, or with data.
The assumption is also delicate, because the same experiment can be described with more than one sample space, and not every one of those descriptions has equally likely outcomes. Roll two dice and record the sum. The possible results are
which has outcomes. If you now “count and divide” you get , and that is simply wrong. The eleven sums are not equally likely: only makes a , while six different rolls make a . The sample space that is equally likely is the set of ordered pairs, because each die is fair. The multiplication principle from the previous lesson counts of them. So . Choosing the right sample space is the modeling step, and it is where most probability errors are born.
A picture to hold on to
Every rule below is a statement about how the sets overlap, so draw the sets. Take a single card drawn from a standard -card deck. Let be “the card is a heart” ( cards) and let be “the card is a face card”, meaning a jack, queen, or king ( cards). Three cards are in both: the jack, queen, and king of hearts.
The complement rule
The first rule is the cheapest and the most useful.
Every outcome of the experiment lies either in or outside it, and never in both places at once. So the outcomes of split cleanly into the ones inside and the ones inside , which means the counts add:
Divide every term by . The left side becomes and the right side becomes , so
and subtracting from both sides gives .
The rule is worth more than its size suggests, because of one recurring phrase: at least one. The event “at least one success” is a sprawling union of many cases (exactly one, exactly two, and so on up). But its complement is a single tidy event: “no successes at all”. Counting the tidy one and subtracting from is called complementary counting, and for “at least one” problems it is almost always the short road.
Worked example 1 At least one six in four rolls
A fair die is rolled four times. What is the probability of getting at least one six?
Start by pinning down an equally likely sample space. A result is an ordered list of four faces, so by the multiplication principle
and every one of those lists is equally likely because the die is fair.
Now let be “at least one six”. Attacking head on means splitting into exactly one six, exactly two sixes, exactly three, and exactly four, which is four separate counts. Its complement is “no six at all”, and that is one count: each of the four rolls must land on one of the five non-six faces, so
Therefore , and the complement rule finishes it:
So a run of four rolls produces a six slightly more often than not, about of the time. Notice that no rule beyond counting was used: the whole computation is and one subtraction.
Check your understanding
A fair coin is flipped three times. What is the probability of getting at least one head?
"At least one head" is a sprawling event (exactly one, exactly two, exactly three), so use the complement instead. The complement is "no heads at all", which is one easy count: every flip must land tails.
The complement rule finishes it.
The addition rule
Now the union. The naive guess, , is wrong in general, and the Venn diagram above shows exactly why: adding hearts to face cards counts the three face-card hearts twice. Fixing that overcount is the entire content of the rule.
Count by hand. An outcome in the union sits in exactly one of three regions: in but not , in both, or in but not . Write those three counts as , , and (the , , and in the picture). Then
Add the first two:
because . Every outcome of the overlap was counted once as a member of and once again as a member of . So each such outcome was counted twice, and the identity records that. Rearranging,
Divide through by :
This is inclusion and exclusion: include each set, then exclude what you double counted.
The familiar “just add them” rule is not a second rule; it is this one with a zero in it. Call and mutually exclusive (or disjoint) when they cannot both happen, which is to say when the intersection is empty, . Then , the correction term vanishes, and
Keep that as a consequence, not as a separate fact to memorize. The general rule is the one to hold, and the special case is what it collapses to when the circles do not touch.
Worked example 2 A heart or a face card
One card is drawn at random from a standard deck. What is the probability it is a heart or a face card?
The word “or” is a union, so use the addition rule with the hearts and the face cards. The deck gives the three counts directly:
since exactly three cards (the jack, queen, and king of hearts) are both. Now apply the rule:
Check it against the picture, which is the point of drawing it: the union holds cards, so as well. Had you forgotten to subtract, you would have claimed favorable cards, three more than exist.
Check your understanding
Two events satisfy , , and . What is ?
Use the addition rule and subtract the overlap once, because adding and counted it twice.
The answer is what you get by forgetting the correction term, and it overstates the union by exactly the size of the overlap.
Conditional probability: shrink the sample space
Here is the idea that makes probability powerful rather than merely tidy. Suppose you learn that the event has happened. That information does not change the experiment, but it changes what is still possible: every outcome outside is now ruled out. So throw them away. Your sample space is no longer ; it is .
Inside this smaller world, which outcomes still make happen? Exactly the ones that were in and in , that is, the outcomes of . The outcomes of were equally likely before and nothing has disturbed them, so count and divide as always:
Read as “the probability of given ”. To turn that count into probabilities, divide the top and the bottom by , which changes nothing:
That is the definition of conditional probability, and it was forced on us: it is what “shrink the sample space to ” says in the language of . It also comes with a condition. The formula divides by , so it requires
That is not a technicality to shrug at. Conditioning on an impossible event is meaningless, because “given ” means “restrict attention to the outcomes of ”, and there are none to restrict to.
Worked example 3 Given the sum is 8, did a die show a 3?
Two fair dice are rolled. Given that the sum is , what is the probability that at least one die shows a ?
Let be “the sum is ” and let be “at least one die shows a ”. List from the grid:
Of those five outcomes, the ones that also lie in are and , so . Shrinking the sample space to gives
The formula in terms of probabilities agrees, as it must, since both routes are the same division:
Compare this with the unconditional probability. Out of all rolls, contain a three, so . Learning the sum pushed the chance of a three up from about to , which is what it means for the information to be worth something.
Worked example 4 A test that is right almost every time, and an answer that is still tiny
A disease affects person in . A screening test detects the disease in of the people who have it. Among people who do not have it, the test still comes back positive of the time. Your test comes back positive. What is the probability that you have the disease?
The clean way to see this is to turn the percentages back into counts, because counts are what probability is made of. Imagine people and follow them through.
The disease affects one in a thousand, so of them are sick and the remaining are healthy. Among the sick people the test catches , giving positives. Among the healthy people it wrongly fires of the time, giving
positives. So the total number of positive tests is , and the number of positive tests belonging to someone who is genuinely sick is . Now condition: a positive result shrinks the sample space from all people to those , and inside that world you want the sick ones.
Under . The test is not broken and the arithmetic is not a trick. The reason is that the false positives are drawn from an enormous healthy population, while the true positives are drawn from a tiny sick one. So even a small error rate on the big group swamps a near-perfect hit rate on the small one. Confusing with is a common and costly mistake, and the two numbers are not even close.
Check your understanding
A single card is drawn from a standard deck. Given that the card is a heart, what is the probability that it is a face card?
Learning that the card is a heart shrinks the sample space from all cards to the hearts. Inside that smaller world, the face cards are the jack, queen, and king of hearts.
The value is , which is the numerator before the sample space was shrunk, not the conditional probability.
The multiplication rule and independence
Multiply both sides of the conditional definition by and you have a rule for intersections:
This is the multiplication rule, and it says something obvious once you hear it. For both events to happen, must happen (probability ), and then, in the world where it did, must happen (probability ). It is how you handle any experiment done in stages, such as drawing two cards one after the other.
Now ask a sharper question. What if learning tells you nothing at all about ? Then the conditional probability is no different from the plain one:
Substitute that into the multiplication rule and the conditional vanishes:
We take this last equation as the definition: and are independent exactly when . Two reasons to prefer the product form. It is symmetric in and , so it cannot pretend that independence is a one-way street: if says nothing about then says nothing about . And it still makes sense when , where is not even defined.
Independence is a numerical condition. You do not decide it by staring at the two events and feeling that they seem unrelated; you compute both sides and compare.
Worked example 5 Two draws, with and without replacement
Two cards are drawn from a standard deck. Find the probability that both are hearts, first when the first card is put back and the deck reshuffled, and then when it is not.
With replacement. The deck is identical for the second draw, so knowing the first card tells you nothing about the second. The conditional probability is still , the same as the unconditional value. The two events are independent, and the product form applies:
Without replacement. Now the first card is gone. If it was a heart, only hearts remain among cards, so
which is not . Use the general multiplication rule, not the product form:
The two answers differ, and they differ in the direction you would expect: removing a heart makes a second heart slightly harder. Independence held in the first setup and failed in the second, and the only thing that changed was whether the card went back.
Check your understanding
Two cards are drawn from a standard deck, without putting the first one back. Which expression gives ?
Without replacement, the second draw sees a changed deck, so this needs the general multiplication rule, not the independent product form.
After one king is removed, only kings remain among cards, giving . The other options either reuse for the second draw, which assumes independence that does not hold here, or add instead of multiply.
Independence can also show up where you did not expect it. Draw one card and let be “the card is a heart” and be “the card is a king”. Then is the single king of hearts, so
They match, so suit and rank are independent. The reason is visible in the deck itself: every rank comes in exactly one card of each suit. So learning the rank leaves the four suits in the same proportions as before. Knowing you hold a king tells you nothing about the suit.
Mutually exclusive is not the same as independent
Two events, two relations, and they get confused constantly. They are not the same relation, and for any two events that can actually happen, they cannot both hold at once, as the proof below shows precisely.
- Mutually exclusive is a statement about sets: , the circles do not touch.
- Independent is a statement about numbers: , knowing one changes nothing about the other.
Now watch what mutual exclusivity actually does to your information. If and cannot both happen and someone tells you that happened, you have learned that definitely did not happen: its probability dropped straight to . That is a large effect on , not the “changes nothing” that independence requires, and the algebra below confirms it exactly.
Mutually exclusive events with positive probability are never independent#
Suppose and suppose both events have positive probability, and . Because and are disjoint, their intersection is the impossible event, so
But and are both strictly positive, and a product of two positive numbers is positive:
So while , and the two are therefore different. The defining equation of independence fails, and and are dependent.
The conditional probability shows how dependent. Since , we may condition on , and
while . Learning that occurred does not nudge the probability of ; it collapses it to zero.
Reading the same argument backwards gives the other half. If and are independent with and , then , so contains at least one outcome and cannot be empty. Independent events of positive probability must overlap.
So the two relations do not merely differ; for events that can actually happen, each one rules the other out. The picture is the fastest way to remember it: mutually exclusive events are drawn as separate circles. Independent events of positive probability are drawn as overlapping ones, with the overlap sized so that .
Make it concrete with one card. Let be “the card is a heart” and be “the card is a spade”. A card cannot be both, so they are mutually exclusive, and . But
so they are not independent. And of course they are not: if you are told the card is a spade, the chance it is a heart drops from to . Compare that with the heart-and-king pair from the last section, which does overlap (in the king of hearts) and is independent. Same deck, two pairs of events, opposite behavior.
The one honest exception
Can two events be both mutually exclusive and independent? Yes, but only in a degenerate way, and it is worth stating precisely because it is the boundary case the proof above deliberately excluded.
Suppose and are mutually exclusive. Then they are independent exactly when or . Both directions are quick. If they are mutually exclusive and independent, then , and a product of real numbers is zero only when one of its factors is zero. Conversely, if they are mutually exclusive and (say) , then and as well, so the two sides agree and the events are independent.
In a finite sample space of equally likely outcomes, forces . So the only way to be both mutually exclusive and independent is for one of the events to be impossible in the first place, which is not a useful case to build examples from. For any two events that can actually occur, the two conditions exclude each other.
Check your understanding
Events and satisfy , , and . Which statement is true?
Disjoint events have , while the product of the two probabilities is positive.
The two sides disagree, so the events are not independent. Conditioning confirms it, because knowing happened rules out entirely.
Mutually exclusive events with positive probability are never independent, because can never equal the positive product .
Probability when the counts get big
This section is an application, not a new rule: it reuses favorable-over-total on sample spaces built from combinations, so the formula does not feel limited to small counts.
Nothing in requires the counts to be small. When the sample space is a set of hands, committees, or arrangements, the counting principles from the previous lesson supply both the numerator and the denominator. The probability is then their quotient. A five-card hand is a set of cards, since the order you are dealt them does not change the hand, so hands are counted with combinations, written exactly as in the previous lesson. One note on notation: the letter is already taken here, since means the probability of the event , so permutation counts below are spelled out as products such as instead.
Worked example 6 Exactly two aces in a five-card hand
Five cards are dealt from a standard deck. What is the probability the hand contains exactly two aces?
The sample space is every possible five-card hand, and all of them are equally likely because the deck is shuffled:
Now count the hands in the event. Building one means making two choices in sequence: pick which two of the four aces are in the hand, then pick the other three cards from the non-aces. Multiply the two counts, and note that all three of those cards must be non-aces, or the hand would hold more than two aces.
Divide:
About of hands, or one in every twenty-five or so. The formula never changed; only the size of the counts did.
The birthday problem
This is an extended application of the complement rule you already learned, on a famous example where intuition usually gets it wrong. It does not introduce a new probability rule.
Probability earns its reputation for being counter-intuitive on questions like this one. In a room of people, what is the probability that at least two of them share a birthday?
Most people guess something small, on the order of a few percent. The true answer is just over one half. Here is the full computation. Assume days, ignore leap years and seasonal effects, and take a person’s birthday to be equally likely to be any day. An outcome is an assignment of one day to each of the people, so the multiplication principle gives
and all of these are equally likely. The event “at least two share” is a nightmare to count head on: two people might share, or three, or two separate pairs might match. So take the complement, exactly as with “at least one six”. Let be the event that all birthdays are different. Counting is a one-liner, because you assign the days one person at a time and each new person must dodge every day already used:
a product of falling factors. Therefore
and the complement rule finishes the job:
Just over , so in a room of a shared birthday is more likely than not.
Why does the answer feel so wrong? Because most people silently answer a different question: “does anyone here share my birthday?” That one really is unlikely. Among other people, the chance that none matches your day is , so the chance someone does is only about , and your intuition was right about that.
The question actually asked is not about you. It is about every pair of people in the room, and pairs are counted with combinations:
Two hundred and fifty-three chances for a match, not twenty-two. Each pair matches with probability . Give every pair its own small “share” of toward a match, and add up the shares: . Adding shares like that is always allowed, no matter how the pairs relate to each other, because you are only totaling how much each pair contributes, not asking whether an event happened. Read the total carefully, though, because it is not a probability. It is a count, called the expected number of matching pairs: roughly how many a room of would turn up on average, a later course’s full topic but honest to name here. Nothing stops such a count from passing , and in a room of it already has, at . So it cannot be the answer, and neither of the two shortcuts below will convert it into one.
The reasons the shortcuts fail are different, and this lesson is precisely about not confusing them. You cannot add the pair probabilities to get the answer, because the pair events overlap: several pairs can match at once, and adding would count those rooms many times over. That is the addition rule talking, and what it demands is disjointness, which these events plainly do not have.
Separately, you cannot multiply the “no match” probabilities either, and the reason is more subtle. Take any two of the events by themselves, say “Ann and Bob match” and “Bob and Cara match”. Those two, on their own, really are independent: knowing one tells you nothing about the other. The trouble only shows up once you look at all together. If Ann and Bob match and Bob and Cara match, then Ann and Cara are forced to match too, so the third event is decided the moment the first two happen. A collection of truly independent events can never do that to each other. So it is the whole collection that fails to be independent, not any two events you might pick out of it: pairwise independence (any two, checked alone) does not force mutual independence (the whole collection, checked together), and that gap is enough to break the multiplication shortcut.
The exact count of above remains the proof. The pair count is only here to explain why a match is not the long shot it feels like. The room grows one person at a time, but the pairs grow roughly like the square of the room.