Quiz 2

Probability Rules — Addition, Multiplication, and Trees

2293 words
11 min read
Python Week 1: the first filter for runtime behavior
Visual companion
Python
Type and operator map

Python Week 1: the first filter for runtime behavior

View
Revision summary

What this note is really saying

Short form

# Probability Rules — Addition, Multiplication, and Trees ## 🎯 Learning Objectives After completing this topic, you will be able to: - Apply the **addition rule** for both disjoint and non-disjoint events - Apply the **multiplication rule** for independent and dependent events - Construct and use **probability tree...

Probability Rules — Addition, Multiplication, and Trees

🎯 Learning Objectives

After completing this topic, you will be able to:
  • Apply the addition rule for both disjoint and non-disjoint events
  • Apply the multiplication rule for independent and dependent events
  • Construct and use probability trees to solve multi-stage probability problems
  • Determine whether events are independent
  • Solve probability problems using systematic approaches

📋 Prerequisites

  • Probability Intro (11-probability-intro) — sample spaces, events, basic probability
  • Basic set theory: union, intersection, complement
  • Conditional probability will be formalized in the next topic, but we'll use the intuition here

📖 Core Content

13.1 Intuition: Rules for Combining Probabilities

Just as we have rules for combining numbers (addition, multiplication), we have rules for combining probabilities. The questions these rules answer:
  • Addition rule: What's the probability that A OR B happens?
  • Multiplication rule: What's the probability that A AND B both happen?
  • Probability trees: How do we compute probabilities over multiple sequential stages?
Everyday analogy: When planning a trip, you might need to know: probability of rain OR snow (addition), probability of rain AND your flight being delayed (multiplication), or the overall probability of a successful trip considering weather, traffic, and flight availability (tree). 🔑 Key Insight: The key distinction is always: are events disjoint (mutually exclusive) or independent? These terms sound similar but are very different.

13.2 The Addition Rule

13.2.1 For Disjoint (Mutually Exclusive) Events

Events A and B are disjoint if they cannot happen simultaneously: AB=A \cap B = \varnothing.
P(AB)=P(A)+P(B)P(A \cup B) = P(A) + P(B)

13.2.2 For Non-Disjoint Events (General Addition Rule)

If A and B can happen together:
P(AB)=P(A)+P(B)P(AB)P(A \cup B) = P(A) + P(B) - P(A \cap B)
(Diagram) Why subtract P(AB)P(A \cap B)? When we add P(A)+P(B)P(A) + P(B), we double-count the probability where both happen (the overlap). So we subtract it once.

Example

