-- -*- M2-comint -*- hash: 7396302359196731251

i1 : S = QQ[a..e];

i2 : g = graph {a*b,b*c,c*d,d*e,a*e} -- the 5-cycle (connected)

o2 = Graph{"edges" => {{a, b}, {b, c}, {c, d}, {a, e}, {d, e}}}
           "ring" => S
           "vertices" => {a, b, c, d, e}

o2 : Graph

i3 : h = graph {a*b,b*c,c*a,d*e} -- a 3-cycle and a disjoint edge (not connected)

o3 = Graph{"edges" => {{a, b}, {a, c}, {b, c}, {d, e}}}
           "ring" => S
           "vertices" => {a, b, c, d, e}

o3 : Graph

i4 : numConnectedComponents g

o4 = 1

i5 : numConnectedComponents h

o5 = 2

i6 : S = QQ[a..d];

i7 : H = hyperGraph {a*b,c}

o7 = HyperGraph{"edges" => {{a, b}, {c}}  }
                "ring" => S
                "vertices" => {a, b, c, d}

o7 : HyperGraph

i8 : isolatedVertices H

o8 = {d}

o8 : List

i9 : connectedComponents H

o9 = {{a, b}, {c}}

o9 : List

i10 : numConnectedComponents H

o10 = 2

i11 : 
