next
|
previous
|
forward
|
backward
| up |
top
|
index
|
toc
|
Macaulay2 web site
Graphs
(missing documentation) ::
isLeaf
isLeaf -- determines whether a vertex is a leaf
Synopsis
Usage:
l = isLeaf(G,v)
Inputs:
G
,
an object of class
Graph
(missing documentation)
v
,
a
thing
Outputs:
l
,
a
Boolean value
, whether vertex v of graph G is a leaf
Description
A vertex of a tree graph is a leaf if its degree is 1
i1 : G = graph({{1,2},{1,3},{3,4},{3,5}},EntryMode=>"edges");
i2 : isLeaf(G,2) o2 = true
See also
isForest
-- determines whether a graph is a forest
isTree
-- determines whether a graph is a tree
leaves
-- lists the leaves of a tree graph
Ways to use
isLeaf
:
isLeaf(Graph,Thing)