Next Article in Journal
Entropy Wake Law for Streamwise Velocity Profiles in Smooth Rectangular Open Channels
Next Article in Special Issue
The Smoluchowski Ensemble—Statistical Mechanics of Aggregation
Previous Article in Journal
Temporal–Spatial Evolution of Kinetic and Thermal Energy Dissipation Rates in a Three-Dimensional Turbulent Rayleigh–Taylor Mixing Zone
Previous Article in Special Issue
Ensembles of Atoms, Ensembles of Species: Comparative Statistical Mechanics
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Network Rewiring in the r-K Plane

Faculty of Science and Technology, Free University of Bozen-Bolzano, 39100 Bolzano, Italy
*
Author to whom correspondence should be addressed.
Entropy 2020, 22(6), 653; https://doi.org/10.3390/e22060653
Submission received: 15 April 2020 / Revised: 10 June 2020 / Accepted: 11 June 2020 / Published: 13 June 2020
(This article belongs to the Special Issue Generalized Statistical Thermodynamics)

Abstract

:
We generate correlated scale-free networks in the configuration model through a new rewiring algorithm that allows one to tune the Newman assortativity coefficient r and the average degree of the nearest neighbors K (in the range 1 r 1 , K k ). At each attempted rewiring step, local variations Δ r and Δ K are computed and then the step is accepted according to a standard Metropolis probability exp ( ± Δ r / T ) , where T is a variable temperature. We prove a general relation between Δ r and Δ K , thus finding a connection between two variables that have very different definitions and topological meaning. We describe rewiring trajectories in the r-K plane and explore the limits of maximally assortative and disassortative networks, including the case of small minimum degree ( k m i n 1 ), which has previously not been considered. The size of the giant component and the entropy of the network are monitored in the rewiring. The average number of second neighbors in the branching approximation z ¯ 2 , B is proven to be constant in the rewiring, and independent from the correlations for Markovian networks. As a function of the degree, however, the number of second neighbors gives useful information on the network connectivity and is also monitored.

1. Introduction

Rewiring algorithms are often employed in network science to build “synthetic networks” for the mathematical modeling of dynamics or diffusion processes [1,2,3,4,5]. Usually, rewiring algorithms preserve the degree distribution of the network while changing the degree correlations and other topological features.
The “configuration model” [6] is a well established generalization of the random networks of Erdös-Renyi which yields uncorrelated networks having a pre-assigned (typically scale-free) degree distribution. It is known, however, that assortative and disassortative correlations play an important role in dynamics and diffusion on networks [7,8,9,10,11]. For this reason some algorithms have been devised, which are able to perform a degree-conserving rewiring while modifying the pair correlations in the direction of increasing assortativity or disassortativity.
It is also possible to rewire the network in order to change its clustering coefficient (see [12] and references) or other metrics, but in this work the focus is on assortativity and disassortativity as measured by the Newman coefficient r, and on the average nearest neighbors degree function k n n ( k ) , or better on its network average K k n n ( k ) = k P ( k ) k n n ( k ) . Here, P ( k ) is the degree distribution, P ( h | k ) denotes the conditional probability for a node of degree k to be connected to a node of degree h, and k n n ( k ) = k h P ( h | k ) .
The algorithm by Xulvi-Brunet and Sokolov [13] is quite efficient for generating networks that are maximally assortative or maximally disassortative, or even have an intermediate r coefficient, if a tunable return probability is inserted in the rewiring criterion. It does not allow, however, any direct control of the degree correlations e j k or P ( h | k ) , the r coefficient or the k n n function. (We recall that e j k is the probability for a node with excess degree j, i.e., degree ( j + 1 ) , to be connected with a node with excess degree k.).
The rewiring method proposed by Newman [1] allows in principle to generate ensembles of networks displaying, on average, any “target” two-point correlations assigned through an e j k matrix compatible with the given degree distribution. There exist several recipes for the construction of such matrices in the case of scale-free networks [1,14,15].
We have recently proposed a new algorithm [16] that is equivalent to the algorithm of [13] when applied to maximally assortative or disassortative networks, but allows at each step the control of the variation Δ r in the Newman coefficient, and therefore permits the introduction of a rewiring “temperature” T in order to tune the return probability via a standard Metropolis update.
It is known that in many classes of networks, no simple method for the creation of random networks of the class exists [3]. In these cases a Monte Carlo method is usually invoked. The desired network class is determined by an energy function, which is defined on a network configuration. The lower the function is, the more desirable are the properties of the network. For a good performance of the algorithm, the energy function should be calculable locally. That is, the change in energy between configurations should depend only on the changed links and possibly some near neighbors, so calculating the new energy should not require recalculating the energy for the entire network. Our proposed method improves previous methods since it satisfies these properties by using Δ r as energy variation.
In order to increase the convergence probability of Metropolis algorithms it is sometimes attempted to start with a high temperature, making all moves probable and covering the entire configuration space, and gradually decrease the temperature in order to approach the real energy minimum (procedure of ”simulated annealing”). This is also possible in principle with our method, but it should be stressed that in general rewiring algorithms do not sample uniformly through spaces of networks (see for instance [17,18,19] and references), and that the more features one wants to preserve in the rewiring, the less successful sampling is. Therefore our rewiring algorithm, like the other cited algorithms for changing network correlations, cannot be used as a randomization procedure. Another reason for this is that these algorithms may generate multiple copies of isomorphic random networks, and so cause over-counting in the sampling.
One of the aims of this work is to clarify the relations existing among these rewiring methods and the asymptotic constraints on maximally assortative and disassortative networks found by Menche et al. [20]. Using our “ Δ r -rewiring” we have also been able to see the effects of extreme assortativity and disassortativity in networks with many nodes of small degree. These were not considered by the authors of [20], who took as a minimum degree a typical value k 0 = 6 and therefore found in general highly connected networks with a very large giant component.
The study of complex networks is often motivated by the interest for the dynamics of some diffusion problem on top of them. Clearly, if a mean-field approximation of the dynamics or diffusion on the network is sufficient for one’s purposes, then the corresponding equations can be written, analyzed, or solved in terms of the excess-degree correlations e j k or in terms of the degree distribution P ( k ) plus the conditional probabilities P ( h | k ) (the so-called probabilistic or “Markovian” description of the network). If, on the other hand, a full realization of the network is needed (e.g., for simulations or stochastic modeling, or because one wants to take into account the effect of correlations beyond the second order), then several issues arise, for example:
  • Is it possible to build any desired assortative or disassortative network, defined at the probabilistic level through a suitable “theoretical” e j k matrix, using a Newman rewiring, at least at the ensemble level? What is in this respect the role of the asymptotic constraints on r? Can the asymptotic constraints tell us in advance that a certain theoretical e j k is impossible to be implemented in a real network?
  • Among the networks obtained through a Xulvi–Brunet–Sokolov rewiring or our Δ r rewiring, will one find the desired assortative or disassortative network? If yes, with what accuracy is this possible, compared to the Newman rewiring?
  • How do the results (and their level of fluctuations and uncertainty) change if we modify the degree distribution, and especially the probability of the nodes with the lowest degree? Will a giant component always be present? If the network is much fragmented, what are the consequences for diffusion processes?
