This tool builds a two-stage probability tree from numbers you choose or from a bag of red and blue balls. It is for students who can draw branches but are unsure how to combine them to answer the question.
Probability tree builder
You draw the tree but cannot decide when to multiply and when to add.
Everything you enter stays on this device.
How do I use it?
- Choose a model: enter the probabilities yourself, or use the bag of balls.
- For your own numbers, type P(A), then P(B) if A happened, then P(B) if A did not happen. For the bag, type the red and blue counts and tick the box if the first ball is replaced.
- Press “Build tree”.
- Tick the paths that make up your event to see their probabilities added.
How does it work?
The second branch at every node is found as 1 minus the first, so each pair of branches always adds to 1. Every probability must be between 0 and 1, and the tool rejects anything else.
Each path is the product of its two branches. The four paths do not overlap, so the probability of an event is the sum of the paths you tick. The tool also checks that all four paths add to 1.
For the bag, the first draw is red with probability r/(r+b). With replacement the second draw uses the same numbers. Without replacement the second draw uses the balls left.
A short worked example
A bag holds 3 red and 2 blue balls, and two balls are drawn without replacement.
P(red first) = 3/5. If the first is red, 2 red remain among 4, so P(red second) = 2/4. The path red then red is 3/5 × 2/4 = 3/10.
Tick “red then blue” and “blue then red” to find exactly one red. Those paths are 3/10 and 3/10, and adding them gives 3/5.
What are its limits?
The tool covers two stages only and a bag with two colours, or probabilities you type yourself. It does not handle three or more stages, conditional questions stated in words, or statistical inference. It describes a model, so the answers are only as good as the numbers you enter.
Where does it connect to the lessons?
The tool supports combined event probability and its practice questions. Draw your own tree on paper first, then use this page to check the paths and the final sum.
If the changing denominators or the add-or-multiply choice keep costing marks, SPM Mathematics tuition gives you a teacher to rebuild the idea with you. It starts with the one-hour trial class (from RM50).
Common questions
When do I multiply and when do I add?
Multiply along the branches of one path, because both things must happen. Add the probabilities of different paths that belong to your event, because any one of them is enough. The tool shows both steps separately.
Why does the second stage change without replacement?
After a ball is removed, the bag has one fewer ball, and one colour may have one fewer as well. The second-stage probabilities are calculated from what remains. The bag model in the tool does this for you.
Why are my probabilities rejected?
A probability must be between 0 and 1 inclusive. The tool rejects values such as 1.2 or -0.1 and asks you to correct them, instead of drawing a meaningless tree.
Can the tool tell me what will happen?
No. A tree describes a model with the probabilities you give it. It does not forecast real events and it is not betting advice.
A teacher working one-to-one can look at which step of your tree keeps going wrong, for example the changed denominator without replacement, and practise that step until it is automatic.
- Online one-to-one lessons for your child with an experienced teacher.
- Your first class is a one-hour trial, from RM50. The fee is agreed before you book.
- Happy with the teacher? Continue with lessons of about 1.5 hours. If not, ask for another teacher.