The Scientific World Journal / 2014 / Article / Alg 1

Research Article

A Fast Overlapping Community Detection Algorithm with Self-Correcting Ability

Algorithm 1

The redistribution algorithm for unallocated nodes.
(1)communities = getCommunities(); /* get the communities of adjacent nodes */
(2)if (communities.   then
(3) /* if the number is 1 */
(4) Add(community); /* join the community */
(5) Return;
(6)else
(7)for communities do
(8)  /* for each community */
(9)  if matchConditions then
(10)   /* judge whether node match the conditions */
(11)   Add(community); /* join community */
(12)  end  if
(13)  end  for
(14)  if averageDistribution() then
(15)  /* if it is equal istribution */
(16)  AddToAll(communities); /* join each community */
(17)  Return;
(18)end  if
(19)if noAdd then
(20)  /* if it doesn't match the above */
(21)  addMaxMembership(); /* join the community getting maximum belonging factor */
(22)end  if
(23)end  if