A New Edge Betweenness Measure Using a Game Theoretical Approach: An Application to Hierarchical Community Detection

: In this paper we formally define the hierarchical clustering network problem (HCNP) as the problem to find a good hierarchical partition of a network. This new problem focuses on the dynamic process of the clustering rather than on the final picture of the clustering process. To address it, we introduce a new hierarchical clustering algorithm in networks, based on a new shortest path betweenness measure. To calculate it, the communication between each pair of nodes is weighed by the importance of the nodes that establish this communication. The weights or importance associated to each pair of nodes are calculated as the Shapley value of a game, named as the linear modularity game. This new measure, ( the node-game shortest path betweenness measure ), is used to obtain a hierarchical partition of the network by eliminating the link with the highest value. To evaluate the performance of our algorithm, we introduce several criteria that allow us to compare different dendrograms of a network from two point of view: modularity and homogeneity. Finally, we propose a faster algorithm based on a simplification of the node-game shortest path betweenness measure , whose order is quadratic on sparse networks. This fast version is competitive from a computational point of view with other hierarchical fast algorithms, and, in general, it provides better results.


Introduction
A major issue in the field of Social Network Analysis (SNA) is the search and study of cohesive groups in a network [1].This issue has been extended to networks of different nature, including biological, communication, transportation and social networks, among many others.Several authors have addressed this problem using a community structure detection approach [1][2][3].Communities, also known as clusters or modules, are groups of vertices or nodes that probably share common properties and/or play similar roles within the graph.
Clustering network algorithms can be divided into non-hierarchical (usually referred to as partitional clustering) and hierarchical methods which consider the final output.The main difference between these types of algorithms is the result obtained.Partitional clustering methods focus on the final partition that divides the set of items into homogeneous groups.Hierarchical clustering methods present an evolution (by means of a dendrogram) of how the groups are formed (in agglomerative methods) or split (in divisive methods), from the beginning of the process to the final step.Although hierarchical clustering methods present more computational problems, they have an important advantage, as the obtained results are more informative than those given by partitional clustering algorithms, which only provide a final picture of the process.Thus, in this paper we focus on techniques for hierarchical clustering of a set of nodes in a network as well as the measures that facilitate that hierarchical clustering.Initially, the methods proposed to obtain hierarchical partitions of communities in networks by clustering processes, considered the calculation of the weight w ij for all the pairs (i, j), being i, j two nodes [1,4].When all these weights are calculated, and once this dissimilarity or distance W matrix is built, the vertices can be grouped by means of any classical hierarchical clustering technique, without considering the structure of the network.For example, let G = (N, E) denote a graph, so that N denotes the set of nodes and E denotes the set of edges.Therefore, a good way to hierarchically cluster the set of nodes N is by starting with that pair of nodes i, j whose corresponding weight w ij is the strongest of all, and then go progressing to the weakest a review of classical hierarchical techniques can be found in [5].The output is a hierarchical cluster that can be visualized in a dendrogram.
Those preliminary techniques offered a wide range of possibilities.Nevertheless, it is important to bear in mind the drawbacks that result from a full consideration of the structure.In [2], Newman and Girvan provide a description of the problems derived from those techniques, as for example the memory required, ( n 2 ) instead of the amount of edges in E, and several assumptions on which the characterization of matrix M is based.
Then, Girvan and Newman proposed a divisive algorithm [4] (GN on the following) with a good performance for small-medium networks.It is based on the calculation of a weight w ij for each pair of adjacent nodes in the network (nodes i, j ∈ N are adjacent if ∃{i, j} ∈ E), and not for all node pairs, as traditional methods do.The weight w ij assigned to the corresponding edge {i, j} shows its power in the communication structure determined by the graph.So, firstly the weight w ij has to be calculated for all the edges {i, j} ∈ E, i.e., for all the pairs of adjacent nodes i, j.Hence, the divisive algorithm can be summarized as follows: 1.
For every edge {i, j} ∈ E, calculate the weight w ij .2.
Calculate the weight w ij for every edge affected by the deleted of {k, ℓ}.

4.
Go again to the step 2 and repeat the process until there are no more edges.
The method previously illustrated provides a hierarchical clustering of the nodes of the network.An essential notion when calculating w ij is the betweenness, described in [4] as the frequency with which every edge takes action in the communication of the set of nodes.There are two ways to obtain that frequency: the shortest path betweenness (SP), which only considers geodesic parts; or the random-walk betweenness defined in [6].These options are some of the most important when calculating the weight w ij ; however, different options which procure several modifications of the divisive algorithm have been proposed in the literature [7][8][9].
Let us note that most of the methods used to calculate a weight or measure w ij for each link in hierarchical clustering assume that all the communications between any pair of nodes in the network are equally important [2,4,[6][7][8][9].In our opinion, it is obvious that this assumption is unrealistic for networks that represent real-world communication situations.
To avoid this assumption, our main contribution is to estimate the relevance or importance of the communications between any pair of nodes in a graph, focusing on situations in which the only information available is a graph.We consider that communication among important nodes will be more relevant than communication among dummy nodes.To determine the importance of a node in a given network, we use centrality or power measures (see [10,11] for a general review of centrality measures).When it comes to problems modeled by a network, it is very common to use some tools inherited from game theory [12,13].In particular, cooperative game theory has been used as natural approach to represent the power or centrality of nodes in a network (see for example [14,15]), or also the cohesion of a set of nodes [16].The use of Game Theory for solving community detection problems is not new.For example, Ref. [17] Avrachenkov et al. proposed two approaches based on the Myerson value of two games: one of them based on simple paths and the other based on hedonic games.This Myerson value permits the authors to define a concept of Nash stable partition which provides a solution to the clustering problem.Once the differences in communications are determined, we obtain a new betweenness measure for each link by incorporating in the classical concept the notion that communications between any pair of nodes are not equally weighted.
The remainder of the paper is organized as follows.In Section 2 we introduce some preliminaries concepts in community detection problems and game theory, introducing a formal characterization of the Hierarchical Clustering Network Problem.In Section 3 we define a new SP betweenness measure based on game theory, which is used to obtain a new hierarchical clustering algorithm.In Section 4, we analyze the computational complexity associated to this new SP betweenness measure as well as the divisive algorithm based on it.In Section 5 we define a faster version of the algorithm previously proposed in Section 3, analyzing also its computational complexity.In Section 6, we compare the divisive algorithm obtained from the new SP betweenness measure with some of the most well-known hierarchical clustering algorithms in some well-known network examples.We also propose several criteria to compare the results given by the different hierarchical algorithms focusing, on the modularity and the homogeneity of the partitions.In Section 7 we analyze the performance of the algorithms here presented in the GN benchmark.We discuss the results of the paper in Section 8, and then we finish in Section 9 with some conclusions.

Cooperative Game Theory
Let N = {1, 2, . . ., n} denote a finite set of players.A game in characteristic function form (a coalitional game or a TU game) is a pair (N, v) where v a real function known as characteristic function and defined on 2 N , the set of all subsets of N (coalitions), that satisfies v(∅) = 0.For each S ⊆ 2 N , v(S) represents the economic possibilities of players in S. G N will denote the class of all coalitional games with players set N. When there is no ambiguity regarding N, we will refer to the game (N, v) as v.
Probably, the most important solution concept in cooperative games was defined by Shapley in [18].This solution concept is known as the Shapley value.The Shapley value is useful when there exists a need to allocate the worth that a set of players can achieve if they agree to cooperate.The Shapley value can be used in a natural way to measure the power or the importance of individuals.
Definition 1 (Shapley value [18]).Let N denote a finite set of players, and let the TU game (N, v).The Shapley value of the player i ∈ N is defined as Other solutions concepts have been proposed to represent the power, importance or capacity of individuals in a cooperative game.Based on the similar structure of marginal contributions of previous definition, in [19] it was defined the concept of semivalue.[19]).Let (N, v) denote a cooperative game, and let i ∈ N denote a player.The semivalue Ψ i (v) is defined as:

