EN2 - Tree diagrams, tables and Venn diagrams

EN2 - Tree diagrams, tables and Venn diagrams

A good picture keeps track of outcomes without missing any or counting one twice. You will construct and use trees for successive choices, two-way tables for paired outcomes and Venn diagrams for overlapping groups. The picture you choose depends on what the outcome actually records.

Listing successive outcomes with a tree

Roll two fair four-sided dice and record the higher score. Is a recorded score of 44 four times as likely as a recorded score of 11? A list of possible recorded scores, 1,2,3,41, 2, 3, 4, hides something important: several different dice outcomes give the same recorded score. We will uncover exactly how many.

Start with a smaller task. Choose a drink, tea or juice, then a snack, apple or biscuit. A tree gives each decision its own stage. Follow a route from left to right to read one complete outcome.

You already know

A sample space lists all possible outcomes. For equally likely outcomes, P(A)=number of outcomes in Atotal number of outcomes\mathrm{P}(A)=\frac{\text{number of outcomes in }A}{\text{total number of outcomes}}. This counting rule is not on the formulae sheet: learn it. Outcomes must really be equally likely before you use it.

The first choice does not complete the outcome: “tea” must be followed by a snack. Each final endpoint represents a complete pair, and every allowed pair needs exactly one endpoint.

[DIAGRAM: asset_name: A tree of drink and snack choices; asset_slug: en2-choice-tree; caption: Each complete route records one drink and one snack; description: A left-to-right tree splits first into tea and juice, then each drink splits into apple and biscuit. Four endpoints are labelled tea apple, tea biscuit, juice apple and juice biscuit. Stage headings identify drink and snack.]
Each complete route records one drink and one snack

Outcome tree

A tree diagram represents successive stages by branches. A complete route from the starting point to an endpoint represents one outcome. For example, tea then apple is one outcome. Tea on its own is not a complete outcome of choosing both a drink and a snack.

Draw the stages in a fixed order, include every allowed branch, then read the endpoints systematically. If an earlier choice removes a later option, the relevant branch must disappear.

Worked example 1: all pairs are allowed

Question. A code consists of one letter, AA or BB, followed by one digit, 1,21, 2 or 33. Use a tree to list its possible codes.

Plan. Draw two first-stage branches, then attach all three digit branches to each.

A⟶A1, A2, A3three endpoints from AB⟶B1, B2, B3three endpoints from Bnumber of codes=3+3=6count complete routes\begin{aligned} A&\longrightarrow A1,\ A2,\ A3 && \text{three endpoints from }A\\ B&\longrightarrow B1,\ B2,\ B3 && \text{three endpoints from }B\\ \text{number of codes}&=3+3=6 && \text{count complete routes} \end{aligned}

Why branch again from both letters? Either letter can be followed by any of the three digits; stopping after the first stage would miss half the code.

Answer. A1,A2,A3,B1,B2,B3A1, A2, A3, B1, B2, B3: 66 codes.

Check. The lists starting with AA and BB have no code in common, and each contains every permitted digit.

The next example changes one feature: an earlier choice now removes a later choice. The second stage depends on the first.

Worked example 2: an object cannot be chosen twice

Question. Three cards are labelled P,Q,RP, Q, R. Two cards are drawn in order without replacement. Use a tree to list the outcomes.

Plan. Give the first draw three branches, then omit that drawn card from its second-stage branches.

P⟶PQ, PRthe P card is goneQ⟶QP, QRthe Q card is goneR⟶RP, RQthe R card is gonenumber of outcomes=2+2+2=6count endpoints\begin{aligned} P&\longrightarrow PQ,\ PR && \text{the }P\text{ card is gone}\\ Q&\longrightarrow QP,\ QR && \text{the }Q\text{ card is gone}\\ R&\longrightarrow RP,\ RQ && \text{the }R\text{ card is gone}\\ \text{number of outcomes}&=2+2+2=6 && \text{count endpoints} \end{aligned}

Why keep PQPQ and QPQP? The outcome records the order of the draws. They follow different routes, even though they use the same cards.

Answer. PQ,PR,QP,QR,RP,RQPQ, PR, QP, QR, RP, RQ: 66 outcomes.

Check. No listed outcome repeats a card, and each possible first card appears twice.

A tree is a record of the rules, so changing those rules changes its branches.

Watch out

Wrong: include PPPP when drawing without replacement from one PP card. There is no PP left for the second draw. Right: after PP, branch only to QQ and RR. With replacement, PPPP would be allowed.

Try the same structure with one extra card. You can describe each set of branches in text; a separate drawing is unnecessary here.

