For a pattern graph H on k nodes, we consider the problems of finding and counting the number of (not necessarily induced) copies of H in a given large graph G on n nodes, as well as finding minimum weight copies in both node-weighted and edge-weighted graphs. Our results include: • The number of copies of an H with an independent set of size s can be computed exactly in O * (2 s n k−s+3 ) time. A minimum weight copy of such an H (with arbitrary real weights on nodes and edges) can be found in O(4 s+o(s) n k−s+3 ) time. (The O * notation omits poly(k) factors.) These algorithms rely on fast algorithms for computing the permanent of a k × n matrix, over rings and semirings. • The number of copies of any H having minimum (or maximum) node-weight (with arbitrary real weights on nodes) can be found in O(n ωk/3 + n 2k/3+o(1) ) time, where ω < 2.4 is the matrix multiplication exponent and k is divisible by 3. Similar results hold for other values of k. Also, the number of copies having exactly a prescribed weight can be found within this time. These algorithms extend the technique of Czumaj and Lingas (SODA 2007) and give a new (algorithmic) application of multiparty communication complexity. • Finding an edge-weighted triangle of weight exactly 0 in general graphs requires Ω(n 2.5−ε ) time for all ε > 0, unless the 3SUM problem on N numbers can be solved in O(N 2−ε ) time. This suggests that the edge-weighted problem is much harder than its node-weighted version.
Vassilevska and Williams REF studied the problem of finding and counting individual non-induced subgraphs.
Finding, minimizing, and counting weighted subgraphs
STOC '09
Mathematics Computer Science