Graphs can have arbitrary labels, but their topology may be isomorphic. In the world of data analysis, we can examine different graphical networks and identify clusters of nodes that have identical connection patterns. This helps us discover when two seemingly different graphical networks end up with the same network mapping. Maybe then we can declare a one-to-one isomorphism between the nodes and learn something profound about the nature of the graphs.
We will use the isIsomorphic
function from Data.Graph.Automorphism
to detect whether two graphs are identical in their connection.
In this recipe, we will let the library calculate whether the two graphs in the following diagram are isomorphic in their connections: