Tree A
tree is an undirected graph that satisfies any of the following equivalent conditions: • is
connected and
acyclic (contains no cycles). • is acyclic, and a simple cycle is formed if any
edge is added to . • is connected, but would become
disconnected if any single edge is removed from . • is connected and the
complete graph is not a
minor of . • Any two vertices in can be connected by a unique
simple path. If has finitely many vertices, say of them, then the above statements are also equivalent to any of the following conditions: • is connected and has edges. • is connected, and every
subgraph of includes at least one vertex with zero or one incident edges. (That is, is connected and
1-degenerate.) • has no simple cycles and has edges. As elsewhere in graph theory, the
order-zero graph (graph with no vertices) is generally not considered to be a tree: while it is vacuously connected as a graph (any two vertices can be connected by a path), it is not
0-connected (or even (−1)-connected) in algebraic topology, unlike non-empty trees, and violates the "one more vertex than edges" relation. It may, however, be considered as a forest consisting of zero trees. An (or inner vertex) is a vertex of
degree at least 2. Similarly, an (or outer vertex, terminal vertex or leaf) is a vertex of degree 1. A branch vertex in a tree is a vertex of degree at least 3. An (or series-reduced tree) is a tree in which there is no vertex of degree 2 (enumerated at sequence in the
OEIS).
Forest A is an undirected acyclic graph or equivalently a
disjoint union of trees. Trivially so, each connected component of a forest is a tree. As special cases, the order-zero graph (a forest consisting of zero trees), a single tree, and an edgeless graph, are examples of forests. Since for every tree , we can easily count the number of trees that are within a forest by subtracting the difference between total vertices and total edges. number of trees in a forest.
Polytree A
Polyforest A (or directed forest or oriented forest) is a directed acyclic graph whose underlying undirected graph is a forest. In other words, if we replace its directed edges with undirected edges, we obtain an undirected graph that is acyclic. As with directed trees, some authors restrict the phrase "directed forest" to the case where the edges of each connected component are all directed towards a particular vertex, or all directed away from a particular vertex (see
branching). 2-ary trees are often called
binary trees, while 3-ary trees are sometimes called
ternary trees.
Ordered tree An
ordered tree (alternatively,
plane tree or
positional tree) is a rooted tree in which an ordering is specified for the children of each vertex. This is called a "plane tree" because an ordering of the children is equivalent to an embedding of the tree in the plane, with the root at the top and the children of each vertex lower than that vertex. Given an embedding of a rooted tree in the plane, if one fixes a direction of children, say left to right, then an embedding gives an ordering of the children. Conversely, given an ordered tree, and conventionally drawing the root at the top, then the child vertices in an ordered tree can be drawn left-to-right, yielding an essentially unique planar embedding. ==Properties==