Colour refinement 2026-11-05
Colour refinement repeatedly separates vertices of a graph according to the colours of their neighbours. Its colours are labels for classes of vertices with the same currently visible structure; they are not a proper vertex colouring requiring adjacent vertices to differ. In individualization-refinement graph search, colour refinement reduces ambiguity before the algorithm branches.[ref]
Practical graph isomorphism, II by Brendan D. McKay and Adolfo Piperno. Section3.1, equitable refinement and Algorithm1
Let be a vertex's colour after round . One conceptual update assigns a common new colour exactly when both the previous colour and neighbour-colour multiset agree:The encoding must give distinct labels to distinct signatures. Retaining prevents old classes from merging. When no class splits, the resulting partition of a set is an equitable partition: vertices in the same cell have equal numbers of neighbours in every cell.
For an original example, start all vertices of the six-vertex path graph with the same colour. The first round separates endpoints from internal vertices . The next separates , which each have an endpoint neighbour, from , which do not. The three cellsare then stable. Reflection of the path exchanges the two vertices in each cell, so the remaining pairs are compatible with a genuine graph automorphism.
Colour refinement is invariant under vertex relabeling. To compare two graphs, colour signatures must be encoded consistently across both, for example by refining their disjoint union of graphs with shared initial colour meanings. A different count of vertices in a resulting colour class certifies graph non-isomorphism.
Agreement is weaker than isomorphism. Starting with one colour, both the complete bipartite graph and the triangular prism graph remain one six-vertex cell because every vertex has three neighbours. Yet the prism has triangles and has none. This failure motivates individualizing vertices and searching further; stable colour classes are not, in general, proof that all their vertices are related by graph automorphisms.
Equitable partition 2026-11-05
An equitable partition of a finite graph groups vertices so that any two vertices in one cell have the same number of neighbours in each cell. For a simple graph with cells , this means that numbersdo not depend on which in is selected. Here denotes the set of neighbours of . These counts form the equitable quotient matrix . An equitable partition need not be a proper vertex colouring and need not have cells of equal sizes.[ref]
Practical graph isomorphism, II by Brendan D. McKay and Adolfo Piperno. Section3.1 and footnote1, equitable-partition terminology
An original five-vertex path graph has an equitable partitionEach endpoint has one neighbour in ; each member of has one neighbour in and one in ; the middle vertex has two neighbours in . Although the graph is undirected, is not symmetric matrix, because its entries count neighbours per vertex rather than total edges between cells. Counting those edges from both ends gives .
The counts also compress an exact part of the adjacency matrix. Let be that matrix and let have one column per cell, with for and zero otherwise. ThenIndeed, counts neighbours of in , which is exactly . Hence implies . Since nonempty disjoint cells make the columns of linearly independent, gives : every eigenvalue of is an eigenvalue of . For the displayed example, these include and .
An equitable partition preserves neighbour counts, not all adjacency information. The disjoint union of graphs of a triangle and a four-vertex cycle has an equitable one-cell partition, since every vertex has two neighbours. Nevertheless, no graph automorphism can send a triangle vertex to a four-cycle vertex: their connected components of a graph are not isomorphic. This distinguishes equitable cells from symmetry orbits and explains why colour refinement may leave ambiguity.
Graph non-isomorphism 2026-11-05
Two graphs exhibit graph non-isomorphism when no bijection of their vertex sets preserves and reflects adjacency. For finite simple graphs and , this means there is no bijection satisfyingfor every pair of distinct vertices. Changing vertex names or drawing positions cannot establish non-isomorphism; the adjacency structure must differ.
A graph invariant is a property preserved by graph isomorphism. Different numbers of vertices, edges or connected components of a graph immediately prove non-isomorphism. Equal values of one invariant need not prove isomorphism.
For an original example, let be the six-vertex cycle graph with edges , and let be the disjoint union of graphs consisting of triangles and . Both have six vertices, six edges and degree sequence . Nevertheless, is a connected graph, whereas has two connected components. Any adjacency-preserving bijection transports a path to a path, so it would have to preserve connectedness. No such bijection exists. The common degree sequence is therefore an incomplete isomorphism test.
Finite exhaustive checking provides a direct decision procedure: if the vertex counts agree at , examine each of the possible bijections and test adjacency. If every bijection fails, the graphs are non-isomorphic. More efficient procedures can avoid enumerating all bijections; this simple procedure explains the logical criterion, rather than a practical performance bound.
Software tests also require a decision about what belongs to the structure. NetworkX's
is_isomorphic ignores node and edge attributes by default; matching functions can require them to agree.[ref]is_isomorphic documentation by NetworkX. node_match, edge_match and Examples
Two differently colored copies of the same uncolored graph can thus be isomorphic as simple graphs but non-isomorphic under a color-preserving requirement. The intended graph category must be specified before interpreting a negative result. Join (graph theory) 2026-10-14
The join is obtained from the disjoint union of graphs by adding every edge between a vertex of and a vertex of .
Past exam of the mathematics course of the University of Cambridge 2010 iii Paper 12 4 ii Solution Created 2026-10-03 Updated 2026-10-14
Write , an integer under the stated divisibility assumption. The degree relation gives . Take the disjoint union of graphs of copies of the complete bipartite graph , placing its -vertex part in and its -vertex part in . The total part sizes are then and . Each left vertex has vertex degree , and each right vertex has vertex degree , so the graph has exactly the required biregular graph parameters.
An independent set in one component can be any subset of its left part or any subset of its right part. It cannot contain a vertex from both parts, because all cross-pairs are edges. The two families share only the empty set, so the component has independent sets. Choices in different connected components of a graph are independent combinatorial choices, and their counts multiply. HenceThis attains equality in part (i). It also explains the entropy weight there: the empty selected left neighbourhood permits all subsets of the opposite part.
Past exam of the mathematics course of the University of Cambridge 2024 iii Paper 134 1 b Solution Created 2026-09-24 Updated 2026-10-03
If is a nontrivial disjoint union of graphs, no defining relation mixes the two vertex sets, and henceOn the topological side, every clique lies in one component, soa one-point union of Salvetti complexes.