If P(A)=0.4P(A) = 0.4, P(B)=0.3P(B) = 0.3, P(AB)=0.1P(A \cap B) = 0.1:
P(AB)=0.4+0.30.1=0.6P(A \cup B) = 0.4 + 0.3 - 0.1 = 0.6
If A and B were disjoint: P(AB)=0.4+0.3=0.7P(A \cup B) = 0.4 + 0.3 = 0.7 (higher, because there's no overlap to subtract).

13.3 The Multiplication Rule

13.3.1 For Independent Events

Events A and B are independent if the occurrence of A does not affect the probability of B.
P(AB)=P(A)×P(B)P(A \cap B) = P(A) \times P(B)
Examples of independent events:
  • Flipping a coin twice: first flip doesn't affect second
  • Rolling two dice: die A doesn't affect die B
  • Drawing cards with replacement

13.3.2 For Dependent Events (General Multiplication Rule)

If events are dependent (the occurrence of A changes the probability of B):
P(AB)=P(A)×P(BA)P(A \cap B) = P(A) \times P(B|A)
Where P(BA)P(B|A) is the conditional probability of B given A. Example of dependent events:
  • Drawing cards without replacement: the first draw changes the deck composition

13.4 Checking Independence

Two events are independent if (any of these hold):
  1. P(AB)=P(A)×P(B)P(A \cap B) = P(A) \times P(B)
  2. P(BA)=P(B)P(B|A) = P(B)
  3. P(AB)=P(A)P(A|B) = P(A)

Example

Weather data: P(rain)=0.4P(\text{rain}) = 0.4, P(cloudy)=0.6P(\text{cloudy}) = 0.6, P(raincloudy)=0.35P(\text{rain} \cap \text{cloudy}) = 0.35. Are rain and cloudy independent? Check: 0.4×0.6=0.240.350.4 \times 0.6 = 0.24 \neq 0.35 So they're not independent (which makes sense — rain and clouds are related).

13.5 Probability Trees

A probability tree is a diagram that shows all possible outcomes of a multi-stage process, with probabilities along each branch.

How to Build a Tree

  1. Start at the root
  2. For each stage, draw branches for each possible outcome
  3. Label each branch with its conditional probability
  4. Multiply along paths to get joint probabilities
  5. Sum relevant paths for the probability of interest

Example: Two Cards Without Replacement

Draw 2 cards from a deck of 52 without replacement. Probability both are hearts? (Diagram) Answer: P(both hearts)=14×1251=12204=117P(\text{both hearts}) = \frac{1}{4} \times \frac{12}{51} = \frac{12}{204} = \frac{1}{17}

13.6 "At Least One" Problems

Strategy: Use the complement rule: P(at least one)=1P(none)P(\text{at least one}) = 1 - P(\text{none}) Example: Roll a fair die 4 times. Probability of getting at least one 6?
P(at least one 6)=1P(no 6s)=1(56)4=16251296=67112960.518P(\text{at least one 6}) = 1 - P(\text{no 6s}) = 1 - \left(\frac{5}{6}\right)^4 = 1 - \frac{625}{1296} = \frac{671}{1296} \approx 0.518

13.7 Worked Examples

Example 1: Addition Rule (Easy)

Scenario: In a class, 30% are in the Math club, 20% are in the Science club, and 8% are in both. What percentage are in at least one club? Solution: P(MS)=P(M)+P(S)P(MS)=0.30+0.200.08=0.42P(M \cup S) = P(M) + P(S) - P(M \cap S) = 0.30 + 0.20 - 0.08 = 0.42 So 42% of students are in at least one club.

Example 2: Independence Check (Medium)

Scenario: P(A)=0.5P(A) = 0.5, P(B)=0.4P(B) = 0.4, P(AB)=0.2P(A \cap B) = 0.2. Are A and B independent? Solution: Check: P(A)×P(B)=0.5×0.4=0.2P(A) \times P(B) = 0.5 \times 0.4 = 0.2 P(AB)=0.2P(A \cap B) = 0.2 Since P(AB)=P(A)×P(B)P(A \cap B) = P(A) \times P(B), the events are independent.

Example 3: Probability Tree (Harder)

Scenario: A factory has two machines. Machine 1 produces 60% of items, of which 5% are defective. Machine 2 produces 40% of items, of which 8% are defective. You randomly pick an item. a) What's the probability it's defective? b) If it's defective, what's the probability it came from Machine 1? Solution: Tree: (Diagram) a) P(defective)P(\text{defective}): Sum the defective paths:
P(D)=0.03+0.032=0.062P(D) = 0.03 + 0.032 = 0.062
b) P(M1D)P(M_1|D): The probability it's from Machine 1 GIVEN it's defective:
P(M1D)=P(M1D)P(D)=0.030.0620.484P(M_1|D) = \frac{P(M_1 \cap D)}{P(D)} = \frac{0.03}{0.062} \approx 0.484
So about 48.4% of defective items come from Machine 1, even though Machine 1 produces 60% of all items. Machine 2 has a higher defect rate, producing more defectives proportionally.

13.8 Edge Cases & Gotchas

Disjoint vs. Independent — Don't Confuse!

