
A tree structure, tree diagram, or tree model is a way of representing the
hierarchical
A hierarchy (from Greek: , from , 'president of sacred rites') is an arrangement of items (objects, names, values, categories, etc.) that are represented as being "above", "below", or "at the same level as" one another. Hierarchy is an importan ...
nature of a
structure
A structure is an arrangement and organization of interrelated elements in a material object or system, or the object or system so organized. Material structures include man-made objects such as buildings and machines and natural objects such as ...
in a graphical form. It is named a "tree structure" because the classic
representation resembles a
tree
In botany, a tree is a perennial plant with an elongated stem, or trunk, usually supporting branches and leaves. In some usages, the definition of a tree may be narrower, e.g., including only woody plants with secondary growth, only ...
, although the chart is generally upside down compared to a biological tree, with the "stem" at the top and the "leaves" at the bottom.
A tree structure is conceptual, and appears in several forms. For a discussion of tree structures in specific fields, see
Tree (data structure)
In computer science, a tree is a widely used abstract data type that represents a hierarchical tree structure with a set of connected nodes. Each node in the tree can be connected to many children (depending on the type of tree), but must be co ...
for computer science; insofar as it relates to graph theory, see
tree (graph theory)
In graph theory, a tree is an undirected graph in which any two vertices are connected by path, or equivalently a connected acyclic undirected graph. A forest is an undirected graph in which any two vertices are connected by path, or equi ...
or
tree (set theory)
In botany, a tree is a perennial plant with an elongated stem, or trunk, usually supporting branches and leaves. In some usages, the definition of a tree may be narrower, e.g., including only woody plants with secondary growth, only pla ...
. Other related articles are listed below.
Terminology and properties
The tree elements are called "
node
In general, a node is a localized swelling (a "knot") or a point of intersection (a vertex).
Node may refer to:
In mathematics
* Vertex (graph theory), a vertex in a mathematical graph
*Vertex (geometry), a point where two or more curves, lines ...
s".
The lines connecting elements are called "branches".
Nodes without children are called
leaf node
In computer science, a tree is a widely used abstract data type that represents a hierarchical tree structure with a set of connected nodes. Each node in the tree can be connected to many children (depending on the type of tree), but must be conn ...
s, "end-nodes", or "leaves".
Every
finite
Finite may refer to:
* Finite set, a set whose cardinality (number of elements) is some natural number
* Finite verb, a verb form that has a subject, usually being inflected or marked for person and/or tense or aspect
* "Finite", a song by Sara Gr ...
tree structure has a member that has no
superior. This member is called the "root" or
root node
In computer science, a tree is a widely used abstract data type that represents a hierarchical tree structure with a set of connected nodes. Each node in the tree can be connected to many children (depending on the type of tree), but must be co ...
. The root is the starting node. But the converse is not true: infinite tree structures may or may not have a root node.
The names of relationships between nodes model the
kinship terminology
Kinship terminology is the system used in languages to refer to the persons to whom an individual is related through kinship. Different societies classify kinship relations differently and therefore use different systems of kinship terminology; ...
of family relations. The gender-neutral names "parent" and "child" have largely displaced the older "father" and "son" terminology. The term "uncle" is still widely used for other nodes at the same level as the parent, although it is sometimes replaced with gender-neutral terms like "ommer".
* A node's "parent" is a node one step higher in the hierarchy (i.e. closer to the root node) and lying on the same branch.
* "Sibling" ("brother" or "sister") nodes share the same parent node.
* A node's "uncles" (sometimes "ommers") are siblings of that node's parent.
* A node that is connected to all lower-level nodes is called an "ancestor". The connected lower-level nodes are "descendants" of the ancestor node.
In the example, "encyclopedia" is the parent of "science" and "culture", its children. "Art" and "craft" are siblings, and children of "culture", which is their parent and thus one of their ancestors. Also, "encyclopedia", as the root of the tree, is the ancestor of "science", "culture", "art" and "craft". Finally, "science", "art" and "craft", as leaves, are ancestors of no other node.
Tree structures can depict all kinds of
taxonomic knowledge, such as
family tree
A family tree, also called a genealogy or a pedigree chart, is a chart representing family relationships in a conventional tree structure. More detailed family trees, used in medicine and social work, are known as genograms.
Representations of ...
s, the biological
evolutionary tree
A phylogenetic tree or phylogeny is a graphical representation which shows the evolutionary history between a set of species or taxa during a specific time.Felsenstein J. (2004). ''Inferring Phylogenies'' Sinauer Associates: Sunderland, MA. In o ...
, the
evolutionary tree of a language family, the
grammatical structure
In linguistics, grammar is the set of rules for how a natural language is structured, as demonstrated by its speakers or writers. Grammar rules may concern the use of clauses, phrases, and words. The term may also refer to the study of such rul ...
of a language (a key example being S → NP VP, meaning a sentence is a noun phrase and a verb phrase, with each in turn having other components which have other components), the way web pages are logically ordered in a web site,
mathematical trees of integer sets, et cetera.
The
Oxford English Dictionary
The ''Oxford English Dictionary'' (''OED'') is the principal historical dictionary of the English language, published by Oxford University Press (OUP), a University of Oxford publishing house. The dictionary, which published its first editio ...
records use of both the terms "tree structure" and "tree-diagram" from 1965 in
Noam Chomsky
Avram Noam Chomsky (born December 7, 1928) is an American professor and public intellectual known for his work in linguistics, political activism, and social criticism. Sometimes called "the father of modern linguistics", Chomsky is also a ...
's ''
Aspects of the Theory of Syntax
''Aspects of the Theory of Syntax'' (known in linguistic circles simply as ''Aspects'') is a book on linguistics written by American linguist Noam Chomsky, first published in 1965. In ''Aspects'', Chomsky presented a deeper, more extensive reformu ...
''.
In a tree structure there is one and only one
path
A path is a route for physical travel – see Trail.
Path or PATH may also refer to:
Physical paths of different types
* Bicycle path
* Bridle path, used by people on horseback
* Course (navigation), the intended path of a vehicle
* Desir ...
from any point to any other point.
Computer science
Computer science is the study of computation, information, and automation. Computer science spans Theoretical computer science, theoretical disciplines (such as algorithms, theory of computation, and information theory) to Applied science, ...
uses tree structures extensively (''see''
Tree (data structure)
In computer science, a tree is a widely used abstract data type that represents a hierarchical tree structure with a set of connected nodes. Each node in the tree can be connected to many children (depending on the type of tree), but must be co ...
and
telecommunications
Telecommunication, often used in its plural form or abbreviated as telecom, is the transmission of information over a distance using electronic means, typically through cables, radio waves, or other communication technologies. These means of ...
.)
For a formal definition see
set theory
Set theory is the branch of mathematical logic that studies Set (mathematics), sets, which can be informally described as collections of objects. Although objects of any kind can be collected into a set, set theory – as a branch of mathema ...
, and for a generalization in which children are not necessarily successors, see
prefix order In mathematics, especially order theory, a prefix ordered set generalizes the intuitive concept of a tree by introducing the possibility of continuous progress and continuous branching. Natural prefix orders often occur when considering dynamical sy ...
.
Examples of tree structures

