Macaulay2 » Documentation
Packages » NautyGraphs :: removeEdges
next | previous | forward | backward | up | index | toc

removeEdges -- creates a list of graphs obtained by removing one edge from the given graph in all possible ways

Synopsis

Description

This method creates a list of all possible graphs obtainable from the given graph by removing one edge. Notice that isomorphic graphs are allowed within the list.

i1 : removeEdges graph {{1,2},{1,3},{2,3},{3,4},{4,5}}

o1 = {Graph{0 => {2}      }, Graph{0 => {1}   }, Graph{0 => {1, 2}}, Graph{0
            1 => {2}               1 => {0, 2}         1 => {0}            1
            2 => {0, 1, 3}         2 => {1, 3}         2 => {0, 3}         2
            3 => {2, 4}            3 => {2, 4}         3 => {2, 4}         3
            4 => {3}               4 => {3}            4 => {3}            4
     ------------------------------------------------------------------------
     => {1, 2}}, Graph{0 => {1, 2}   }}
     => {0, 2}         1 => {0, 2}
     => {1, 0}         2 => {1, 0, 3}
     => {4}            3 => {2}
     => {3}            4 => {}

o1 : List

If the List input format is used, then one should use care as the list may contain isomorphic pairs.

See also

Ways to use removeEdges :

For the programmer

The object removeEdges is a method function with options.