(I) We revisit the algorithmic problem of finding all triangles in a graph $G=(V,E)$ with $n$ vertices and $m$ edges. According to a result of Chiba and Nishizeki (1985), this task can be achieved by a combinatorial algorithm running in $O(m α) = O(m^{3/2})$ time, where $α= α(G)$ is the graph arboricity. We provide a new very simple combinatorial algorithm for finding all triangles in a graph and show that is amenable to the same running time analysis. We derive these worst-case bounds from first principles and with very simple proofs that do not rely on classic results due to Nash-Williams from the 1960s. Our experimental results show that our simple algorithm for triangle listing is substantially faster in practice than that of Chiba and Nishizeki on all examples of real-world graphs we tried. (II) We extend our arguments to the problem of finding all small complete subgraphs of a given fixed size. We show that the dependency on $m$ and $α$ in the running time $O(α^{\ell-2} \cdot m)$ of the algorithm of Chiba and Nishizeki for listing all copies of $K_\ell$, where $\ell \geq 3$, is asymptotically tight. (III) We give improved arboricity-sensitive running times for counting and/or detection of copies of $K_\ell$, for small $\ell \geq 4$. A key ingredient in our algorithms is, once again, the algorithm of Chiba and Nishizeki. Our new algorithms are faster than all previous algorithms in certain high-range arboricity intervals for every $\ell \geq 7$.
翻译:(I) 我们重新审视在图$G=(V,E)$(具有$n$个顶点和$m$条边)中寻找所有三角形的算法问题。根据Chiba和Nishizeki(1985)的研究结果,该任务可通过组合算法在$O(m α) = O(m^{3/2})$时间内完成,其中$α= α(G)$为图乔木度。我们提出了一种新的、非常简单的组合算法来寻找图中的所有三角形,并证明其适用于相同的运行时间分析。我们从基本原理推导出这些最坏情况界限,并提供了不依赖于1960年代Nash-Williams经典结果的极简证明。实验结果表明,在我们尝试的所有现实世界图例中,我们提出的简单三角形列举算法在实际运行速度上显著优于Chiba和Nishizeki的算法。(II) 我们将论证扩展到寻找给定固定尺寸的所有小型完全子图问题。对于列举所有$K_\ell$(其中$\ell \geq 3$)副本的算法,我们证明Chiba和Nishizeki算法运行时间$O(α^{\ell-2} \cdot m)$中关于$m$和$α$的依赖关系是渐近紧的。(III) 针对$ℓ ≥ 4$的小型$\ell$值,我们为$K_\ell$副本的计数和/或检测提供了改进的乔木度敏感运行时间。我们算法的关键组成部分再次采用了Chiba和Nishizeki的算法。对于每个$\ell \geq 7$,在特定的高范围乔木度区间内,我们的新算法比以往所有算法都更快速。