Counting paired outcomes with a two-way table

A two-way table puts the first outcome down the rows and the second across the columns, so every cell stands for one ordered pair.

For two four-sided dice, label the rows with the first die's scores and the columns with the second die's scores. The cell in row 22, column 44 represents (2,4)(2, 4); row 44, column 22 represents (4,2)(4, 2). These are different outcomes even if the quantity recorded is the same.

Two-way outcome table

A two-way outcome table has one possible first-stage result per row and one possible second-stage result per column. Fill each cell using the stated rule. A repeated value in several cells represents several different underlying outcomes, not a duplicate to remove.

For our opening question, put the higher of the two scores in each cell. Read the rule carefully: adding the scores would answer a different question.

[DIAGRAM: asset_name: Higher score from two four-sided dice; asset_slug: en2-higher-score-table; caption: Seven of the sixteen equally likely dice pairs have higher score 4; description: A four-by-four outcome table has row and column headings 1 to 4. Each cell shows the maximum of its row and column headings. The last row and last column are pale blue with their common corner counted once. The seven highlighted cells contain 4; the upper-left cell alone contains 1.]
Seven of the sixteen equally likely dice pairs have higher score 4

Worked example 3: a square outcome table

Question. Two fair four-sided dice, each numbered 11 to 44, are rolled. The higher score is recorded. Find the probabilities of recording 11 and of recording 44.

Plan. Fill the outcome table with the higher score, then count the relevant cells.

first\second123411234222343333444444\begin{array}{c|rrrr} \text{first}\backslash\text{second}&1&2&3&4\\\hline 1&1&2&3&4\\ 2&2&2&3&4\\ 3&3&3&3&4\\ 4&4&4&4&4 \end{array} total cells=4+4+4+4=16four rowscells recording 1=1only (1,1)cells recording 4=4+4−1=7last row or column\begin{aligned} \text{total cells}&=4+4+4+4=16 && \text{four rows}\\ \text{cells recording }1&=1 && \text{only }(1, 1)\\ \text{cells recording }4&=4+4-1=7 && \text{last row or column} \end{aligned}

Why subtract 11? The corner (4,4)(4, 4) belongs to both the last row and the last column; it is only one cell.

Answer. P(1 recorded)=116\mathrm{P}(1\text{ recorded})=\frac1{16} and P(4 recorded)=716\mathrm{P}(4\text{ recorded})=\frac7{16}.

Check. The counts for recorded scores 1,2,3,41, 2, 3, 4 are 1,3,5,71, 3, 5, 7, which sum to 1616. Thus 44 is seven times as likely as 11, answering the opening question.

Here is a pleasing pattern hidden in the picture: the first kk odd numbers sum to k2k^2. Each new outside row and column enlarges a square by the next odd number of cells. In particular, 1+3+5+7=161+3+5+7=16.

The next example changes only the second die: the table becomes a rectangle.

Worked example 4: a rectangular outcome table

Question. A fair four-sided die numbered 11 to 44 and a fair five-sided die numbered 11 to 55 are rolled. The higher score is recorded. Find the probability of recording 44.

Plan. Use four rows and five columns, then count cells whose higher score is 44.

first\second12345112345222345333345444445\begin{array}{c|rrrrr} \text{first}\backslash\text{second}&1&2&3&4&5\\\hline 1&1&2&3&4&5\\ 2&2&2&3&4&5\\ 3&3&3&3&4&5\\ 4&4&4&4&4&5 \end{array} total cells=5+5+5+5=20four rowscells recording 4=1+1+1+4=7count row by rowP(4 recorded)=720equally likely pairs\begin{aligned} \text{total cells}&=5+5+5+5=20 && \text{four rows}\\ \text{cells recording }4&=1+1+1+4=7 && \text{count row by row}\\ \mathrm{P}(4\text{ recorded})&=\frac7{20} && \text{equally likely pairs} \end{aligned}

Why exclude the last cell in row 44? It represents (4,5)(4, 5), whose higher score is 55.

Answer. 720\frac7{20}.

Check. There are 55 cells recording 33, 77 recording 44 and 44 recording 55; together with the 1+31+3 earlier cells, that gives 2020.

Equal chances attach to the dice pairs, not to the values written in the cells.

Watch out

Wrong: “The recorded score is one of 1,2,3,41, 2, 3, 4, so each has probability 14\frac14.” The four values occur in different numbers of cells. Right: count equally likely underlying pairs before forming the probability.

Change the first die's range again and keep the recorded-value rule fixed.

Separating overlapping groups in a Venn diagram