As this work was progressing, we gradually realized that such issues are hard to solve in general terms. We found partial answers, but we chose to leave most of them for a forthcoming publication. Still the efforts described in this work have already led to some useful spin-offs. In an attempt to obtain a better characterization of the rewiring process, we have represented the state of the network in an r-K plane trying to use K as a “coordinate” independent from r. This brought us first to a revision of the meaning and of the properties of K (Section 2, Section 2.1, and Section 2.2) and then to establish a new general relation between the variations of r and K in a rewiring step (Section 2.3 and Section 2.4). This relation has been proven theoretically and verified numerically through the rewiring code. The code has also allowed to guess some related properties of the quantity z ¯ 2 , B (average number of second neighbors in the branching approximation), which have been proven theoretically in Section 3, although they are not strictly necessary for the rest of the present work.
In Section 4, we describe the main features of the rewiring code and the procedure for the calculation of the entropy of the generated networks. In Section 5.1 we describe the “rewiring trajectories” in the r-K plane obtained for some different values of the scale-free exponent γ ( γ = 2.25, 2.5, 2.75, 3) starting from uncorrelated networks and performing an assortative or disassortative rewiring at a low temperature, i.e., with small return probability. For some of the cases a qualitative description is given of the “super-assortative” and “super-disassortative” asymptotic networks generated. Section 5.2 describes the preliminary results of the assortative rewiring in equilibrium at variable temperature T, with a plot showing the case γ = 2.5 , as a function of T, the values of the entropy S, of r , K , and the size of the giant component. Section 6 contains our conclusions.

2. The Function “Average Degree of the First Neighbors” K N

The quantity k n n ( k ) N , introduced by Boguñá et al. [21], is defined as:
k n n ( k ) N = K N = k = 1 n P ( k ) k n n ( k ) .
We shall denote it for simplicity K, or K N , since for a given type of network it depends only on its size, namely on the number N of nodes (related in turn to the maximum degree n, for scale-free networks, through the Dorogovtsev–Mendes criterion as detailed in Equation (3)). Since k n n ( k ) amounts to the average degree of the first neighbors of a node of degree k and P ( k ) is the probability that such a node is present, K N is the average degree of the first neighbors taken over the entire network, or better the average degree of the first neighbors of a randomly chosen node. Generally speaking, K N is strongly related to the diffusion properties of the network.
The definition above is probabilistic, and used for Markovian networks and for applications to mean-field equations on these networks. If we have complete knowledge of the network, we can compute K exactly by just looking at the first neighbors of each node and computing a total average of their degrees (see Section 4).
The authors of [21] prove that as a function of N, K N is diverging when N in a scale-free network with exponent 2 < γ 3 , for any kind of correlations (at least when the function k n n ( k ) has a certain form). This property is employed to conclude that in the “thermodinamic” limit of large N, phenomena of epidemic diffusion always propagate to the entire network, no matter how small the contagion probability is (“absence of epidemic threshold”). The intuitive reason is that although the average number of neighbors k tends to a constant for large N, the average degree of these neighbors tends to infinity. This means that each node is very close to a hub from which the epidemics can easily spread.
In the following two sub-sections we give some examples of computation of the function K N in Markovian networks, as an introduction to the results obtained through the rewiring of real networks.

2.1. Uncorrelated Networks

For an uncorrelated network we obtain for K N a simple expression. We have in this case:
P ( h | k ) = h P ( h ) k .
Therefore k n n ( k ) does not depend on k:
k n n ( k ) = 1 k h = 1 n h 2 P ( h ) = k 2 k ,
and
K N = k = 1 n k n n ( k ) P ( k ) = k 2 k k ,
where we have used the normalization condition k = 1 n P ( k ) = 1 and the last inequality is due to the fact that in general k 2 k 2 .
The inequality K N k expresses the well-known property that in an uncorrelated network, from the point of view of one node looking at its first neighbors, on the average “my friends have more friends than me” (because their average degree is K N and my degree is k). As we shall see, this property is also numerically confirmed for correlated networks, at least in the scale-free case.
The dependence from N in the expression of Equation (2) for K N arises as follows. First note that when we consider a finite network with maximal degree n, the normalization condition of P ( k ) is k = 1 n P ( k ) = 1 . Therefore the properly normalized degree distribution P ( k ) for a scale-free network is:
P ( k ) = c n , γ k γ , c n , γ 1 = k = 1 n k γ .
The quantities k and k 2 , respectively equal to k = 1 n k P ( k ) and k = 1 n k 2 P ( k ) , depend on n through the factor c n , γ and the upper limit of the sum. However, in the limit of large n the factor c n , γ tends to a constant and k = 1 n k P ( k ) is convergent for 2 < γ 3 ; the dependence of K N on n comes from the divergent series k = 1 n k 2 P ( k ) .
Approximating with an integral the dependence of the series on its upper limit, we obtain for large n:
k 2 1 n k 2 γ d k n 3 γ for 2 < γ < 3 ,
and
k 2 ln ( n ) for γ = 3 .
Of course, for k close to 1 the integral is not a good approximation of the series; furthermore, if the sum starts from a value k m i n > 1 , the factor c n , γ has a substantial dependence on k m i n (see Table 1), as we shall later see in some examples. Here, however, we are interested into the divergent dependence of K on n.
In order to relate the maximum degree n to the number of nodes N we make recourse to the integral criterium of Dorogovtsev–Mendes [22], which states that the probability to have in the network a node with degree in the range ( n , + ) must be equal to 1, implying:
n c n , γ k γ d k = 1 N .
From this we obtain the known relation:
γ 1 c n , γ n γ 1 = N .
An example of exact values of the various quantities involved is given in Table 1.

