Abstract
Algorithms for listing the subgraphs satisfying a given property (e.g., being a clique, a cut, a cycle, etc.) fall within the general framework of set systems. A set system (U, F) uses a ground set U (e.g., the network nodes) and an indicator F, subset of 2^U, of which subsets of U have the required property. For the problem of listing all sets in F maximal under inclusion, the ambitious goal is to cover a large class of set systems, preserving at the same time the efficiency of the enumeration. Among the existing algorithms, the best-known ones list the maximal subsets in time proportional to their number but may require exponential space. In this paper we improve the state of the art in two directions by introducing an algorithmic framework that, under standard suitable conditions, simultaneously (i) extends the class of problems that can be solved efficiently to strongly accessible set systems, and (ii) reduces the additional space usage from exponential in |U| to stateless, thus accounting for just O(q) space, where q <= |U| is the largest size of a maximal set in F.
The Problem: Beyond Hereditary Properties
In network analysis, bioinformatics, and graph databases, researchers frequently need to find all subgraphs that satisfy a specific property (e.g., finding all cliques, paths, or matching motifs). To avoid drowning in redundant data, algorithms typically only look for maximal solutions—subgraphs that cannot be expanded any further without breaking the required property.
Computer scientists model these problems using "set systems." For simple properties, like "hereditary" properties (where if a subgraph is valid, all its sub-parts are also valid), efficient algorithms exist. However, for trickier properties—like "connected hereditary" properties (e.g., finding the maximal common connected subgraphs between two different graphs)—existing algorithms hit a wall. To avoid outputting the same maximal subgraph twice, current frameworks have to keep every single previously found solution in active memory. Because the number of maximal solutions can be exponential, this memory requirement easily crashes real-world systems.
The authors set out to create an algorithm that is both fast (output-sensitive) and uses minimal memory for these complex graph properties, specifically targeting "strongly accessible" set systems.
Methods: Stateless Reverse Search
The authors build upon Reverse Search, a classic enumeration technique by Avis and Fukuda. Reverse search avoids storing visited solutions by defining a strict "parent-child" relationship among all valid solutions, effectively organizing them into a virtual tree that can be traversed without keeping a history.
However, standard reverse search relies on lexicographical (alphabetical) ordering to define these parent-child relationships. The authors prove that for complex set systems, calculating this lexicographical order is actually NP-hard. To bypass this, they introduce several novel techniques:
- Dynamic Canonical Ordering: Instead of standard sorting, they design a
COMPLETEroutine paired with a black-boxCHOOSEfunction. This dynamically builds a "canonical order" of elements based on the actual topology of the solution, which can be computed in polynomial time. - Layering for Commutable Systems: For "commutable" set systems (which includes connected hereditary graphs), they refine the
CHOOSEfunction by grouping elements into "layers." This allows the algorithm to efficiently generate child solutions by solving a smaller, localized "restricted problem." - Stateless Execution: Most recursive algorithms use a memory stack that grows with the depth of the search tree. The authors designed their algorithm to be completely stateless. By cleverly re-computing state variables on the fly using only information about the current child node, they simulate the recursion tree without an explicit stack.
Key Insights and Ideas
- Lexicographical ordering is a trap: The authors formally proved that trying to find the lexicographically smallest maximal solution containing a subset is NP-hard for certain graphs (like BC-cliques). This insight explains exactly why previous attempts to apply reverse search to these problems failed.
- Let the topology dictate the order: By letting the algorithm dictate the order of elements dynamically (via the
CHOOSEfunction) rather than forcing a static alphabetical order, the authors successfully bypassed the NP-hard bottleneck. - Statelessness is possible for complex graphs: You don't need to remember the past if you can perfectly deduce your parent and children. Simulating the recursion tree without a stack drastically cuts memory usage, proving that you can "dump" outputs as you find them without fear of duplication.
- Closing a decade-old gap: They successfully linked the time-delay of the general problem to the easier "restricted problem" for connected hereditary graphs without the exponential space penalty, solving an open problem posed by Cohen et al. in 2008.
Key Results
- Massive Memory Reduction: The framework reduces the space complexity for connected hereditary set systems from exponential ($exp(|U|)$) to strictly polynomial. The stateless version reduces this even further to just $O(q)$ additional space, where $q$ is the maximum size of a solution.
- Near-Optimal Time Complexity: For strongly accessible set systems, the framework runs in $O(\alpha 2^q)$ time (where $\alpha$ is the number of maximal solutions). The authors prove this is remarkably close to the theoretical lower bound of $\Omega(\alpha 2^{q/2})$ under the Strong Exponential Time Hypothesis (SETH).
- Case Study Success: They achieved a bounded delay of $O(q^5|U|^2)$ and $O(q)$ space for listing maximal BC-cliques, which directly translates to finding Maximal Common Connected Induced Subgraphs (MCCIS) between two graphs.
Conclusion and Future Work
The framework's efficiency relies heavily on the mathematical properties of "strongly accessible" and "commutable" set systems. If a specific graph property does not fit these strict definitions, this specific reverse search framework cannot be directly applied. Future work involves implementing this framework for practical problems in bioinformatics and database querying, and potentially adapting it to an even broader context of problems that do not rely on strong accessibility.
Summary updated