Definition 2 (Semivalue
where ∑ S⊂N\{i} P(S) = 1 and P(S) ≥ 0, ∀S ⊂ N \ {i} Let us observe that Ψ i (v) is a convex combinations of the marginal contributions of the player i regarding the different coalitions S ⊂ N \ {i}, where the values of this convex combination only depends on the cardinality of S. Obviously, the Shapley value is a specific case of a semivalue but it is not the only solution concept that derives from a semivalue.The Banzhaf-Coleman value [20] is another well-known semivalue which has been deeply studied in the literature [21].Formally, the Banzhaf-Coleman value is a semivalue where:

Hierarchical Clustering for Graphs
A graph or a network G is a pair (N, E), where N = {1, 2, . . ., n} denotes a finite set of nodes and E is a collection of links or edges, that is, unordered pairs {i, j} with i, j ∈ N. The adjacency matrix of a graph, usually denoted by A, is another way to characterize a graph.This matrix represents the direct connections among nodes, so that A ij = 1 if there exist the edge {i, j} ∈ E and 0 otherwise.
Given a graph or network, the problem of finding a good partition on it is known as clustering network problem or community detection problem.Although it can be found other definitions of this problem in which nodes may belong to more than one partition, in the classical approach only non overlapping partitions are allowed, so a feasible partition is as follows.

Definition 3 (Feasible partition).
A partition P of a graph (N, E) is defined as a set P = {H 1 , . . ., H r }, where for all i ̸ = j, H i ∩ H j = ∅ (non overlapping communities), r j=1 H j = N, and for all i, the subgraph (H i , E |H i ) is a connected graph (i.e.there exist, at least, one path between any pair of nodes of H i that does not use any node outside of H i ).
In this paper, we focus on the Hierarchical Clustering Network Problem (HCNP).It can be defined as the problem of finding a good hierarchical clustering of the graph, it is, a sequence of partitions build in a hierarchical way.A hierarchical partition of a graph is usually represented by a dendrogram.Then we introduce several concepts and notation, for a next formal definition of the hierarchical clustering of a graph.Definition 4 (Finer partition).Let P and Q denote two partitions of a graph.P is said to be finer than Q if for all A ∈ P, there exists B ∈ Q so that A ⊆ B. If P is finer than Q, we denote it by P ⊆Q.
Definition 5 (Hierarchical partition).Let G = (N, E) denote a graph with k connected components, and let D = (P 1 , P 2 , . . ., P n−k ) denote a sequence of partitions of G. D is said to be a hierarchical partition of the graph (obtained in a divisive way) when the following holds: e. in the last partition, all the nodes are singleton clusters).
e. the number of groups or communities increases in one unit in each iteration).
Another way to define this hierarchical clustering of a network is by changing the arrangement of the sequence of partitions.Note that this options is also an agglomerative process.However, it is obvious that every hierarchical clustering network algorithm, whether agglomerative or divisive, provides a hierarchical partition of the graph in this way.The set of all the possible hierarchical clustering for a given network (N, E) is denoted by P (D).
• D 2 = {S 0 , S 1 , S 2 , S 3 } with: Note that {2} and {3} are not connected in G and, consequently, it is not a partition.
Once hierarchial clustering network problem has been clearly defined, we review different clustering networks algorithms, focusing on those that produce hierarchical partitions.Some of the most well-known algorithms in community detection can be found in [1,22].As it is pointed in [22], these algorithms are a representative subset, that exploits some of the most interesting ideas and techniques developed over the last years.

1.
Girvan and Newman algorithm (see introduction for more details), denoted as GN algorithm in the following.2.
Clauset, Newman and Moore algorithm (see [23] for more details), denoted as CN M algorithm in the following.

3.
Walktrap algorithm.Based on random walk (see [24] for more details), denoted as Walktrap algorithm in the following.4.
Newman 2012 algorithm (see [25] for more details), denoted as N2012 algorithm in the following.This algorithm is considered as a reference of those algorithms that are based on the construction of a dissimilarity matrix between any pairs of nodes. 5.
Radicchi et al. algorithm (see [8] for more details), denoted as Radicchi algorithm in the following.In [8], two measures to cut the edges of the graph giving the weak and strong version of the Radicchi algorithm are proposed.For the computational results of this paper, we have used (in each example) the version that obtain better results.
Clearly, the methods GN, CN M, Walktrap, N2012 and Radicchi can be understood as hierarchical clustering methods, as a hierarchical partition of the network is obtained with all of them, according to the basis of the Definition 5.There are other methods which have not been considered in the current work because they do not give a hierarchical partition in the sense of Definition 5: some of them (as for example the well-known Louvain algorithm [26] or the Leiden method [27]) do not provide a hierarchical partition in which the amount of communities increases in one unit in each iteration.On the other hand, there are other type of methods,a s those based on eigenvector transformation [28], which do not guarantee connected partitions in every step.Lately, some authors have addressed the problem in which the network has not a clear community structure, and many methods have been proposed; however, this approach is not comparable to ours [29,30].

