{'fraction_non_alphanumeric': 0.043401165245292576, 'fraction_numerical': 0.015958794224436378, 'mean_word_length': 4.269632925472748, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Random Ancestor Trees

We investigate a network growth model in which the genealogy controls the evolution. In this model, a new node selects a random target node and links either to this target node, or to its parent, or to its grandparent, etc; all nodes from the target node to its most ancient ancestor are equiprobable destinations. The emerging random ancestor tree is very shallow: the fraction g_n of nodes at distance n from the root decreases super-exponentially with n, g_n=e^{-1}/(n-1)!. We find that a macroscopic hub at the root coexists with highly connected nodes at higher generations. The maximal degree of a node at the nth generation grows algebraically as N^{1/beta_n} where N is the system size. We obtain the series of nontrivial exponents which are roots of transcendental equations: beta_1= 1.351746, beta_2=1.682201, etc. As a consequence, the fraction p_k of nodes with degree k has algebraic tail, p_k ~ k^{-gamma}, with gamma=beta_1+1=2.351746.


I. INTRODUCTION
The interplay between dynamics, structure, and function of complex networks is the subject of intense current research [1][2][3][4]. A wide spectrum of social, technical, and biological networks have broad degree distributions with a power-law tail [2,3]. Further, many real-life networks also have macroscopic hubs that are connected to a finite fraction of all nodes and these hubs play important function in the network [2][3][4]. In this study, we introduce a minimal model that captures both of these features.
Common mechanisms of network growth include preferential attachment [5][6][7][8][9], copying, and re-direction [10][11][12][13]. In these processes, a target node is identified and the attachment is either to the target node itself or to one of its immediate ancestors. These growth processes result in heterogeneous networks with broad degree distributions. However, there are no macroscopic hubs because the maximal degree in these networks grows sub-linearly with the network size.
In this study, we consider the complementary situation where attachment to any ancestor is possible. We show that the resulting network has a fundamentally different structure: there is coexistence between a hub with a macroscopic degree and highly connected nodes with sub-macroscopic degrees. Moreover, there is a series of exponents that characterize how the maximal degree at a given distance from the root scales with system size.
To model situations where the genealogy controls the network growth, we start with a single node, the root, and add nodes sequentially, so that each new node attaches to an existing node through a two-step process (see Fig. 1): • The new node selects a target node at random.
• The new node attaches to one node, selected at random from the set of nodes that includes the target node and all its ancestors.
FIG. 1: The random ancestor tree. A new node attaches, with equal probabilities, to one of three nodes: the target node (marked by ×), its parent, or its grandparent.
Since each new node adds a single link, the growing network retains a tree structure, and apart from the root, each node has a single parent node. We term the resulting structure the random ancestor tree. An appealing feature of this model is the absence of control parameters.
Our motivation for this model comes from social, scholarly, and reference networks [14]. For example, the published literature in science, law, and religion grows by sequential addition of material. Starting with some reference, a scholar typically studies an entire line of preceding reports or rulings, and refers to the most appropriate or the most important published literature, not necessarily the most recent one [15][16][17]. In this sense, the evolution of such reference networks is coupled to their genealogy.
We find that the random ancestor tree has a single macroscopic hub, namely the root, that is connected to a fraction e −1 of all nodes. Furthermore, the degree distribution is broad as the fraction p k of nodes with degree k decays algebraically, when k → ∞. Interestingly, the exponent γ is obtained as a root of a transcendental equation. We also obtain a series of nontrivial exponents γ n , each characterizing the degree distribution of nodes at the nth generation. As n increases, the exponents γ n increase, so that the nodes become less and less connected as their distance from the root increases. Throughout this paper, we focus on the asymptotic behavior of large trees. We first analyze the genealogical structure of the random ancestor tree in section II. The depth distribution indicates that the root is a macroscopic hub, and in section III we show that the root is the only such hub. We then establish (Sec. IV) the degree of the most connected nodes at higher generations and discuss the implications of these results for the degree distribution (Sec. V). Other structural properties including the number of leaves, and the likelihood that the tree has star or chain topology are derived in section VI. Conclusions are given in section VII.

II. GENEALOGICAL STRUCTURE
We treat the random ancestor tree as a genealogical tree and group nodes according to generation (figure 1). The first generation consists of nodes at distance one from the root, the second generation includes nodes at distance two from the root, etc. In principle, the number of nodes in each generation fluctuates from one realization to another, yet in the thermodynamic limit such fluctuations are negligible, and we therefore study the average number of nodes in each generation.
Let N be the total number of nodes in the tree and let G n (N ) be the average number of nodes at distance n from the root. Only the root belongs to the zeroth generation and therefore, G 0 (N ) = 1. The average number of nodes in the first generation, G 1 (N ), grows according to the rate equation Hereinafter we treat the size of the network N as a continuous variable; our results are asymptotically exact in the limit N → ∞. Equation (2) reflects that new nodes are added to the first generation only when a new node links to the root. The first term on the right-hand side corresponds to the situation when the root is chosen as the target node; the second term accounts for situations when a node in the first generation is chosen -then the probability that the actual link will be to the root is 1/2; the following terms describe situations where the target nodes are in higher generations. The generalization of (2) to arbitrary generation n is straightforward, We now introduce g n , the fraction of nodes that belong to the nth generation, The coefficients g n are normalized, n≥1 g n = 1. Further, since G 0 = 1 we have g 0 = 0 in the limit N → ∞. Equation (3) shows that the fractions g n satisfy It is convenient to re-write Eq. (5) as the explicit recursion g n = n −1 g n−1 + g n+1 .
By evaluating the first few terms, g 2 = g 1 , g 3 = g 1 /2!, g 4 = g 1 /3!, and by induction, g n = g 1 /(n − 1)!. The normalization condition n≥1 g n = 1 sets g 1 = e −1 . Thus, indicating that the number of nodes decays superexponentially with increasing generation or alternatively, depth. Hence, the random ancestor tree is exceptionally shallow. For instance, the average depth is finite: The genealogical structure of the random ancestor tree drastically differs from the genealogical structure of other growing networks [11]. In particular, random recursive trees [18,19], which grow by attachment of new nodes to random target nodes, have the depth distribution G n (N ) = (ln N ) n /n!. Thus, there is a sharp peak at n peak ∼ ln N , and furthermore, the maximal depth, defined as the deepest non-empty generation n max , also scales logarithmically with system size, n max ∼ ln N [11]. This behavior is very robust and occurs in most growing trees [20][21][22], but there are exceptions where the maximal depth grows algebraically with system size [23].
For the random ancestor tree, the generation profile (7) is a sharply decreasing function of depth, and from the criterion G nmax ∼ 1 we estimate the maximal depth This depth behavior reflects that the tree is shallow [24].

III. MACROSCOPIC HUB
The random ancestor tree has a macroscopic hub: the root is connected to a finite fraction, e −1 = 0.367879, of all nodes as follows from (7). Such macroscopic hubs are found in social networks [14], and have an important function in as transportation networks [4,[25][26][27][28]. Yet, with a few exceptions including super-linear preferential attachment [8,11,29], most models of network growth have no such hubs and instead, the most central nodes have degrees that grow sub-linearly with network size.
To find out whether, in addition to the root, there are other hubs, let's consider the most connected node at the first generation. We denote the number of descendants of this node in the second generation by H 2 (N ), the number of its descendants in the third generation by H 3 (N ), etc. The equation governing H j (N ) is identical to (3), with H 1 = 1. By definition, the node degree is 1+H 2 (N ). Suppose that the most connected node at the first generation has macroscopic degree, for all j ≥ 2. By substituting (10) into (9), we find that the coefficients u j satisfy a recursion relation identical to (6), Any solution to (11) is a linear combination of the two independent solutions: the fast-decaying solution above u j = 1/(j − 1)! and the slow-decaying one, u j ∼ j −1 when j ≫ 1. For the first few coefficients we have u 1 = 0 and u 2 = u 3 . The boundary condition u 1 = 0 implies that we can not express the solution solely in terms of the rapidly decaying solution u j = 1/(j − 1)!. Yet, the slowly decaying solution is unphysical because the sum j u j diverges. Therefore, the only possible solution is the trivial one, u j = 0 for all j ≥ 1, and we conclude that there are no macroscopic hubs in the first generation.
Similarly, there are no macroscopic hubs in higher generations. If there is a hub in the nth generation, the recurrence (11) holds for j > n with the boundary condition u n = 0, or equivalently u n+1 = u n+2 . By repeating the steps above, we conclude that all coefficients u j vanish.

IV. HIGHLY CONNECTED NODES
In the previous section we have shown that the degree of the most connected node in the first generation cannot be macroscopic. It is then natural to assume that the degree scales as N 1/β with β > 1, or equivalently [30] for all j ≥ 2. The fractions h j satisfy obtained by substituting (12) into (9). Therefore, the recursion relation (6) becomes The boundary conditions is Certain features can be determined without solving Eqs. (14)- (15). For instance, to obtain the total number of descendants h tot = i≥2 h i we multiply (14) by j and sum over all j. This yields Since h tot > 1, we have the bound β < 2.
Similarly, by multiplying (14) by j 2 and summing over all j we determine the average generation number The second order linear difference equation (14) has two independent solutions. We obtain the asymptotic behavior of these solutions by converting the difference equation (14) into a differential equation. If h j decays sufficiently slow, we may approximate Eq. (14) by the differential equation dh/dj ≃ −β h/j with solution h j ∼ j −β at large j. Otherwise, if h j decays very quickly, we have h j ≃ β h j−1 /j in the leading order and therefore h j ∼ β j /j!. Using this solution as an integrating factor, that is, substituting h j = q j β j /j! into Eq. (14), we have the recurrence q j −q j−1 = βq j+1 /(j +1). This recurrence reduces to the differential equation dq/dj ≃ β q/j, with power-law solution q j ∼ j β . Therefore the asymptotic behavior of the second solution to Eq. (14) is Equations (14)-(15) admit a solution for arbitrary value of β. In general, such a solution is a linear combination of the two solutions above. However, the slowly decaying solution is unphysical. If H j ∼ j −β N 1/β for j ≫ 1, then the depth of the subtree emanating from the most connected node in the first generation, j max ∼ N 1/β 2 , as follows from the criterion H jmax ∼ 1, would exceed the maximal depth (8). Therefore, we must find the special value of β for which solution to (14)- (15) is the rapidly decaying solution with the asymptotic behavior (17). Therefore, β is analogous to an eigenvalue.
To determine the proper eigenvalue β we use the generating function technique. We write and convert the difference equation (14) into an integral equation z 0 dx H(x), and convert the integral equation (19) into the differential equation The boundary condition is F(0) = 0. We use the integrating factor I(z) = e −β z (1 − z) −β to simplify (20) to d(FI)/dz = z 2 (1 − z) −1 I. Hence, the solution of (20) is The behavior of the generating function in the limit z → 1 reflects the behavior of the coefficients h j in the limit j → ∞. Therefore, we evaluate the integral in (21) in the limit z → 1, .

The function f (β) is given by the infinite sum
We can also express this function in terms of the incomplete Gamma function γ(a, x) = x 0 dt t a−1 e −t , Using H = dF/dz and the leading z → 1 asymptotics of the integral in (21) we find Generally, the generating function has a regular component and a singular one, H(z) = H reg (z) + H sing (z), with Since j z j j −β ∼ (1−z) β−1 when z → 1, we identify the singular component with the unphysical solution. Hence, the singular term must vanish, and the exponent β is root of the transcendental equation By solving this equation numerically, using the bisection method [31] for example, we find the eigenvalue to essentially arbitrary precision β = 1.351746470331 . . . .
The above behavior extends to higher generations. In general, the degree of the most connected node at the nth generation grows algebraically with the total number of nodes, H n+1 ∼ N 1/βn , and the exponent β n is function of the generation index n. Let H j be the number of descendants of the most connected node at generation j > n. The coefficients h j , defined by H j = H n+1 h j , again satisfy the recursion (13) with the boundary condition h n = 0 and h n+1 = 1. Thus, the coefficients h j decay super-exponentially as in (17).
The exponents β n are obtained by repeating the steps above, and we merely quote the final results. First, the integral of the generating function is The values of the exponents β n for n ≤ 8 are listed in table I. The exponents increase with n and therefore, the degree of the most connected nodes declines sharply as distance from the root increases.  I: The exponent βn, the ratio htot between the total number of descendants and the degree, and the average distance of a descendant ∆j versus generation n. The exponents βn are roots of the transcendental equation f (βn) = 0 with f (βn) given by (26). The quantities htot and ∆j are given in equations (28) and (29), respectively.
The expression (26) holds for all n as long as β n is noninteger. There are, however, two exceptions. We have already seen that for the zeroth generation β 0 = 1 and the coefficients h j can be determined analytically, h j = 1/(j − 1)!. For the third generation, β 3 = 2 and again, the coefficients h j have simple form This can be verified by direct substitution into (14). Of course, the solution (27) agrees with the general asymptotic behavior (17). Using β n , we calculate several other useful properties. First, the ratio h tot between the total number of descendants and the degree equals This quantity mildly increases with generation and eventually saturates (table 1). Also, we mention the average distance of a descendant ∆j = j − n with j = j≥n jh j / j≥n h j . This quantity is given by When n = 3, ∆j = (e 2 − 3)/2. Like h tot , the average distance slowly grows with generation but ultimately approaches a constant. Hence, statistical properties of average quantities such as the total number of descendants and the distance to a descendant weakly depend on depth, but statistical properties of extreme quantities such as the degree of the most connected node strongly depend on depth.

V. THE DEGREE DISTRIBUTION
The degree distribution is an important quantity that characterizes local properties of networks. For many growing networks, the degree distribution satisfies closed recurrence equations and consequently, this quantity can be determined analytically. It appears impossible to find a closed set of equations that govern the degree distribution for the random ancestor tree. Remarkably, the closed set of equations (9) allows us to obtain the tail of the degree distribution analytically. The power-law degree of the most connected node (12) already shows that the degree distribution has power-law tail. Let p k be the fraction of all nodes with degree k. As announced in (1), this distribution decays algebraically, for k ≫ 1. Indeed, if we substitute k max ∼ N 1/β with β ≡ β 1 into the extreme statistics criterion, N k>kmax p k ∼ 1, we obtain (30). Here, we take β = β 1 because the exponents β n increase monotonically. Our numerical simulations results are in excellent agreement with the theoretical prediction (1). The simulations are straightforward to implement: with each new node, a target node is selected at random, and then, the attachment node is selected at random from the target node and all of its ancestors. Since the average depth remains finite, the computational cost is proportional to the network size and we can simulate networks as large as N = 10 8 . We comment that many real-world networks have power-law degree distributions [2] as in (30) with exponent γ in the range 2 < γ < 3. For example, for the Internet at the Autonomous Systems level, as of 2007, the exponent is approximately γ = 2.5, see [32].
Remarkably, the random ancestor tree has a family of degree distributions, each characterized by a distinct nontrivial exponent. The fraction p n,k of nth generation nodes with degree k decays algebraically p n,k ∼ k −γn with γ n = β n + 1.
As in the preferential attachment network, the exponent that characterizes the degree distribution increases with generation [33].
From the roots of the transcendental equation f (β n ) = 0 with f (β n ) given by (26), we find that the exponent γ n grows linearly with n, that is ( figure 3) γ n ∼ n.
Since p k = n≥1 g n p n,k and since g n increases with n, the dominant contribution to the distribution p k comes from first generation nodes. Hence, γ ≡ γ 1 . This behavior is in contrast with the preferential attachment network where the behavior at the average generation dominates the degree distribution [33]. For completeness, we mention that the in-component distribution mimics the degree distribution. The degree of the in-component of a node is defined as the total number of its descendants. The quantity h tot above is always finite and hence, the total number of descendants of the most connected nodes is proportional to the degree. As consequence, the fraction I s of nodes with in-component degree s decays algebraically, I s ∼ s −γ .

VI. LEAVES, STARS, AND CHAINS
It is also possible to calculate a few other structural properties of the network including the average number of leaves as well as the probabilities that the network has an extreme structure such as a star or a chain.
Nodes with no incoming links, or equivalently, nodes with degree one are termed leaves. To calculate the total number of leaves, we must first find a more detailed quantity: L n (N ), the total number of leaves at the jth generation. This quantity evolves as follows Each new node is necessarily a leaf and hence, the gain term is as in (3). The loss term reflects the fact that any new link into a leaf decreases the number of leaves by one.
We assume that the number of leaves in each generation is macroscopic, By substituting this form into the rate equation (33), we find that leaves constitute a finite fraction of all nodes in each generation, ℓ n = n+1 n+2 g n , or equivalently, ℓ n = e −1 n(n + 1) 2 (n + 2)! .
The fraction of leaves grows with depth: 2/3 of all nodes in the first generation are leaves; 3/4 of all nodes in the second generation are leaves; etc. The total number of leaves, L tot , is the sum L tot = n≥1 L n and from (35), we obtain As is often the case in complex networks, a large fraction of all nodes have no incoming links. It is also possible to calculate the likelihood that the tree has one of two extreme topologies: (i) a star where all nodes link to the root, and (ii) a linear chain of length N . Let S N be the probability that the tree is a star graph. This probability satisfies the recursion The network is a star graph only if it was previously a star. Furthermore, the factor 1/N is the probability that the root is the target node and the factor (N − 1)/(2N ) is the probability that the target node is any one of the N −1 leaves, but the actual link is made to the root. With the boundary condition S 1 = S 2 = 1, the probability S N decays exponentially with the network size, The likelihood that the tree has a chain topology, C N , obeys the recursion equation C N +1 = C N /N 2 . This recursion reflects that the newest node must always be selected both as the target node and as the attachment node. The probability for this event is 1/N 2 . Using the boundary condition C 2 = C 3 = 1, the likelihood of growing a chain decays extremely rapidly, Therefore, it is far more likely that the random ancestor tree is a star than it is a chain. This is another consequence of the shallow nature of the tree.

VII. CONCLUSIONS
We introduced a random structure where the genealogy governs the evolution. The random ancestor tree has a remarkably rich structure. The network is very tight with a sharply-decaying distribution of depth. There is a single macroscopic hub that is connected to a finite fraction of all nodes along with multiple highly connected nodes.
The network is strongly stratified because the genealogical structure controls the growth. The most connected node at distance n from the hub has a submacroscopic degree that scales as N 1/βn with system size N . Interestingly, the exponents β n are generally transcendental numbers. Moreover, the exponents β n grow monotonically with n, and thus, the connectivity sharply declines with increasing depth. As a consequence, the degree distribution has power-law tail, p k ∼ k −γ with γ = β 1 +1 and furthermore, the degree distribution varies strongly with depth.
We obtained all of these features analytically using the total number of descendants of a highly connected node as a function of generation. This quantity obeys a closed set of equations and it allows us to determine many scaling properties including in particular, the exponent that governs the tail of the degree distribution. This theoretical technique has promise in other growing trees problems when the degree distribution does not satisfy closed equations [24,34], especially in situations where the distribution of depth becomes independent of system size asymptotically.
The random ancestor tree includes no control parameters but can be easily generalized by various modifications of the attachment process. More generally, the target node can be selected at a rate that is proportional to the degree and similarly, the attachment node can be determined according to either the generation number or the degree. We envision that such generalizations can be useful for controlling the degree distribution or the number of macroscopic hubs and hence, relevant for modeling complex networks. The most challenging generalization is the theoretical understanding of ancestor networks with cycles.