Finding Four-Node Subgraphs in Triangle Time

We present new algorithms for finding induced four-node subgraphs in a given graph, which run in time roughly that of detecting a clique on three nodes (i.e., a triangle). • The best known algorithms for triangle finding in an n-node graph take O(nω) time, where ω < 2.373 is the matrix multiplication exponent. We give a general randomized technique for finding any induced four-node subgraph, except for the clique or independent set on 4 nodes, in O(nω) time with high probability. The algorithm can be derandomized in some cases: we show how to detect a diamond (or its complement) in deterministic O(nω) time. Our approach substantially improves on prior work. For instance, the previous best algorithm for C4 detection ran in O(n3.3) time, and for diamond detection in O(n3) time. • For sparse graphs with m edges, the best known triangle finding algorithm runs in O(m2ω/(ω+1)) ≤ O(m1.41) time. We give a randomized O(m2ω/(ω+1)) time algorithm (analogous to the best known for triangle finding) for finding any induced four-node subgraph other than C4, K4 and their complements. In the case of diamond detection, we also design a deterministic O(m2ω/(ω+1)) time algorithm. For C4 or its complement, we give randomized O(m(4ω−1)/(2ω+1)) ≤ O(m1.48) time finding algorithms. These algorithms substantially improve on prior work. For instance, the best algorithm for diamond detection ran in O(m1.5) time.

[1]  Raphael Yuster,et al.  Detecting short directed cycles using rectangular matrix multiplication and dynamic programming , 2004, SODA '04.

[2]  A. O. Houcine On hyperbolic groups , 2006 .

[3]  David Coudert,et al.  On the recognition of $C_4$-free and $1/2$-hyperbolic graphs , 2014 .

[4]  Feodor F. Dragan,et al.  A Note on Distance Approximating Trees in Graphs , 2000, Eur. J. Comb..

[5]  Svatopluk Poljak,et al.  On the complexity of the subgraph problem , 1985 .

[6]  Richard J. Lipton,et al.  A Probabilistic Remark on Algebraic Program Testing , 1978, Inf. Process. Lett..

[7]  Friedrich Eisenbrand,et al.  On the complexity of fixed parameter clique and dominating set , 2004, Theor. Comput. Sci..

[8]  David Coudert,et al.  Recognition of C4-Free and 1/2-Hyperbolic Graphs , 2014, SIAM J. Discret. Math..

[9]  Andrzej Lingas,et al.  Counting and Detecting Small Subgraphs via Equations , 2013, SIAM J. Discret. Math..

[10]  Noga Alon,et al.  Finding and counting given length cycles , 1997, Algorithmica.

[11]  Andrzej Lingas,et al.  Detecting and Counting Small Pattern Graphs , 2013, ISAAC.

[12]  Richard Zippel,et al.  Probabilistic algorithms for sparse polynomials , 1979, EUROSAM.

[13]  Stephan Olariu,et al.  Paw-Fee Graphs , 1988, Inf. Process. Lett..

[14]  Andrzej Lingas,et al.  Induced subgraph isomorphism: Are some patterns substantially easier than others? , 2012, Theor. Comput. Sci..

[15]  François Le Gall,et al.  Faster Algorithms for Rectangular Matrix Multiplication , 2012, 2012 IEEE 53rd Annual Symposium on Foundations of Computer Science.

[16]  Lorna Stewart,et al.  A Linear Recognition Algorithm for Cographs , 1985, SIAM J. Comput..

[17]  François Le Gall,et al.  Powers of tensors and fast matrix multiplication , 2014, ISSAC.

[18]  Andrzej Lingas,et al.  Induced Subgraph Isomorphism: Are Some Patterns Substantially Easier Than Others? , 2012, COCOON.

[19]  Dieter Kratsch,et al.  Finding and Counting Small Induced Subgraphs Efficiently , 1995, WG.

[20]  Virginia Vassilevska Williams,et al.  Multiplying matrices faster than coppersmith-winograd , 2012, STOC '12.

[21]  Marián Boguñá,et al.  Sustaining the Internet with Hyperbolic Mapping , 2010, Nature communications.

[22]  Alon Itai,et al.  Finding a minimum circuit in a graph , 1977, STOC '77.

[23]  Jacob T. Schwartz,et al.  Fast Probabilistic Algorithms for Verification of Polynomial Identities , 1980, J. ACM.