A Venn diagram separates a collection into regions, so a person belonging to two groups is still counted once.

The rectangle is the universal set: everyone or everything under discussion. Circles show membership of particular sets. The overlap means both; outside both circles but inside the rectangle means neither. “Neither” is a region, not a third circle.

Intersection, union and complement

A∩BA\cap B means both AA and BB; A∪BA\cup B means AA or BB, including both. The complement A′A' means everything in the universal set that is not in AA. For example, a member of BB only belongs to A′A'. The complement is not just the region outside both circles.

Write numbers into the non-overlapping regions. If 2424 people belong to AA, and 99 of those also belong to BB, the AA-only region contains 24−9=1524-9=15, not 2424.

[DIAGRAM: asset_name: Membership totals and disjoint Venn regions; asset_slug: en2-two-set-venn; caption: The total in set A includes its overlap with set B; description: A labelled universal-set rectangle containing two overlapping circles A and B. The A-only region contains 15, the overlap contains 9, B-only contains 7, and the outside region contains 9. A note states total 40; A total 24; B total 16.]
The total in set A includes its overlap with set B

Worked example 5: start with the overlap

Question. Of 4040 students, 2424 study art, 1616 study music and 99 study both. Determine how many study neither.

Plan. Put 99 in the overlap, subtract it from each set total, then subtract all occupied regions from 4040.

art only=24−9=15remove the overlapmusic only=16−9=7remove the overlapat least one=15+9+7=31disjoint regionsneither=40−31=9complete the rectangle\begin{aligned} \text{art only}&=24-9=15 && \text{remove the overlap}\\ \text{music only}&=16-9=7 && \text{remove the overlap}\\ \text{at least one}&=15+9+7=31 && \text{disjoint regions}\\ \text{neither}&=40-31=9 && \text{complete the rectangle} \end{aligned}

Why not subtract 24+1624+16 from 4040? The 99 in both sets would have been subtracted twice.

Answer. 99 students study neither.

Check. The four regions total 15+9+7+9=4015+9+7+9=40, while the art and music totals are 2424 and 1616.

The next example changes the supplied region: you know “neither” and must recover “both”.

Worked example 6: recover the overlap

Question. Of 5252 students, 2929 cycle, 2424 swim and 88 do neither. Determine how many do both.

Plan. Find the total in at least one set, then account for the repeated count in the sum of the set totals.

at least one=52−8=44exclude neitherboth=29+24−44=9remove the double countcycle only=29−9=20subtract bothswim only=24−9=15subtract both\begin{aligned} \text{at least one}&=52-8=44 && \text{exclude neither}\\ \text{both}&=29+24-44=9 && \text{remove the double count}\\ \text{cycle only}&=29-9=20 && \text{subtract both}\\ \text{swim only}&=24-9=15 && \text{subtract both} \end{aligned}

Why does the excess give “both”? Everyone in one set is counted once in 29+2429+24, while everyone in both is counted twice.

Answer. 99 students do both.

Check. The disjoint regions give 20+9+15+8=5220+9+15+8=52.

The same double-counting correction can be written using counts, or using probabilities.

Combining two overlapping sets

n(A∪B)=n(A)+n(B)−n(A∩B)n(A\cup B)=n(A)+n(B)-n(A\cap B)

Here n(A)n(A) is the number in the finite set AA.
Not on the formulae sheet: learn it.

The same correction applies to probability: adding the two probabilities counts their overlap twice. This version is printed on the June 2027 extra sheet.

Probability of either event

P(A or B)=P(A)+P(B)−P(A and B)\mathrm{P}(A\text{ or }B) =\mathrm{P}(A)+\mathrm{P}(B)-\mathrm{P}(A\text{ and }B)

This holds for any two events AA and BB.
On the formulae sheet.

Keep the enclosing rectangle visible in a drawn answer. Its boundary tells the reader where the complement ends.

Watch out

Wrong: put the total 2929 in the cycle-only region, then add 99 in the overlap. That would make 3838 cyclists. Right: put 2020 in cycle only and 99 in both. Draw the universal-set rectangle and put “neither” outside the circles, inside it.

Use the same reasoning when the set totals are larger.

Building a three-set Venn diagram from the centre

With three sets, start in the triple overlap and work outwards; a total for “both” can include people in all three.

There are seven regions inside at least one of three circles, plus the region outside them all. For instance, “AA and BB” includes the triple overlap, whereas “AA and BB, but not CC” names just one region. Read that distinction before doing arithmetic.

Exactly two and at least two

A member of exactly two sets belongs to one of the three pair-only regions. A member of at least two sets belongs to one of those regions or to all three. For example, someone in A∩B∩CA\cap B\cap C counts towards “at least two”, but not “exactly two”.

The picture below separates totals from regions. Each number belongs in one region only.

[DIAGRAM: asset_name: Eight regions of three overlapping sets; asset_slug: en2-three-set-venn; caption: Fill the triple overlap before the pair-only regions and then the single-only regions; description: Three overlapping circles A, B and C within a universal-set rectangle, with region values A only 10, B only 8, C only 5, A and B only 4, A and C only 6, B and C only 3, all three 2, and neither 12. A legend gives universal total 50, A total 22, B total 17, C total 16.]
Fill the triple overlap before the pair-only regions and then the single-only regions

Worked example 7: inclusive pair totals

Question. In a group of 5050, 2222 belong to AA, 1717 to BB and 1616 to CC. Also 66 belong to both AA and BB, 88 to both AA and CC, 55 to both BB and CC, and 22 to all three. Find the number in none of the sets.

Plan. Subtract the triple overlap from each pair total, then complete the single-only and outside regions.

AB only=6−2=4remove all threeAC only=8−2=6remove all threeBC only=5−2=3remove all threeA only=22−4−6−2=10complete set AB only=17−4−3−2=8complete set BC only=16−6−3−2=5complete set Cnone=50−(10+8+5+4+6+3+2)=12complete the rectangle\begin{aligned} AB\text{ only}&=6-2=4 && \text{remove all three}\\ AC\text{ only}&=8-2=6 && \text{remove all three}\\ BC\text{ only}&=5-2=3 && \text{remove all three}\\ A\text{ only}&=22-4-6-2=10 && \text{complete set }A\\ B\text{ only}&=17-4-3-2=8 && \text{complete set }B\\ C\text{ only}&=16-6-3-2=5 && \text{complete set }C\\ \text{none}&=50-(10+8+5+4+6+3+2)=12 && \text{complete the rectangle} \end{aligned}

Here AB onlyAB\text{ only} is shorthand for the region in AA and BB, but not CC.

Why begin at the centre? Its 22 is included in every inclusive pair total and in every set total. Removing it first prevents those 22 people appearing in several separate regions.

Answer. 1212 belong to none.

Check. Set CC contains 5+6+3+2=165+6+3+2=16; the eight regions total 5050.

The next example changes only the wording of the pair information: the pair-only regions are supplied directly.

Worked example 8: pair-only totals

Question. A survey of 5050 people gives n(A)=22n(A)=22, n(B)=17n(B)=17, n(C)=16n(C)=16. There are 44 in AA and BB only, 66 in AA and CC only, 33 in BB and CC only, and 22 in all three. Find how many belong to none of the sets.

Plan. Keep the supplied pair-only numbers unchanged and subtract the other three regions from each set total.

A only=22−4−6−2=10complete set AB only=17−4−3−2=8complete set BC only=16−6−3−2=5complete set Cnone=50−(10+8+5+4+6+3+2)=12complete the rectangle\begin{aligned} A\text{ only}&=22-4-6-2=10 && \text{complete set }A\\ B\text{ only}&=17-4-3-2=8 && \text{complete set }B\\ C\text{ only}&=16-6-3-2=5 && \text{complete set }C\\ \text{none}&=50-(10+8+5+4+6+3+2)=12 && \text{complete the rectangle} \end{aligned}

Why not subtract 22 from the pair-only values? The wording has already excluded the triple overlap from them. This describes exactly the same group as Worked example 7, but the pair-only regions are now supplied directly.

Answer. 1212 belong to none.

Check. The union contains 10+8+5+4+6+3+2=3810+8+5+4+6+3+2=38, leaving 1212 outside. All region counts are non-negative and total 5050, as before.

Negative region counts are a useful alarm: they indicate inconsistent data or an earlier subtraction error. All region values here are whole-number counts.

Watch out

Wrong: treat “88 in AA and CC” as “88 in AA and CC only” when 22 are in all three. Right: the pair-only region is 8−2=68-2=6. The word “only” changes what the number includes.

Try the same construction for a fresh survey. The pair-only counts are again supplied directly.

Quick Recap

  • A complete tree route represents one complete outcome; update later branches when an object is removed.
  • A two-way table distinguishes underlying pairs, even when several pairs produce the same recorded value.
  • Put Venn counts in disjoint regions inside a universal-set rectangle.
  • With three sets, fill the triple overlap first; distinguish “both” from “both only”.

The opening question: the higher score is 44 in 77 of the 1616 equally likely pairs, and 11 in only 11. The ratio is 7:17:1.