Quantum inspired evolutionary algorithm for community detection in complex networks

Quantum inspired evolutionary algorithm for community detection in complex networks

JID:PLA AID:25141 /SCO Doctopic: Quantum physics [m5G; v1.236; Prn:29/05/2018; 15:41] P.1 (1-8) Physics Letters A ••• (••••) •••–••• 1 Contents li...

1MB Sizes 0 Downloads 97 Views

JID:PLA AID:25141 /SCO Doctopic: Quantum physics

[m5G; v1.236; Prn:29/05/2018; 15:41] P.1 (1-8)

Physics Letters A ••• (••••) •••–•••

1

Contents lists available at ScienceDirect

2

67 68

3

Physics Letters A

4 5

69 70 71

6

72

www.elsevier.com/locate/pla

7

73

8

74

9

75

10

76

11 12 13

Quantum inspired evolutionary algorithm for community detection in complex networks

14 15 16 17 18

Meng Yuanyuan

, Liu Xiyu

a,∗

23 24 25 26 27 28 29 30 31

79 81 82

a

School of Management Science and Engineering, Shandong Normal University, China b School of Computer Science and Technology, Shandong University of Finance and Economics, China

83 84 85

20 22

78 80

a, b

19 21

77

86

a r t i c l e

i n f o

Article history: Received 2 January 2018 Received in revised form 24 May 2018 Accepted 25 May 2018 Available online xxxx Communicated by M.G.A. Paris Keywords: Quantum Complex networks Community detection

32

a b s t r a c t

87 88

Community structure is indispensable to discover the potential property of complex network systems. In this paper we propose two algorithms (QIEA-net and iQIEA-net) to discover communities in social networks by optimizing modularity. Unlike many existing methods, the proposed algorithms adopt quantum inspired evolutionary algorithm (QIEA) to optimize a population of solutions and do not need to give the number of community beforehand, which is determined by optimizing the value of modularity function and needs no human intervention. In order to accelerate the convergence speed, in iQIEA-net, we apply the result of classical partitioning algorithm as a guiding quantum individual, which can instruct other quantum individuals’ evolution. We demonstrate the potential of two algorithms on five real social networks. The results of comparison with other community detection algorithms prove our approaches have very competitive performance. © 2018 Published by Elsevier B.V.

89 90 91 92 93 94 95 96 97 98

33

99

34

100

35

101

36

102

37 38

1. Introduction

39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59

Many systems existing in real world can be characterized by complex networks, such as neural, biological, technological and social networks, food web, etc. In those networks, a vertex (or a node) represents an individual or a component, and an edge (or a link) represents natural or artificial relationships. Generally, a community can be defined as a set of nodes with more densely internal connections and relatively sparse connections than with the rest nodes of the network [1,2]. Some unexpected meanings and structural features of complex networks can be revealed by the community structure. For this reason, the structure of network is regarded as a common and significant property. In recent years, community discovery is becoming one of research hotspots in the field of biology, physics, sociology, climate and others. Many different approaches have been proposed [1,3,4]. In these approaches, modularity is an important benefit function for measuring the quality of community division in social networks, which is proposed by Newman and Girvan. Besides, many typical algorithms have been declared to community discovery in complex networks, such as LPA, BGLL algorithm etc, which can be found in the literature [5,6].

60 61 62 63 64 65 66

*

Corresponding author. E-mail addresses: [email protected] (M. Yuanyuan), [email protected] (L. Xiyu).

https://doi.org/10.1016/j.physleta.2018.05.044 0375-9601/© 2018 Published by Elsevier B.V.

In the existing algorithms, there are a class of approaches based on evolutionary algorithm (EAs) and swarm intelligence algorithms (SIAs), which has a large volume of research, for example, see [7–10]. These metaheuristics are population-based metaheuristics, which are outstanding for excellent local and global search abilities and suitable for solving optimization problems. In general, finding an underlying community structure in a network can be considered as a problem of cluster analysis. In many clustering algorithms, clustering can be equivalent to an optimization problem, therefore the research of community discovery can be formally defined as an optimization problem. Over the past ten-odd years, many researchers aim to apply EAs and SIAs to community division. Recent surveys could be found in [11–15]. In [11] the authors proposed a memetic algorithm for community detection by optimizing modularity and used multi-level learning strategies to accelerate the optimization process. Pizzuti applied two objective functions to evaluate division result, which were community score and community fitness. Consequently, the community detection problem can be transformed into a multiobjective optimization problem [12]. In [13], authors investigated the GAs with a random walk based on distance measure to study the subgroups in social networks. In [14], authors used a multiobjective discrete particle swarm optimization (MODPSO) algorithm to detect community. These algorithms play a significant role in community detection. However, they still will be confronted with an obstacle in solution limitation. In [11], MLCD algorithm used a multi-level learning

103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132

JID:PLA

AID:25141 /SCO Doctopic: Quantum physics

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44

[m5G; v1.236; Prn:29/05/2018; 15:41] P.2 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

2