ConceptDefinitionExample
DisjointAB=A \cap B = \varnothing (can't both happen)A: die shows 1, B: die shows 2
IndependentP(AB)=P(A)P(B)P(A \cap B) = P(A)P(B)A: coin heads, B: die shows 6
Key fact: Disjoint events (with positive probability) are NEVER independent! If A and B are disjoint and both have positive probability, then P(AB)=0P(A \cap B) = 0 but P(A)P(B)>0P(A)P(B) > 0. Why? If A and B can't happen together, knowing that A happened tells you B definitely didn't happen — that's dependence.

"Or" in Everyday Language

In everyday language, "or" is often exclusive ("coffee or tea?" means one or the other, not both). In probability, "or" always means inclusive (one, the other, OR both).

13.9 Why This Matters

These rules are the building blocks of:
  • Bayes' theorem (next topic): Based on the multiplication rule
  • Diagnostic testing: Sensitivity, specificity, predictive values
  • Risk analysis: Combining probabilities in chains of events
  • Decision trees: Business decisions under uncertainty

📐 Key Formulas / Concepts

RuleFormulaWhen to Use
Addition (disjoint)P(AB)=P(A)+P(B)P(A \cup B) = P(A) + P(B)Events can't happen together
Addition (general)P(AB)=P(A)+P(B)P(AB)P(A \cup B) = P(A) + P(B) - P(A \cap B)Events can overlap
Multiplication (independent)P(AB)=P(A)×P(B)P(A \cap B) = P(A) \times P(B)Events don't affect each other
Multiplication (general)$P(A \cap B) = P(A) \times P(B\A)$
ComplementP(Aˉ)=1P(A)P(\bar{A}) = 1 - P(A)"At least one" problems
Independence checkP(AB)=P(A)P(B)P(A \cap B) = P(A)P(B)Test if events are independent

⚠️ Common Pitfalls

Pitfall 1: Adding Probabilities of Non-Disjoint Events Without Subtracting Overlap

The mistake: P(AB)=P(A)+P(B)P(A \cup B) = P(A) + P(B) when A and B can both happen. Why it happens: "Or" suggests addition. Correction: Always check for overlap. If there's overlap, subtract it.

Pitfall 2: Multiplying Probabilities of Dependent Events

The mistake: P(AB)=P(A)×P(B)P(A \cap B) = P(A) \times P(B) when events are dependent. Why it happens: The multiplication rule for independent events is simpler, and students default to it. Correction: Ask: "Does A happening change the probability of B?" If yes, use P(AB)=P(A)×P(BA)P(A \cap B) = P(A) \times P(B|A).

Pitfall 3: Confusing Disjoint and Independent

The mistake: Thinking disjoint events are independent. Why it happens: Both concepts involve events being "separate" in some sense. Correct understanding: Disjoint = can't both happen. Independent = one doesn't affect the other. They're opposite concepts in some ways.

📝 Practice Questions

Q1: Addition Rule
P(A)=0.35P(A) = 0.35, P(B)=0.25P(B) = 0.25, P(AB)=0.10P(A \cap B) = 0.10. Find P(AB)P(A \cup B).
<details> <strong>Solution</strong>
P(AB)=0.35+0.250.10=0.50P(A \cup B) = 0.35 + 0.25 - 0.10 = 0.50
0.50\boxed{0.50}
</details> > **Q2: Multiplication Rule (Independent)** > > </strong> > > A fair coin is flipped and a fair die is rolled. Probability of heads AND a 6? > > <details> <strong>Solution</strong> > > These are independent events. > > $P(H \cap 6) = P(H) \times P(6) = \frac{1}{2} \times \frac{1}{6} = \frac{1}{12}$ > > $\boxed{1/12}$ </details> > **Q3: Without Replacement** > > </strong> > > Draw 2 cards from a deck without replacement. Probability both are aces? > > <details> <strong>Solution</strong> > > **Method 1:** $P(\text{first ace}) = 4/52$ $P(\text{second ace | first ace}) = 3/51$ $P(\text{both aces}) = \frac{4}{52} \times \frac{3}{51} = \frac{12}{2652} = \frac{1}{221}$ > > **Method 2 (combinations):** $\frac{C(4,2)}{C(52,2)} = \frac{6}{1326} = \frac{1}{221}$ > > $\boxed{1/221}$ </details> > **Q4: At Least One** > > A biased coin has P(H) = 0.6. Flip it 3 times. Probability of at least one head? > > <details> <strong>Solution</strong> > > $P(\text{at least one H}) = 1 - P(\text{no heads}) = 1 - P(\text{all tails})$ > > $P(\text{tails}) = 1 - 0.6 = 0.4$ > > $P(\text{all tails}) = 0.4^3 = 0.064$ > > $P(\text{at least one H}) = 1 - 0.064 = 0.936$ > > $\boxed{0.936}$ </details> > **Q5: Independence Check** > > </strong> > > $P(A) = 0.6$, $P(B) = 0.5$, $P(A \cap B) = 0.25$. Are A and B independent? > > <details> <strong>Solution</strong> > > $P(A) \times P(B) = 0.6 \times 0.5 = 0.30$ > > $P(A \cap B) = 0.25$ > > Since $0.25 \neq 0.30$, they are **not independent**. </details> > **Q6: Probability Tree** > > </strong> > > Bag A has 3 red, 2 blue. Bag B has 1 red, 4 blue. Flip a fair coin: if heads, draw from A; if tails, draw from B. Probability of drawing a red ball? > > <details> <strong>Solution</strong> > > **Tree:** > > - Heads (0.5) → Red from A: 3/5 → $0.5 \times 3/5 = 0.30$ > - Heads (0.5) → Blue from A: 2/5 → $0.5 \times 2/5 = 0.20$ > - Tails (0.5) → Red from B: 1/5 → $0.5 \times 1/5 = 0.10$ > - Tails (0.5) → Blue from B: 4/5 → $0.5 \times 4/5 = 0.40$ > > $P(\text{red}) = 0.30 + 0.10 = 0.40$ > > $\boxed{0.40}$ </details> > **Q7: Application — Diagnostic Test** > > </strong> > > A test for a disease has: > > - Sensitivity: 90% (correctly identifies those with the disease) > - Specificity: 95% (correctly identifies those without) > - Prevalence: 3% (the disease rate in the population) > > Find the probability that a randomly selected person tests positive. > > <details> <strong>Solution</strong> > > **Tree approach:** > > - Has disease (0.03) → positive (0.90): $0.03 \times 0.90 = 0.027$ > - Has disease (0.03) → negative (0.10): $0.03 \times 0.10 = 0.003$ > - No disease (0.97) → positive (0.05): $0.97 \times 0.05 = 0.0485$ > - No disease (0.97) → negative (0.95): $0.97 \times 0.95 = 0.9215$ > > $P(\text{positive}) = 0.027 + 0.0485 = 0.0755 \approx 7.55\%$ > > So about 7.55% of the population tests positive, but only a fraction (0.027/0.0755 ≈ 35.8%) actually have the disease. > > $\boxed{0.0755}$ </details> > **Q8: Extended Addition** > > </strong> > > $P(A) = 0.5$, $P(B) = 0.3$, $P(C) = 0.2$, $P(A \cap B) = 0.1$, $P(A \cap C) = 0.08$, $P(B \cap C) = 0.04$, $P(A \cap B \cap C) = 0.02$. Find $P(A \cup B \cup C)$. > > <details> <strong>Solution</strong> > > $P(A \cup B \cup C) = P(A) + P(B) + P(C) - P(A\cap B) - P(A\cap C) - P(B\cap C) + P(A\cap B\cap C)$ > > $= 0.5 + 0.3 + 0.2 - 0.1 - 0.08 - 0.04 + 0.02 = 0.80$ > > $\boxed{0.80}$ </details> > **Q9: Three Events Independence** > > </strong> > > If $P(A) = 0.5$, $P(B) = 0.4$, $P(C) = 0.3$, and events are mutually independent, find $P(A \cap B \cap C)$. > > <details> <strong>Solution</strong> > > For mutually independent events: > > $P(A \cap B \cap C) = P(A) \times P(B) \times P(C) = 0.5 \times 0.4 \times 0.3 = 0.06$ > > $\boxed{0.06}$ </details> > **Q10: Application — System Reliability** > > </strong> > > A system works if at least one of two components works. Component A works with probability 0.9. Component B works with probability 0.8. They fail independently. What's the probability the system works? > > <details> <strong>Solution</strong> > > **Method 1 (Direct):** $P(\text{system works}) = P(A \cup B) = P(A) + P(B) - P(A \cap B)$ $= 0.9 + 0.8 - (0.9 \times 0.8) = 1.7 - 0.72 = 0.98$ > > **Method 2 (Complement):** $P(\text{system fails}) = P(\bar{A} \cap \bar{B}) = P(\bar{A}) \times P(\bar{B}) = 0.1 \times 0.2 = 0.02$ $P(\text{system works}) = 1 - 0.02 = 0.98$ > > $\boxed{0.98}$ </details> * * * ## 🔗 Cross-References - **Next topic:** [Conditional Probability](/notes/01-foundation-bsma1002-stats-1-week08-13-conditional-probability) — formalizing $P(A|B)$ - **After that:** [Bayes' Theorem](/notes/01-foundation-bsma1002-stats-1-week08-14-bayes-theorem) — the capstone of probability rules - **Week 9 (Random Variables):** Probability distributions build on these rules - **BSMA1004 (Stats 2):** Likelihood functions use the multiplication rule [Join Discord](https://discord.gg/gE2m4Qrdqv) [Previous**Probability Basics**](/notes/01-foundation-bsma1002-stats-1-week07-11-probability-intro)[Next**Conditional Probability**](/notes/01-foundation-bsma1002-stats-1-week08-13-conditional-probability)
Document outline

Keep your place and jump directly to a heading.

Table of Contents
System Normal // Awaiting Context

Intelligence Hub

Navigate the knowledge graph to generate context. The Hub adapts dynamically to surface backlinks, related notes, and metadata insights.