Modularity Function in Networks
The measurement of the reliability of a partition is not easy; moreover, there is no a unique global measure.Here we focus on the definition of the modularity (usually denote as Q) reported in [2].The modularity is very often used to measure partition goodness.Then, given a partition of a network, P, the corresponding modularity is defined as: where m denotes the number of edges in the graph, l i denotes the degree of the node i, A represents the adjacency matrix of the graph, and the value of δ(c i , c j ) depends on if i and j belong to the same cluster, in the sense that δ(c i , c j ) = 1 if i and j are in the same community, and δ(c i , c j ) = 0 otherwise.On the other hand, the modularity of a partitions measures the difference between the amount of edges which are in the considered groups, and the expected amount of edges which would be in those groups if the graph were randomly distributed.
Taking into account that hierarchical divisive methods provide a partition in each step, there is a modularity vector related to a hierarchical clustering; it is denoted by Q.The coordinate ℓ of this vector represent the modularity of the partition obtained in this step.
Formally, given a hierarchical clustering of a network D = {P 1 , . . ., P n−k }, the modularity vector can be defined as Q = (Q 1 , . . . ,Q n−k ) where Q i is the modularity of the partition P i .

The SP Edge Betweenness Measure
The SP betweenness measure defined in [4] is an extension of the popular concept of site betweenness introduced in [31].SP edge betweenness represents the importance of the edges in processes such as information spread, where information usually flows through SPs.Thus, an edge or link has a high SP betweenness value if it lies on a large number of short paths between vertices.Definition 6 (SP betweenness measure [4]).Let G = (N, E) denote a graph, and let the pair of adjacent nodes i, j.The SP betweenness measure of the link {i, j} is defined as: where I rs ((ij)) = 1 if the SP from r to s uses the link {i, j}.If there are more than one SPs between r and s, I rs ((ij)) is divided by the number of SPs.
Although the SP betweenness measure performs well in the GN algorithm, there are some real situations in which it yields poor results in terms of modularity.In general, such poor performance occurs when there are nodes of low degree (usually 1) connected to a set of nodes for which the edges are redundant.In these situations, the SP betweenness is greater for the link that connects an isolated node with the cluster than for the rest of the links or for connections within the cluster.Thus, after applying the GN algorithm with this measure, nodes of low degree are cut from the graph.This yields two clusters with cardinality 1 and n − 1, where n is the number of nodes in the graph.This situation is now illustrated with an example.(2,4), (3,5), (4,5), (5,6)}.The SP betweenness measure for the links of graph G = (N, E) reaches a maximum value for the edges (1, 2) and (5,6).Thus, according to the GN algorithm, one of the edges (1, 2) or (5,6) is removed randomly in the first step.It is easy to see that this first partition has low quality in terms of modularity (Q = −1 72 ).In the second step, after the recalculation of the betweenness measure for the links in the new graph, the GN algorithm cuts the other link, dividing the graph into three components, {1}, {6} and {2, 3, 4, 5} with modularity Q = −3 72 .In the following step it is divided the square 2,3,4,5 in two components, for example {2, 3} and {4, 5} with modularity Q = −2 72 .
This poor performance is reproduced in higher-dimensionality problems and complex networks that contain nodes of low degree connected to groups of nodes for which the relations are redundant.In these situations, the relations that connect nodes of low degree are considered more important (in terms of betweenness measure) than others, so the divisive algorithm defined in [2] starts cutting these nodes from the rest of the network, leading to poor partition.Although this could be reasonable from a betweenness measure point of view, it is clear that the obtained partition is poor in terms of modularity and size homogeneity when this measure is used as a criterion to cut the graph.

