Difference between revisions of "List space"

From Organic Design wiki
 
m (Three keys)
 
(27 intermediate revisions by 3 users not shown)
Line 1: Line 1:
[[Category:Nodal|List]]
+
The Nodes are relatively high-level structures and at ''[[Wikipedia:Runtime|runtime]]'' within the peer-nodes they sit upon a more fundamental layer called ''list space'' in which the actual nodal change takes place in a peer.
[[Category:Documents]]
 
The Nodes are relatively high-level structures and at ''[[Wikipedia:Runtime|runtime]]'' within the peer-nodes they sit upon a more fundamental layer called ''List-Space'' in which the actual nodal change takes place in a peer.
 
  
The project uses a very fundamental memory model based on binary sequences where each bit in the sequence can be referred to also by a ''key'' which is a binary-sequence of fixed length (determined by the total number of bits in the sequence). This can be done because binary-sequences can represent numbers as well as arbitrary content.
+
== List items ==
 +
The project uses a very fundamental memory model based on binary sequences. The entire memory can be divided into groups of smaller sequences which can themselves each be referred to by a locally unique binary sequence. For example, a 16 megabyte section of RAM can be divided into two million 64-bit sequences. ''List-space'' uses blocks of binary as its local memory resource and divides the block up into smaller binary sequences called ''list items''. Every ''list-item'' holds the same structure of content which is a sequence of three ''list-item-keys''.
  
There is no arbitrary content in the List-Space though, the only actual ''content'' stored in this binary memory are ''List-Items'', which are each a sequence of three binary ''List-Item-Keys''. Since the smallest addressable unit in the List-Space is the List-Item, the size of a List-Item-Key can be based on the total number of List-Items that can fit in the space, rather than the total number of bits. For simplicity and efficiency of running in current environments, ensuring the List-Item size is on DWORD boundaries may be best. Maybe 32-bit List-Item-Keys, or maybe 64-bit List-Items with 21-bit keys.
+
== List item keys ==
 +
Since binary can be treated as numbers, each of the two million sequences in the example above can itself be referred to, or ''addressed'', by a unique binary sequence called a ''list-item-key''. In the case of two million items, the list-item-keys are 21 bit sequences. In other words, a 16MB ''list-space'' is divided into two million ''list-items'' each formed from three 21-bit ''list-item-keys''.
 +
*The slight inefficiency of wasting one out of every 64 bits is done because of increased efficiency gained from working with sizes which are powers of two.
 +
*Even an "empty" ''list-item'' containing only zero's is still considered to be composed of three ''list-item-keys'' all referring to the very first ''list-item'' in the ''list-space'' (the one that has a sequence of 21 zero's for its address).
  
