Tuesday, December 6, 2011

Linked data structures

Graph theory deals with collections of nodes and edges. Linked data structures are graphs such that each edge is a link between precisely two nodes. Each such structure can be expressed using an adjacency list:
{
  :a [[:- :a] [:> :b] [:> :c]]
  :b [[:- :b] [:> :c]]
  :c [[:- :c]]
}
Edges stored outside the adjacency list may also be linked to in order to describe more complicated metadata, in which case our representation is closer to an incidence list.

No comments:

Post a Comment