## 7.6.3 Vector trees

Page 193 of 800 |
| Search internet |

A vector tree is a data structure built up from vectors and pairs. A vector tree represents the concatenation of all vectors in the tree. As an example, represents .

The function converts a vector tree to a vector:

In particular, a vector is a vector tree:

In the vector tree representation, all structures which are not pairs or vectors are ignored:

As a consequence of the latter, *all* data structures are vector trees, but quite many data structures represent the empty string.

Vector trees have the nice property that they make it easy and cpu-fast to construct a text from pieces. Furthermore, vector trees are easy to print to a terminal or write to a disk file. For that reason, many Logiweb output functions are constructed such that they accept vector trees as their arguments.

Page 193 of 800 |
| Search logiweb.eu |

Copyright © 2010
Klaus Grue,
GRD-2010-01-05