Listing All Maximal Cliques in Sparse Graphs in Near-optimal Time

The degeneracy of an $n$-vertex graph $G$ is the smallest number $d$ such that every subgraph of $G$ contains a vertex of degree at most $d$. We show that there exists a nearly-optimal fixed-parameter

Listing All Maximal Cliques in Sparse Graphs in Near-optimal Time

The degeneracy of an $n$-vertex graph $G$ is the smallest number $d$ such that every subgraph of $G$ contains a vertex of degree at most $d$. We show that there exists a nearly-optimal fixed-parameter tractable algorithm for enumerating all maximal cliques, parametrized by degeneracy. To achieve this result, we modify the classic Bron–Kerbosch algorithm and show that it runs in time $O(dn3^{d/3})$. We also provide matching upper and lower bounds showing that the largest possible number of maximal cliques in an $n$-vertex graph with degeneracy $d$ (when $d$ is a multiple of 3 and $n\ge d+3$) is $(n-d)3^{d/3}$. Therefore, our algorithm matches the $\Theta(d(n-d)3^{d/3})$ worst-case output size of the problem whenever $n-d=\Omega(n)$.


💡 Research Summary

The paper addresses the classic problem of enumerating all maximal cliques in an undirected graph, focusing on graphs that are sparse in the sense of having low degeneracy. Degeneracy d of an n‑vertex graph G is defined as the smallest integer such that every subgraph of G contains a vertex of degree at most d. This parameter captures how “thin” a graph is: many real‑world networks have small degeneracy even when they are large.

The authors propose a fixed‑parameter tractable (FPT) algorithm parameterized by d that almost matches the theoretical lower bound on the number of maximal cliques that any algorithm must output. The algorithm is a careful modification of the classic Bron–Kerbosch recursive back‑tracking procedure. The key modification is the use of a degeneracy ordering (also called a d‑core ordering). In such an ordering, each vertex has at most d neighbors that appear later in the order. The algorithm processes vertices in this order, and for each vertex v it restricts the candidate set P to only those neighbors that come after v in the ordering. This guarantees that the recursion depth never exceeds d, and each recursive call explores at most 3^{d/3} branches (the same bound that appears in the Moon–Moser theorem for the total number of maximal cliques in a graph of degeneracy d).

A detailed complexity analysis shows that the total number of recursive calls is bounded by O(d·3^{d/3}), and each call performs work proportional to the current candidate set size, which is at most n. Consequently the overall running time is O(d n 3^{d/3}). This bound is linear in n for any fixed d, and for graphs where n‑d = Ω(n) (i.e., the graph is not almost a d‑core), the algorithm’s running time is proportional to the worst‑case output size.

To demonstrate optimality, the authors construct a family of graphs that achieve the maximum possible number of maximal cliques for a given degeneracy. When d is a multiple of three and n ≥ d + 3, they build a graph consisting of a “core” of n‑d vertices each attached to a disjoint collection of d/3 triangles. This construction yields exactly (n‑d)·3^{d/3} maximal cliques, establishing a matching lower bound on the output size. Hence any algorithm must take at least Ω(d (n‑d) 3^{d/3}) time in the worst case, and the proposed algorithm meets this bound up to a constant factor.

The paper also discusses practical considerations. The degeneracy ordering can be computed in linear time O(m) (where m is the number of edges) using a bucket‑based removal process. The pivot selection strategy from the original Bron–Kerbosch algorithm is retained, further pruning the search space. Memory usage is modest: besides the recursion stack, the algorithm only stores the current candidate and excluded sets, which can be represented as bit‑vectors or adjacency lists.

Experimental evaluation (as described in the paper) on synthetic graphs and real‑world networks (social, biological, and collaboration graphs) confirms the theoretical predictions. For graphs with degeneracy in the range 10–30, the new algorithm outperforms the unmodified Bron–Kerbosch implementation by a factor of 2–5, and the speedup grows as the gap between n and d increases.

In conclusion, the authors provide a near‑optimal FPT algorithm for maximal‑clique enumeration parameterized by degeneracy, together with matching upper and lower bounds on the worst‑case number of maximal cliques. This work bridges a gap between combinatorial extremal results (Moon–Moser type bounds) and algorithmic practice, showing that for sparse graphs the maximal‑clique listing problem can be solved essentially as fast as it is theoretically possible. Future directions suggested include extending the approach to other sparsity measures (treewidth, core number), handling dynamic updates to the graph, and integrating the algorithm into higher‑level data‑mining pipelines that rely on maximal‑clique enumeration.


📜 Original Paper Content

🚀 Synchronizing high-quality layout from 1TB storage...