Faster algorithms for finding and counting subgraphs

  • Authors:
  • Fedor V. Fomin;Daniel Lokshtanov;Venkatesh Raman;Saket Saurabh;B.V. Raghavendra Rao

  • Affiliations:
  • Department of Informatics, University of Bergen, Bergen, Norway;Department of Informatics, University of Bergen, Bergen, Norway;The Institute of Mathematical Sciences, Chennai, India;The Institute of Mathematical Sciences, Chennai, India;Department of Computer Science, Universitaet des Saarlandes, Germany

  • Venue:
  • Journal of Computer and System Sciences
  • Year:
  • 2012

Quantified Score

Hi-index 0.00

Visualization

Abstract

In the Subgraph Isomorphism problem we are given two graphs F and G on k and n vertices respectively as an input, and the question is whether there exists a subgraph of G isomorphic to F. We show that if the treewidth of F is at most t, then there is a randomized algorithm for the Subgraph Isomorphism problem running in time O^@?(2^kn^2^t). Our proof is based on a novel construction of an arithmetic circuit of size at most n^O^(^t^) for a new multivariate polynomial, Homomorphism Polynomial, of degree at most k, which in turn is used to solve the Subgraph Isomorphism problem. For the counting version of the Subgraph Isomorphism problem, where the objective is to count the number of distinct subgraphs of G that are isomorphic to F, we give a deterministic algorithm running in time and space O^@?((nk/2)n^2^p) or (nk/2)n^O^(^t^l^o^g^k^). We also give an algorithm running in time O^@?(2^k(nk/2)n^5^p) and taking O^@?(n^p) space. Here p and t denote the pathwidth and the treewidth of F, respectively. Our work improves on the previous results on Subgraph Isomorphism, it also extends and unifies most of the known results on sub-path and sub-tree isomorphisms.