Networks and Combinatorics
Graph theory provides mathematical models for real-world networks — road systems, social networks, computer circuits. Combinatorics gives powerful counting tools for arrangements and selections. Both are Extended-level discrete mathematics topics assessed in the eAssessment calculator paper.
What You'll Learn
- Define and identify key graph theory terms: vertices, edges, degree, path, circuit
- Apply Euler's theorem to determine whether an Euler circuit or path exists
- Find minimum spanning trees using Kruskal's and Prim's algorithms
- Calculate permutations (nPr) and combinations (nCr) using factorials
- Distinguish when to use permutations vs combinations in context
- Apply counting principles (multiplication and addition rules) to multi-stage problems
eAssessment Focus
Criterion A: Apply Euler's theorem and counting formulas correctly in unfamiliar network contexts.
Criterion B: Investigate patterns in networks — e.g., how does vertex degree relate to traversability?
Criterion C: Use correct terminology: degree, Euler circuit, permutation, combination — define before applying.
Criterion D: Apply combinatorics to real contexts (scheduling, genetics, password security).
Key Vocabulary
| Term | Definition |
|---|---|
| Graph (network) | A set of vertices (nodes) connected by edges (arcs) |
| Vertex (node) | A point in a graph; plural: vertices |
| Edge (arc) | A connection between two vertices |
| Degree of a vertex | The number of edges meeting at that vertex |
| Path | A route through a graph that does not repeat any vertex |
| Circuit | A path that begins and ends at the same vertex |
| Connected graph | Every vertex can be reached from every other vertex |
| Weighted graph | A graph where edges have numerical values (weights), e.g., distances |
| Spanning tree | A subgraph connecting all vertices with no cycles and minimum edges |
| Permutation (nPr) | An ordered arrangement of r items from n: nPr = n! / (n−r)! |
| Combination (nCr) | An unordered selection of r items from n: nCr = n! / (r!(n−r)!) |
| Factorial (n!) | n! = n × (n−1) × … × 2 × 1; defined 0! = 1 |
Graph Theory Basics
A graph is a mathematical structure consisting of vertices and edges. Understanding the properties of graphs is the foundation for network problems.
Graph Properties
Simple Graph
No loops (edges connecting a vertex to itself) and no multiple edges between the same pair of vertices.
Complete Graph (Kn)
Every vertex is connected to every other vertex. Kn has n(n−1)/2 edges.
Directed Graph
Edges have a direction (arrows). Used for one-way streets, website links, task dependencies.
Bipartite Graph
Vertices split into two groups; edges only connect between groups (not within). Used for matching problems.
The Handshaking Lemma
∑deg(v) = 2|E|
This means the number of vertices with odd degree is always even. This is a powerful fact for checking your work.
Degree Table Approach
For exam questions, always build a degree table first:
| Vertex | Connected to | Degree |
|---|---|---|
| A | B, C, D | 3 (odd) |
| B | A, C | 2 (even) |
| C | A, B, D | 3 (odd) |
| D | A, C | 2 (even) |
Sum of degrees = 3 + 2 + 3 + 2 = 10 = 2 × 5 edges ✓
Euler Paths & Circuits
An Euler path traverses every edge exactly once. An Euler circuit does the same but returns to the starting vertex. Euler's theorem gives a simple test for when these exist.
Euler's Theorem
Euler path (not a circuit) exists ⇔ graph is connected AND exactly two vertices have odd degree (these are the start and end points).
Decision Table
| Odd-degree vertices | Result |
|---|---|
| 0 | Euler circuit exists (start/end anywhere) |
| 2 | Euler path exists (start at one odd vertex, end at the other) |
| 4 or more | No Euler path or circuit exists |
Hamiltonian Path vs Euler Path
Euler Path/Circuit
Visits every edge exactly once. Vertices may be revisited. Can test with the degree rule.
Hamiltonian Path/Circuit
Visits every vertex exactly once. No simple rule — must try systematically. Hamiltonian circuit = travelling salesman problem.
Minimum Spanning Trees
A spanning tree connects all vertices of a graph with no cycles. A minimum spanning tree (MST) does so with the smallest total edge weight. MSTs model efficient network design: road, cable, or pipeline systems.
Kruskal's Algorithm
- List all edges in ascending order by weight.
- Add the cheapest edge that does not create a cycle.
- Repeat until all n vertices are connected (you will add exactly n−1 edges).
Prim's Algorithm
- Start at any vertex.
- At each step, add the cheapest edge connecting the current tree to a new (not yet included) vertex.
- Repeat until all vertices are included.
Edges: AB=4, AC=2, BC=5, BD=3, CD=1, DE=6
Kruskal's step-by-step:
1. CD=1 ✓ (add)
2. AC=2 ✓ (add)
3. BD=3 ✓ (add)
4. AB=4 — skip (would create cycle A-C-D-B-A... check: A already connects to C and C to D and D to B; adding AB creates cycle ABCA)
Wait: A is connected to C; D is connected to C and B. Adding AB connects A to B; is there already a path A to B? A-C-D-B yes! Skip.
5. DE=6 ✓ (add)
MST total = 1+2+3+6 = 12
Combinatorics: Permutations & Combinations
Combinatorics is the mathematics of counting. Two fundamental tools — permutations and combinations — handle the vast majority of counting problems at MYP level.
The Fundamental Counting Principle
Total = 4 × 6 × 3 = 72 meals
Permutations (Order Matters)
The number of ordered arrangements of r items chosen from n distinct items.
Combinations (Order Does NOT Matter)
The number of unordered selections of r items from n distinct items. Also written as C(n,r) or nCr.
Permutation vs Combination: Decision Guide
| Situation | Order? | Use |
|---|---|---|
| Arranging books on a shelf | Yes | Permutation |
| Creating a PIN code / password | Yes | Permutation |
| First/second/third place in a race | Yes | Permutation |
| Choosing a committee | No | Combination |
| Selecting students for a group | No | Combination |
| Drawing cards from a deck (hand) | No | Combination |
Worked Examples
These examples cover the range of question types expected in the eAssessment. Show all steps.
Odd-degree vertices: B (degree 3) and D (degree 3) — two vertices with odd degree.
By Euler's theorem: An Euler circuit requires ALL vertices to have even degree. Since B and D are odd, no Euler circuit exists.
However, since exactly two vertices are odd, an Euler path exists starting at B and ending at D (or vice versa).
n = 10 digits, r = 4 chosen
10P4 = 10! / (10−4)! = 10! / 6! = 10 × 9 × 8 × 7 = 5040 PIN codes
Alternative method (multiplication principle): 10 choices for 1st digit × 9 for 2nd × 8 for 3rd × 7 for 4th = 5040 ✓
Ways to choose 2 teachers from 7: 7C2 = 7! / (2! × 5!) = (7 × 6) / 2 = 21
Ways to choose 2 students from 5: 5C2 = 5! / (2! × 3!) = (5 × 4) / 2 = 10
By the multiplication principle: Total = 21 × 10 = 210 ways
Step 1: Add CD=2 ✓ (no cycle)
Step 2: Add AC=3 ✓ (no cycle; connects A to C–D)
Step 3: Add BC=4 — check: B not yet connected to tree {A,C,D}, so ✓ add
Now all 4 vertices connected. n−1 = 3 edges added. Stop.
MST edges: CD=2, AC=3, BC=4. Total weight = 9.
Skip: AB=5 (would create cycle A-B-C-A), BD=7, AD=8.
8P3 = 8! / (8−3)! = 8! / 5! = 8 × 7 × 6 = 336 ways
52C5 = 52! / (5! × 47!) = (52 × 51 × 50 × 49 × 48) / (5 × 4 × 3 × 2 × 1)
= 311,875,200 / 120 = 2,598,960 hands
6 × 4 = 24 = 2|E|
|E| = 12 edges
For an Euler circuit: every vertex must have even degree. All vertices have degree 4 (even). If the graph is also connected, an Euler circuit exists.
Practice Q&A
Attempt each question before revealing the model answer. Always state whether you are using a permutation or combination, and why.
8P3 = 8! / 5! = 8 × 7 × 6 = 336
Letters: 26P3 = 26 × 25 × 24 = 15,600
Digits: 10P2 = 10 × 9 = 90
Total = 15,600 × 90 = 1,404,000 passwords
By Euler's theorem: no Euler circuit (not all even), but an Euler path exists (exactly 2 odd vertices), starting at the degree-1 vertex and ending at the degree-3 vertex.
10C3 = 10! / (3! × 7!) = (10 × 9 × 8) / 6 = 720 / 6 = 120 combinations
Note: for a straight line, the answer would be 5! = 120.
8C5 = 8! / (5! × 3!) = (8 × 7 × 6) / 6 = 56
8C3 = 8C5 = 56 ✓
This makes sense: choosing 3 items to include is equivalent to choosing 5 items to exclude.
Flashcard Review
Tap each card to reveal the answer. Try to answer from memory first.