strategies and the sub community was the basic unit for merging and splitting. However, if a vertex was misclassified into a sub community, it was hardly to jump out from the sub community in the subsequent stages. The proposed algorithm in [12], the individuals were initialized randomly. Although the individuals were corrected in later period, they failed to make full use of the effective information in the community network, so the initialized individuals were not of high quality. In [13], the proposed algorithms can only solve the community’s division which the number of community were known. Thus the use of these algorithms had some limitations. In 1980, Benioff [16] proposed Quantum mechanical computers. In 1985, Deutsch [17] formalized the description of quantum mechanical computers. Quantum inspired genetic algorithms was firstly introduced in [18]. In [19], a genetic quantum algorithm was proposed by Han et al. which used the concept of qubit (Q-bit) and superposition, the principles of quantum computing. In [20], Han et al. further proposed quantum inspired evolutionary algorithm (QIEA). The essence of the QIEA is to use the superposition of quantum states in quantum mechanics. QIEA uses the qubit as a probabilistic representation and applies it to the chromosome coding, so that one chromosome can express multiple superposition states. Quantum algorithm works in parallel and the encoding and decoding of quantum are nonlinear. Based on this reason, an essential advantage of QIEA over other conventional EAs and SIAs, is QIEA has quantum parallelism and can correspond to a huge number of search states by using a smaller scale population. In addition, the representation of qubit makes QIEA have the characteristics of avoiding premature convergence and keeping the balance between exploration and exploitation even with a smaller population. Ever since emergence, QIEA has been utilized to solve various optimization problems and many other domains [21–26]. Due to the success of QIEA, we attempt this evaluation algorithm to detect community structure. Inspired by the researches above, we propose two complex network detection algorithms, named QIEA-net and iQIEA-net. Furthermore, our two algorithms have the ability to determine the number of cluster automatically, instead of setting the number in advance, which is crucial to analyze a new social network with unknown structure. The paper is organized as follows. We briefly give the related work of community detection in Section 2. In Section 3, two proposed algorithms are described in detailedly. In Section 4, the experimental results on 5 real-world networks are discussed. Finally, this paper is concluded in Section 5.

45 46

2. Related work

47 48

2.1. Network community definition

49 50 51 52 53 54 55 56 57 58

In general, a community can be grouped into sets of vertices (or nodes) if each set of vertices is densely connected internally and relatively sparse connections between groups. A network is denoted as G = ( V , E ) comprising a set V of vertices together with a set of E of edges. Let A be the adjacency matrix of G. Its element A i j is one, if there is an edge from vertex i to vertex j, otherwise, A i j is zero when there is no edge between the two vertices; ki is the degree of vertex i, with ki =

59 60 61 62 63

66

j =1

A i j , i , j = 1, 2, ..., n, where n

is the size of vertices. Network modularity function proposed by Newman [27], also called Q function, which is widely used in the studies of community partition to evaluate a division of a network into communities. Formally, one of the definition of Q -function is

64 65

n 

Q =

1  2m

[ Ai j −

i, j

ki k j 2m

where m is the size of edges and δ(c i , c j ) = 1, if vertex i and vertex j are in the same community, otherwise, δ(c i , c j ) = 0. The value of Q lies in the range between −1 and 1 which can measure the strength of links within communities, rather than the random distribution of links among all communities. Normally, the higher value of Q indicates the stronger community partition of G. The quality is generally fine when Q is between 0.3 and 0.7. In general, Q is difficult to exceed 0.7 in the real-life network. In fact, if we analyze from the perspective of improving modularity, community division will evolve into an optimal clustering problem, which goal is to get optimal or near optimal modularity value. Therefore, several metaheuristics algorithms for finding communities have been utilized to optimize Q -function to discover the community structure with the optimum Q value.

(1)

68 69 70 71 72 73 74 75 76 77 78 79 80 81 82

2.2. Quantum inspired evolutionary algorithm

83

Theoretically, QIEA belongs to the domain of evolutionary algorithms (EAs), which is based upon the concept and principle of the superposition states of quantum bits in quantum computing. Like most EAs, QIEA is also based on the representation of candidate individuals, the fitness function and a population of randomly generated individuals [20]. Unlike traditional EAs, QIEA represents a qubit as a basic information unit. Accordingly, a quantum individual can be defined by a qubit string, which can represent the probability of a linear superposition of states. Therefore, from the point of view of population diversity, the representation of qubit can be more abundant than other classical representations. Furthermore, to generate a next generation population of quantum individuals, QIEA also uses a quantum gate (Q-gate) as an evolutionary operator. In the process of evolution, the diversity property disappears gradually and the quantum individuals eventually converge to a single state. In each iteration, the probability of each qubit is shifting to 1 or 0 under the drive of quantum gate. By these inherent mechanisms, QIEA has the ability to balance exploration and exploitation. A qubit is a linear superposition of the basis states, defined as a column vector

[α β]

T

(2)

84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107

where α and β are probability amplitudes, which satisfy the constrain by the equation |α |2 + |β|2 = 1. In quantum theory, there is a fundamental property that a qubit can be expressed as a linear superposition of |0 and |1. When we measure a qubit, |α |2 is the probability in state ‘0’ and |β|2 is the probability in state ‘1’. Eq. (2) can be represented as α |0 + β|1. Qubit can also be combined. A quantum individual can be considered to a string of n qubit, which have the following states

108



116

α1 α2 · · · αn

 (3)

β1 β2 · · · βn

Where |αi |2 + |βi |2 = 1, i = 1, 2, · · · , n. For example, a three qubit string with three pairs of amplitudes is as follows





5 3

1 2





3 2

− 23



2 2





(4)

2 2

10







10

12

|101 +

110 111 112 113 114 115 117 118 119 120 121 123 124 125



8

8



30

|000 + |001 − |010 − |011 − |100 12 12 12 12 √ √ √ 30

109

122



then the states of this system in the computational basis can be written as

12

]δ(c i , c j )