2.2. Correlated Networks

In order to obtain K N for a correlated network we must compute numerically the sum over k starting from an explicit expression for k n n ( k ) , if known, or else expressing also k n n ( k ) as a sum, according to its definition k n n ( k ) = h = 1 n h P ( h | k ) .
A simple formula which defines assortative correlations has been proposed by Vazquez and Weigt [14] and has been employed in [24] for diffusion studies. It is a linear combination of an uncorrelated term and a totally assortative term proportional to δ h k , namely:
P ( h | k ) = ( 1 r ) h P ( h ) k + r δ h k ,
where r ranges from 0 to 1 and coincides with the Newman assortativity coefficient.
From this matrix one obtains:
k n n ( k ) = ( 1 r ) k 2 k + r k ,
whence
K N = ( 1 r ) k 2 k + r k .
It follows that for fixed n (which also fixes k and k 2 ), when r 1 one has K N k , corresponding to the fact that in the case of extreme assortativity each node is only connected with other nodes having the same degree. We shall show in forthcoming work, however, that for a real scale-free network this limit is purely hypothetical, because the function k n n ( k ) cannot increase linearly for large k, but eventually must decrease.
Further evaluations of K N as a function of N for assortative networks, built using a different set of P ( h | k ) matrices [15,25], and for disassortative networks will be given elsewhere.
In any case, for fixed N the value of K is quite useful in characterizing the network and depends strongly on the type of correlations, on the scale-free exponent and on the minimum degree. A first example is given in Table 1 for Markovian networks. Then in Section 5.1 and Section 5.2 we investigate the behavior of K for real rewired networks. An exact direct calculation of K from the list of links of a real network can be efficiently implemented and compared with the average value of K obtained from the k n n function.

2.3. Local Variation of K

The variation of K in a rewiring step is obtained using its definition as the average degree of the first neighbors of each node, averaged over the whole network. Let A , B , C , D denote respectively the degrees of the nodes a , b , c , d involved in the rewiring (see Figure 1). Let σ a denote the sum of the degrees of the first neighbors of the node a, which are not involved in the rewiring, and similarly define σ b , σ c , σ d . Before the rewiring the averages s a , s b , s c , s d of the degrees of the first neighbors of a , b , c , d  are:
s a = σ a + B A ; s b = σ b + A B ; s c = σ c + D C ; s d = σ d + C D .
After the rewiring, these quantities become:
s a = σ a + C A ; s b = σ b + D B ; s c = σ c + A C ; s d = σ d + B D .
Therefore the change in the total average K is:
Δ K = 1 N C A + D B + A C + B D B A + A B + D C + C D .

2.4. Relation between the Local Variations of K and r

In previous work [16] we found an expression for the local variation of the Newman coefficient in a rewiring of the same kind as in Figure 1. The variation is given by:
Δ r = 2 ( A B C D + A C + B D ) L σ q 2 ,
where L is the number of links in the network and σ q 2 is the denominator of the fraction which defines r, namely:
r = 1 σ q 2 j , k = 0 n 1 j k ( e j k q j q k ) ,
σ q 2 = k = 0 n 1 k 2 q k k = 0 n 1 k q k 2 .
Here e j k is the probability of finding in the network a link between nodes with excess-degrees j and k and q k = j = 0 n 1 e j k is the excess-degree distribution. Note that q k and σ q 2 depend on the degree distribution but not on the correlations. Also note that in [16] a slightly different notation is used, in which A , B , C , D denote directly the excess-degrees. However, since:
( A 1 ) ( B 1 ) ( C 1 ) ( D 1 ) + ( A 1 ) ( C 1 ) + ( B 1 ) ( D 1 ) = A B C D + A C + B D ,
we can safely use Equation (6) according to the conventions of this paper, where A , B , C , D are the degrees and not the excess-degrees.
After some algebraic manipulations it is possible to express the variation Δ K in Equation (5) in terms of Δ r , thus establishing a relation between two quantities which have very different definitions and topological meaning. We find:
Δ K = L σ q 2 2 N ( A D + B C ) A B C D Δ r .
This holds for each rewiring. The factor L σ q 2 / ( 2 N ) is fixed for a given degree distribution, while the factor ( A D + B C ) / ( A B C D ) clearly depends on the nodes involved; we only know a priori that it is always positive, and as a consequence Δ K is always opposite to Δ r and Δ K = 0 if and only if Δ r = 0 . For the rewiring trajectories described in Section 5.1 the ratio Δ K / Δ r , averaged over many rewirings, turns out to be approximately constant for a given degree distribution; see data in Table 2.

3. The Average Number of Second Neighbors z ¯ 2 , B

