Action:

Determines whether or not a given vertex is a cycle vertex.


Filename:

kern/kern_scm/graph_scm.cxx


Syntax:

(graph:cyclevertex? ingraph invertex)


Arg Types:

ingraph

graph


invertex

string  entity


Returns:

boolean


Description:

A cycle is defined as a connected group of vertices whose individual removal from the graph results in a linear graph and the same number of components. In other words, none of the vertices of the cycle are cut vertices and none have edges to more than one vertex.



ingraph specifies a graph.



invertex could be the designated name string within the graph or the model entity associated with the graph vertex.


Example:

; graph:cyclevertex?


; Create a simple example


(define g1 (graph "meyou youus usthem



themthey methey



FIDOSPOT SPOTKING SPOTPETEY"))


;; g1


; CAREFUL: The order of the graph output may


; not be the same each time.


(graph:cycle? g1)


;; #f


(define g2 (graph:component g1 "FIDO"))


;; g2


(graph:cycle? g2)


;; #f


(define g3 (graph:component g1 "me"))


;; g3


(graph:cycle? g3)


;; #t


(graph:cyclevertex? g1 "FIDO")


;; #f


(graph:cyclevertex? g1 "me")


;; #t


(graph:cyclevertex? g3 "me")


;; #t