67

24

12

|110 +

24

12

|111

126 127 128 129 130 131 132

JID:PLA AID:25141 /SCO Doctopic: Quantum physics

[m5G; v1.236; Prn:29/05/2018; 15:41] P.3 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

 1 2

Table 1 The lookup table of θi and

3

xi

4

best i

0 0 0 0 1 1 1 1

5 6 7 8 9 10

0 0 1 1 0 0 1 1

αi βi .

f (x) > f (best ) False True False True False True False True

qtj

θi 0 0 0.05π 0.05π 0.05π 0.05π 0 0

αi βi > 0

αi βi < 0

0 0

0 0

+1 −1 −1 +1

−1 +1 +1 −1

0 0

0 0

αi = 0 0 0 0

0 0

±1 ±1

0 0

0 0 0

0 0

13 14 15 16 17 18 19 20



22

U (θi ) =

23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53

cos(θi ) sin(θi )

−sin(θi ) cos(θi )



αi



αi

±1 ±1



(5)



= U (θi ) βi βi θi = S (αi βi )θi

(6) (7)

Where [αi βi ] T is an updated the ith qubit. θi is a rotation angle toward either 0 or 1 state, which depends entirely on its sign S (αi βi ). S (αi βi ) is defined as the sign of the rotation angle, can be 1, −1 or 0, to determine the direction of convergence. θi is the value of the rotation angle. The values from 0.001π to 0.05π are recommended for the magnitude of θi to control the speed of convergence. Mathematically speaking, using quantum gate, the qubit undergoes a unitary transformation and the update coefficients αi and βi still satisfy |αi |2 + |βi |2 = 1. The lookup table is illustrated in Table 1. Where xi is the ith bit of the current solution x, best i is the ith bit of the searched best solution, and f (x) is the fitness function. Suppose xi = 0, best i = 1 and the condition f (x) > f (best ) is false. If the qubit is located in the first or the third quadrant, θi is a positive value increase the probability of state “1”. However, when the qubit is in the second and the fourth quadrant, θi is a negative value to increase the probability of state “1”. Suppose xi = 0, best i = 1 and the condition f (x) > f (best ) is true. This means x is a better individual, the ith bit of other individuals should increase the probability of state “0”. For more information about quantum gate, see the literature [20,28]. The general structure of QIEA is illustrated in following Algorithm 1.

54 55

Algorithm 1 Quantum inspired evolutionary algorithm (QIEA).

56

1: 2: 3: 4: 5:

57 58 59 60 61 62

t←0 Initialize Q (t ). Make P (t ) by observing the states of Q (t ). Evaluate P (t ) and save the best solution. While the termination condition is satisfied, the current best solution is output. The algorithm is finished, otherwise, goto step 6. 6: Update Q (t ) using quantum gate. 7: t ← t + 1, goto step 3.

63 64 65 66

(8)

t In QIEA, Q (t ) is defined as Q (t ) = {qt1 , qt2 , · · · , qm } at generat tion t, where q j is a quantum individual at generation t defined as

β 0ji

67 68 69



In the initialization step, α = = 1/ 2, j = 1, 2, · · · , m and i = 1, 2, · · · , n. In the step of “Make P (t ) by observing the states of Q (t )”, we can create a population P (t ) = {x1 , x2 , · · · , xm } of binary strings by observing quantum states and x ji means the ith bit in binary string of x j . Draw a random number r ∈ [0, 1], if r > |α ji |2 , the bit of x ji is collapsed to state “1”, otherwise, it is collapsed to state “0”.

Where U (θi ) is a quantum rotation gate and θi is an adjustable quantum gate rotation angle. Therefore, the update of the ith qubit [αi βi ] T can be described as





0 ji

Thus, the above gives the probabilities to represent the states |000, |001, |010, |011, |100, |101, |110 and |111 are 10/144, 10/144, 8/144, 8/144, 30/144, 30/144, 24/144 and 24/144, respectively. We say that the quantum state collapses to a classical state by making measurement. A quantum individual can be modified and evolved by operating with a quantum gate. The following quantum rotation gate can be used as a quantum gate in QIEA, such as

21

αtj1 αtj2 · · · αtjn β tj1 β tj2 · · · β tjn

βi = 0

11 12

=

3

70 71 72 73 74 75 76 77 78

3. Two community detection algorithms based on QIEA in complex network

79 80 81

3.1. QIEA-net

82 83

