Abstract
We propose a simple and efficient local algorithm for graph isomorphism which succeeds for a large class of sparse graphs. This algorithm produces a low-depth canonical labeling, which is a labeling of the vertices of the graph that identifies its isomorphism class using vertices' local neighborhoods. Prior work by Czajka and Pandurangan showed that the degree profile of a vertex (i.e., the sorted list of the degrees of its neighbors) gives a canonical labeling with high probability when $n p_n = \omega( \log^{4}(n) / \log \log n )$ (and $p_{n} \leq 1/2$); subsequently, Mossel and Ross showed that the same holds when $n p_n = \omega( \log^{2}(n) )$. We first show that their analysis essentially cannot be improved: we prove that when $n p_n = o( \log^{2}(n) / (\log \log n)^{3} )$, with high probability there exist distinct vertices with isomorphic $2$-neighborhoods. Our first main result is a positive counterpart to this, showing that $3$-neighborhoods give a canonical labeling when $n p_n \geq (1+\delta) \log n$ (and $p_n \leq 1/2$); this improves a recent result of Ding, Ma, Wu, and Xu, completing the picture above the connectivity threshold. Our second main result is a smoothed analysis of graph isomorphism, showing that for a large class of deterministic graphs, a small random perturbation ensures that $3$-neighborhoods give a canonical labeling with high probability. While the worst-case complexity of graph isomorphism is still unknown, this shows that graph isomorphism has polynomial smoothed complexity.
Introduction
The Graph Isomorphism (GI) problem—determining if two graphs are structurally identical—occupies a unique "NP-intermediate" status in computer science. While generally solvable for most graphs, sparse graphs present a significant challenge because many vertices appear identical when viewed through a local lens. Previous research suggested that a 2-neighborhood (looking two steps out) might suffice for identification, but this work demonstrates that for very sparse graphs, 2-neighborhoods are mathematically insufficient. The authors identify the "3-neighborhood" as the critical threshold for unique identification in sparse regimes, providing a robust local labeling strategy.
Methods
The core of the proposal is a local canonical labeling algorithm that assigns unique signatures to vertices based on their local topology. The process involves several key steps:
- Modulo Binning: Vertices are initially partitioned into "bins" based on their degree modulo a constant $m$. This acts as a "pseudo-random" coloring of the graph without requiring external randomness.
- Signature Generation: For each vertex $v$, the algorithm examines its neighbors. For each neighbor, it records how many vertices of each "color" (bin) that neighbor is connected to.
- 3-Neighborhood Depth: By aggregating these neighbor color counts, the algorithm captures structural information up to three steps away. This "signature" acts as a unique fingerprint for the vertex.
The algorithm's efficiency is a major highlight, running in $O((n + |E|)\log n)$ time, which is nearly linear relative to the graph size. Furthermore, the authors employ "smoothed analysis," demonstrating that even adversarial "worst-case" graphs become solvable with high probability after a small random perturbation (adding or flipping a few edges).
Results
The study utilizes mathematical models including Erdős-Rényi graphs ($G(n, p)$) and perturbed deterministic graphs to establish theoretical bounds. Key findings include:
- Uniqueness at Depth 3: The 3-neighborhood algorithm provides a unique canonical labeling for random graphs above the connectivity threshold ($np_n \geq (1 + \delta)\log n$).
- Insufficiency of Depth 2: A lower bound proof shows that 2-neighborhoods fail to distinguish vertices in sparse regimes where $np_n = o(\log^2 n)$.
- Smoothed Complexity: The paper establishes that GI has polynomial smoothed complexity, meaning it is robustly easy to solve even under slight perturbations of difficult instances.
Conclusion
This work completes the theoretical picture for local graph isomorphism above the connectivity threshold. While 3-neighborhoods are powerful, they may fail below the connectivity threshold where isolated vertices or small components exist; in such cases, deeper neighborhoods ($r > 3$) might be necessary. Future research may extend these local labeling techniques to the more challenging problem of graph matching in noisy environments.
Summary updated