Search code examples
algorithmgraphfuzzysubgraph

Fuzzy graph matching


I have a fuzzy graph G=(V, E) where V is the set of vertices and E is the set of edges. Every vertex is a fuzzy vertex, that means, it has a property with a membership function associated to it (stored in the vertex somehow). Every edge is a fuzzy edge, that means, it has a property with a membership function associated to it (stored in the edge somehow). By doing this, G is a fuzzy graph in terms of edges and vertices.

Given G and G2, another fuzzy graph with different (or equal) number of edges and/or vertices, I need to compare both graphs in a fuzzy way. I want to check if G2 is a subgraph or G (or vice versa). Is there any algorithm to address this?


Solution

  • First, to compare two graphs you should solve the Subgraph isomorphism problem, it could be polynomial or not.

    But you have not graphs, you have fuzzy graphs. I don't know if explicit algorithm exists but I would try two approaches:

    1. If you can define membership as a probability, you can first find "the maximum similarity" assuming usual graphs (P{is member}=1) and then, try to find some relation using Bayesian networks (if acyclic) or in a more general way using Markov random fields.

    2. You can define a metric between fuzzy graphs using Monte Carlo methods. As an example simply walk the two graphs and stop when one step produce some difference. The number of steps is a metric. Run n times and get the max, avg, ... The final algorithm depends strongly if your membership function have state, you know "the maximum similarity" and so...

    The former approach should be fast and reliable but you have nothing if you can't find the adequate equations. The latter approach, looks more feasible but much less efficient.

    Anyway, the usability of the defined metric is subjetive (if you don't explain the requirements, any metric could be valid).