In our proposed QIEA-net, we apply QIEA to community detection. Through the analysis of community division, the number of clusters for a community with n nodes is no more than l, where √ l ≤ n . If 2k−1 ≤ l ≤ 2k , this means that k is sufficient to represent the division of community network with n nodes. In fact, we have analyzed the conclusions of community partition using differ√ ent algorithms in published literatures. Therefore, we use n as the maximum number of subgroups, which is not based on mathematical reasoning, but the result of statistical analysis. For instance, a community network with 12 nodes, the number of subgroups is usually no more than 4. A two-qubit system with two pairs of amplitudes is enough to indicate a community division within 4 t subgroups. In QIEA-net, Q (t ) = {qt1 , qt2 , · · · , qm } is the population at generation t, where m means the size of population, and qtj is a quantum individual at generation t defined as

 qtj

=

t j1 β tj1

α

t j2 β tj2

α

··· α ···

t j (nk) β tj (nk)



84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100

(9)

101 102 103

where nk is the string length of the quantum individual, n is the number of nodes in a complex network and j = 1, 2, · · · , m. The description of the proposed QIEA-net for complex network clustering is given in Algorithm 2.

104 105 106 107 108

Algorithm 2 QIEA-net. Input: Adjacent Matrix of Community; Max Generation Output: The best modularity; The best clustering result of community. 1: t ← 0 2: Initialize Q (t ) according to the community size 3: Make P (t ) by observing the states of Q (t ) 4: Transform P (t ) into a corresponding community structure C (t ) 5: Evaluate C (t ) by modularity function 6: Store the best solutions among P (t ) into B (t ) 7: while t <= MaxGen do 8: t ←t +1 9: Make P (t ) by observing the states of Q (t − 1) 10: Transform P (t ) into a corresponding community structure C (t ) 11: Evaluate C (t ) by modularity function 12: Update Q (t ) using quantum gates 13: Store the best solutions among B (t − 1) and P (t ) into B (t ). 14: Store the best solution b among B (t ) 15: end while 16: Convert b to the cluster label of each vertex. Output the best value of modularity.

109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126

In step 2,

αi0 and βi0 , i = 1, 2, · · · , nk, of all q0j , j = 1, 2, · · · , m, √

are initialized to 1/ 2. The quantum individual, q0j , indicates the linear superposition of all the probable community structure owning identical probability. It means we firstly divide each vertex randomly into 2k communities.

127 128 129 130 131 132

JID:PLA

AID:25141 /SCO Doctopic: Quantum physics

4

[m5G; v1.236; Prn:29/05/2018; 15:41] P.4 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

1

67

2

68

3

69

4

70

5

71

6

72

7

73

8

74

9

75

10 11 12

76

Fig. 1. (a) A simple network with ten nodes √ identified by BGLL algorithm; (b) Community ID and binary coding; (c) Guiding quantum individual, given which will be found in the known state with the probabilities of 0.9.

13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43

In the step of transformation, each binary solution (j = 1, 2, · · · , m) of P (0), was divided into n groups sequentially, each group has a binary string which length is k. Then we convert each binary string of length k into the corresponding community ID. Finally we transform P (0) into a set of corresponding community structure C (0). C (0) is an m-by-n matrix. In step 5, c 0j ( j = 1, 2, · · · , m) is a possible scheme of commux0j

nity division. Using modularity function (Eq. (2)), each c 0j can be evaluated to obtain the corresponding modularity value. In step 6, according to the best modularity, select the initial best solution in P (0) and store it into B (0). QIEA-net runs in the while loop until the terminating condition is satisfied. In steps of 9, 10 and 11, we make binary solutions in P (t ) by analyzing the status of Q (t − 1), similarly to step 3. Each binary solution is transfered into a corresponding community structure C (t ) and evaluated for the modularity value as in step 4 and step 5. In step 12, all quantum bit individuals in Q (t ) are modified by utilizing quantum gates. In steps of 13 and 14, the optimum solutions in B (t − 1) and P (t ) are chosen and stored in B (t ). Compare the optimal solution in B (t ) to the optimal one in b. If the former is better, b is replaced with the new optimal one.

48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66

Table 2 Network Properties.

80 81

Network

Vertex

Edge

Real clusters

82

Karate Dolphins Football Polbooks Jazz

34 62 115 105 198

78 159 613 441 2742

2 2 12 Unknown Unknown

83 85 86 88

nity ID and corresponding binary representation of each vertex. Fig. 1(c) indicates the definition of guiding Q-bit with the prob√ abilities of 0.9. In addition, other q0j , j = 2, 3, · · · , m, are still



initialized with the probability of 1/ 2, which can guarantee the global search. The improvement of initialization method greatly accelerates the convergence speed. Actually, we can regard iQIEA-net as a special form of QIEA-net, but the iQIEA-net is extraordinary in theory. Compare our proposed algorithms with those algorithms in literatures [24–26], although they are all based on QIEA, there are many differences. For instance, in [24], num Q I E Am algorithm was proposed, in which m was for mutation. Individual mutation could increase the diversity of the population, but when the individual had higher modularity, this mutation was not very effective. In [25], the proposed algorithms was actually a hierarchical bipartitioning approach. If vertex was mistakenly divided in the upper layer, the error would affect the lower layer. In [26], authors focused on the parallel implementations of the above serial algorithms. Unlike these algorithms, we still use the traditional QIEA to detect community structure and utilize guiding quantum individual to approximate the optimal solution in iQIEA-net. The steps are intuitive and easy to implement, and the outcome is unsupervised.

