Implementation Issues of Clique Enumeration Algorithm

Implementation Issues of Clique Enumeration Algorithm

05 Progress in Informatics, No. 9, pp.25–30, (2012) 25 Special issue: Theoretical computer science and discrete mathematics Research Paper Implementation issues of clique enumeration algorithm Takeaki UNO1 1National Institute of Informatics ABSTRACT A clique is a subgraph in which any two vertices are connected. Clique represents a densely connected structure in the graph, thus used to capture the local related elements such as clus- tering, frequent patterns, community mining, and so on. In these applications, enumeration of cliques rather than optimization is frequently used. Recent applications have large scale very sparse graphs, thus efficient implementations for clique enumeration is necessary. In this paper, we describe the algorithm techniques (not coding techniques) for obtaining effi- cient clique enumeration implementations. KEYWORDS maximal clique, enumeration, community mining, cluster mining, polynomial time, reverse search 1 Introduction A maximum clique is hard to find in the sense of time A graph is an object, composed of vertices, and edges complexity, since the problem is NP-hard. Finding a such that each edge connects two vertices. The fol- maximal clique is easy, and can be done in O(Δ2) time lowing is an example of a graph, composed of vertices where Δ is the maximum degree of the graph. Cliques 0, 1, 2, 3, 4, 5 and edges connecting 0 and 1, 1 and 2, 0 can be considered as representatives of dense substruc- and 3, 1 and 3, 1 and 4, 3 and 4. tures of the graphs to be analyzed, the clique enumera- tion has many applications in real-world problems, such as cluster enumeration, community mining, classifica- 0 12 tion, and so on. Real-world graph data often has huge sizes but they are usually sparse. The clique sizes are usually bigger than the expected size in the random graphs of the same sizes. It means that the graphs usu- ally have locally dense structures. On the other hand, 34 the number of cliques is usually not so huge, and is often tractable even for huge size graphs. Applica- = , tions having graphs of big sizes but sparse structures For a graph G (V E) of vertex set V and edge set are listed below. E, a clique is a subset of V such that any two its ver- tices are connected by an edge of E. For example, the vertices 0, 1, and 3 compose a clique. A vertex itself is Finding web communities a clique, and two vertices connected by an edge is also Consider a web network graph, in which vertices are a clique. A clique is called maximal if it is included in web sites, and two vertices are connected by an edge no other clique. For example, vertices 0 and 1 compose if the corresponding sites are linked. Then, a clique of a clique, but it is not maximal clique. vertices 0, 1, and this web network graph can be considered to compose a 3 compose a clique, and it is also a maximal clique. community, since they have link in any pair of its mem- bers. Finding web communities by hand is not an easy Received October 10, 2011; Revised December 6, 2011; Accepted December 6, 2011. task. By enumerating the cliques in the web network 1) [email protected] graph, we can automatically find candidates and seeds DOI: 10.2201/NiiPi.2012.9.5 c 2012 National Institute of Informatics 05 26 Progress in Informatics, No. 9, pp.25–30, (2012) of communities. adding edges for all pairs of vertices in the same ver- tex set. If the bipartite graph is sparse, the obtained Application; finding clusters graph becomes dense, thus for the practical efficiency, Suppose that we have data of collection of objects, we should use an implementation designed for bipar- and we want to find groups which we can consider that tite cliques. An implementation named LCM, avail- the members of the group are similar, or have common able on the author’s Web site, is designed for enumerat- features. Such a group is called a cluster. Consider a re- ing closed itemsets in a transaction database. A closed lation graph such that two objects similar to each other itemset is a maximal bipartite clique in the graph rep- is connected. Then, any pair of members of a clique resenting inclusion relation between items and transac- are similar, thus a clique should be totally included in tions in the database, thus we can use LCM for enu- a cluster. Therefore, cliques are used as seeds of clus- merating bipartite maximal cliques. The performance ters. By joining cliques, or appending a clique itera- is significantly better than MACE in the case. tively, clusters can be found. For the purpose maximal The organization of this paper is as follows. In the cliques are good to append, and maximal clique enu- next section, we describe Makino-Uno algorithm, and meration does a big help. the implementation issues and techniques for fast com- putation. We describe the usage of the implementation Existing algorithms in Section 3, and conclude the paper in Section 4. Clique enumeration is actually easy, since the fam- ily of cliques satisfies the monotone property. It ad- 2 Algorithm and implementation issue mits a simple hill climbing algorithm. The iterations Let G = (V, E) be a graph with vertex set V = can be fastened by updating the candidates to be added {1,...,n} and edge set defined on V.Lettail(K)be to the currently operating clique, as described below. the largest vertex in K. Since the graph would be large Conversely, maximal clique enumeration is not easy; scale and very sparse, we load the graph to the mem- maximal cliques can not be traversed by small changes, ory by using adjacency list. Adjacency list is a data such as constant number of addition/deletion of ver- structure for storing graph structure in memory, that tices. There are mainly two algorithms for enumerating uses small amount of memory for sparse graphs. For maximal cliques; one is Makino-Uno algorithm [2] and each vertex, we assign an array of integer, and store the the other is Tomita algorithm [3]. The Makino-Uno al- vertices adjacent to the vertex in the array. The size gorithm is based on reverse search, and is a polynomial of array is thus equal to the degree of the vertex. The time delay algorithm. The Tomita algorithm is not poly- memory usage is one pointer for each vertex, and two nomial time, and uses an efficient pruning methods. By integers for each edge. computational experiments, Tomita algorithm is faster Enumeration of cliques is actually easy. Since any for relatively dense graphs, and Makino-Uno algorithm subset of a clique is also a clique, we can find any clique is faster for relatively sparse graphs. Makino-Uno algo- by iteratively adding vertices to the emptyset. This rithm is based on the algorithm proposed by Tsukiyama yields a depth-first backtracking algorithm; In each it- et al. [1]. eration, for each vertex v not in the current clique K, if K ∪{v} is a clique then recursively call the iteration Contribution to enumerate the cliques including K ∪{v}.Toavoid In this paper, we describe the details of the duplications, we add only vertices larger than tail(K). implementation issues of Makino-Uno algorithm. The implementation is named MACE (MAximal Squeeze the candidates to be added Clique Enumerator), and is available on the au- To execute the above operations quickly, we main- thor’s Web site (http://research.nii.ac.jp/ tain the vertex set CAND(K) which is the set of vertices ˜uno/codes.htm). On the Web site, an implemen- adjacent to all the vertices in K. K ∪{v} is a clique if tation of the Tomita algorithm is also available. The and only if v is in CAND(K), so we have to generate program parts are common, thus we can fairly compare recursive calls for the vertices in CAND(K). When K the performance. is the emptyset, then CAND(K)isV, it means K ∪{v} A subgraph is called bipartite clique if it is a com- is a clique for any vertex v. Denote by N(v)thesetof plete bipartite graph, i.e., the vertex set of the subgraph vertices adjacent to v.ThenCAND(K ∪{v}) is the inter- can be partitioned into two groups such that no edge section of CAND(K)andN(v). By having CAND(K) connect two vertices from the same group, and there is and N(v) in sorted order in the memory, we can take the always an edge connecting two vertices from one group intersection in linear time in the sizes of them. More- and the other group. The bipartite clique enumeration over, in each iteration, we need only vertices larger than problem can also be solved by clique enumeration, by tail(K), thus in the bottom of the recursion, the vertices 05 Implementation issues of clique enumeration algorithm 27 to be maintained are so few. The bottom of the recur- Sweep pointer method sion dominates the total computation time in usual enu- To check this conditions, we use sweep pointer meration algorithms, thus clique enumeration is usually method. (i) is violated when there is a vertex u < v done very quickly. adjacent to all vertices in K(v) ∩ N(v) ∪{v}.Wetrance N(v) in the increasing order of vertices, and when we meet a vertex u not in K(v), check whether u is adja- Maximal clique enumeration by reverse search cent to all vertices in K(v) ∩ N(v) or not.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    6 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us