Class Weighted-Edge

A weighted edge is both a weighted-edge-mixin and a graph-container-edge.

Part of:

package cl-graph, class weighted-edge-mixin, class graph-container-edge

Direct Superclass

graph-container-edge

This is the root class for edges in graph-containers. It adds vertex-1 and vertex-2 slots.

weighted-edge-mixin

This mixin class adds a weight slot to an edge.

Slot

color
The `color` is used by some algorithms for bookkeeping. [?? Should probably be in a mixin]
Initargs::color; Accessors:color.
edge-id
The `edge-id` is used internally by CL-Graph for bookkeeping.
Initform:0, Initargs::edge-id; Accessors:edge-id.
elementInitargs::element,:value; Accessors:element, value.
graph
The `graph` of which this edge is a part.
Initargs::graph; Reader:graph.
tag
The `tag` is used by some algorithms for bookkeeping. [?? Should probably be in a mixin]
Initargs::tag; Accessors:tag.
vertex-1
`Vertex-1` is one of the two vertexes that an edge connects. In a directed-edge, `vertex-1` is also the `source-edge`.
Initargs::vertex-1; Reader:vertex-1.
vertex-2
`Vertex-2` is one of the two vertexes that an edge connects. In a directed edge, `vertex-2` is also the `target-vertex`.
Initargs::vertex-2; Reader:vertex-2.
weight
The value of the weight of this edge. Defaults to 1.0d0
Initform:1.0d0, Initargs::weight; Accessors:weight.

Other Method

add-edge

Add-edge adds an existing edge to a graph. As
add-edge-between-vertexes is generally more natur...

add-edge-to-vertex

Attaches the edge edge to the vertex vertex.

delete-edge

Delete the edge' from the graph' and returns it.

dfs-back-edge-p
dfs-cross-edge-p
dfs-edge-type
dfs-forward-edge-p
dfs-tree-edge-p
directed-edge-p

Returns true if-and-only-if edge is directed

edge->dot

Used by graph->dot to output edge formatting for
edge onto the stream. The function can ass...

edge-lessp-by-direction

Returns true if and only if edge-1 is undirected and edge-2 is directed.

edge-lessp-by-weight

Returns true if the weight of edge-1 is strictly less than the weight of edge-2.

find-edge

Search graph for an edge whose vertexes match
edge. This means that vertex-1 of the edge ...

find-vertex

Search 'graph' for a vertex with element
'value'. The search is fast but inflexible because it ...

find-vertex-if

Returns the first vertex in thing for which the
predicate function returns non-nil. If the ...

iterate-vertexes

Calls fn on each of the vertexes of thing.

other-vertex

Assuming that the value-or-vertex corresponds to
one of the vertexes for edge, this method re...

out-edge-for-vertex-p

Returns true if the edge is connected to vertex and
is either an undirected edge or a directed ...

source-vertex

Returns the source-vertex of a directed
edge. Compare with vertex-1.

tagged-edge-p

Returns true if-and-only-if edge's tag slot is t

target-vertex

Returns the target-vertex of a directed
edge. Compare with vertex-2.

undirected-edge-p

Returns true if-and-only-if edge is undirected

untagged-edge-p

Returns true if-and-only-if edge's tage slot is nil

vertexes

Returns a list of the vertexes of thing.

weight

Returns the weight of an edge. This defaults to 1.0
and can only be altered if the edge is a sub-...