Macaulay2 » Documentation
Packages » EdgeIdeals :: isEdge
next | previous | forward | backward | up | index | toc

isEdge -- determines if an edge is in a (hyper)graph

Synopsis

Description

This function checks if a given edge, represented either as a list or monomial, belongs to a given (hyper)graph.

i1 : S = QQ[z_1..z_8];
i2 : h = hyperGraph {z_2*z_3*z_4,z_6*z_8,z_7*z_5,z_1*z_6*z_7,z_2*z_4*z_8};
i3 : edges h

o3 = {{z , z , z }, {z , z }, {z , z , z }, {z , z , z }, {z , z }}
        2   3   4     5   7     1   6   7     2   4   8     6   8

o3 : List
i4 : isEdge (h,{z_2,z_4,z_8})

o4 = true
i5 : isEdge (h,z_2*z_3*z_4)

o5 = true
i6 : isEdge (h,{z_1,z_2})

o6 = false

See also

Ways to use isEdge :

For the programmer

The object isEdge is a method function.