Function find_isomorphism

Source
pub fn find_isomorphism<N1, N2, E, Ix>(
    graph1: &Graph<N1, E, Ix>,
    graph2: &Graph<N2, E, Ix>,
) -> Option<HashMap<N1, N2>>
where N1: Node + Clone + Hash + Eq, N2: Node + Clone + Hash + Eq, E: EdgeWeight, Ix: IndexType,
Expand description

Find an isomorphism between two graphs if one exists

§Arguments

  • graph1 - The first graph
  • graph2 - The second graph

§Returns

  • Option<HashMap<N1, N2>> - Mapping from graph1 nodes to graph2 nodes if isomorphic