Proofs: Bliss
These are the human proofs of Bliss, at full length.
The certificate search returns a canonical form and the automorphism group order full
This proof shows: correctness, termination.
Setting. is a simple undirected graph on with a vertex coloring . A node of the search is an ordered partition (an array of vertices cut into cells at given start positions) with a certificate , the list of refinement traces from the root to . At a discrete leaf with vertex order , the labeling is and the key is followed by the colors of and the adjacency rows of relabeled by . Keys are compared as sequences (lexicographically). The full tree contains every child , refined, for every in the target cell, the first largest cell. A permutation of acts on everything by renaming vertices.
Lemma 1 (invariance). For every permutation , the refinement of in is the image under of the refinement of in , as a sequence of cells, with the same trace; individualization of in is the image of individualization of in ; the target cell has the same start; and leaves and have the same key.
Proof. Every decision of REFINE depends on cell starts, cell sizes, and the numbers of neighbors in the splitter: the queue holds starts, the touched cells are processed by start, pieces are ordered by neighbor count, and the piece left out of the queue is the first largest one. These quantities do not change under renaming, and the trace records only them. The order of vertices inside a cell may change, but no later decision and no trace entry depends on it. The target cell rule uses only sizes and starts. A leaf of lists , whose colors and adjacencies in are those of in .
So maps onto and preserves certificates and keys; and an automorphism that fixes a node maps the subtrees of its children onto each other with equal keys.
Lemma 2 (equal keys give automorphisms). If leaves have equal keys, then , which maps the vertex at each position of to the vertex at the same position of , is an automorphism. This is the map recorded in L7.
Proof. The keys end with the same colors and relabeled rows, so keeps colors and adjacency.
Lemma 3 (the cut in L4 is safe). If a node with certificate has worse than the best key , that is, at the first index where they differ is smaller, then every leaf below has a key smaller than .
Proof. Every leaf key below starts with , so it differs from at the same index, with the same comparison.
Lemma 4 (the orbit cut in L10 is safe). Skipping a child that is in the orbit of a tried child under found automorphisms fixing the prefix loses no key.
Proof. Such automorphisms fix the node, by Lemma 1, so they map the subtree of the tried child onto the subtree of the skipped child with the same keys.
Theorem. The search terminates and returns the leaf of largest key in . Its form is the same for isomorphic colored graphs and different for non-isomorphic ones, and L12 returns .
Proof. Termination. Individualization adds a cell and refinement never merges cells, so the depth is at most and every node has at most children. REFINE stops: each queue entry is processed once, and only a split, at most of them, adds entries.
Maximum. By Lemmas 3 and 4, every cut subtree holds only keys smaller than the current best or keys already present in an explored subtree. By induction, the best key at the end is the largest key of .
Canonical form. By Lemma 1, has the same keys as , so the largest keys and their final parts are equal. Conversely, the final part is the colored graph relabeled by a bijection, so equal final parts imply isomorphic graphs.
Group order. Let be the first path, the prefix and the first child of , and the automorphisms fixing pointwise. As in the proof for nauty, , and it suffices that every explored child of in the -orbit of yields a recorded automorphism in mapping to . Some maps the subtree of onto that of , so the subtree of contains a leaf with the key of the first leaf, and every node on the way has a certificate equal to a prefix of the first key. L4 never cuts such nodes, because of the condition prefix of the first key, and L10 only replaces a subtree by an image under an automorphism fixing the prefix, which contains another leaf with that key. So the search reaches a leaf below with the key of the first leaf, and L7 records with mapping positions of to positions of . Cells are split in place, so a vertex that is a singleton of , and the vertex individualized from the target cell of , have the same positions in all leaves below . Hence fixes and maps to .