The middle key is called the ''data''-key and its meaning and use are context-specific. The first and last keys in a List-Item are the previous-key (''prev'') and next-key (''next'') allowing the formation of ''[http://en.wikipedia.org/wiki/Linked_list#Doubly-linked_list doubly-linked lists]'' called ''Lists'', and hence ''List-Space''. (List-Item 0 is the ''Root-List-Item'' and ''Root-Node'' and indicates a null link). Lists are referred to by the List-Item-Key of their first List-Item and such keys a referred to as ''List-Keys''. List-Keys are a subset of the List-Item-Keys.
+
== Three keys ==
#[[+Nodal/ListSpace/Methods|List-Space Methods]]
+
There are a number of ways that ''list-items'' can be linked together to form lists and ''[[w:Binary Tree|binary-trees]]'' which are all constructed from this general "three-slot" data structure, such as [[List#Stack|stack]]s, [[List#Queue|queue]]s and [[List#Axis|axes]]. ''List-space'' uses a generic [[loop]] linking system for handling what's in use and what's free, but the main functionality of ''list-space'' that is the foundation for [[Nodal Reduction]] is [[binary traversal details|binary traversal]].
#[[+List Characteristics]]
+
 
 +
Within each of the three keys common to all ''list-items'', the first and second are used for [[binary traversal details|binary traversal]] which allows ''list-item-keys'' to be used as [[association]]s (see [[node references]] for more details on this concept). The last key is context-specific and represents a ''value'' at the end of an ''association'', but both the association-key and the association-value are ''list-item-keys'' -- references to other ''list-items''.
 +
 
 +
== List-space methods ==
 +
''List-space'' is an environment which offers a generic set of methods that can manipulate a space of ''list-items'', each addressable by a binary ''list-item-key''. Each ''list-item'' is composed of three ''list-item-keys''. This simple model is rich enough to support many kinds of higher data structures such as stacks, queues, threads, loops and trees.
 +
*listInsert()
 +
*listRemove(subject)
 +
*listTraverse(subject, object)
 +
*listGetValue(subject)
 +
*listSetValue(subject, value)
 +
*listGetKeys(subject)
 +
 
 +
== List space definition ==
 +
To allow automated replication of list-space functionality in different environments, nodal organisations are defined to integrate with the program compilation resources. To make use of these nodal organisations, the list-space must be completely defined using the concepts available from within a node-space.
 +
 
 +
The list-space functions are designed to use only very generic operations. The highest level operations a list-space needs are as follows:
 +
*malloc - the ability to access an area of memory in the form of a sequence of items, which each have a fixed-ordered range of possible states, the most practical being 24- or 32-bit binary words, or in a high-level language, an array of integers.
 +
*reference - each item in the sequence can be referred to by exactly one of the possible states - i.e., a state can be interpreted as an item-reference.
 +
*change - states can be copied from one address to another.
 +
*binary operations - the ability to represent a state as a binary sequence and iterate through it. Interpretation of a state as an address is also based on representing state as binary. In both high- and low-level languages, this can be achieved with the standard binary operations such as AND, OR, XOR, <<, >>.
 +
 
 +
== See also ==
 +
*[[list-space.c]] ''- current implementation''
 +
[[Category:Nodal Concepts]]__NOTOC__

Latest revision as of 07:51, 25 May 2016

The Nodes are relatively high-level structures and at runtime within the peer-nodes they sit upon a more fundamental layer called list space in which the actual nodal change takes place in a peer.

List items

The project uses a very fundamental memory model based on binary sequences. The entire memory can be divided into groups of smaller sequences which can themselves each be referred to by a locally unique binary sequence. For example, a 16 megabyte section of RAM can be divided into two million 64-bit sequences. List-space uses blocks of binary as its local memory resource and divides the block up into smaller binary sequences called list items. Every list-item holds the same structure of content which is a sequence of three list-item-keys.

List item keys

Since binary can be treated as numbers, each of the two million sequences in the example above can itself be referred to, or addressed, by a unique binary sequence called a list-item-key. In the case of two million items, the list-item-keys are 21 bit sequences. In other words, a 16MB list-space is divided into two million list-items each formed from three 21-bit list-item-keys.

  • The slight inefficiency of wasting one out of every 64 bits is done because of increased efficiency gained from working with sizes which are powers of two.
  • Even an "empty" list-item containing only zero's is still considered to be composed of three list-item-keys all referring to the very first list-item in the list-space (the one that has a sequence of 21 zero's for its address).

Three keys

There are a number of ways that list-items can be linked together to form lists and binary-trees which are all constructed from this general "three-slot" data structure, such as stacks, queues and axes. List-space uses a generic loop linking system for handling what's in use and what's free, but the main functionality of list-space that is the foundation for Nodal Reduction is binary traversal.

Within each of the three keys common to all list-items, the first and second are used for binary traversal which allows list-item-keys to be used as associations (see node references for more details on this concept). The last key is context-specific and represents a value at the end of an association, but both the association-key and the association-value are list-item-keys -- references to other list-items.

List-space methods

List-space is an environment which offers a generic set of methods that can manipulate a space of list-items, each addressable by a binary list-item-key. Each list-item is composed of three list-item-keys. This simple model is rich enough to support many kinds of higher data structures such as stacks, queues, threads, loops and trees.

  • listInsert()
  • listRemove(subject)
  • listTraverse(subject, object)
  • listGetValue(subject)
  • listSetValue(subject, value)
  • listGetKeys(subject)

List space definition

To allow automated replication of list-space functionality in different environments, nodal organisations are defined to integrate with the program compilation resources. To make use of these nodal organisations, the list-space must be completely defined using the concepts available from within a node-space.

The list-space functions are designed to use only very generic operations. The highest level operations a list-space needs are as follows:

  • malloc - the ability to access an area of memory in the form of a sequence of items, which each have a fixed-ordered range of possible states, the most practical being 24- or 32-bit binary words, or in a high-level language, an array of integers.
  • reference - each item in the sequence can be referred to by exactly one of the possible states - i.e., a state can be interpreted as an item-reference.
  • change - states can be copied from one address to another.
  • binary operations - the ability to represent a state as a binary sequence and iterate through it. Interpretation of a state as an address is also based on representing state as binary. In both high- and low-level languages, this can be achieved with the standard binary operations such as AND, OR, XOR, <<, >>.

See also