Graph Operations and Modifications
A graph with a certain property can often be built starting from another graph. They may be a subgraph of a larger graph, they can be incrementally modified by deleting or adding elements, or they can be built by combining multiple graphs using Boolean operations. The Wolfram Language provides an extensive collection of functions for producing new graphs from old.
Selecting Subgraphs
Subgraph — extract a subgraph containing vertices, edges, or combinations
NeighborhoodGraph — extract a subgraph up to some distance from a graph element
FindSpanningTree — find a tree that connects all vertices
Conversion of Graphs
UndirectedGraph — convert a directed graph to an undirected graph
DirectedGraph — convert an undirected graph to a directed graph
ReverseGraph ▪ SimpleGraph ▪ IndexGraph
Tagging of Graphs
EdgeTaggedGraph — generate a graph with tagged edges
IndexEdgeTaggedGraph ▪ EdgeTags ▪ EdgeTaggedGraphQ
Modifications of Graphs
VertexReplace — replace vertices using rules
VertexAdd ▪ VertexDelete ▪ VertexContract ▪ EdgeAdd ▪ EdgeDelete ▪ EdgeContract
Operations on Graphs
BooleanGraph — Boolean combination of graphs
LineGraph — give the line graph where edges become vertices and vice versa
GraphPower — graph with all vertices adjacent that are n steps or fewer apart
DualPlanarGraph — dual of a planar graph
GraphIntersection ▪ GraphUnion ▪ GraphDifference ▪ GraphDisjointUnion ▪ GraphComplement ▪ GraphProduct ▪ GraphJoin ▪ GraphSum
Reachability and Relation
TransitiveClosureGraph — give the transitive closure
TransitiveReductionGraph — give the transitive reduction
Control Flow Graphs
DominatorTreeGraph — give the tree of immediate dominators
DominatorVertexList — give immediate dominators for each vertex