89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111

4. Experiments and results QIEA-net algorithm divides the communities with an approximately optimal value of modularity. Although the QIEA-net has many advantages, it still has space to be improved. In QIEA-net, when initializing Q (t ), we divide each vertex randomly into different communities. For smaller communities, computational complexity and computation time can be ignored. However, we can easily find out that with the size of the community increasing, the initialization method in QIEA-net will seriously affect the convergence of modularity and the accuracy of community division. Therefore, to solve the problem of slow convergence, we propose a novel method, improved QIEA-net (iQIEA-net), which apply the result of classical partitioning algorithm as an initial quantum bit individual. We name this quantum individual as a guiding quantum individual. While other quantum individuals are still assigned to a random community at initialization step. When we initialize the guiding quantum individual, q01 , we usually define a higher probability in order to make q01 close to the existing community division result. In Fig. 1(a), we design an undirected network with 10 vertices and 12 edges, which is divided into 3 modules by BGLL algorithm. Fig. 1(b) shows the commu-

84

87

3.2. Improved QIEA-net (iQIEA-net)

46 47

78 79

In step 3, we make binary solution in P (0) by observing the 0 status of Q (0), where P (0) = {x01 , x02 , · · · , xm } at generation t = 0. 0 Each binary solution, x j , j = 1, 2, · · · , m, is represented as a binary string with the length of nk, which is comprised of 0 or 1. Each bit is 0 or 1 completely determined by the probability, either |αi0 |2 or |βi0 |2 , i = 1, 2, · · · , nk, of q0j , respectively.

44 45

77

112 113

In this section, five real-world networks are discussed to demonstrate the applicability of QIEA-net and iQIEA-net, respectively.

114 115 116 117

4.1. Five real-world networks

118 119

We test the proposed QIEA-net and iQIEA-net on five networks existing in the real world: the Zachary’s Karate Club network (karate) [29], the Dolphins Social network (dophins) [30], the American College Football Network (football) [31], the Copurchased Political Books network (polbooks) [27] and the collaboration network between Jazz musicians (Jazz) [32]. They are extensively applied in the literature of community detection. The basic information of these networks is described in Table 2.

120 121 122 123 124 125 126 127 128

4.2. Parameter setting

129 130

We adjust the population size of quantum individuals based on the number of vertices and edges of the network. In iQIEA-net, pa-

131 132

JID:PLA AID:25141 /SCO Doctopic: Quantum physics

[m5G; v1.236; Prn:29/05/2018; 15:41] P.5 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

1 2 3 4

FN

BGLL

MIGA

Meme-net

GA-net

MOGA-net

MODPSO

QIEA-net

iQIEA-net

Karate

Q max Q av g

0.3807 0.3807

0.4188 0.4188

0.4188 0.3950

0.4020 0.3855

0.4059 0.4059

0.4198 0.4198

0.4198 0.4182

0.4198 0.4198

0.4198 0.4198

Dolphins

Q max Q av g

0.4897 0.4897

0.5118 0.5118

0.5210 0.4631

0.5155 0.4832

0.5014 0.4948

0.5258 0.5225

0.5265 0.5250

0.5213 0.5199

0.5213 0.5211

72

Football

Q max Q av g

0.5497 0.5497

0.6046 0.6046

0.5911 0.5480

0.5888 0.5432

0.5940 0.5833

0.5280 0.5177

0.6046 0.6015

0.5824 0.5567

0.5988 0.5812

74

Polbooks

Q max Q av g

0.5020 0.5020

0.4986 0.4986

0.4988 0.4830

0.4833 0.4478

0.5033 0.4997

0.4993 0.4618

0.5264 0.5263

0.5214 0.5209

0.5269 0.5266

76

Jazz

Q max Q av g

0.4389 0.4389

0.4433 0.4420

0.4372 0.4245

0.4201 0.4131

0.4279 0.4208

0.4440 0.4325

0.4449 0.4312

0.4451 0.4442

0.4451 0.4450

78

11 12 13

69

Index

9 10

68

Network

7 8

67

Table 3 Maximum modularity and average modularity obtained using nine algorithms for several different complex networks.

5 6

5

70 71 73 75 77 79

14

80

15

81

16

82

17

83

18

84

19

85

20

86

21

87

22

88

23

89

24

90

25

91

26

92

27

93

28 29

Fig. 2. Testing algorithms on Zachary’s karate club network: (a) Community structure divided by BGLL algorithm on zachary network; (b) Community structure divided by QIEA-net algorithm on zachary network.

30 31 32 33 34 35 36 37 38 39 40 41 42 43 44

4.3. Experimental analysis

47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66

95 96

