Math 2.0

Combinatorics Proof

Proof of the rule of sum

Builds on Cardinality of a finite setBijective functionDisjoint sets

Proof

We first treat two sets, and then argue by induction on kk.

  1. Let m=∣A∣m = |A| and n=∣B∣n = |B|. By the definition of cardinality, there are bijections f:{1,…,m}→Af : \set{1, \dots, m} \to A and g:{1,…,n}→Bg : \set{1, \dots, n} \to B.
  2. Define h:{1,…,m+n}→A∪Bh : \set{1, \dots, m + n} \to A \cup B by h(i)=f(i)h(i) = f(i) for i≤mi \le m and h(i)=g(i−m)h(i) = g(i - m) for m<i≤m+nm < i \le m + n.
  3. The map hh is surjective. An element of AA is f(i)=h(i)f(i) = h(i) for some i≤mi \le m. An element of BB is g(j)=h(m+j)g(j) = h(m + j) for some j≤nj \le n.
  4. The map hh is injective. Let h(i)=h(i′)h(i) = h(i'). If i,i′≤mi, i' \le m, then f(i)=f(i′)f(i) = f(i'), so i=i′i = i' because ff is injective.
  5. If i,i′>mi, i' > m, then g(i−m)=g(i′−m)g(i - m) = g(i' - m), so i=i′i = i' because gg is injective.
  6. If i≤m<i′i \le m < i', then h(i)∈Ah(i) \in A and h(i′)∈Bh(i') \in B. This is impossible, because AA and BB are disjoint. The case i′≤m<ii' \le m < i is the same.
  7. So hh is a bijection, A∪BA \cup B is finite, and ∣A∪B∣=m+n=∣A∣+∣B∣|A \cup B| = m + n = |A| + |B|.
  8. Now let A1,…,AkA_1, \dots, A_k be pairwise disjoint finite sets. For k=0k = 0 the union is empty and both sides are 00. For k=1k = 1 the formula ∣A1∣=∣A1∣|A_1| = |A_1| holds.
  9. Suppose the formula holds for kk sets, and let A1,…,Ak+1A_1, \dots, A_{k+1} be pairwise disjoint finite sets. Put U=A1∪⋯∪AkU = A_1 \cup \dots \cup A_k.
  10. By the induction hypothesis, UU is finite and ∣U∣=∣A1∣+⋯+∣Ak∣|U| = |A_1| + \dots + |A_k|.
  11. The sets UU and Ak+1A_{k+1} are disjoint. Indeed, an element of both would lie in Ai∩Ak+1A_i \cap A_{k+1} for some i≤ki \le k, and this set is empty.
  12. By steps 1 to 7, ∣U∪Ak+1∣=∣U∣+∣Ak+1∣=∣A1∣+⋯+∣Ak+1∣|U \cup A_{k+1}| = |U| + |A_{k+1}| = |A_1| + \dots + |A_{k+1}|. This completes the induction.

Idea

Number the elements of AA first and then continue the numbering through the elements of BB. Because no element is in both sets, no element gets two numbers. So the numbers 11 to ∣A∣+∣B∣|A| + |B| count the union exactly once.

Reading path

To understand this page from the ground up, read these 23 pages in order. The foundations come first.

Show the path as a graph
Cardinality of a finite set, definition, no evidence levelCardinality of a fini…definitionElement, definition, no evidence levelElementdefinitionProposition, concept, no evidence levelPropositionconceptSet, definition, no evidence levelSetdefinitionConjunction, definition, no evidence levelConjunctiondefinitionImplication, definition, no evidence levelImplicationdefinitionPredicate, definition, no evidence levelPredicatedefinitionEmpty set, object, no evidence levelEmpty setobjectOrdered pair, definition, no evidence levelOrdered pairdefinitionIntersection, definition, no evidence levelIntersectiondefinitionExistential quantifier, definition, no evidence levelExistential quantifierdefinitionUniversal quantifier, definition, no evidence levelUniversal quantifierdefinitionCartesian product, definition, no evidence levelCartesian productdefinitionDisjoint sets, definition, no evidence levelDisjoint setsdefinitionSubset, definition, no evidence levelSubsetdefinitionUniqueness quantifier, definition, no evidence levelUniqueness quantifierdefinitionBinary relation, definition, no evidence levelBinary relationdefinitionFunction, definition, no evidence levelFunctiondefinitionCodomain, definition, no evidence levelCodomaindefinitionInjective function, definition, no evidence levelInjective functiondefinitionSurjective function, definition, no evidence levelSurjective functiondefinitionBijective function, definition, no evidence levelBijective functiondefinitionProof of the rule of sum, proof, no evidence levelProof of the rule of …proof
Each page uses the pages above it. The colour of the bar on a box shows how strong the evidence is, and the box also gives it as text. The list has the same pages.
  • no evidence level
  1. Cardinality of a finite set definition
  2. Element definition
  3. Proposition concept
  4. Set definition
  5. Conjunction definition
  6. Implication definition
  7. Predicate definition
  8. Empty set object
  9. Ordered pair definition
  10. Intersection definition
  11. Existential quantifier definition
  12. Universal quantifier definition
  13. Cartesian product definition
  14. Disjoint sets definition
  15. Subset definition
  16. Uniqueness quantifier definition
  17. Binary relation definition
  18. Function definition
  19. Codomain definition
  20. Injective function definition
  21. Surjective function definition
  22. Bijective function definition
  23. Proof of the rule of sum proof

Where this leads

104 pages build on this one.

Further reading

  1. Web https://proofwiki.org/wiki/Sum_Rule_for_Counting
About this page
TagQAA80GMKNM
URIm2://QAA80GMKNM
Kindproof
WritingW0 stub
MSC05A05
ProvesRule of sum
UsesCardinality of a finite set, Bijective function, Disjoint sets
MethodsMathematical induction
Changed4 November 2026

Markdown · JSON · Edit on GitHub

What this page needs for W1

  • an inventory row: the row of the inventory that the node accounts for (0 of 1)
  • a source with a locator (0 of 1)

The writing levels say how complete the text of a page is. They do not measure its truth.

What links here

No page links to this page yet.