The condition for the existence of a giant component in an uncorrelated network with arbitrary degree distribution has been first found by Molloy and Reed [26] and is expressed by the inequality:
k 2 2 k > 0 .
Later the same condition has been proven by Newman, Strogatz, and Watts with the method of the generating functions, which also allows one to find the size of the giant component [27]. In [27] the inequality in Equation (10) is reformulated in an intuitive way by stating that the giant component exists when z ¯ 2 > k , where z ¯ 2 is the average number of second neighbors and k (the average degree) can also be interpreted as the average number of first neighbors. A crucial underlying assumption is that the network is locally a branching structure; moreover, being the network uncorrelated, one supposes that there are no preferences in linking behavior depending on the node degrees and that therefore it makes sense to consider total averages like z ¯ 2 and k .
We are now going to define a quantity that is closely related to z ¯ 2 and will show that starting from the intuitive “percolation” condition z ¯ 2 > k , Equation (10) can be immediately obtained without using the generating functions.
We call this quantity “average number of second neighbors in the branching approximation” and denote it by z ¯ 2 , B . It is a network average like z ¯ 2 , but includes by definition multiple counting in the case of shared second neighbors. More precisely, if one node a 0 has a second neighbor b in common with other h nodes a 1 , , a h , then b is counted h + 1 times in the average z ¯ 2 , B . The two quantities z ¯ 2 and z ¯ 2 , B coincide if the network is a pure branching structure, without nodes that have second neighbors in common with other nodes.
According to this definition, z ¯ 2 , B can be obtained as:
z ¯ 2 , B = k P ( k ) k [ k n n ( k ) 1 ] ,
because the probability for a node to have degree k is P ( k ) , the node has k first neighbors and their average degree is k n n ( k ) .
Let us compute z ¯ 2 , B for an uncorrelated network:
z ¯ 2 , B = k P ( k ) k [ k n n ( k ) 1 ] = k P ( k ) k k 2 k 1 =
= k 2 k 1 k = k 2 k ( uncorrelated network ) .
This expression gives the Molloy–Reed condition if we require z ¯ 2 > k and admit that the network is a locally branching structure such that z ¯ 2 z ¯ 2 , B .
Equation (11) for z ¯ 2 , B is interesting in itself and we have used our code for the configuration model with rewiring in order to test it. The code generates a list, called the “Friends” list, of the first neighbors of each node. The list is updated and used in many parts of the program, for instance after the first wiring of the stubs, in order to check that the nodes’ degrees match the prescribed degree distribution. It is also used at the end of the rewiring cycles, in order to find the giant component of the final network, and possibly for the numerical solution of diffusion equations in first or second closure approximation. It is straightforward to use the Friends list to also obtain the number of second neighbors of each node, because the degrees of the nodes do not change in the rewiring and are stored in a vector “Degrees[i]”, with i = 1 , , N , fixed from the degree distribution before the wiring. The contribution to z ¯ 2 , B from each node is obtained as the sum of (degree of each friend − 1). The total network average z ¯ 2 , B is the sum of the contributions of all nodes, divided by N. One can check that the exact value obtained in this way is well approximated by the probabilistic value in Equation (11).
Somewhat unexpectedly, the exact obtained value of z ¯ 2 , B is accurately reproduced in each simulation with the same degree distribution, signaling that it is not affected by the rewiring. In fact, the following two properties hold, which are not difficult to prove but cannot be found in the literature, to the best of our knowledge.
Property 1
(Property of z ¯ 2 , B ). For Markovian networks which satisfy the Network Closure Condition h P ( k | h ) P ( h ) = k P ( h | k ) P ( k ) , z ¯ 2 , B does not depend on the correlations but only on the degree distribution, and it is equal to the value k 2 k obtained for an uncorrelated network having that degree distribution (Equation (13)).
In fact the first term on the r.h.s. in Equation (11), namely k P ( k ) k k n n ( k ) , is equal to k 2 , as already noted in [21]:
k P ( k ) k k n n ( k ) = k P ( k ) k h h P ( h | k ) =
= k h P ( k ) k h P ( h | k ) = k h h h P ( k | h ) P ( h ) =
= h h 2 P ( h ) k P ( k | h ) = k 2
(because k P ( k | h ) = 1 ). The second term is equal to k , which is fixed if the degree distribution is fixed.
Property 2
(Property of z ¯ 2 , B ). z ¯ 2 , B does not change in a binary rewiring which preserves the degree distribution.
This is a direct consequence of the definition of the rewiring (see Figure 1). Let σ a denote, as before, the sum of the degrees of the first neighbors of the node a which are not involved in the rewiring, and similarly define σ b , σ c , σ d . Let A , B , C , D denote the degrees of the nodes. The total number of second neighbors of the four nodes involved in the rewiring is equal, before the rewiring, to:
z 2 , B b e f o r e ( a , b , c , d ) = ( σ a A + B 1 ) + ( σ b B + A 1 ) + ( σ C C + D 1 ) + ( σ D D + C 1 ) .
After the rewiring we have:
z 2 , B a f t e r ( a , b , c , d ) = ( σ a A + C 1 ) + ( σ b B + D 1 ) + ( σ C C + A 1 ) + ( σ D D + B 1 ) ,
and the two quantities are equal.
These properties offer a strong indication for the absence of epidemic threshold in correlated large scale-free networks with 2 < γ 3 . In fact, in this range of γ , z ¯ 2 , B diverges when N . Denoting by λ the contagion probability for one single contact, consider an infected node randomly chosen, thus with the average degree k . The probability that the node infects one of its neighbors is k λ , which tends to zero if λ is very small. However, the probability that the node infects one of its second neighbors is (for a locally branching structure) equal to z ¯ 2 , B λ 2 , and this quantity can stay finite even as λ 0 , because of the divergence of z ¯ 2 , B , independently from the degree correlations.

4. The Rewiring Algorithm