rameters are set as follows: on karate network, dolphins network, football network, polbooks network and jazz network, the population size of quantum individuals are set to 50, 200, 400, 200 and 500, respectively. When initializing quantum individuals, we apply the result of BGLL algorithm to define √ the guiding quantum individual, q01 , with the probability of 0.9, in order to make it close to the community division result of BGLL algorithm. The reason why we choose BGLL algorithm is that it can find higher modularity partition and has a linear complexity. This will show obvious advantage in dealing with mass complex network. We only use one instructional quantum individual to direct the population evolution and quicken up the speed of convergence. The maximum of iteration in iQIEA-net and QIEA-net are 700 and 1500. For each algorithm, 30 independent trials are conducted.

45 46

94

In Table 3, we provide the results for the maximum modularity and the average modularity achieved by our algorithm and compare the results to the modularities obtained using several algorithms, which are four EA-based algorithms named MIGA [33], Meme-net [34], GA-net [35], MOGA-net [36] and two classical community detection algorithms named FN [3], BGLL [6], and one PSO-based algorithms named MODPSO [14]. We want to emphasize that our aim in this paper is not to fine tune the model parameters but to provide a proof that QIEA-net and iQIEA-net are capable of producing compatible, even better results with the traditional algorithms in the field of community detection. As shown in Table 3, in addition to Football network, the two proposed algorithms obtain higher modularity than BGLL in other four social networks. We can clearly notice that QIEA-net and iQIEA-net algorithms can discover the community structure with the largest Q values on karate network, polbooks network and Jazz network. The results of QIEA-net and iQIEA-net are slightly lower than MOGA-net and MODPSO, but they are still higher than the vast majority of the partitioning algorithms. Besides, the algorithm

of iQIEA-net also has the best average Q values compared with all other algorithms on karate network, polbooks network and Jazz network. In the process of optimizing modularity, Q is worthy of improvement because the vertex wrongly classified can be readjusted to a more suitable sub community. In addition, with the increase of population size and iteration number we may obtain a higher modularity. Fig. 2 (a) and (b) display the communities detected on karate network using the BGLL algorithm and QIEA-net. Using BGLL, the network is divided into four groups and the modularity is Q = 0.416. Using QIEA-net and iQIEA-net, the peak modularity is Q = 0.4198 and corresponds to a split into four groups. Two vertices, number 28 and number 24, are divided to another community. We can see that the community structure is evident. Fig. 3 (a) and (b) are the two kinds of divisions on dolphins network, which all divide the network into 5 groups. Fig. 3 (a) is the partition by BGLL with Q = 0.5118, and Fig. 3 (b) is the result with higher modularity value ( Q = 0.5213). Fig. 4 (a), (b) and (c) reveal the polbooks network divided into 3, 4 and 4 groups respectively. Fig. 4 (a) is the partitioning by BGLL with the modularity Q = 0.4986. It is clear that Fig. 4 (b) is a further subdivision of Fig. 4 (a). One of the groups is further divided into two sub groups. Fig. 4 (b) has higher modularity obtained by the partition in 4 communities with the modularity Q = 0.5266. In Fig. 4 (c), in order to obtain the highest modularity, the classification of two nodes has been finely adjusted. The greatest advantage of QIEA is that it can represent the exponential numbers of superposition states with fewer qubit and consequently has a huge number of search space. This feature can ensure the diversity of population, avoid falling into local optimal and premature convergence. In iQIEA-net we only use one guiding quantum individual to instruct population evolution and to search the optimal solution at an accelerating convergence rate. For dolphins network and polbooks network, the number of guiding quantum individual: one, three, half of population and all the population, are experimented respectively.

97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132

JID:PLA

6

AID:25141 /SCO Doctopic: Quantum physics

[m5G; v1.236; Prn:29/05/2018; 15:41] P.6 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

1

67

2

68

3

69

4

70

5

71

6

72

7

73

8

74

9

75

10

76

11

77

12

78

13

79

14

80

15

81

16

82

17

83

18

84

19

85

20

86

21

87

22 23

Fig. 3. Testing algorithms on the Dolphins Social network: (a) Community structure divided by BGLL algorithm on dolphins network; (b) Community structure divided by iQIEA-net algorithm on dolphins network.

88 89

24

90

25

91

26

92

27

93

28

94

29

95

30

96

31

97

32

98

33

99

34

100

35

101

36

102

37

103

38

104

39

105

40

106

41

107

42

108

43

109

44 45 46

110

Fig. 4. Testing algorithms on the Co-purchased Political Books network: (a) Community structure divided by BGLL algorithm on polbooks network; (b) Community structure divided by iQIEA-net algorithm on polbooks network with higher modularity; (c) Community structure divided by iQIEA-net algorithm on polbooks network with the highest modularity.

47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66

111 112 113

Fig. 5 is the experiment result of dolphins network and polbooks network with different parameters. Fig. 5 (a) and (b) show the modularity and convergence speed on two social networks. We observe that for these networks, (1) iQIEA-net algorithm is significantly more effective using only one guiding quantum individual than using multiple guides. On dolphins network, we can achieve an approximate optimal modularity ( Q = 0.5213) when we define one or three guiding individuals. However, when we apply half of population or all the population as guiding, although the values of initial modularity are higher, the highest value is still not available. The values of final modularity are 0.5148 and 0.5190 respectively after 600 iterations. The similar situation appears in polbooks network. (2) Higher probability can quicken up the convergence rate of the algorithm. By comparison, we can see that the rate√of con√ vergence of Propability = 0.7 is lower than Propability = 0.9. In √ Fig. 5 (c) and (d), when we define Probability = 2/2 and Number of Guiding = 0, iQIEA-net actually becomes QIEA-net. Fig. 5 (c) and (d) show that the improved algorithms, iQIEA-net, is highly

active, which can obtain higher, even the optimal modularity, through fewer iterations. The result of iQIEA-net is extraordinary both in theory and experiments.

114 115 116 117 118

5. Conclusions

119 120

In our paper, QIEA-net and iQIEA-net are proposed to detect community structure in social networks. We apply the method of optimizing modularity and formulate the detection task to the optimization problem. Moreover, in the process of optimization, the algorithm can determine the best segmentation scheme and the number of the communities, and do not need to adjust too much parameters. In addition, we have done experiments on iQIEA-net using different probability and number of guiding to illustrate that only one guiding quantum individual with higher probability can satisfy the need of accelerating convergence and optimizing. From another point of view, iQIEA-net can accelerate convergence to approximate optimum and avoid the fine tuning of parameters.

121 122 123 124 125 126 127 128 129 130 131 132

JID:PLA AID:25141 /SCO Doctopic: Quantum physics

[m5G; v1.236; Prn:29/05/2018; 15:41] P.7 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

7

1

67

2

68

3

69

4

70

5

71

6

72

7

73

8

74

9

75

10

76

11

77

12

78

13

79

14

80

15

81

16

82

17

83

18

84

19

85

20

86

21

87

22

88

23

89

24

90

25

91

26

92

27

93

28

94

29

95

30

96

31

97

32

98

33 34 35

99

Fig. 5. Comparison of convergence speed with different parameters: (a) iQIEA-net algorithm on dolphins network; (b) iQIEA-net algorithm on polbooks network. (For interpretation of the colors in the figure(s), the reader is referred to the web version of this article.)

36 37 38 39

Acknowledgements

42 43 44 45 46

This research is supported by the National Natural Science Foundation of China (NSFC) (61472231, 61502283 and 61640201), and Social Science Foundation of Shandong Province (16BGLJ06 and 11CGLJ22).

47 48

References

49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66

101 102

Overall, empirical studies in five real-life networks confirm the availability of two proposed algorithms and the efficiency of iQIEAnet algorithm.

40 41

100

[1] M. Newman, M. Girvan, Finding and evaluating community structure in networks, Phys. Rev. E 69 (2) (2004) 026113. [2] P.G. Sun, L. Gao, Y. Yang, Maximizing modularity intensity for community partition and evolution, Inf. Sci. 236 (0) (2013) 83–92. [3] M.E.J. Newman, Fast algorithm for detecting community structure in networks, Phys. Rev. E 69 (6) (2004) 066133. [4] S. Lozano, J. Duch, A. Arenas, Analysis of large social datasets by community detection, Eur. Phys. J. Spec. Top. 143 (1) (2007) 257–259. [5] U.N. Raghavan, R. Albert, S. Kumara, Near linear time algorithm to detect community structures in large-scale networks, Phys. Rev. E 76 (3) (2007) 036106. [6] V.D. Blondel, J.-L. Guillaume, R. Lambiotte, E. Lefebvre, Fast unfolding of communities in large networks, J. Stat. Mech. 10 (2008) 155–168. [7] B. Xue, M. Zhang, W.N. Browne, X. Yao, A survey on evolutionary computation approaches to feature selection, IEEE Trans. Evol. Comput. 20 (4) (2016) 606–626. [8] M. Mavrovouniotis, C. Li, S. Yang, A survey of swarm intelligence for dynamic optimization: algorithms and applications, Swarm Evol. Comput. 33 (2017) 1–17. [9] S.-C. Chu, H.-C. Huang, J.F. Roddick, J.-S. Pan, Overview of algorithms for swarm intelligence, in: International Conference on Computational Collective Intelligence: Technologies & Applications, 2011, pp. 28–41.

