简体   繁体   English

寻找相等的子图

[英]Finding equal subgraphs

Given: 鉴于:

  • a directed Graph 有向图
  • Nodes have labels 节点有标签
  • the same label can appear more than once 同一标签可以出现多次
  • edges don't have labels 边缘没有标签

I want to find the set of largest (connected) subgraphs which are equal taking the labels of the nodes into account. 我想找到最大(连接的)子图的集合,这些子图考虑节点的标签是相等的。

The graph could be huge (millions of nodes) does anyone know an efficient solution for this? 该图可能很大(数以百万计的节点),有谁知道有效的解决方案?

I'm looking for algorithm and ideally a Java implementation. 我正在寻找算法,最好是Java实现。

Update: Since this problem is most likely NP-complete. 更新:由于此问题很可能是NP完全的。 I would also be interested in an algorithm that produces an approximated solution. 我也会对产生近似解的算法感兴趣。

This seems to be close at least: Frequent Subgraphs 这似乎至少接近: 频繁的子图

I strongly suspect that's NP-hard. 我强烈怀疑这是NP问题。

Even if all the labels are the same that's at least as hard as graph isomorphism. 即使所有标签都相同,也至少与图同构一样硬。 (Join the two graphs together as a single disconnected graph; are the largest equal subgraphs the two original graphs?) (将两个图作为一个断开的图连接在一起;两个原始图的最大相等子图是吗?)

If identical labels are relatively rare it might be tractable. 如果相同的标签相对少见,则可能很容易处理。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM