Louxin Zhang1. 1. Department of Mathematics, National University of Singapore, 10 Lower Kent Ridge Road, Singapore, 119076, Singapore. matzlx@nus.edu.sg.
Abstract
BACKGROUND: Galled trees are studied as a recombination model in theoretical population genetics. This class of phylogenetic networks has been generalized to tree-child networks and other network classes by relaxing a structural condition imposed on galled trees. Although these networks are simple, their topological structures have yet to be fully understood. RESULTS: It is well-known that all phylogenetic trees on n taxa can be generated by the insertion of the n-th taxa to each edge of all the phylogenetic trees on n-1 taxa. We prove that all tree-child (resp. normal) networks with k reticulate nodes on n taxa can be uniquely generated via three operations from all the tree-child (resp. normal) networks with k-1 or k reticulate nodes on n-1 taxa. Applying this result to counting rooted phylogenetic networks, we show that there are exactly [Formula: see text] binary phylogenetic networks with one reticulate node on n taxa. CONCLUSIONS: The work makes two contributions to understand normal networks. One is a generalization of an enumeration procedure for phylogenetic trees into one for normal networks. Another is simple formulas for counting normal networks and phylogenetic networks that have only one reticulate node.
BACKGROUND: Galled trees are studied as a recombination model in theoretical population genetics. This class of phylogenetic networks has been generalized to tree-child networks and other network classes by relaxing a structural condition imposed on galled trees. Although these networks are simple, their topological structures have yet to be fully understood. RESULTS: It is well-known that all phylogenetic trees on n taxa can be generated by the insertion of the n-th taxa to each edge of all the phylogenetic trees on n-1 taxa. We prove that all tree-child (resp. normal) networks with k reticulate nodes on n taxa can be uniquely generated via three operations from all the tree-child (resp. normal) networks with k-1 or k reticulate nodes on n-1 taxa. Applying this result to counting rooted phylogenetic networks, we show that there are exactly [Formula: see text] binary phylogenetic networks with one reticulate node on n taxa. CONCLUSIONS: The work makes two contributions to understand normal networks. One is a generalization of an enumeration procedure for phylogenetic trees into one for normal networks. Another is simple formulas for counting normal networks and phylogenetic networks that have only one reticulate node.
Phylogenetic networks have been used to date both vertical and horizontal genetic transfers in evolutionary genomics and population genetics in the past two decades [1-3]. A rooted phylogenetic network (RPN) is a directed acyclic digraph in which all the sink nodes are of indegree 1 and a unique source node is designated as the root, where the former represent a set of taxa (e.g, species, genes, or individuals in a population) and the latter represents the least common ancestor of the taxa. Moreover, the other nodes in a RPN are divided into tree nodes and reticulate nodes, where reticulate nodes represent reticulate evolutionary events such as horizontal genetic transfers and genetic recombination.The topological properties of RPNs are much more complicated than phylogenetic trees [2, 4, 5]. Therefore, different mathematical issues arise in the study of RPNs. First, phylogenetic reconstruction problems are often NP-hard even for trees [6, 7]. As such, a phylogenetic reconstruction method often uses nearest neighbor interchanges (NNIs) or other rearrangement operations to search for an optimal tree or network [8, 9]. Recently, different variants of NNI have been proposed for RPNs [10-16].Second, to develop efficient algorithms for NP-complete problems on RPNs, simple classes of RPNs have been introduced, including galled trees [17, 18], tree-child networks (TCNs) [19], normal networks [20], reticulation-visible networks [4] and tree-based networks [21, 22] (see also [5, 23]). For instance, a RPN is a TCN if every non-leaf node has a child that is a tree node or a leaf. Although these network classes have been intensively investigated, their topological structures remain unclear [5, 24]. How to efficiently enumerate and count normal networks remains unclear [25-30].This work makes two contributions to understanding TCNs and normal networks. It is a well-known fact that all phylogenetic trees on n taxa can be generated by inserting the n-th taxa in every edge of all the phylogenetic trees on n−1 taxa. We prove that all TCNs with k reticulate nodes on n taxa can be uniquely generated via three operations from TCNs with k−1 or k reticu- late nodes on n−1 taxa (Theorem 1, “Generating TCNs and normal networks” section). Using this fact, we obtain recurrence formulas for counting TCNs and normal networks (“Counting formulas” section). In particular, simple formulas are given for the number of RPNs and normal networks with one reticulate node, respectively.
Methods
Basic notation
A RPN over a finite set of taxa X is an acyclic digraph such that:there is a unique node of indegree 0 and outdegree 1, called the root;there are exactly |X| nodes of outdegree 0 and indegree 1, called the leaves of the RPN, each being labeled with a unique taxon in X;each non-leaf/non-root node is either a reticulate node that is of indegree 2 and outdegree 1, or a tree node that is of indegree 1 and outdegree 2; andthere are no parallel edges between a pair of nodes.Two RPNs are drawn in Fig. 1, where each edge is directed away from the root and both the root and edge orientation are omitted. For a RPN N, we use and to denote the set of all nodes, the set of reticulate nodes and the set of tree nodes and the set of directed edges for N, respectively.
Fig. 1
Two tree-child networks on {1,2,3,4,5}, where reticulate and tree nodes are drawn as filled and unfilled circles, respectively. Only the right network is normal. Here, edge downward orientation is omitted
Two tree-child networks on {1,2,3,4,5}, where reticulate and tree nodes are drawn as filled and unfilled circles, respectively. Only the right network is normal. Here, edge downward orientation is omittedLet and . The node u is said to be a parent (resp. a child) of v if (resp. ). Every reticulate node r has a unique child, named c(r), whereas every tree node t has a unique parent, named p(t). Furthermore, u is an ancestor of v or, equivalently, v is belowu if there is a direct path from the network root to v that contains u. We say that u and v are incomparable if neither of them is an ancestor of the other.Let . It is a reticulate edge if v is a reticulate node and a tree edge otherwise. Hence, a tree edge leads to either a tree node or a leaf.A phylogenetic tree is simply a RPN with no reticulate nodes.A TCN is a RPN in which every non-leaf node has a child that is a tree node or a leaf or, equivalently, there is a path from every non-leaf node to some leaf that consists only of tree edges. Both RPNs in Fig. 1 are tree-child.A normal network is a TCN in which every reticulate node satisfies the following condition:(The normal condition) The two parents are incomparable.The first PRN in Fig. 1 is not normal, as a parent of the left most reticulate node is an ancestor of the other in the network.
Generating TCNs and normal networks
We define the following rearrangement operations for TCNs N on [1,n], which are illustrated in Fig. 2:
Fig. 2
Insertion and child rotations for tree-child networks. a Leaf 3 is attached to a tree edge. b The reticulation insertion is applied to attach a new reticulate node r onto two tree edges. The child rotation swaps the tree node w (yellow) and Leaf 4. Here, green nodes and edges are added nodes
Leaf insertion For a tree edge , insert a new node w to subdivide e and attach Leaf n+1 below w as its child. The resulting network is denoted by Leaf-Insert(N,e,n+1), in which w is a tree node.Insertion and child rotations for tree-child networks. a Leaf 3 is attached to a tree edge. b The reticulation insertion is applied to attach a new reticulate node r onto two tree edges. The child rotation swaps the tree node w (yellow) and Leaf 4. Here, green nodes and edges are added nodesReticulation insertion For a pair of tree edges e1=(u1,v1) and e2=(u2,v2) of N, which are not necessarily distinct, insert a new node w1 to subdivide e1 and a new node w2 to subdivide e2, attach a new reticulate node r as the common child of w1 and w2 and make Leaf (n+1) to be the child of r. In this case, we say that rstraddles
e1 and e2. We use Ret-Insert(N,e1,e2,n+1) to denote the resulting network. We simply write Ret-Insert(N,e,n+1) if e1=e2=e.Child rotation Let r be a reticulate node with parents and v. If u is not an ancestor of v, exchange the unique child of r and the other child of u. The resulting network is denoted by C-Rotate(N,u,r).Note that a child rotation is a special case of the rNNI rearrangement introduced by Gambette et al. in [12]. Let denote the set of TCNs with k reticulations on [1,n].
Proposition 1
Let and let e1 and e2 be two tree edges of M. Then,
Proof
The second statement is a special case of the first. Let e1=(u,v) and e2=(x,y). Since e1 and e2 are tree edges, both v and y are tree nodes or leaves. Let r be the added reticulate node. Then the parents of r have v and y as their child, respectively, the nodes u and x have the parents of r as their tree node child; Leaf n+1 is the tree childr. Additionally, all the other nodes have the same children as in M. Therefore, Ret-Insert(M,e1,e2,n+1) is a TCN. □
Proposition 2
Let . Assume that and its parents are u and v such that u is not an ancestor of v in M. Then,Let M′=C-Rotate(M,u,r). Since u is a parent of r and M is tree-child, u is a tree node. Let w be the other child of u and let z be the unique child of r. Since M is tree-child, z and w are tree nodes (see Fig. 2). The tree node z becomes the child of u Therefore, every node also has a child that is a tree node or a leaf in M′. □By definition, w becomes a child of r and z becomes a tree node child of u in M′. If M′ contains a directed cycle C, C must contain v and w, implying that u is an ancestor of v in M, a contradiction. Therefore, M′ is acyclic and .
Proposition 3
Let .(i) If Leaf (n+1) is the child of a reticulate node r, N can then be obtained from an via a reticulation insertion.(ii) If Leaf (n+1) is the child of a tree node t and the sibling of n+1 is also a tree node, N can then obtained from an via a leaf insertion.(iii) If Leaf (n+1) is a child of a tree node t and the sibling of n+1 is a reticulate node, N can then be obtained from an via a child rotation.(i) Let r have parents u1 and u2 in N. Since N is a TCN, u1 and u2 are tree nodes and so are their children other than r. Let w and v be the parent and the child of u such that v≠r, respectively, for each i=1,2. Since r is a reticulate node, v1 and v2 are tree nodes. Without loss of generality, we assume that u2 is not the parent of u1. There are two cases for consideration.If u1 is the parent of u2, then u1=w2 and u2=v1 (Fig. 3a). Removing Leaf (n+1),u1 and u2 (together with incident edges) and adding an edge e=(w1,v2) produce a TCN M with k reticulations such that N=Ret-Insert(M,e,n+1).
Fig. 3
An illustration of the proof of Proposition 3. a The reticulate node parent r of n+1 has two adjacent parents. b The reticulate node parent r of n+1 has two non-adjacent parents. c The parent and sibling of n+1 are both a tree node. d The parent of n+1 is a tree node, whereas the sibling of n+1 is a reticulate node
An illustration of the proof of Proposition 3. a The reticulate node parent r of n+1 has two adjacent parents. b The reticulate node parent r of n+1 has two non-adjacent parents. c The parent and sibling of n+1 are both a tree node. d The parent of n+1 is a tree node, whereas the sibling of n+1 is a reticulate nodeIf u1 is not the parent of u2, then, w1≠u2 (Fig. 3b). After removing Leaf n+1,u1 and u2 (together with incident edges) and adding two edges e=(w,v) (i=1,2), we obtain a TCN M such that N=Ret-Insert(M,e1,e2,n+1).(ii) Let u be the parent of t and let v be the sibling of Leaf n+1 (Fig. 3c). By assumption, v is a tree node. After removing t and Leaf (n+1) (together with incident edges) and adding e=(u,v), we obtain a TCN such that N=Leaf-Insert(M,(u,v),n+1).(iii) Let y be the sibling of n+1 that is a reticulate node (Fig. 3d). Let z be the child of y and let M=C-Rotate(N,t,y). Since z is below y and y is below t in N, neither attaching the tree node z below t nor attaching Leaf (n+1) below y generates a directed cycle in M. Hence, in which Leaf (n+1) is the child of a reticulate node y such that N=C-Rotate(M,t,y). □
Proposition 4
Let .(i) Leaf-Insert(N1,e1,n+1) is identical to Leaf-Insert(N2,e2,n+1) iff N1=N2 and e1=e2.(ii) Ret-Insert(N1,e1,e1′,n+1) is identical to Ret-Insert(N2,e2,e2′,n+1) iff N1=N2.(iii) Assume the parent of Leaf n is a reticulate node y in N for i=1,2. C-Rotate(N1,x1,y1) is identical to C-Rotate(N2,x2,y2) iff N1=N2.(i) Let and . Let M1=Leaf-Insert(N1,e1,n+1) and M2=Leaf-Insert(N2,e2,n+1) such that M1=M2. Then, there exists a node mapping ϕ from M1 to M2 such that (i) it maps a leaf in M1 to the same leaf and (ii) if and only if . Since n+1 is inserted as a leaf, ϕ maps the parent p1 of (n+1) in M1 to the parent p2 of n+1 in M2, implying that ϕ induces an isomorphic mapping from N1 to N2. This proves the necessity condition. The sufficient condition is straightforward.(ii) and (iii) Both statement can be proved similarly. The proposition is proved. □Figure 4 show how to generate the left TCN given in Fig. 1.
Fig. 4
Illustration how to generate the left TCN in Figure 1 from a tree on 2 taxa
Illustration how to generate the left TCN in Figure 1 from a tree on 2 taxa
Results
Main theorems
Taken together, Propositions 1–4 imply the following theorem.
Theorem 1
Each TCN of can be obtained from either (i) a unique TCN of by attaching Leaf n+1 to a tree edge or (ii) a unique TCN by applying one of the following operations:Insertion of a reticulate node r with the child Leaf (n+1) into a tree edge or straddling two tree edges;Insert r into a tree edge (u,v), as described in (a), and then conduct the child rotation to switch the child of r and the tree node child of v.Insert r straddling two tree edges e′=(u′,v′) and e′′=(u′′,v′′), as described in (a), and then conduct the child rotation to switch the child of r and the tree node child of v′′ (resp. v′) if u′′ (resp. u′) is not an ancestor of u′ (resp. u′′).If we restrict the operations on normal networks, we obtain all the normal networks in . However, inserting a reticulate node and then applying the child rotation may lead to a scenario that a reticulation no longer satisfy the normal condition (Fig. 5). Hence, the child-rotation operation should be taken after some verification when all normal networks are enumerated.
Fig. 5
Illustration the undesired condition in Theorem 2 that prevents from applying s a child rotation. Here, the reticulate node r and its child Leaf 4 are first inserted into the tree edges entering v1 and v2(i.e. 2) in a normal network (top), generating a normal network (middle). But, child rotation to left leads to a tree-child network that is no longer normal (bottom), in which y does not satisfy the normal condition
Illustration the undesired condition in Theorem 2 that prevents from applying s a child rotation. Here, the reticulate node r and its child Leaf 4 are first inserted into the tree edges entering v1 and v2(i.e. 2) in a normal network (top), generating a normal network (middle). But, child rotation to left leads to a tree-child network that is no longer normal (bottom), in which y does not satisfy the normal condition
Theorem 2
Each normal network of can be obtained from either (i) a unique normal network in by attaching Leaf n+1 to a tree edge or (ii) a unique normal network by applying one of the following operations for each pair of incomparable edges e1=(u1,v1) and e2=(u2,v2) in N:Insert a reticulate node r with the child (n+1) straddling e1 and e2. Let p be the tree node inserted into e for i=1,2.Insert r as described in (a) and then conduct the child rotation to make v1 to be the child of r and n+1 the child of p1, respectively, unless a reticulate edge (x,y) exists in N (Fig. 5) such that:y is below v1;x is not an ancestor of v1;x is an ancestor of v2.Insert r as described in (a) and then conduct the child rotation to make v2 to be the child of r and n+1 the child of p2, respectively, unless a reticulate edge (x,y) exists in N such that:y is below v2;x is not an ancestor of v2;x is an ancestor of v1.The statement for normal networks is based on the fact that if N is obtained from N′ vis one of the three operations given in Theorem 1, that the normality of N implies the normality of N′.The conditions in (b) and (c) are used to exclude the child rotations that make the normal condition invalid for some existing reticulate nodes in the generated TCN. □
Counting formulas
Let N be a TCN. For a pair of edges (u1,v1) and (u2,v2) of N, they are incomparable if neither of v1 and v2 is an ancestor of the other. Let u(N) be the number of unordered pairs of incomparable edges in N and let:Define a to be and b to be the number of normal networks in TCN(n),0≤k
Theorem 3
(i) The a can be calculated through the following recurrence formula:where a2,0=1 and u is defined in Eq. (1).(ii) The b can be calculated through the following recurrence formula:where u is the total number of unordered pairs of incomparable edges in all the phylogenetic trees on n−1 taxa.(i) The unique tree on two taxa is a TCN and thus a2,0=1.Each TCN of has 2n+k−3 tree edges and Leaf n can be attached to each of these edges. The first term of the right hand side of Eq. (2) counts the TCNs obtained by applying the leaf insertion in Theorem 1.Consider . N has n−1 leaves, n+k−3 tree nodes, and thus 2n+k−4 tree edges. The reticulation insertion can be used on a single edge or a pair of edges in N. Thus, we can insert a reticulate node r with the child Leaf n in possible ways. After the insertion of r in a tree edge (u,v), we can apply a child rotation to exchange Leaf n with v, as u is not an ancestor of v after r was inserted. Similarly, after r is connected to a pair of edges e1 and e2, we can apply a child rotation once if one edge is below the other and in two possible ways if neither is an ancestor of the other.In summary, for each unordered pair of tree edges (e1,e2), we can generate three different tree child networks with k reticulations on [1,n] if they are incomparable and two otherwise. Thus, we have the second and third terms of the formula.(ii) The fact that b=0 was first proved by Bickner [25]. □In the case that n>2 and k≤n−2, Eq. (3) for b follows from the following two facts:Only two incomparable edges in normal networks in can be used to generate normal networks in ;For each unordered pair of incomparable edges in a tree on [1,n−1], three normal networks can be obtained by applying insertion of reticulate node and two child rotations.Unfortunately, we do not know how to obtain a simple formula for b in general. By Theorem 3, one still can compute the number of normal networks with k reticulate nodes on [1,n],b, by enumeration. For each 1≤k≤n−2 and 3≤n≤7,b is listed in Table 1.
Table 1
Counts of the normal networks with k reticulations on [n],1≤k≤n−2 and 3≤n≤7
k\n
3
4
5
6
7
8
1
3
54
855
14,040
248,535
4,787,370
2
48
2310
78,120
2,377,620
70,749,000
3
1920
184,680
11,038,530
536,524,830
4
146,520
23,797,302
2,217,404,379
5
16,198,764
3,802,965,091
6
2,479,006,101
Counts of the normal networks with k reticulations on [n],1≤k≤n−2 and 3≤n≤7It is challenging to obtain a simple formula for counting u for arbitrary k. But we can find a closed formula for u and thus obtain a recurrence formula for a and b.
Lemma 1
For any n≥2, the total number of unordered pairs of incomparable edges in all the phylogenetic trees on n taxa is:Let T be a phylogenetic tree on [1,n−1] and let O(T) denote the set of ordered pairs of comparable edges in T, where that (x,y)∈O(T) means the edge x is above the edge y. Then, it is not hard to verify:□Assume T′ is obtained from T by attaching Leaf n in an edge e=(u,v). In T′, the parent w of Leaf n is the tree node inserted in e, implying that e is subdivided into two edges of T′:
and
Thus,Hence,Since T has 2n−3 edges,where denotes the set of 2n−3 phylogenetic trees that are obtained by a Leaf-Insertion on T.Let c be the total number of unordered pairs of comparable edges in all the phylogenetic trees on n taxa. Clearly, c2=2. Since there are phylogenetic trees with n−1 leaves, which each have 2n−3 edges, Eq. (5) implies:or, equivalently,Therefore,where is the k-th Catalan number C that is equal to the integral appearing above ([31]). Since there are phylogenetic trees on [1,n] each having (2n−1) edges,
Theorem 4
For any n≥3, the numbers of TCNs and normal networks with exactly one reticulate node on n taxa are:andrespectively.Since , by Theorem 3,or, equivalently,Therefore, since a2,1=2,
By induction, we can show that and . Continuing the above calculation, we obtain:
□This proves Eq. (6).Similarly, by Theorem 3 and Lemma 1, we have:or, equivalently,Since b2,1=0,This proves Eq. (7).
Remark 1
Every RPN with exactly one reticulate node is a TCN. Therefore, a is actually the number of RPNs with one reticulate node.
Conclusions
It is well-known that all phylogenetic trees on n taxa can be generated by the insertion of the n-th taxa in each edge of all the phylogenetic trees on the first n−1 taxa. The main result of this work is a generalization of this fact into TCNs. This leads to a simple procedure for enumerating both normal networks and TCNs, the C-code for which is available upon request. It is fast enough to count all the normal networks on eight taxa. Recently, Cardona et al. introduced a novel operation to enumerate TCNs. Their program was successfully used to compute the exact number of tree-child networks on six taxa. Although our program is faster than theirs, it still cannot be used to count TCNs on eight taxa on a PC.Another contribution of this work is Eq. (6) and (7) for counting RPNs with exactly one reticulate node. Semple and Steel [30] presented formulas for counting unrooted networks with one reticulate node. Since an unrooted networks can be oriented into a different number of RPNs, it is note clear how to use their results to derive a formula for the count of RPNs. Bouvel et al. [26] presented a formula for counting RPNs with one reticulate node. Our formula is much simpler than the formula given in [26].Lastly, the following problem is open:Is there a simple formula like Eq. (6) for the count of TCNs with k reticulate nodes on n taxa for each k>1?
Authors: Philippe Gambette; Leo van Iersel; Mark Jones; Manuel Lafond; Fabio Pardi; Celine Scornavacca Journal: PLoS Comput Biol Date: 2017-08-01 Impact factor: 4.475