[10] X. Liu, L. Xiang, X. Wang, Spatial cluster analysis by the Adleman–Lipton DNA computing model and flexible grids, Discrete Dyn. Nat. Soc. (2012). [11] L. Ma, M. Gong, J. Liu, Q. Cai, L. Jiao, Multi-level learning based memetic algorithm for community detection, Appl. Soft Comput. 19 (2014) 121–133. [12] C. Pizzuti, A multi-objective genetic algorithm for community detection in networks, in: Proceedings of the 21st IEEE International Conference on Tools with Artificial Intelligence, 2009, pp. 379–386. [13] A. Firat, S.C.M. Yilmaz, Genetic clustering of social networks using random walks, Comput. Stat. Data Anal. 51 (2007) 6285–6294. [14] M. Gong, Q. Cai, X. Chen, Complex network clustering by multiobjective discrete particle swarm optimization based on decomposition, IEEE Trans. Evol. Comput. 1 (18) (2014) 82–97. [15] Q. Cai, L. Ma, M. Gong, A survey on network community detection based on evolutionary computation, Int. J. Bio-Inspir. Comput. 8 (2) (2016) 84–98. [16] P. Benioff, The computer as a physical system: a microscopic quantum mechanical Hamiltonian model of computers as represented by Turing machines, J. Stat. Phys. 22 (5) (1980) 563–591. [17] D. Deutsch, Quantum theory, the Church–Turing principle and the universal quantum computer, Proc. R. Soc. Lond. Ser. A, Math. Phys. Sci. 400 (1818) (1985) 97–117. [18] A. Narayanan, M. Moore, Quantum-inspired genetic algorithms, in: Proceedings of IEEE International Conference on Evolutionary Computation, 1996, pp. 61–66. [19] K.-H. Han, J.-H. Kim, Genetic quantum algorithm and its application to combinatorial optimization problem, in: Proceedings of the 2000 Congress on Evolutionary Computation, 2002, pp. 1354–1360. [20] K.-H. Han, J.-H. Kim, Quantum-inspired evolutionary algorithm for a class of combinatorial optimization, IEEE Trans. Evol. Comput. 6 (6) (2002) 580–590. [21] C. Patvardhan, S. Bansal, A. Srivastav, Parallel improved quantum inspired evolutionary algorithm to solve large size quadratic knapsack problems, Swarm Evol. Comput. 26 (2016) 175–190. [22] R. Zhang, Z. Wang, H. Zhang, Quantum-inspired evolutionary algorithm for continuous space optimization based on multiple chains encoding method of quantum bits, Math. Probl. Eng. (2014). [23] J. Cheng, G. Zhang, T. Wang, A membrane-inspired evolutionary algorithm based on population p systems and differential evolution for multi-objective optimization, J. Comput. Theor. Nanosci. 12 (7) (2015) 1–11.

103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132

JID:PLA

8

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

AID:25141 /SCO Doctopic: Quantum physics

[m5G; v1.236; Prn:29/05/2018; 15:41] P.8 (1-8)

M. Yuanyuan, L. Xiyu / Physics Letters A ••• (••••) •••–•••

[24] S. Gupta, N. Kumar, Parameter tuning in quantum-inspired evolutionary algorithms for partitioning complex networks, in: Companion Publication of the Conference on Genetic & Evolutionary Computation, 2014, pp. 1045–1048. [25] S. Gupta, S. Taneja, N. Kumar, Quantum inspired genetic algorithm for community structure detection in social networks, in: Companion Publication of the Conference on Genetic & Evolutionary Computation, 2014, pp. 1119–1126. [26] S. Gupta, S. Mittal, T. Gupta, I. Singhal, B. Khatri, A.K. Gupta, N. Kumar, Parallel quantum-inspired evolutionary algorithms for community detection in social networks, Appl. Soft Comput. 61 (2017) 331–353. [27] M. Newman, Modularity and community structure in networks, Proc. Natl. Acad. Sci. USA 103 (23) (2006) 8577–8582. [28] G. Zhang, Quantuminspired evolutionary algorithms: a survey and empirical study, J. Heuristics 17 (3) (2011) 303–351. [29] W.W. Zachary, An information-flow model for conflict and fission in small groups, J. Anthropol. Res. 33 (4) (1997) 452–473. [30] D. Lusseau, K. Schneider, O. Boisseau, P. Haase, E. Slooten, S. Dawson, The bottlenose dolphin community of Doubtful Sound features a large proportion of long-lasting associations, Behav. Ecol. Sociobiol. 54 (4) (2003) 396–405.

[31] M. Girvan, M. Newman, Community structure in social and biological networks, Proc. Natl. Acad. Sci. USA 99 (12) (2002) 7821–7826. [32] P.M. Gleiser, L. Danon, Community structure in jazz, Adv. Complex Syst. 6 (4) (2003) 565–573. [33] R. Shang, J. Bai, L. Jiao, C. Jin, Community detection based on modularity and an improved genetic algorithm, Phys. A 392 (2013) 1215–1231. [34] M. Gong, B. Fu, L. Jiao, H. Du, Memetic algorithm for community detection in networks, Phys. Rev. E 84 (2011) 056101. [35] C. Pizzuti, GA-net: a genetic algorithm for community detection in social networks, in: Parallel Problem Solving from Nature, PPSN X, International Conference Dortmund, 2008, pp. 1081–1090. [36] C. Pizzuti, A multiobjective genetic algorithm to find communities in complex networks, IEEE Trans. Evol. Comput. 16 (3) (2012) 418–430.

67 68 69 70 71 72 73 74 75 76 77 78 79 80 81

16

82

17

83

18

84

19

85

20

86

21

87

22

88

23

89

24

90

25

91

26

92

27

93

28

94

29

95

30

96

31

97

32

98

33

99

34

100

35

101

36

102

37

103

38

104

39

105

40

106

41

107

42

108

43

109

44

110

45

111

46

112

47

113

48

114

49

115

50

116

51

117

52

118

53

119

54

120

55

121

56

122

57

123

58

124

59

125

60

126

61

127

62

128

63

129

64

130

65

131

66

132