Graphs and combinatorics
State whether a graph is directed, simple and connected. In counting, decide what is distinguishable, whether order matters and whether repetition is allowed before selecting a formula.
11.1 Graph basics and connectivity
Past papers · CS 2014–2026 (23 papers): 18 questions, 30 marks
A simple undirected graph has no loops or parallel edges. A walk may repeat edges and vertices; a trail has no repeated edge; a path has no repeated vertex. A connected component is a maximal connected subgraph. Strong connectivity in a digraph means directed reachability in both directions.
11.2 Graph structure, trails and planarity
Past papers · CS 2014–2026 (23 papers): 8 questions, 13 marks
Graph isomorphism is a vertex bijection preserving adjacency. Equal degree sequences are necessary, not sufficient. The complement of a simple graph contains exactly the absent non-loop edges.
11.3 Matching and colouring
Past papers · CS 2014–2026 (23 papers): 9 questions, 16 marks
A matching has no shared endpoints. Maximal means no edge can be added; maximum means largest cardinality. A perfect matching covers every vertex. A proper vertex colouring gives adjacent vertices different colours; an edge colouring gives incident edges different colours.
11.4 Counting and inclusion–exclusion
Past papers · CS 2014–2026 (23 papers): 13 questions, 19 marks · DA 2024–2026 (3 papers): 3 questions, 3 marks
Use multiplication for successive choices and addition for disjoint alternatives. For identical objects in identical boxes, enumerate nonincreasing occupancy sequences (integer partitions); stars and bars counts labelled boxes instead. An involution on labelled objects consists of fixed points and disjoint transpositions, so its count is . The elementary permutation and combination formulas are in the probability chapter.
11.5 Recurrences and generating functions
Past papers · CS 2014–2026 (23 papers): 13 questions, 22 marks
Choose the state counted by a sequence before forming its recurrence. Useful finite sums are , , and . Initial values are part of the problem; a characteristic equation alone does not determine the sequence.
Last-minute recall
- Degree sums count each undirected edge twice.
- Connectivity and acyclicity together characterise a tree.
- Euler concerns edges; Hamilton concerns vertices.
- A degree sequence alone does not prove isomorphism.
- Maximal matching can be smaller than maximum matching.
- Hall's condition tests every subset of the chosen bipartition side.
- Labelled colours and unlabelled colour classes give different counts.
- Stars and bars requires identical objects and labelled boxes.
- Inclusion–exclusion fixes overlap, not independence.
- A recurrence needs initial conditions and a clear counted state.