* Internet:
**
usenet hierarchy
**
Document Object Model
The Document Object Model (DOM) is a cros s-platform and language-independent API that treats an HTML or XML document as a tree structure wherein each node is an object representing a part of the document. The DOM represents a document with ...
's logical structure,
Yahoo!
Yahoo (, styled yahoo''!'' in its logo) is an American web portal that provides the search engine Yahoo Search and related services including My Yahoo, Yahoo Mail, Yahoo News, Yahoo Finance, Yahoo Sports, y!entertainment, yahoo!life, and its a ...
subject index,
Curlie
DMOZ or DMoz (stylized dmoz in its logo; from ''directory.mozilla.org'', an earlier domain name) was a multilingual open content, open-content directory of World Wide Web links. The site and community who maintained it were also known as the Op ...
*
Operating system
An operating system (OS) is system software that manages computer hardware and software resources, and provides common daemon (computing), services for computer programs.
Time-sharing operating systems scheduler (computing), schedule tasks for ...
:
directory structure
In computing, a directory structure is the way an operating system arranges files that are accessible to the user. Files are typically displayed in a hierarchical tree structure.
File names and extensions
A filename is a string used to uniquely ...
* Information management:
Dewey Decimal System,
PSH, this hierarchical bulleted list
* Management: hierarchical
organization
An organization or organisation (English in the Commonwealth of Nations, Commonwealth English; American and British English spelling differences#-ise, -ize (-isation, -ization), see spelling differences) is an legal entity, entity—such as ...
al structures
* Computer science:
**
binary search tree
In computer science, a binary search tree (BST), also called an ordered or sorted binary tree, is a Rooted tree, rooted binary tree data structure with the key of each internal node being greater than all the keys in the respective node's left ...
**
red–black tree
In computer science, a red–black tree is a self-balancing binary search tree data structure noted for fast storage and retrieval of ordered information. The nodes in a red-black tree hold an extra "color" bit, often drawn as red and black, wh ...
**
AVL tree
In computer science, an AVL tree (named after inventors Adelson-Velsky and Landis) is a self-balancing binary search tree. In an AVL tree, the heights of the two child subtrees of any node differ by at most one; if at any time they differ by m ...
**
R-tree
R-trees are tree data structures used for spatial access methods, i.e., for indexing multi-dimensional information such as geographical coordinates, rectangles or polygons. The R-tree was proposed by Antonin Guttman in 1984 and has found s ...
**
doubly logarithmic tree
* Biology:
evolutionary tree
A phylogenetic tree or phylogeny is a graphical representation which shows the evolutionary history between a set of species or taxa during a specific time.Felsenstein J. (2004). ''Inferring Phylogenies'' Sinauer Associates: Sunderland, MA. In o ...
* Business:
pyramid selling scheme
* Project management:
work breakdown structure
A work-breakdown structure (WBS) in project management and systems engineering is a breakdown of a project into smaller components. It is a key project management element that organizes the team's work into manageable sections. The Project Mana ...
* Linguistics:
** (Syntax)
Phrase structure trees
** (Historical Linguistics)
Tree model
In historical linguistics, the tree model (also Stammbaum, genetic, or cladistic model) is a model of the evolution of languages analogous to the concept of a family tree, particularly a phylogenetic tree in the biological evolution of species. ...
of language change
* Sports:
business chess,
playoffs brackets
* Mathematics:
Von Neumann universe
In set theory and related branches of mathematics, the von Neumann universe, or von Neumann hierarchy of sets, denoted by ''V'', is the class of hereditary well-founded sets. This collection, which is formalized by Zermelo–Fraenkel set theory ( ...
* Group theory:
descendant trees
Representing trees
There are many ways of visually representing tree structures.
Almost always, these boil down to variations, or combinations,
of a few basic styles:
Classical node-link diagrams
Classical node-link diagrams, that connect nodes together with line segments:
Nested sets
Nested sets that use enclosure or containment to show parenthood; examples include
TreeMaps,
fractal maps, and
Euler diagrams:
Layered "icicle" diagrams
Layered "icicle" diagrams that use alignment/adjacency.
Outlines and tree views
Lists or diagrams that use indentation, sometimes called "
outlines" or "
tree views".
An outline:
:encyclopedia
::culture
:::art
:::craft
::science
A tree view:
*encyclopedia
**culture
***art
***craft
**science
Nested parentheses
A correspondence to nested parentheses was first noticed by Sir
Arthur Cayley
Arthur Cayley (; 16 August 1821 – 26 January 1895) was a British mathematician who worked mostly on algebra. He helped found the modern British school of pure mathematics, and was a professor at Trinity College, Cambridge for 35 years.
He ...
:
((art,craft)culture,science)encyclopedia
or
encyclopedia(culture(art,craft),science)
Radial trees
Trees can also be
represented radially:
See also
;Kinds of trees:
*
B-tree
In computer science, a B-tree is a self-balancing tree data structure that maintains sorted data and allows searches, sequential access, insertions, and deletions in logarithmic time. The B-tree generalizes the binary search tree, allowing fo ...
*
Dancing tree
In computer science, a dancing tree is a tree data structure similar to B+ trees. It was invented by Hans Reiser, for use by the Reiser4 file system. As opposed to self-balancing binary search tree
In computer science, a self-balancing binary ...
*
Decision tree
A decision tree is a decision support system, decision support recursive partitioning structure that uses a Tree (graph theory), tree-like Causal model, model of decisions and their possible consequences, including probability, chance event ou ...
*
Left-child right-sibling binary tree
*
Porphyrian tree
*
Tree (data structure)
In computer science, a tree is a widely used abstract data type that represents a hierarchical tree structure with a set of connected nodes. Each node in the tree can be connected to many children (depending on the type of tree), but must be co ...
*
Tree (graph theory)
In graph theory, a tree is an undirected graph in which any two vertices are connected by path, or equivalently a connected acyclic undirected graph. A forest is an undirected graph in which any two vertices are connected by path, or equi ...
*
Tree (set theory)
In botany, a tree is a perennial plant with an elongated stem, or trunk, usually supporting branches and leaves. In some usages, the definition of a tree may be narrower, e.g., including only woody plants with secondary growth, only pla ...
;Related articles:
*
Data drilling
Data drilling (also drilldown) refers to any of various operations and transformations on tabular, relational, and multidimensional data. The term has widespread use in various contexts, but is primarily associated with specialized software design ...
*
Hierarchical model
A hierarchical database model is a data model in which the data is organized into a tree-like structure. The data are stored as records which is a collection of one or more fields. Each field contains a single value, and the collection of fields i ...
:
clustering and
query
*
Tree testing
References
Further reading
Identification of some of the basic styles of tree structures can be found in:
*
Jacques Bertin
Jacques Bertin (27 July 1918 – 3 May 2010) was a French cartographer and theorist, known from his book ''Sémiologie Graphique'' (''Semiology of Graphics''), published in 1967. This monumental work, based on his experience as a cartographer an ...
, ''Semiology of Graphics'', 1983, University of Wisconsin Press (2nd edition 1973, ;
*
*Brian Johnson and
Ben Shneiderman
Ben Shneiderman (born August 21, 1947) is an American computer scientist, a Distinguished University Professor in the University of Maryland Department of Computer Science, which is part of the University of Maryland College of Computer, Mathem ...
,
Tree-maps: A space-filling approach to the visualization of hierarchical information structures, in ''Proceedings of IEEE Visualization (VIS)'', 1991, pp. 284–291, ;
*
Peter Eades, Tao Lin, and Xuemin Lin, "Two Tree Drawing Conventions", ''International Journal of Computational Geometry and Applications'', 1993, volume 3, number 2, pp. 133–153.
*
External links
Visualization of phylogenetic trees on the T-REX serverUsing a tree structure to design a business process– from the
Society for Technical Communication
The Society for Technical Communication (STC) was a professional association dedicated to the advancement of the theory and practice of technical communication with more than 4,500 members in the United States, Canada, and the world. The society pu ...
{{DEFAULTSORT:Tree Structure
Trees (data structures)
Conceptual models
de:Baum (Datenstruktur)
pl:Struktura drzewiasta