Graph (Network - Nodes and edges)


A graph is a set of vertices connected by edges. See data:type:graph:model

Data representation that naturally captures complex relationships is a graph (or network).

Except of the special graph that a tree is, the data structure of a graph is non-hierarchical.

Points are called nodes, links are called edges. A link can only connect two nodes (only binary relationship ?)

Each edge has two endpoints, the nodes it connects. The endpoints of an edge are neighbors.

See also: (Graph|Network) - Database


Are mostly graphs:


  • Graph - Undirected graph
  • (Network|Graph) - Directed acyclic graph (DAG)
  • (Network|Graph) - Force
  • Graph - Acyclic - graphs that do/don't allow self-loops.
  • graphs whose nodes/edges are insertion-ordered, sorted, or unordered


Graph data structure explained: Graph - Data Structure (Physical Representation)




London Tube Map 1908 Lond Tube Map 1933

Directed Graph

(Network|Graph) - Directed acyclic graph (DAG)

  • flowcharts
  • dependency trees.

Dominating set

A dominating set in a graph is a set S of nodes such that every node is in S or a neighbor of a node in S.

Neither algorithm is guaranteed to find the smallest solution.

Grow Algorithm

initialize S = 0; 
while S is not a dominating set, 
    add a node to S.

Shrink Algorithm

initialize S = all nodes
while there is a node x such that S −{x} is a dominating set,
    remove x from S




A x-to-x path is called a cycle


A set S of edges is spanning for a graph G if, for every edge {x, y} of G, there is an x-to-y path consisting of edges of S.


A set of edges of G is a forest if the set includes no cycles.


See Graph - Analysis

Documentation / Reference

Powered by ComboStrap