In the first part of the algorithm, the “wiring” part, we generate a series of 2 L “stubs” with given degree distribution, like in any implementation of the configuration model. The exact procedure for assigning the degrees to the hubs has two possible alternatives and has been described in [16]. In the first alternative (“cumulative hubs”), the probability of hubs for which P ( k ) · N < 1 is cumulated with increasing k until it exceeds 1, at which point the hub is created and the accumulation starts again. In the second alternative (“random hubs”), hubs of degree k are created entirely at random with probability P ( k ) · N .
For a description of the linking of the stubs the reader is referred to [16]. Details of this procedure are little relevant because the extensive rewiring that follows cancels any memory of the initial wiring scheme.
When we perform a rewiring step, we choose at random two links in the current list of links describing the network, say ( a , b ) and ( c , d ) (nodes are identified by a sequential number in the range 1 , , N , so a , b , c , d denote this number). With a probability of 50% we exchange a and b, to avoid any asymmetry, and then we build the new links ( a , c ) , ( b , d ) . In order to avoid the formation of loops, the rewiring is not performed if a = c or b = d . The formation of multi-links (more than one link between the same two nodes) is avoided through a check of the adjacency matrix [ A a b ] , which is computed from the list of links before the rewiring cycle and updated after each rewiring according to formulas:
A a b A a b 1 ; A c d A c d 1 ; A a c A a c + 1 ; A b d A b d + 1
(plus the symmetrical variations for A b a etc.).
The knowledge of the adjacency matrix also allows one to compute the Shannon entropy of the network (see [28] and references) by ensemble-averaging A over sub-cycles. For instance, consider a typical rewiring cycle with 100 sub-cycles of 10 4 steps each, for a network with N = 10 3 . The values of A a b , with a , b = 1 , , N at the end of each sub-cycle are averaged to compute S according to the formula:
S = a , b = 1 N A ¯ a b ln A ¯ a b + ( 1 A ¯ a b ) ln ( 1 A ¯ a b ) ; A ¯ a b = A a b s u b c y c l e s .
The number of sub-cycles is increased until the result stabilizes. The averages of r and K are also computed in the same way. A long rewiring process of this kind is used to compute S and other quantities as functions of the temperature; see results in Section 5.2.
When the rewiring temperature is very low one can actually observe that the value of r changes by 10 5 or less, and the entropy becomes very small. This is because when the network is very close to its maximum possible assortativity or disassortativity, almost all rewiring steps are rejected, changes in r are very small and the adjacency matrix remains practically constant (thus A ¯ a b is either very close to 0 or 1, with small contribution to S).
In its present form the algorithm has been applied to relatively small networks ( N < 10 4 nodes), because the double sum involved in the calculation of the entropy has N 2 terms and the average adjacency matrix A ¯ requires much memory. For such values of N the part of the code which performs the rewiring is quite fast, taking at most a few seconds to complete. If one wants to apply the rewiring to larger networks without computing the entropy, a check of the adjacency matrix A will still be needed (especially in the assortative case) in order to avoid the formation of multi-link. However, in that case A should be handled as a sparse integer matrix, thus lowering the memory requirements.

5. Results

5.1. Trajectories of Assortative and Disassortative Rewiring in the r-K Plane at Low T

Let us first describe the “trajectories” (see examples in Figure 2 and Figure 3), which are generated in the r-K plane when we make a rewiring of the assortative kind, i.e., with the rewiring step always accepted when Δ r > 0 and accepted with probability exp ( | Δ r | / T ) when Δ r < 0 . The rewiring cycles described in this section are relatively short, in comparison to those of Section 5.2, in which we need to reach equilibrium, and T can be large.
The starting point of each trajectory is a network generated through a completely random rewiring. Note that especially for the lower values of γ this “configuration model” network is not uncorrelated, but displays some structural disassortativity.
We observe at the beginning a rapid increase of r along the trajectory. For instance, for a network with 1500 nodes, in Figure 2 the data points represent the values of r and K during 80 sub-cycles of 100 rewirings each. The temperature T is chosen to be quite low, compared to the magnitude order of the variation Δ r . The latter is of the order of 10 3 as deduced from Equation (6) and Table 2. With these values and units, a temperature of 10 6 is sufficiently low to give a very small return probability in the Metropolis algorithm and to make the networks evolve quickly and almost without fluctuations towards their maximum possible assortativity.
The points on the trajectory are seen to converge to a final spot, and typically if we perform 50 sub-cycles of 10,000 steps (not shown in the figure), which take about one second to be completed, the values of r and K become constant up to the sixth decimal digit. This value, however, depends on the degrees of the hubs effectively present in the network and is reproducible in different runs only if the hubs are generated with the method of cumulative probability (see Section 4).
If at this stage we compute the Shannon entropy S according to Equation (14), we find S = 0 exactly. This means that at this temperature the assortative rewiring causes the network in the long run to evolve towards a unique “asymptotic” state.
The maximum and minimum values (asymptotic values) that can be obtained for the r coefficient of scale-free networks have been extensively studied in [20]. Those results, however, are referred to networks whose minimum degree is relatively large, typically k m i n = 6 ; such networks are usually completely connected (giant component equal to 100%). In this work we take instead k m i n = 1 , because we are also interested in the network “fragmentation” caused by the strong assortativity and disassortativity. The giant component we find can be very small, down to 10% or less. Most of the asymptotic networks consist, in the assortative case, of isolated couples made of nodes of degree k = 1 , and then of long chains with variable length, open or closed, made of nodes of degree k = 2 . Such structures can be easily identified in a complete graphical representation of the network or more “economically” in the table of the values of the number z 2 of second neighbors of each node. For instance, for each node of degree 1 belonging to a couple we obviously have z 2 = 0 , and for each node of degree 2 belonging to a chain we have z 2 = 2 (except at the ends of the chain). Another less obvious occurrence observed in strongly disassortative networks is shown in Figure 4 and involves nodes of degree 3.
In the extreme assortative case the giant component contains all the major hubs, strongly connected among themselves. From the strongly connected core depart long chains (see an example in Figure 5) whose connection or disconnection to the core affects the size of giant component, but has very little influence on the value of r. In other words, a rewiring in which long chains are connected or disconnected at their ends can easily occur also at low temperature, with little effect on r and on the entropy.
In the extreme disassortative case, especially for γ close to 3, it may happen that the network is completely fragmented and there is no giant component. One example is shown in Figure 6. These kinds of networks have been studied theoretically in [29]. In addition, in this case the table of values of the number z 2 of second neighbors is useful in order to identify some patterns without the need to visualize the entire network. For instance, all the hubs of the network in Figure 6 have z 2 = 0 exactly.

