YAP 7.1.0
Undirected Graphs

The following graph manipulation routines use the red-black tree graph library to implement undirected graphs. More...

Detailed Description

The following graph manipulation routines use the red-black tree graph library to implement undirected graphs.

Mostly, this is done by having two directed edges per undirected edge


Class Documentation

◆ undgraph_new/1

class undgraph_new/1

undgraph_new(+ Graph)

Create a new directed graph This operation must be performed before trying to use the graph

◆ undgraph_complement/2

class undgraph_complement/2

undgraph_complement(+ Graph, - NewGraph)

Unify NewGraph with the graph complementary to Graph

◆ undgraph_vertices/2

class undgraph_vertices/2

undgraph_vertices(+ Graph, - Vertices)

Unify Vertices with all vertices appearing in graph Graph

◆ undgraph_add_edges/3

class undgraph_add_edges/3

undgraph_add_edges(+ Graph, + Edges, - NewGraph)

Unify NewGraph with a new graph obtained by adding the list of edges Edges to the graph Graph

◆ undgraph_add_vertices/3

class undgraph_add_vertices/3

undgraph_add_vertices(+ Graph, + Vertices, - NewGraph)

Unify NewGraph with a new graph obtained by adding the list of vertices Vertices to the graph Graph

◆ undgraph_edges/2

class undgraph_edges/2

undgraph_edges(+ Graph, - Edges)

Unify Edges with all edges appearing in graph Graph

◆ undgraph_neighbours/3

class undgraph_neighbours/3

undgraph_neighbours(+ Vertex, + Graph, - Vertices)

Unify Vertices with the list of neighbours of vertex Vertex in Graph

◆ undgraph_del_edges/3

class undgraph_del_edges/3

undgraph_del_edges(+ Graph, + Edges, - NewGraph)

Unify NewGraph with a new graph obtained by removing the list of edges Edges from the graph Graph Notice that no vertices are deleted

◆ undgraph_del_vertices/3

class undgraph_del_vertices/3

undgraph_del_vertices(+ Graph, + Vertices, - NewGraph)

Unify NewGraph with a new graph obtained by deleting the list of vertices Vertices and all the edges that start from or go to a vertex in Vertices to the graph Graph