FindSubgraphIsomorphism
FindSubgraphIsomorphism[g1,g2]
finds a subgraph isomorphism that maps the graph g1 to a subgraph of g2 by renaming vertices.
FindSubgraphIsomorphism[g1,g2,n]
finds at most n subgraph isomorphisms.
Details

- FindSubgraphIsomorphism is also known as subgraph matching.
- FindSubgraphIsomorphism is typically used to find similarities and substructures in graphs.
- FindSubgraphIsomorphism[g1,g2] gives a list of associations Association[v1->w1,v2->w2,…] where vi are vertices in g1 and wi are vertices in g2.
- FindSubgraphIsomorphism gives an empty list if no isomorphism can be found.
- FindSubgraphIsomorphism[g1,g2,All] gives all the subgraph isomorphisms.

Examples
open allclose allBasic Examples (2)
Scope (7)
Specification (4)
FindSubgraphIsomorphism works with undirected graphs:
Applications (1)
Properties & Relations (2)
Test whether a graph and a subgraph are isomorphic using IsomorphicSubgraphQ:
Use FindIsomorphicSubgraph to find a subgraph that is isomorphic to a graph:
Text
Wolfram Research (2021), FindSubgraphIsomorphism, Wolfram Language function, https://reference.wolfram.com/language/ref/FindSubgraphIsomorphism.html.
CMS
Wolfram Language. 2021. "FindSubgraphIsomorphism." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/FindSubgraphIsomorphism.html.
APA
Wolfram Language. (2021). FindSubgraphIsomorphism. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/FindSubgraphIsomorphism.html