5.2. Equilibrium Rewiring at Variable T

In this subsection we report some preliminary results from assortative rewiring cycles performed at variable temperature, in the range 10 5 T 10 2 . These rewiring cycles consist of several long sub-cycles (typically 100 sub-cycles of 10 4 rewiring steps), such that the equilibrium is attained and entropy can be measured by averaging the adjacency matrix on each sub-cycle. We recall (see Section 5.1) that the value of the temperature for the rewiring algorithm must refer to the magnitude order of the variations of r, and this depends in turn on the number of nodes.
The data are still quite noisy and more statistics need to be accumulated for different values of γ , followed by extension to the case of disassortative rewiring. One of the objectives of these measurements is to verify the conjecture of [28] that disassortative networks are entropically favored. Another interesting suggestion from the data in Figure 7 is that there is a correlation between K and the size of the giant component, as T varies. The exact anticorrelation between r and K according to Equation (9) is also evident.

6. Conclusions

The method of assortative and disassortative rewiring at variable T that we presented in this work appeared to be quite effective for the generation of correlated scale-free networks. At each step of the rewiring process, our algorithm permitted a control of the variations of the assortativity coefficient r and of the average degree of the nearest neighbors K. The two variations were actually connected through a general relation that we have proven in Section 2.4.
We also proved that the average number z ¯ 2 , B of second neighbors in the branching approximation was constant in the rewiring. This property provided further evidence for the absence of epidemic threshold in scale-free networks with exponent γ in the range 2 < γ 3 .
If we represented an assortative or disassortative rewiring process at low temperature (i.e., with low return probability) in a r-K plane, we obtained an almost linear trajectory converging towards a point, which represents the maximally assortative or disassortative network having the given degree distribution. The position of the trajectory in the plane and its (negative) slope depended on the exponent γ . In general, the value of K was smaller for assortative networks, compared to uncorrelated or disassortative networks having the same degree distribution. For a fixed value of r, K was larger when γ was smaller, therefore the trajectories with small γ lie in the upper part of the plane.
The features of super-assortative and super-disassortative networks were found to depend quite strongly, for a given γ , on the minimum and maximum degree present in the network.
Preliminary evaluations of the network entropy, the size GC of the giant component, K and r as functions of the rewiring temperature confirmed the exact anti-correlation between r and K and indicated a positive correlation between K and GC.

Author Contributions

Conceptualization, M.L.B. and G.M.; Formal analysis, M.L.B. and G.M.; Writing—original draft, M.L.B. and G.M. All authors have read and agreed to the published version of the manuscript.

Funding

