Maths4U · Learning together
Trees, total probability and reverse conditioning
Notes
Objective
Weight every route through a mixture and distinguish independence within a group from independence after mixing.
Before you start
Use exact fractions and identify what is selected at random. Counting-selections questions refer to the next chapter; the combination notation used there is introduced briefly in the final lesson.
Key ideas
Choose the population, then the outcome
If the first-stage groups G and G′ exhaust the possibilities,
Group labels do not make groups equally likely. At every reached node, outgoing probabilities sum to 1; terminal path probabilities also sum to 1.
Reverse the condition through the joint event
The denominator must include success through every possible group. Use the observed outcome to update the group probability; do not just report a forward branch.
Conditional independence can disappear after mixing
Two tests may be independent within each production line while both share that unobserved line. Calculate the unconditional joint and compare it with the product of the unconditional marginals. Choosing one line once is different from choosing a fresh line before each test.
Recover an unknown branch or group weight
Use the total-probability equation, then check the recovered value lies between 0 and 1 and reproduces the observed total. A zero denominator makes a conditional undefined, not zero.
Method
- Define outcomes, events and any condition before calculating.
- Decide which outcomes are equally likely and which branch probabilities change.
- Multiply along a path and add only disjoint qualifying paths.
- For a conditional probability, restrict both numerator and denominator to the stated condition.
- Check probability bounds, all branches and original model restrictions.
Common mistakes
- Weight groups by their actual selection probabilities.
- A posterior is not its forward branch.
- The denominator includes all routes to the observed outcome.
- Independence within groups does not imply independence after mixing.
Worked examples
A weighted choice changes the observed mixture
Container A is chosen with probability , B otherwise. Their red proportions are and . One counter is selected uniformly from the chosen container. Find the red probability and the chance of A given red.
Follow the solutionRecover an unknown success branch
A route A is chosen with probability . It succeeds with probability . The other route succeeds with probability q. Overall success has probability . Find q.
Follow the solutionThus q=. It lies in [0,1] and reproduces the given success probability.
Independent inside each line, dependent overall
A component comes from A with probability , B otherwise. Conditional on the line, two tests are independent, each with pass chance on A and on B. Find the marginal and joint pass probabilities, then update the line probability after two passes.
Follow the solutionThe two pass events are dependent overall because differs from . Each term in the joint first weights the appropriate line, then multiplies its two conditional pass chances.
A rare observation updates a source proportion
Source A has defect probability ; B has defect probability . Overall defect probability is . Find the proportion from A and the chance that a defective item came from A.
Follow the solutionHence w=.
The posterior is different from the prior and from the forward defect probability .