A New SP Edge Betweenness Measure Based on Game Theory
When calculating the SP edge betweenness measure, all communications are considered equally important.However, for many real situations this assumption is far from reality [32].It is easy to imagine real networks (transportation networks, flight communications networks and social networks, among others) for which communications between key nodes are more relevant than others.
We denote the importance of the communication between nodes r and s (not necessarily adjacent nodes) by h rs .We emphasize that if the only information available for a real network is the direct relations between its nodes, then classical methods [2,4,[6][7][8][9] assume that h rs = 1 for all r ̸ = s to obtain a weight w ij for each link of the graph.This is one of the main reasons for the poor performance of the SP betweenness measure noted above.
To estimate the value of h rs for each pair of nodes r and s with any additional information, we assume that the communications between main nodes/actors (paths among them) are more relevant than communications between dummy nodes or between important nodes and dummy nodes.Thus, before determining the h rs value for a pair of nodes r and s, it is necessary to measure the importance of the nodes in the graph.To this aim, we use centrality measures to represent the importance of nodes in a network.Let Φ = (ϕ 1 , . . . ,ϕ n ), denote the vector that measures the node importance in a graph.
As previously pointed out, it seems logical that the relations among powerful nodes should be considered more relevant than others.Thus, to aggregate the values ϕ r and ϕ s to determine the importance of the relation h rs , we use conjunctive aggregation operators.Although many aggregation operators can be used [33], we apply the most well known, the minimum operator.Then the importance of the communication between nodes r and s is calculated as h rs = MI N {ϕ r , ϕ s }.
Once the weight h rs has been determined for all pairs of nodes in the network, the new SP edge betweenness measure that we will refer as node-weighted SP edge betweenness measure can be expressed as: where I rs ((ij)) = 1 if the SP from r to s uses the link {i, j}.Note that this formula is the same that formula (5) if h rs = 1.It is important to note that, as occurs in the original Girvan-Newman SP betweenness measure, if there is more than one SP between nodes r and s, I rs ((ij)) is divided by the number of SPs.

Determining the Importance of the Nodes: A Game Theoretical Approach
Cooperative game theory can be a useful tool in order to represent the importance of nodes in a network (see for example [34] among other approaches), when it is known the motivation (the game) that shows the interaction between players.Different games may be proposed in this section, but, taking into account that our main aim is to maximize the modularity of a partition, we will focus on those games that show the power or importance of a coalition in the modularity function and/or the community detection problem.
First of all, let us observed that modularity formula defined in ( 4) is equivalent to Furthermore, as it is well known in the literature [35,36] and demonstrated in the Appendix A, note that Equation ( 6) is equivalent to where l in (C r ) denotes the number of edges of the set of nodes inside the cluster C r (i.e.l in (C r ) = ∑ i,j∈C r A(i, j)/2) and l out (C r ) denotes the number of edges that go from the cluster C r to outside (i.e.l out (C r ) = ∑ i∈C r ,j̸ ∈C r A(i, j)).
From Equation (7), it is clear that the contribution of a coalition C r to the modularity function only depends on two values: l in (C r ) and l out (C r ), so the corresponding game that shows the importance or power of a coalition should be strongly dependent on these two parameters.We provide the following example to illustrate the definition of the modularity, according to Equations ( 6) and (7).

▷
Using Equation (6): One of the main problem that have the most well-known solution concepts in cooperative game theory is the computational complexity related to its calculation.Although this problem was partially solved in [37,38], where the authors proposed some methods to approximate the Shapley value by sampling models in polynomial time, the computational complexity is still high for community detection problems.Then, in order to reduce this computational complexity associated with the calculation of the classical solution concepts in cooperative game theory, we will consider a linear combination of these two values.We will refer to this game as the linear modularity game.Taking into account that the modularity function and the community detection problems search partition in which the edges between clusters are punished and the edges inside the cluster are rewarded, we define the linear modularity game as the pair (N, v mod ), where N is the set of nodes and the characteristic function is given by: with α and β positive values.The characteristic function of the defined linear modularity game models the strength and/or the cohesion of a coalition S as the percentage of links that has this coalition (weighted by α) minus the percentage of links that this coalition has with other clusters (weighted by β).This characteristic function satisfies the two keyproperties (see [16] for more details) of any cohesiveness measure: (1) it is increasing in the number of links among its member; (2) it is decreasing in the number of links that connects nodes of the group with others groups.
Let us note that the game v mod is a simplification of the modularity measure; although it has a similar approach, is not the same or equivalent.The similarities between the function v mod and the classic modularity function is that, for a given coalition, both measures punish the relations of its members with the individuals of another coalition and reward the internal relations.However, v mod should clearly be understood as a very simplified version of the original modularity function.We introduce the v mod measure for the sole purpose of simplifying the computational process.
In the following proposition we suggest a specific expression for any semivalue in the linear modularity game that satisfies a small constraint.Firstly, let us introduce some notation.Given a network (N, A), being A the adjacency matrix, and given a node i ∈ N, let us denote by P i = {S ⊂ N \ {i}} the set of subsets of N that do not contain the node i, and let us denote by S k i = {R ∈ P i / ∑ j∈R A(i, j) = k}, the set of subsets in P i that have exactly k adjacent nodes of i. Obviously, the sets {S k i } establish a partition of P i for k = 0, . . ., l i (i.e When there is no ambiguity about the node i considered, we denote S k = S k i .Before we enunciate the proposition, we provide an example to illustrate the calculation of the values of S k i .We illustrate the calculation of every subset S k i with degree k for each single player i.
Those sets {S k i } have many properties; the following three are really useful to deal with the Proposition 1 provided below.

•
The marginal contribution of player i is the same for every set {S k i }, ∀k = 0, . . ., l i .

•
The number of sets in {S k i } is equal to the number of sets in {S l i −k i }, ∀k = 0, . . ., l i .

•
The sum of the marginal contribution of an element in {S k i } and the marginal contribution of an element in {S l i −k i } turns into an expression which only depends on the degree of the node i, i.e. l i .
Then, the proof of the Proposition 1 is based on a sorting of the summation which appears in every semivalue which sets it in terms of {S k i }.After that, these three properties are considered (taking into account if l i is even or odd) to demonstrate that the summation which appears in the semivalue just depends on l i .Proposition 1.Let (N, v mod ) denote the linear modularity game, let i denote a node in N and let Proof.Taking into account that first analyze the marginal contribution of the player i in the linear modularity game.We prove that the marginal contribution of a player i in a coalition S is the same for all S that belongs to S k (i.e. the marginal contribution only depends on the value of k).
To do it, we observe that for all S ∈ S k , l in (S ∪ {i}) = l in (S) + k, and l out (S ∪ {i}) = l out (S) − k + (l i − k).So, for all S ∈ S k , the following holds: which is equal to From previous equation, we can rewrite the semivalue as: P(S) (the constraint that we impose to the semivalue) we have: which is equal to Now, taking into account that P(S) , then the following holds and thus If l i is even, then Ψ i (v mod ) can be rewritten as: which is equal to Now, taking into account that then the following holds and thus In the following two propositions we see that the Shapley and the Banzahf-Coleman values are particular cases of previous situation.Proposition 2. Let (N, v mod ) denote the linear modularity game and let i be a node in N, then the Shapley value of this node i is: Proof.Because of the results demonstrated in the Proposition 1, we only have to demonstrate that For each S ∈ S k , N \ (S ∪ {i}) belong to S l i −k and viceversa.Then, the the cardinal of S k is the same that the cardinal of S l i −k .Therefore, a sufficient condition to prove previous equality is that P(S) = P(N \ (S ∪ {i})) where Proposition 3. Let (N, v mod ) denote the linear modularity game and let i denote a node in N,.Then Banzahf-Coleman value of this node i is: Proof.From Proposition 1, we only have to check the following equation.
. Equation ( 9) trivially holds since the cardinal of S k is equal to the cardinal of S l i −k .
On the following, we will refer to the node-weighted SP betweenness measure as the node-game SP betweenness measure.Also, we will use the terms power, Shapley value or Banzahf-Coleman in a similar way since these concepts coincide for the linear modularity game.
Example 6.Consider the graph defined in Example 3. From a centrality point of view, nodes 1 and 6 have low centrality.Nodes 2 and 5 have high centrality and nodes 3 and 4 have medium centrality.Considering the power solution given by the linear modularity game in the graph and using the minimum operator, we obtain the following weights matrix: Intermediate links in the SP communication between nodes 2 and 5 have greater betweenness, so the divisive algorithm will try to separate them.It is not difficult to see that the node-game SP betweenness for matrix H will rank the links of the graph in the following way: w 2,3 = w 2,4 = w 3,5 = w 4,5 > w 1,2 = w 5,6 .This new rank fixes the poor performance of the classical SP betweenness.Without lost of generality, let us suppose that the first link we cut is the link (2,4) or (3,5) (the other situation is analogous).Then, the first cut of the algorithm will partition the graph into two clusters: C 1 = {1, 2, 3} and C 2 = {4, 5, 6}, with modularity Q = 1 6 .

Remark 1.
Let us observe that the value α does not affect the ranking of the edges in terms of node-game SP betweeness measure if α > 0. So, without loss of generality, we will consider from now and on α = 1 .

Computational Complexity
The previous section revealed how the inclusion of the importance or power of the nodes when calculating SP betweenness improves the performance of the GN algorithm.We will see that this new algorithm does not increases the computational complexity of the GN algorithm.
As it is pointed in [1], the betweenness of all edges of the graph can be calculated in a time that scales as O(mn) (or O(n 2 ) on a sparse graph).Taking into account that in the GN algorithm this calculation is repeated m times, the computational complexity of the GN algorithm is O(m 2 n) (or O(n 3 ) on a sparse networks).
The main difference between the calculation of betweenness and node-game betweenness for all edges of the network is the calculation of the power for all nodes.So, if we denote by f (n) the computational complexity associated with its calculation, the complexity associated with the calculation of the node-game betweenness for all edges is O(mn + f (n)).As this process is repeated m times, the complexity of new algorithm (denoted as GICE algorithm) for a general power measure is O(m 2 n + m f (n)).Let us note that the Shapley value of the linear modularity game can be obtained in order O(m), and it is not necessary to recalculate in each iteration as the power of a node can be update automatically after one edge is removed from the network.Hence, the computational complexity of our algorithm is O(m 2 n + m).As m is bounded by m 2 n, we can say that this algorithm has a complexity of O(m 2 n) (or O(n 3 ) on sparse networks), when the power measure is the Shapley value of the linear modularity game.

Reducing the Computational Complexity of the Node-Game Betweeness Measure
The computational complexity of the GN algorithim, whose order is O(m 2 n) or O(n 3 ) in sparse networks, is one of the main inconveniences of this method.Hence in practice, it is not possible to analyze large networks related to real problems.To be competitive in large networks, several authors (see [9,39,40] among others) have developed faster techniques for calculating the SP betweenness measure for all the edges of a graph.For example, in [40], it is proposed a modification of the GN algorithm to improves the speed of SP edge betwenness measure calculation.The computational complexity of the calculation of the SP betweeness (with order O(nm)) is drastically reduced: only some key nodes, which are defined a priori and called gene co-ocurrences, are used.This SP betweeness approximation is obtained by considering the shortest paths from some key nodes to all nodes.Using a breadth first search, the calculation of the SP edge betweeness when considering the SP from one center to the rest of the nodes, has a linear complexity (O(m)) in unweighted graphs.The calculation of the SP edge betweenness for every adjacent nodes may be reduced from O(nm) to (O( f (n)m) when there are f (n) < n nodes in the networks.For instance, when f (n) = log(n), the computational complexity related to the calculation of the SP edge betweenness approximation is roughly O(m).In this scenario, the complexity of the GN algorithm can be reduced to O(m 2 ) or O(n 2 ) in sparse networks.Obviously, the selection of the f (n) nodes in the network is essential in the performance of the divisive algorithm.In [39], the key nodes are chosen at random, deriving a sort of Monte Carlo estimate.The authors indicate that, for each connected subgraph, it is sufficient to choose a number of centers growing as the logarithm of the number of vertices of the component.Obviously, the partitions are, in general, different for different choices of the set of center vertices.
Following the same spirit of [39,40], in this paper we propose a fast version of the algorithm presented in Section 3, by reducing the calculation of the node-game SP betweeness measure in a similar way.When only considering the log(n) nodes with maximum power in the whole graph to approach the node-game SP betweenness measure, the corresponding computational complexity of this approximation has an order of O(mlog(n)).Taking into account that this calculation has to be done m times, we can conclude that the computational complexity associated with this fast version is O(m 2 log(n)), that for sparse networks is O(n 2 ) (the same complexity as the CNM algorithm).It allows us to analyze large networks.In Table 1, we present the computational complexity associated with the different algorithms that have been used in this paper.These are a representative sample of the algorithm that can obtain a hierarchical clustering of the network.Let us note that for hierarchical clustering algorithms as they are defined in Section 3, the length of the dendrogram (usually denote as d) is n, as we need to obtain all the partitions of the graph and, in each iteration, we reduce (in agglomerative methods) or increase (in divisive) the number of groups in one unit.

Computational Results in Real Well-Known Examples
When you want to test the effectiveness of an algorithm, it is necessary to answer several questions.The first one is related to those algorithms with which you have to compare yours.The second is about the selection of the examples in which you test your effectiveness.The third is related to the accuracy measures that show the quality of the output of the different algorithms.Then we give an answer for these questions to validate the performance of our algorithm.
In Section 2.2 we give a short review about some of the most well-known techniques that can deal with the hierarchical clustering network problem: GN, CN M, Walktrap, N2012 and Radicchi.We compare our algorithm with these methods.
Regarding the selection of the examples, in the field of community detection problems there exist two types of benchmark examples ( [22,41]).The first type of data sets are some well-known examples as the karate club network, the dolphins network, Les miserables network, the football network, the centrality authors network or the jazz network among others, in which most of the clustering networks have been tested.The second class of test examples are generated by simulation with an a priori knowledge of the classes.The simulation model starts with a known number of classes, and it assigns different probabilities for two nodes of being connected in the same community (p in ) or in different communities (p out ). Generating the networks in this way, we can test the performance of an algorithm that searches an optimal partition measuring how close or similar are the partition given by an algorithm with the a priori classes of the network.
Finally, we focus on the accuracy measures used to compare the results given by two different algorithms.Apart from some innate features of any algorithm, as its complications to implement or the computational complexity associated with it, there are other two problems which have to be faced: 1.
The comparison of two partitions of a graph.

2.
The comparison of two sequence of partitions.
Although there exist others accuracy measures ( [1]), in this paper we use the concept of modularity to measure the quality of a partition in a graph.The modularity represents the homogeneity in terms of cluster density, and punishes the relations that exist among groups.Nevertheless, in some situations, the modularity of two partitions are very similar, so it may be necessary to consider more information to discriminate them.Thus, another criterion considered in the clustering literature is the size homogeneity.In our opinion, it is clear that when two partitions are very similar it would be better to have homogeneous groups in terms of size.
Given a partition P = {C 1 , . . .C r } of a set of nodes N with size vector S = (s 1 , . . .s r ), many measures of heterogeneity in groups are available.Since we use this measure to compare the dispersion of two samples with different average and the sum of the size vector is always constant, we use the coefficient of variation, which can be formalized as : where s is the average size and σ S is the typical deviation for sample s 1 , . . .s r .
As we have done with the modularity vector, given a hierarchical clustering of a graph D = (P 1 , P 2 , . . ., P n−k ), we denote by CV (D) = (CV 1 (D), CV 2 (D), . . ., CV n−k (D)) the coefficient of variation vector associated to the dendrogram D.
Despite the existence of measures to determine the quality of a partition (in this case we use the modularity measure), it is not clear how to measure the goodness of a hierarchical clustering.The problem of comparing dendrograms is an open topic which requires further study.A possible criterion for comparing two dendrograms [2,6] is to compare the partitions obtained by hierarchical clustering in the step in which maximum modularity is reached.However, we describe an example to show how this criterion could be unfair when two dendrograms are compared.However, if we analyze the algorithm from a divisive point of view, the first obtained partition should be P R = {R 1 = {1, 2, 3, 4, 5, 6}, R 2 = {7, 8, 9, 10, 11, 12}}, in which it is reached the maximum of modularity in two clusters.Nevertheless, pay attention to the fact that, if P R were considered the first partition, the optimal partition P = {C 1 , C 2 , C 3 } will never be reached by any divisive method.Even so, that optimal partition P with three clusters C 1 , C 2 , C 3 may be reached with a first iteration such as {1, 2, 3, 4} and {5, 6, 7, 8, 9, 10, 11, 12}.
Note that divisive hierarchical clustering methods presents the evolution of a group which is divided into a network.Then, we should not take into consideration just a specific stage, even though the initial iterations were considered to be more relevant than the followings.
In our opinion, the comparison of two hierarchical clusters has to take into account more than just one step because a these methods not only provide the obtained final partition, but they provide the whole evolution of a group split into a network.Hence, we propose some different criteria to compare dendrograms, assuming that the problem of comparing partitions has been solved by the modularity definition (and in case of similar modularity value by its homogeneity).
Given a dendrogram D, we denote by t max (D) the iteration in which the maximum modularity is reached, i.e. t max (D) = arg{ Max 1≤t≤n−k Q t (D)}.

•
Maximum modularity criterion (denoted by Cr 1 ).To compare two (or more) dendrograms, the partitions obtained for each dendrogram are compared in the step in which they reach maximum modularity.Although this criterion presents the problems described above, Cr 1 is a unique criterion that can be derived from the literature on social network clustering to compare two divisive hierarchical clustering algorithms.It could be used to determine a possible number of clusters/groups in a network for any further optimization partitional methods that require this information.Cr 1 can be defined as a function from the set of all possible dendrograms to the set of real numbers Cr 1 : P (D) → I R such that: • Average criterion.To compare two (or more) dendrograms, this compares the average of the modularity vector.In our opinion, this criterion has too many inconveniences.
The most important one is that this criterion gives the same importance to the first partition as to the final one.It is clear that when a network is connected, the first cuts have more relevance than the last ones, in which only a few nodes are connected.These last iterations are usually not analyzed.Formally this criteria can be defined as a function from the set of all possible dendrograms to the set of real numbers Cr : P → I R such that: . One way to compare two (or more) dendrograms, is comparing the modularity vectors lexicographically (i.e. the first partitions are compared; if these are equal, then the second partitions are compared, and so on).This criterion leads to greater importance for the first partition than for subsequent ones.Formally Cr 2 establish an order in the set of P (D) in such a way D <D ′ iff the modularity vector Q D is lexicographically lower than Q D ′ (i.e D <D ′ iff there exists Average truncated by the maximum criterion (denoted by Cr 3 ).Following the average criterion but fixing the problem of considering all the partitions in the dendrogram, this criterion only compares the dendrograms until they reach a maximum value.This approach follows an idea in which the hierarchical process stops at the step in which the maximum (in terms of modularity) is reached.Formally, this criteria can be defined as a function from the set of all possible dendrograms to the set of real numbers Cr 3 : P (D) → I R such that: Similarly, the size homogeneity of a given partition could be used to establish different criteria to discriminate between two dendrograms.We suggest the following homogeneity criteria.

•
Maximum modularity homogeneity (denoted by SCr 1 ).Following the ideas described for Cr 1 , we compare two or more dendrograms by comparing the homogeneity of the partitions obtained in the step in which the maximum modularity is reached.Formally, this criteria can be defined as a function from the set of all possible dendrograms to the set of real numbers SCr 1 : P (D) → I R such that: • Lexicographical criterion (denoted by SCr 2 ).We compare the homogeneity vectors lexicographically.This criterion assigns greater importance to the first partitions than to subsequent ones.Formally SCr 2 establishes an order of the set of P (D) in such a way D <D ′ iff the CV D is lexicographically lower than CV D ′ (i.e D <D ′ iff there exist t such that CV r (D) = CV r (D ′ ) for r < t and CV t (D) Homogeneity criterion for the average truncated by the maximum (denoted by SCr 3 ).This criterion only compares the dendrograms until the step in which the maximum modularity is reached.Formally this criteria can be defined as a function from the set of all possible dendrograms to the set of real numbers SCr 3 : P (D) → I R such that: Taking into account previous considerations, we analyze the performance of our algorithm in four well-known examples, comparing with the five hierarchical algorithms GN, CNM, Walktrap, N2012 and Radicchi, in the criteria Cr 1 , Cr 2 , Cr 3 and SCr 1 , SCr 2 , SCr 3 : 1.
The karate club network [42].The nodes of this graph represent the partners of a karate club, and every edge connecting two nodes represents they have a friendship relation.Historically, cutting the network into two groups has been studied because of its sociological importance.This network has 34 nodes and 156 links.We show the performance of the different algorithms in Table 2.

2.
The dolphins network [43].This network is an undirected social network of frequent associations between some dolphins in a community living off Doubtful Sound, New Zealand.It comprises 62 nodes and 159 links.We show the performance of the different algorithms in Table 3.

3.
Les Miserables network [44].The nodes of this network are the actors that appear in the book by Victor Hugo, and the links represent the relations among them.The network has 77 nodes and 254 links.We show the performance of the different algorithms in Table 4.

4.
The centrality authors [45], taken from the pajek web page.This network is related to several papers about network centrality, and how these work are interconnected between them by cross-reference, considering the cites between 1940 and 1979.Every node represents a paper, so the edges represent if there is a citation among the connected nodes 129 nodes and 613 links.Let us note that the result of Walktrap algorithm for this network is not included, as this method can not deal with nonconnected networks.We show the performance of the different algorithms in Table 5.Finally, to summarize both criteria (Modularity and Homogeneity) into one (from the perspectives Cr 1 , Cr 2 and Cr 3 ), we have considered that modularity is more important than homogeneity.It is clear that if you have a completed graph with 25 nodes connected with another completed graph with 100 nodes, the optimal partition should have two clusters with sizes 25 and 100.Obviously, there are others partitions with more size homogeneity, but their modularity will be significantly lower.Nevertheless, homogeneity criteria should have an impact in the quality of a partition when the modularity values are very similar or are not significantly different.As we have pointed out previously, from our point of view, it is clear that two partitions P and P ′ with similar modularity values (for example Q(P) = 0.398 and Q(P ′ ) = 0.388) but with sizes s(P) = (80, 20) and s(P ′ ) = (51, 49) are entirely different.
To measure the differences between two partitions we could used the absolute value |Q(P) − Q(P ′ )| = |0.398− 0.388| = 0, 01 (i.e the partition P improved the modularity of P ′ in 0, 01), or, the relative value, .398 − 0.388| 0.388 = 0, 025 (i.e. the modularity of P ′ is improved in a 2.5% by the partition P).Taking into account that the homogeneity and modularity take values in different scales, we have used the second expression (the relative value) to compare two dendrograms.Following (Cr 1 , SCr 1 ), in Tables 6-9 we have summarized the modularity and homogeneity criteria into one as we have described previously.Formally, given two hierarchical partitions D and D ′ and an error ϵ value, we have considered that D is greater than D ′ (or is better) in the criteria (Cr 1 , SCr 1 ) if and only if one of the two cases holds: > ϵ (i.e. the percentage of gain in the modularity criteria of maximum in D is significatively better than D ′ ) or > ϵ (i.e. if both hierarchical partitions are similar in terms of maximum modularity then the homogeneity criteria has to be significatively better).Following (Cr 2 , SCr 2 ), in Tables 6-9 we have combined the modularity and homogeneity criteria.Formally, given two hierarchical partitions D and D ′ , we have considered that D is greater than D ′ (or is better) in the criteria (Cr 2 , SCr 2 ) if and only if one of the following cases holds:

•
There exists l ∈ {1, . . ., n} such that |Q(P r )−Q(P ′ r )| min{Q(P l ),Q(P ′ l )} ≤ ϵ for all r < l and > ϵ (i.e.D and D' are significantly equals in the first l − 1 partitions but the modularity of D is significantly better in the l partition) or for all i and the homogeneity is lexicographically better in a similar way as we have done in the previous step for the modularity.
Following (Cr 3 , SCr 3 ), in Tables 6-9 we have combined the modularity and homogeneity criteria into one.Formally, given two hierarchical partitions D and D ′ and an error ϵ value, we have considered that D is greater than D ′ (or is better) in the criteria (Cr 3 , SCr 3 ) if and only if one of the two cases holds.> ϵ (i.e. if both hierarchical partitions are similar in terms of average modularity then the homogeneity criteria has to be significatively better).Table 6.Comparison between GICE and GICEF algorithms versus GN, CNM, Walktrap (Walk), N2012 and Radicchi (Ra) algorithms from a Modularity and Homogeneity point of view in the criteria Cr 1 , . . .Cr 3 and SCr 1 , . . .SCr 3 for the karate club network.Letter B represent that our algorithm present better performance in this criteria, W worst and E represent that the difference is not significative.than 0.4, as it happens with GN, Radicchi, Walktrap or CN M [22].However, they work properly when µ ≤ 0.4.In [22], it can be found with more details the results given by the GN and CN M. In Table 10 we show the results obtained with the GICE algorithm, and GICEF algorithm for the step 4. In order to measure the similarity between the reference partition P = {C 1 , . . ., C 4 } with C 1 = {1, . . ., 32}, C 2 = {33, . . ., 64}, C 3 = {65, . . ., 96} and C 4 = {97, . . ., 128} we have used the Normalized Mutual Information (NMI).In the table we show, for each scenario, the average over 100 iterations realized over the benchmark graph.In this table we also show the modularity average in the 100 realization of the GICE, GICEF and also the modularity average of the reference partition.

Discussion
In this section we discuss the results obtained in the different tests.Regarding the well-known examples, in Tables 2-5 we show the results in terms of modularity and homogeneity of the five hierarchical clustering algorithms previously mentioned for the first partitions in those examples.The criteria Cr 1 ,Cr 2 ,Cr 3 ,SCr 1 ,SCr 2 and SCr 3 are also analyzed.We can say that, in general, the GICE algorithm here presented and its fast version are very competitive from modularity and homogeneity point of view.
Moreover, let us note that the fast version of the algorithm here proposed presents worst performance than the slower version, since the fast version obtain results significatively worst in 9 of 12 scenarios.Nevertheless, comparing this fast version with the rest of the algorithms studied in this paper, we see that it is very competitive.The fast version of the algorithm here presented improves the results of the CN M (see Tables 6-9) in 7 of 12 scenarios, improves the results of Radicchi algorithm in 8 of 12 (only is worst in 3 of 12) situations, present better results than GN and N2012 algorithms in 11 of 12 scenarios and improves the results of Walktrap in all situations.
Regarding the performance of our algorithm in the benchmark model, several conclusions previously explained are repeated again.As happen with the well-known examples, it is clear that the performance of the GICE is better than the fast version.Both provide very good results and similar N MI values for µ lower than 0.3, but for µ = 0.35 the difference is 0.03, for µ = 0.4 the difference is 0.07, and for µ = 0.5 the difference is 0.15, so the difference between these two algorithms increased (in terms N MI) as the value of µ increase.Nevertheless, note that the performance of GICEF is better than other fast algorithms compared in this paper as the CNM for these values.For example, (see [22]) N MI of CN M for µ = 0.3 is around 0.9, for µ = 0.4 is around 0.75, and for µ = 0.5 is around 0.38.In general, GN, Walktrap, N2012 and Radicchi algorithms give worst results than CN M.
To conclude this section, let us note that in general and for µ values lower than 0.55, the reference partition is the best partition in the criteria (SCr 1 , Cr 1 ), since this partition has the best possible coefficient of variation (its homogeneity is perfect) and its modularity is better or at least non significantly lower (for values of µ = 0.45, 0.5, 0.55 it can be found partitions with higher values of modularity but not significatly) than other partitions founded by GICE algorithm.Taking into account this, N MI could reflect in some way both criteria (SCr 1 , Cr 1 ) (as we have done in the previous section) since it is clear that if one partition is more similar to the reference one than other, then it is expected better values of (SCr 1 , Cr 1 ).A similar analysis, could be done taking into account (for the same random graphs) what happen in the second and the third step to consider the criteria (SCr 2 , Cr 2 ) and (SCr 3 , Cr 3 ).Also let us note that for µ values greater than 0.60, the GICE and GICEF algorithms improve the reference modularity.

Final Remarks and Conclusions
Community detection problems [1] are commonly described as clustering network problems whose main aim is to obtain a good partition of the graph analyzed.In this paper we formally present the hierarchical clustering network problem (HCNP) as the problem to find a good hierarchical partition of a network.This new perspective emphasizes more in the dynamic process of the clustering rather than the final picture of the clustering process.From a social network analysis, a hierarchical partition of a network is more informative than a partition, as it shows the whole process along which the communities are grouped (regarding agglomerative methods) or splitted (regarding divisive methods), from the very first step until the last situation.As Clauset et al. point out in [46], a hierarchy is a central organizing principle of complex networks, capable of offering insight into many network phenomena.Hence, it can be said that a hierarchical analysis of a graph provides much more information than the output of a single non-hierarchical method.
Taking into account the HCNP approach here introduced, in this paper we propose a divisive algorithm based on a new SP edge betwenness measure.Given a network for which the only information is the direct relations among its members, a common assumption for calculating indexes such as the SP edge betweenness measure is that the communication between any pair of nodes in the network is equally important.The key element of this study is to avoid this assumption, and then to estimate the importance of communications between any pair of nodes (not necessarily adjacent) in a network.Then, we propose a new SP betweenness measure in which the communications between nodes are not equally weighted.To measure the importance of the communication between two nodes i and j (i.e.w ij ), we first measure the importance or power of these nodes, assuming that the communications between important nodes is more relevant that the communication between dummy nodes.The power of nodes in network is obtained as the Shapley value (or any other semivalue) of a game that we call linear modularity game.Let us emphasize again that this game has been built under the assumption that the only available information in the problem is the network, so only modularity function has been considered.If more information is known about the clustering problem, this information should be included in the game, to obtain more cohesive partitions [47,48].
To measure the performance of the divisive hierarchical clustering network algorithm here proposed, we agree on the need for having different methods to evaluate the performance of community detection and classification algorithms, whenever the data shows some structure [46].In the framework of algorithms for the clustering of networks, we can find [1] some measures to assess the quality of any particular partition of a graph.For example, in [4] it is introduced the notion of modularity; we also considered the homogeneity size to measure the quality of a partition.However, these measures are not well fitted to the performance assessment of a hierarchical algorithm, in which the final output is usually a dendrogram.Hence, in this paper we introduce several criteria that allow us to compare different dendrograms of network from a modularity and homogeneity point of view.Nevertheless, more efforts should be dedicated in community detection literature to compare two hierarchical partitions of a given graph.
The computational results reveal that the hierarchical clustering network algorithm here defined eliminates the main problems of the classical GN algorithm for many real situations and exhibits good performance in those situations in which the classical betweenness measure also does.We observe that partitions obtained using the our GICE algorithm (in which the node-game SP edge betweennees measure is used) yield groups that are more homogeneous in size than the classical GN algorithm (in which the classical SP edge betweenees is used).
Another crucial concept we develop is the use of the minimum operator to aggregate the importance of two nodes to represent the importance of the corresponding communication.Other conjunction aggregation operators could also be used instead.The relations between the results for a divisive algorithm and the aggregation operators is an issue that merits investigation.
Most of social network analysis, as centrality measures or community detection problems among others, analyze the network and its properties only taking into account the relations that exist between nodes (i.e. the graph) or in more complex situations assuming that these relation are valued (in a positive or negative way).Nevertheless, as it was pointed in [16,34], it is very difficult to find a social network analysis in which it is also reflected the interests or motivations that reflect the interaction between nodes in a network.In [34], it was introduced a game theory framework to model (in addition with the relation that exist between nodes in a network) the interactions that motivates the relation between nodes in the network by means of a cooperative game.From a community detection point of view, let us suppose that we have a wheel-graph with four nodes N = {1, 2, 3, 4} ordered in a natural way (i.e.E = {(1, 2), (2, 3), (3,4), (1,4)} ) that we want to cluster.If we have not additional information about what is the real situation that are represented by this graph or we do not know the interests that have motivated this network to be built, then the first partition could be P = {1, 2}; {3, 4} or P ′ = {1, 4}; {2, 3}.Now, let us suppose that the interest which motivates the relation between nodes in this network is to maintain together the nodes 1 − 4 and 2 − 3.Then, the characteristic function v(S) that models the worth associated with the coalition S, can be v({i}) = 0, for all i = 1, . . ., 4, v({1, 2}) = v({1, 3}) = v({2, 4}) = v({3, 4}) = 0, v({1, 4}) = v({2, 3}) = 1, v(S) = 1 if |S| = 3 and v({1, 2, 3, 4}) = 2 since in this coalition we maintain 1 − 4 and 2 − 3 together.From a clustering network point of view, it is clear that if the interest of this network is to maintain the nodes 1 − 4 together or 2 − 3, then the partition P = {1, 2}; {3, 4} is not realistic for this situation.We want to emphasize that the divide algorithm here defined could take into account the interests or motivations that have the nodes in the network by means of a cooperative game and could take into account this information in the clustering process of the network.Actually, there is not any hierarchical or non hierarchical clustering network algorithm that take into account this information for the clustering problem.
To conclude this section, we want to emphasize that the divisive algorithm here presented based on the node-game SP betweenness measure clearly provides very good results in terms of modularity and homogeneity.For small and medium networks, its complexity (the same that the GN algorithm) allows us to obtain a very informative evolution of how the groups are break in the network in a hierarchical way, and it should be the best option to analyze these size networks from this point of view.For large networks, we present a simplification of our measure, providing a fast version of the algorithm that has a quadratic order on sparse networks.This fast version is competitive from a computational point of view with other hierarchical algorithms (as for example CN M, Walktrap, N2012, GN or Radicchi) presenting (in general) better results in the examples analyzed.

Example 5 . 3 Figure 3 .
Figure 3. Graph G = (N, E) with adjacency matrix A. Toy example to illustrate S k i calculation.

Table 2 .
Modularity and Homogeneity for partitions with k groups (k = 2, . . ., 6) obtained using the GN, CNM, Walktrap, N2012, Radicchi, our GICE and its fast version (GICEF) for the karate club network.The criteria values are shown in parentheses.

Table 3 .
Modularity and Homogeneity for partitions with k groups (k = 2, . . ., 7) obtained using the GN, CNM, Walktrap, N2012, Radicchi, our GICE and its fast version (GICEF) for the dolphins network.The criteria values are shown in parentheses.

Table 4 .
Modularity and Homogeneity for partitions with k groups (k = 2, . . ., 11) obtained using the GN, CNM, Walktrap, N2012, our GICE and its fast version (GICEF) for Les miserables network.The criteria values are shown in parentheses.

Table 5 .
Modularity and Homogeneity for partitions with k groups (k = 13, . . ., 60) obtained using the GN, CNM, N2012, Radicchi, our GICE and its fast version (GICEF) for the authors network.The criteria values are shown in parentheses.

Table 10 .
Normalized Mutual Information (NMI) based on the mixing parameter µ = z out z in +z out respect to the reference partition with four groups in the GN benchmark using the GICE and GICEF algorithms.