This work was supported by the Open Access Publishing Fund of the Free University of Bozen-Bolzano.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Newman, M. Mixing patterns in networks. Phys. Rev. E 2003, 67, 026126. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  2. Boccaletti, S.; Latora, V.; Moreno, Y.; Chavez, M.; Hwang, D.U. Complex networks: Structure and dynamics. Phys. Rep. 2006, 424, 175–308. [Google Scholar] [CrossRef]
  3. Cohen, R.; Havlin, S. Complex Networks: Structure, Robustness and Function; Cambridge University Press: Cambridge, UK, 2010. [Google Scholar]
  4. Pastor-Satorras, R.; Castellano, C.; Van Mieghem, P.; Vespignani, A. Epidemic processes in complex networks. Rev. Mod. Phys. 2015, 87, 925. [Google Scholar] [CrossRef] [Green Version]
  5. Barabási, A.L. Network Science; Cambridge University Press: Cambridge, UK, 2016. [Google Scholar]
  6. Newman, M. Networks: An Introduction; Oxford University Press: Oxford, UK, 2010. [Google Scholar]
  7. Newman, M. Assortative mixing in networks. Phys. Rev. Lett. 2002, 89, 208701. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  8. Van Mieghem, P.; Wang, H.; Ge, X.; Tang, S.; Kuipers, F. Influence of assortativity and degree-preserving rewiring on the spectra of networks. Eur. Phys. J. B 2010, 76, 643–652. [Google Scholar] [CrossRef] [Green Version]
  9. D’Agostino, G.; Scala, A.; Zlatić, V.; Caldarelli, G. Robustness and assortativity for diffusion-like processes in scale-free networks. Europhys. Lett. 2012, 97, 68006. [Google Scholar] [CrossRef] [Green Version]
  10. Noldus, R.; Van Mieghem, P. Assortativity in complex networks. J. Complex Netw. 2015, 3, 507–542. [Google Scholar] [CrossRef] [Green Version]
  11. Arcagni, A.; Grassi, R.; Stefani, S.; Torriero, A. Higher order assortativity in complex networks. Eur. J. Oper. Res. 2017, 262, 708–719. [Google Scholar] [CrossRef] [Green Version]
  12. Alstott, J.; Klymko, C.; Pyzza, P.; Radcliffe, M. Local rewiring algorithms to increase clustering and grow a small world. J. Complex Netw. 2019, 7, 564–584. [Google Scholar] [CrossRef]
  13. Xulvi-Brunet, R.; Sokolov, I. Reshuffling scale-free networks: From random to assortative. Phys. Rev. E 2004, 70, 066102. [Google Scholar] [CrossRef] [Green Version]
  14. Vázquez, A.; Weigt, M. Computational complexity arising from degree correlations in networks. Phys. Rev. E 2003, 67, 027101. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  15. Bertotti, M.; Brunner, J.; Modanese, G. The Bass diffusion model on networks with correlations and inhomogeneous advertising. Chaos Soliton Fract. 2016, 90, 55–63. [Google Scholar] [CrossRef] [Green Version]
  16. Bertotti, M.; Modanese, G. The configuration model for Barabasi-Albert networks. Appl. Netw. Sci. 2019, 4, 32. [Google Scholar] [CrossRef] [Green Version]
  17. Ray, J.; Pinar, A.; Seshadhri, C. A stopping criterion for Markov chains when generating independent random graphs. J. Complex Netw. 2015, 3, 204–220. [Google Scholar] [CrossRef]
  18. Gray, C.; Mitchell, L.; Roughan, M. Generating connected random graphs. J. Complex Netw. 2019, 7, 896–912. [Google Scholar] [CrossRef]
  19. Cimini, G.; Squartini, T.; Saracco, F.; Garlaschelli, D.; Gabrielli, A.; Caldarelli, G. The statistical physics of real-world networks. Nat. Rev. Phys. 2019, 1, 58–71. [Google Scholar] [CrossRef] [Green Version]
  20. Menche, J.; Valleriani, A.; Lipowsky, R. Asymptotic properties of degree-correlated scale-free networks. Phys. Rev. E 2010, 81, 046103. [Google Scholar] [CrossRef] [Green Version]
  21. Boguñá, M.; Pastor-Satorras, R.; Vespignani, A. Epidemic spreading in complex networks with degree correlations. In Statistical Mechanics of Complex Networks; Springer: Berlin/Heidelberg, Germany, 2003; pp. 127–147. [Google Scholar]
  22. Dorogovtsev, S.; Mendes, J. Evolution of networks. Adv. Phys. 2002, 51, 1079–1187. [Google Scholar] [CrossRef] [Green Version]
  23. Silva, D.; Ferreira, S.C.; Cota, W.; Pastor-Satorras, R.; Castellano, C. Spectral properties and the accuracy of mean-field approaches for epidemics on correlated power-law networks. Phys. Rev. Res. 2019, 1, 033024. [Google Scholar] [CrossRef] [Green Version]
  24. Nekovee, M.; Moreno, Y.; Bianconi, G.; Marsili, M. Theory of rumour spreading in complex social networks. Physica A 2007, 374, 457–470. [Google Scholar] [CrossRef] [Green Version]
  25. Bertotti, M.; Modanese, G. On the evaluation of the takeoff time and of the peak time for innovation diffusion on assortative networks. Math. Comp. Model. Dyn. 2019, 25, 482–498. [Google Scholar] [CrossRef]
  26. Molloy, M.; Reed, B. A critical point for random graphs with a given degree sequence. Random Struct. Algor. 1995, 6, 161–180. [Google Scholar] [CrossRef]
  27. Newman, M.; Strogatz, S.; Watts, D. Random graphs with arbitrary degree distributions and their applications. Phys. Rev. E 2001, 64, 026118. [Google Scholar] [CrossRef] [Green Version]
  28. Johnson, S.; Torres, J.; Marro, J.; Muñoz, M. Entropic origin of disassortativity in complex networks. Phys. Rev. Lett. 2010, 104, 108702. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  29. Moreno, Y.; Vazquez, A. Disease spreading in structured scale-free networks. Eur. Phys. J. B 2003, 31, 265–271. [Google Scholar] [CrossRef] [Green Version]
Figure 1. Scheme of a rewiring which involves the nodes a , b , c , d and leaves their degrees A , B , C , D unchanged. Before the rewiring the links are ( a , b ) , ( c , d ) . After the rewiring the links are ( a , c ) , ( b , d ) . Each node has in general other neighbors, not depicted; the sum of the degrees of the neighbors of a not involved in the rewiring is denoted in the text as σ a , and similarly for b , c , d .
Figure 1. Scheme of a rewiring which involves the nodes a , b , c , d and leaves their degrees A , B , C , D unchanged. Before the rewiring the links are ( a , b ) , ( c , d ) . After the rewiring the links are ( a , c ) , ( b , d ) . Each node has in general other neighbors, not depicted; the sum of the degrees of the neighbors of a not involved in the rewiring is denoted in the text as σ a , and similarly for b , c , d .
Entropy 22 00653 g001
Figure 2. Trajectories of assortative rewiring in the r-K plane. Each trajectory begins from the left (initial network obtained by uncorrelated rewiring) and converges to a maximally assortative network on the right. Between two dots on the same trajectory there are 100 rewiring steps with return probability exp ( Δ r / T ) , T = 10 6 . The number of nodes is N = 1500 .
Figure 2. Trajectories of assortative rewiring in the r-K plane. Each trajectory begins from the left (initial network obtained by uncorrelated rewiring) and converges to a maximally assortative network on the right. Between two dots on the same trajectory there are 100 rewiring steps with return probability exp ( Δ r / T ) , T = 10 6 . The number of nodes is N = 1500 .
Entropy 22 00653 g002
Figure 3. Trajectories of disassortative rewiring in the r-K plane. Each trajectory begins from the right (initial network obtained by uncorrelated rewiring) and converges to a maximally disassortative network on the left. Between two dots on the same trajectory there are 100 rewiring steps with return probability exp ( Δ r / T ) , T = 10 6 . The number of nodes is N = 1500 .
Figure 3. Trajectories of disassortative rewiring in the r-K plane. Each trajectory begins from the right (initial network obtained by uncorrelated rewiring) and converges to a maximally disassortative network on the left. Between two dots on the same trajectory there are 100 rewiring steps with return probability exp ( Δ r / T ) , T = 10 6 . The number of nodes is N = 1500 .
Entropy 22 00653 g003
Figure 4. Basic assortative building blocks classified through k (node degree) and z 2 (number of second neighbors). Looking at the table which gives for each node of a strongly assortative network the number z 2 of its second neighbors, we find a large number of nodes with k = 1 , z 2 = 0 (corresponding to Graph (1), isolated couples), of nodes with k = 2 , z 2 = 2 (corresponding to Graph (2), chains), and of nodes with k = 3 , z 2 = 6 (corresponding to Graph (3), linked 3-stars).
Figure 4. Basic assortative building blocks classified through k (node degree) and z 2 (number of second neighbors). Looking at the table which gives for each node of a strongly assortative network the number z 2 of its second neighbors, we find a large number of nodes with k = 1 , z 2 = 0 (corresponding to Graph (1), isolated couples), of nodes with k = 2 , z 2 = 2 (corresponding to Graph (2), chains), and of nodes with k = 3 , z 2 = 6 (corresponding to Graph (3), linked 3-stars).
Entropy 22 00653 g004
Figure 5. An example of a maximally assortative network with γ = 3 , k m i n = 2 . The minimum degree has been taken greater than 1 in this example in order to avoid the formation of isolated couples, which make up the large majority of maximally assortative networks if k m i n = 1 . The length of the chains and their connection or disconnection to the the giant component have only a little effect on the total r coefficient, and can therefore vary in each realization, even at a very low temperature (here T = 10 6 ).
Figure 5. An example of a maximally assortative network with γ = 3 , k m i n = 2 . The minimum degree has been taken greater than 1 in this example in order to avoid the formation of isolated couples, which make up the large majority of maximally assortative networks if k m i n = 1 . The length of the chains and their connection or disconnection to the the giant component have only a little effect on the total r coefficient, and can therefore vary in each realization, even at a very low temperature (here T = 10 6 ).
Entropy 22 00653 g005
Figure 6. Maximally disassortative network with γ = 2.75 , k m i n = 1 . The network is completely fragmented into “stars” (compare [29]). For all hubs the number of second neighbors is exactly zero.
Figure 6. Maximally disassortative network with γ = 2.75 , k m i n = 1 . The network is completely fragmented into “stars” (compare [29]). For all hubs the number of second neighbors is exactly zero.
Entropy 22 00653 g006
Figure 7. Assortative rewiring in equilibrium at different temperatures T. (Network of 1000 nodes, with γ = 2.5 , k m i n = 1 .) The entropy per node S / N is shown, along with the average degree of the first neighbors K, the Newman assortativity coefficient r multiplied by 10 (note the slight structural disassortativity at high temperature), and the fractional size of the giant component multiplied by 10.
Figure 7. Assortative rewiring in equilibrium at different temperatures T. (Network of 1000 nodes, with γ = 2.5 , k m i n = 1 .) The entropy per node S / N is shown, along with the average degree of the first neighbors K, the Newman assortativity coefficient r multiplied by 10 (note the slight structural disassortativity at high temperature), and the fractional size of the giant component multiplied by 10.
Entropy 22 00653 g007
Table 1. An example of values of K for Markovian networks with 1000 nodes in dependence on the scale-free exponent γ and the minimum degree k m i n , in the uncorrelated case, assortative case (Vazquez–Weigt recipe, Equation (4), with r = 0.5 ) and disassortive case (Porto–Weber recipe as employed in [23]).
Table 1. An example of values of K for Markovian networks with 1000 nodes in dependence on the scale-free exponent γ and the minimum degree k m i n , in the uncorrelated case, assortative case (Vazquez–Weigt recipe, Equation (4), with r = 0.5 ) and disassortive case (Porto–Weber recipe as employed in [23]).
γ k min Nn c n , γ k K (unc.)K (ass.)K (dis.) r dis
2.511000931.341.797.434.618.52−0.088
2.541000150.08966.237.396.8120.1−0.140
2.7511000431.261.503.632.565.15−0.062
2.754100060.04134.644.774.7016.0−0.120
Table 2. An example of the numerical factors involved in the relation of Equation (9) between Δ K and Δ r , for scale-free networks with a fixed number of nodes. These factors explain why the rewiring trajectories in the r-K plane have different slopes. (See Figures 2 and 3 and the description in Section 5.1.) N is the number of nodes, L the number of links. σ q 2 is the variance of the excess-degree distribution (Equation (8)). ( A D + B C ) / ( A B C D ) r e w denotes the average along an assortative rewiring trajectory with low temperature T = 10 6 . The hubs of the networks are defined by the cumulative probability method.
Table 2. An example of the numerical factors involved in the relation of Equation (9) between Δ K and Δ r , for scale-free networks with a fixed number of nodes. These factors explain why the rewiring trajectories in the r-K plane have different slopes. (See Figures 2 and 3 and the description in Section 5.1.) N is the number of nodes, L the number of links. σ q 2 is the variance of the excess-degree distribution (Equation (8)). ( A D + B C ) / ( A B C D ) r e w denotes the average along an assortative rewiring trajectory with low temperature T = 10 6 . The hubs of the networks are defined by the cumulative probability method.
γ NL σ q 2 L σ 2 N AD + BC ABCD rew
2.257157981931080.24
2.571563081.6360.31
2.7571553630.211.30.35
371548112.44.20.43

Share and Cite

MDPI and ACS Style

Bertotti, M.L.; Modanese, G. Network Rewiring in the r-K Plane. Entropy 2020, 22, 653. https://doi.org/10.3390/e22060653

AMA Style

Bertotti ML, Modanese G. Network Rewiring in the r-K Plane. Entropy. 2020; 22(6):653. https://doi.org/10.3390/e22060653

Chicago/Turabian Style

Bertotti, Maria Letizia, and Giovanni Modanese. 2020. "Network Rewiring in the r-K Plane" Entropy 22, no. 6: 653. https://doi.org/10.3390/e22060653

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop