Journal of Graph Algorithms and Applications Parameterized Algorithmics and Computational Experiments for Finding 2-clubs 156 Hartung Et Al. Algorithms and Experiments for Finding 2-clubs

Given an undirected graph G = (V, E) and an integer ≥ 1, the NP-hard 2-Club problem asks for a vertex set S ⊆ V of size at least such that the subgraph induced by S has diameter at most two. In this work, we extend previous parameterized complexity studies for 2-Club. On the positive side, we give polynomial-size problem kernels for the parameters feedback edge set size of G and size of a cluster editing set of G and present a direct combinatorial algorithm for the parameter treewidth of G. On the negative side, we first show that unless NP ⊆ coNP/poly, 2-Club does not admit a polynomial-size problem kernel with respect to the size of a vertex cover of G. Next, we show that, under the strong exponential time hypothesis, a previous O(2 |V |− · |V ||E|)-time search tree algorithm [Schäfer et al., Optim. Lett. 2012] cannot be improved and that, unless NP ⊆ coNP/poly, there is no polynomial-size problem kernel for the dual parameter |V | −. Finally, we show that, in spite of this lower bound, the search tree algorithm for the dual parameter |V | − can be tuned into an efficient exact algorithm for 2-Club that outperforms previous implementations.


Introduction
Finding cohesive subnetworks in a network is an important task in graphbased data mining and social network analysis.The natural cohesiveness requirement is to demand that the subnetwork is a complete graph, that is, a clique.However, this requirement is often too restrictive and thus relaxed versions such as s-cliques [1], s-plexes [24], and s-clubs [19] have been proposed.An s-club is a graph with diameter at most s, and s-clubs are thus a distance-based relaxation of cliques (which are exactly the graphs of diameter 1).For a constant integer s ≥ 1, the problem of finding large s-clubs is defined as follows.

s-Club
Input: An undirected graph G = (V, E) and an integer ≥ 1. Question: Is there a vertex set S ⊆ V of size at least such that G[S] has diameter at most s?
Clearly, 1-Club is equivalent to the well-known Clique problem.In this work, we consider 2-Club, the most basic variant of s-Club that is different from Clique.Furthermore, 2-Club is also an important special case concerning the applications: For biological networks, 2-clubs and 3-clubs have been identified as the most reasonable diameter-relaxations of Clique [21], further applications of 2-Club arise in the analysis of social networks [18].Consequently, experimental evaluations concentrate on finding 2-clubs and 3-clubs [7,8,17].
Related Work.For all s ≥ 1, s-Club is NP-complete on graphs of diameter s + 1 [3]; 2-Club is NP-complete even on split graphs and, thus, also on chordal graphs [3].For all s ≥ 1, s-Club is NP-hard to approximate within a factor of n1 /2− [2]; a simple approximation algorithm obtains a factor of n 1 /2 for even s ≥ 2 and a factor of n 2 /3 for odd s ≥ 3 [2].Several heuristics [7] and integer linear programming formulations [3,7] for s-Club have been proposed and experimentally evaluated [17].1-Club is equivalent to Clique and thus W [1]-hard with respect to .In contrast, for s ≥ 2, s-Club is fixed-parameter tractable with respect to [8,22,23].s-Club can be solved in O * (2 n− ) time by a search tree algorithm [8,22,23] 1 .s-Club can be formulated in monadic second order logic and thus is fixed-parameter tractable with respect to the treewidth of G [23].Moreover, s-Club does not admit a polynomial kernel with respect to (unless NP ⊆ coNP/poly), but a so-called Turing-kernel with at most k 2 vertices for even s and at most k 3 vertices for odd s [22].2-Club is solvable in polynomial time on bipartite graphs, on trees, and on interval graphs [23].
Our Contribution.We make progress towards a systematic classification of the complexity of 2-Club with respect to structural parameters of the input graph.In Section 2, we give an O(k2 )-vertex kernel for the parameter "size of a cluster editing set" and an O(k)-size kernel for the parameter "feedback edge set size".The kernelization results for these rather large parameters are motivated by our negative results: We show that 2-Club does not admit a polynomial kernel with respect to the size of a vertex cover of the underlying graph, unless NP ⊆ coNP/poly.This excludes polynomial kernels for many prominent structural parameters such as "feedback vertex set size", pathwidth, and treewidth.In Section 3, we give a direct combinatorial algorithm solving 2-Club in 2 O(2 ω ) n 2 time on graphs of treewidth ω.Notably, up to a constant in the exponent, this is also the current best running time for the parameter vertex cover size (which we present in Theorem 4).In Section 4, we study s-Club, s ≥ 2, parameterized by the dual parameter k := n − .We prove that unless the Strong Exponential Time Hypothesis (SETH) 2 fails, s-Club cannot be solved in O * ((2 − ) k ) time for all > 0. This is evidence that the previous search tree algorithm [22] is optimal with respect to the parameter k .Moreover, the presented reduction also implies that s-Club does not admit a polynomial kernel with respect to k unless NP ⊆ coNP/poly.
Having explored the limits of parameterized algorithmics for the dual parameter k on the theoretical side, in Section 5 we examine its usefulness for solving 2-Club in practice.To this end, we implemented the search tree strategy for the dual parameter together with data reduction rules that are partially deduced from our findings in Section 2. We show that our implementation outperforms all previously implemented exact algorithms for 2-Club on random and on large-scale real world graphs.Especially on large graphs the concept of Turing kernelization turns out to be the most efficient technique in our "parameterized toolbox".For the relevant notions of parameterized complexity refer to [11,12,20].A more recent concept not presented in these monographs is Turing kernelization.Roughly speaking, in Turing kernelization one creates polynomially many problem kernels instead of one problem kernel.Then, the solution to the parameterized problem can be computed by solving the problem separately on each of these problem kernels.Throughout this work, we assume that, unless stated otherwise, the structural parameter under consideration is provided as an additional input of the 2-Club instance.Due to the space restrictions, most of the proofs are deferred to a long version of this article.

Kernelization Algorithms and Lower Bounds
In this section, we provide polynomial-size problem kernels for 2-Club parameterized by "cluster editing set size" and "feedback edge set size", respectively.While these parameters can often be rather large, we show that for the (also relatively large) parameter "vertex cover size of G", there exists no polynomial-size problem kernel (unless NP ⊆ coNP/poly).
A Quadratic-Vertex Kernel for the Parameter Cluster Editing Set Size.A cluster editing set of G is a set of edge additions and deletions that transforms G into a vertex-disjoint union of cliques.Let G = (V, E), an integer , and a cluster editing set D be an instance of 2-Club; the parameter is k := |D|.Denote by V (D) the set of all endpoints of the edges in D and observe that G−V (D) is a cluster graph.The following rules yield an O(k 2 )-vertex kernel for 2-Club.The first reduction rule is obvious.A Linear Kernel for the Parameter Feedback Edge Set Size.A feedback edge set of a graph is an edge set whose deletion leads to a forest.Let F ⊂ E be a feedback edge set for G = (V, E).Furthermore, let T := (V, E \ F ) be the forest obtained by deleting F from G. The correctness of the first data reduction rule follows from the fact that for each vertex v the set In the following, we exploit that after application of Rule 4 all 2-clubs of size at least have to "use" feedback edges.The next rule removes all vertices that are not on paths between the endpoints between feedback edges.These vertices are defined as follows.
Definition 1.For a feedback edge {u, v} ∈ F the path P {u,v} between u and v in T is called feedback edge path.If a vertex w lies on the path P {u,v} , then the edge {u, v} is a spanning feedback edge of w.
Rule 5. Let (G, ) be reduced with respect to Rule 4.Then, delete all vertices that do not lie on any feedback edge path.
The final rule removes vertices that are too far away from feedback edges.Rule 6.If there is a vertex v that has in G distance at least three to at least one endpoint of every spanning feedback edge, then remove v.
Applying these data reduction rules exhaustively results in a linear kernel: Theorem 2. The 2-Club problem parameterized by the size k of a feedback edge set admits a kernel of size 6k that can be computed in O(n 4 ) time.
A Kernelization Lower Bound for the Parameter Vertex Cover.We next show that 2-Club does not admit a polynomial kernel with respect to the parameter vertex cover size.This result implies that 2-Club does not admit a polynomial kernel for many structural graph parameters such as feedback vertex set number or treewidth.

Fixed-Parameter Tractability with respect to Treewidth
In this section, we show that 2-Club is fixed-parameter tractable when parameterized by treewidth.To demonstrate the principle idea behind the algorithm, we first describe a fixed-parameter algorithm for the parameter vertex cover.
where k denotes the size of a vertex cover.
Extending the ideas behind Theorem 4, we now give a direct combinatorial algorithm for the parameter treewidth which uses the following lemma.
Lemma 1.Let G be a graph and let S be a 2-club in G.Then, for any tree-decomposition of G there is at least one vertex v ∈ S such that there is a bag that contains N [v] ∩ S.
Proof.Let T = (X 1 ∪ . . .∪ X r , E) be a tree-decomposition of G. Fix an arbitrary vertex u ∈ S and denote by X u any bag in T that contains u.Now, choose a vertex w ∈ S such that the length of the path from X u to the first bag that contains w is maximum.Denote this bag by X w .We show that N (w) ∩ S ⊆ X w .Suppose there is a neighbor v ∈ N (w) ∩ S that is not contained in X w .Since v and w are adjacent and thus are together contained in at least one bag, v is not contained in any bag on the path between X u and X w .This implies that the path from X u to the first bag that contains v is longer than the path between X u and X w ; a contradiction to the choice of w.
• n 2 time where ω denotes the treewidth.
In this section, we prove algorithmic lower bounds for s-Club when parameterized by the dual parameter k := n − .We first show that there is a reduction from Cnf-Sat to s-Club with certain properties that allows to infer these lower bounds.
Lemma 2. There is a parameterized reduction from Cnf-Sat to s-Club where the dual parameter in the constructed s-Club instance is equal to the number of variables in the boolean formula of the Cnf-Sat instance.
Denoting Chen et al. [9] showed that Cnf-Sat does not admit a polynomial kernel unless coNP ⊆ NP/poly.Since Lemma 2 provides a polynomial time and parameter transformation [6] this lower bound result transfers to 2-Club.
Corollary 2. s-Club parameterized by the dual parameter k does not admit a polynomial problem kernel unless coNP ⊆ NP/poly.

Implementation and Experiments
Search tree.We implemented the following search tree strategy to find a maximum 2-club S in a given graph Then, branch into the cases to either delete v from G or to mark v to be contained in S and subsequently delete all vertices in V \ N 2 [v].During branching we maintain a lower bound, that is, the size of a largest 2-club found so far; this lower bound is initialized by the maximum degree plus one.Branching is aborted if the current graph has less than vertices.
After exploring all branches, we output the current lower bound (along with a 2-club of this size).The above search tree strategy was introduced by Bourjolly et al. [7] and has been already experimentally evaluated [8].By simple recursion analysis the running time can be bounded by O * (α n ) where α is the golden ratio with α ≈ 1.62 [8].Schäfer et al. [22] showed that for the dual size parameter k this search tree strategy runs in O * (2 k ) time (if branching is aborted if more than k vertices have been removed).Note that by Corollary 1, the search tree size measured by k cannot be improved unless the SETH fails.
Turing kernelization.Before starting the search tree algorithm, we use the Turing kernelization introduced by Schäfer et al. [22].That is, we compute the Turing kernels consisting of N 2 [v] for all vertices v of the input graph. 3e say N 2 [v] is the Turing kernel for vertex v.Then, as long as at least one Turing kernel is left, we apply the search tree algorithm to the smallest one, say the one for vertex v, to find the largest 2-club in the Turing kernel of v that contains v. Afterwards, we delete v in all other Turing kernels.The maximum 2-club found during this iteration is the output.Note that this is indeed equivalent to what the search tree algorithm does: In one case v is contained in the maximum 2-club S and thus S ⊆ N 2 [v], in the other case v is not contained and can thus be deleted.This observation explains the effectiveness of the search tree algorithms on the considered real-world data from social network analysis: There, the smallest two-neighborhood in the graph is typically much smaller than the entire vertex set, ensuring that all except n nodes in the search tree have limited size.
Heuristic Speed-up.Our main tool for accelerating the search tree algorithm is an extensive application of the following data reduction rules in each branching step.We describe the rules in descending order of observed effectiveness.Herein, let G = (V, E) be the graph of the current branching step.
I1 Vertex Cover Rule: Let G = (V, E ) be the graph where two vertices are adjacent iff they have distance at least three in G. Clearly, if a minimum vertex cover of G has size at least x, then at least x vertex deletions have to be performed in G to obtain a 2-club.We compute a 2-approximate vertex cover C for G that is disjoint to the marked vertices (as they may not be deleted).If |V | − |C|/2 is less than the current lower bound, then abort this branch.I2 Cleaning conflicts with marked vertices: If there is a vertex v ∈ V that has distance at least three to a vertex that is marked to be contained in the 2-club, then delete v.If v is marked, then abort this branch.I3 Common neighbors of marked vertices: If there are two marked vertices with only one common neighbor v, then mark v.We ran all our experiments on an Intel(R) Core(TM) i3-2130 CPU 3.40GHz machine with 8GB memory under the Debian GNU/Linux 6.0 operating system.The program is implemented in Java and runs under Java 1.6.0.18.The source code is freely available from http://fpt.akt.tu-berlin.de/two_club/.We tested our program on random instances as well as on real world data from the 10th DIMACS challenge [10] and compare our running times with recent implementations [8,17].
Random Instances.As in previous experimental evaluations [8,17], we use the random graph generator proposed by Gendreau et al. [13] where the density of the resulting graphs is controlled by two parameters, 0 ≤ a ≤ b ≤ 1, and the expected density is (a + b)/2.Table 5 summarizes our findings (see Table 3, appendix, for a full list).As first observed by Bourjolly et al. [7], density 0.15 produces the hardest instances.We solve instances of these types for n = 150 typically within 2min; previous implementations needed about 6min [8], or up to an hour [17] for these instances.We observed that the key point for the good behavior of our algorithm on these instances is the Vertex Cover Rule that allows quite frequently to prune the search tree.
Real-world Networks.We considered real-world data taken from the 2012 DIMACS challenge [10].To investigate the usefulness of 2-Club as natural clique relaxation concept, we ran our algorithm on instances from the clustering category; to test our algorithm on large scale social network graphs we ran it on graphs from the co-author and citation category.These graphs were obtained by the co-author relationship or the citation relation among authors listed in the DBLP and Citeseer database.In addition to the DIMACS instances, we created a further DBLP coauthor graph, which is the largest instance in our experiments (dblp thres 1).Table 5 shows the results (see Table 4, appendix, for a full list).
We observe that, since the average degree in real world graphs is small, the Turing kernelization typically produces small graphs for our search tree algorithm.We thus can solve all instances from the clustering category within 10s.This is a significant performance increase in comparison to [17] who needed up to 70min for these instances.Moreover, although the co-author/citation graphs are quite large (up to 715,000 vertices), Turing kernelization enabled us to handle them within roughly 30min.
We observed, however, the unexpected behavior that the largest 2-club is on a majority of the real-world instances "just" a maximum degree vertex together with its neighbors.Thus, the question arises whether the resulting community structures are meaningful.In a first step to examine this, we created from a DBLP coauthor graph subgraphs of the pattern dblp thres i where two authors are related by an edge if they coauthored at least i papers.We expected that for moderate values of i, say 2 or 3, the resulting (2-club) communities would have a stronger meaning because there are no edges between authors that are only loosely related.Unfortunately, even for values up to i = 6 this seems not to be the case.We think the main reason for this is the large gap between the maximum degree vertex (around 1000) and the average degree (less than 10).Thus, there seem to be some authors that dominate the overall structure because of their large number of coauthors.Notably, there are only few of these "dominating" authors: less than 200 authors have more than 200 coauthors. 4

Conclusion
On the theoretical side, we extended existing fixed-parameter tractability results for the 2-Club problem by providing polynomial-size kernels for the parameters cluster editing set size and feedback edge set size.Proof.Let v be a vertex that does not lie on any feedback edge path.Then, v is not contained in a cycle in G. Suppose otherwise, and let C be a cycle that contains v. Clearly, C contains at least one feedback edge.In case C contains > 1 feedback edges, then a cycle C with − 1 feedback edges also containing v is obtained by replacing an arbitrary feedback edge with a path consisting only of edges from E \ F (by the minimality of F such a path must exist).In case C contains exactly one feedback edge, v lies on the feedback edge path of this edge, contradicting the initial assumption for v.
Let S be a 2-club containing v. Since v is not contained in any cycle in G, v has degree one in G[S] or v is a cut vertex in G[S].In the first case, S is completely contained in the neighborhood of v's neighbor in G[S].In the second case, S ⊆ N [v].Since G is reduced with respect to Rule 4, S thus has size less than .Consequently, there is no 2-club of size at least that contains v. Therefore, removing v from G yields an equivalent instance.

A.4 Proof 3 (Proof of correctness for Rule 6)
Proof.We show that v is not contained in a 2-club of size at least .Let S be a 2-club containing v. Since v has in G distance at least three to at least one endpoint of every spanning feedback edge, S contains at most one endpoint of every spanning feedback edge.Consequently, either v has degree one in G[S] or v is a cut vertex in G[S].In the first case, S is completely contained in the neighborhood of v's neighbor in G[S].In the second case, S ⊆ N [v].Since G is reduced with respect to Rule 4, S has size less than .Consequently, there is no 2-club of size that contains v. Therefore, removing v from G yields an equivalent instance.

A.5 Proof 4 (Theorem 2)
Proof.Let G be a graph that is reduced with respect to Rules 4, 5, and 6.The size of G can be bounded as follows.There are at most 2k vertices incident with feedback edges; let X denote this vertex set.To show the kernel size, we show that the set Y := V \ X of vertices not incident with any edge in F has size at most 3k.The main idea underlying our proof is that after the reduction rules have been exhaustively applied each vertex of Y is in T either adjacent to an endpoint of some feedback edge or has distance exactly two to both endpoints of a spanning feedback edge.Using this characterization, a size bound of 5k for Y is relatively easy to achieve.In the following, we use a more sophisticated approach to show that |Y | ≤ 3k.
The main idea of the proof is to iteratively add feedback edges to T , and count the number of vertices for which there is a spanning feedback edge whose endpoints have distance at most two to this vertex.More precisely, let T 0 := T and let T k := G. Furthermore, let T i be obtained from T i−1 by adding a feedback edge e with the following property: all feedback edges e such that P e is a subpath of P e are already contained in T i−1 ; in the following, we say that P e covers P e (see Figure 1 for an illustration).Note that finding such an edge e is always possible: If e is covered by an edge e that is not contained in T i−1 , then we consider e .Clearly the path P e is longer than the path P e .Therefore, there has to be some edge whose covering edges are already contained in T i−1 .
For each T i we bound the number of vertices that have distance at most two to both endpoints of a spanning feedback edge; we call these vertices satisfied.To this end, we create a set Y i ⊆ {(v, e) | v ∈ V, e ∈ F }.This set contains pairs of satisfied vertices and spanning feedback edges to which they are attributed.The central property for Y i is that for each satisfied vertex in T i the set Y i contains at least one pair that contains this vertex.Then, the aim is to show that Y k ≤ 3k.
Before proving the claim we introduce some further terminology concerning the feedback edges that will be used in the proof.A feedback edge {u, v} is called u-minimal in T i if there is in T i no feedback edge {u, w} such that the path P {u,w} is a subpath of P {u,v} .A vertex w is an u-neighbor of a feedback edge {u, v} if {u, v} spans w and w is in T a neighbor of u.Now, by induction on i we show that for each i there is a set Y i with the following properties: -|Y i | ≤ 3i, each vertex satisfied in T i is in at least one pair contained in Y i , and if a feedback edge {u, v} is u-minimal in T i , then Y i contains the pair (w, {u, v}) where w is the u-neighbor of {u, v}.
For T 1 , the claim can be proven as follows.By definition, T 1 contains one feedback edge {u, v}.For each satisfied vertex w we add the pair containing (w, {u, v}) to Y 1 .Then Y 1 fulfills the invariant since at most three vertices are satisfied in T 1 : the u-neighbor of {u, v}, the v-neighbor of {u, v} and at most one further inner vertex (this is the case when P {u,v} contains exactly five vertices).
For the inductive step, assume that the claim holds for i − 1, and let {u, v} be the feedback edge that is added from T i−1 to T i .We construct Y i fulfilling the claim as follows.Initially, we set Y i := Y i−1 .Then, for the u-neighbor and the v-neighbor of {u, v}, we add the pair containing {u, v} and the respective vertex to Y i , and, if it exists, a pair containing the vertex that is in T adjacent to both inner neighbors of {u, v}.After these additions, |Y i | ≤ |Y i−1 | + 3. We now show that for each further satisfied vertex that is not satisfied in T i−1 we can add a pair containing this vertex while also removing another pair from Y i without violating the invariant.
All further vertices that are satisfied in T i but not in T i−1 are neighbors of u or v since they must "use" {u, v} in order to have distance two to some endpoint of a spanning edge.Since the neighbors of u and v that are in P {u,v} have already been added to Y i , only satisfied vertices that are not in P {u,v} have to be considered.Let Z denote this set and partition Z into Z u := Z ∩ N T [u] and Z v := Z ∩ N T [v].Clearly, such a partition is possible since every vertex of Z is in T a neighbor of either u or v but not of both.Now consider the set Z v , and let z 1 , . . ., z q denote the vertices in Z v .
By definition, each z j is adjacent to v and there must be a spanning feedback edge e such that in T i but not in T i−1 the vertex z j has distance at most two to both endpoints of e. Consequently, u is one of the endpoints of e, that is, e = {u, w j } for some w j .Moreover, {u, w j } covers {u, v} and furthermore, for all z j 's the w j 's are pairwise distinct.Thus, the situation is as depicted in Figure 2. We now show that for each z j there is a pair (x, {u, p j }) where x is the u-neighbor of {u, v} in Y i that can be removed from Y i without violating the invariant.By the invariant, there is for each spanning edge {u, w j } a u-minimal edge e j that is covered by {u, w j } and such that Y i−1 contains the pair (x, e j ).Since so far, Y i is a superset of Y i−1 this pair is also contained in Y i .Note that since the last edge that was added is {u, v} and by the fact that T i contains no edges that are covered by {u, v} these pairs are pairwise distinct: they must cover {u, v} and thus their endpoints p j are on the paths from v to w j ; these paths are, with the exception of v, vertex-disjoint.Now each such pair can be removed, since after adding {u, v} each edge {u, p j } is not uminimal, and we have already added the pair (x, {u, v}).Consequently, when adding the |Z v | pairs for the satisfied vertices in Z v to Y i we can at the same time safely remove |Z v | pairs without violating the invariant.Analogously, when adding the pairs for Z u , we can also remove |Z v | pairs without violating the invariant.Summarizing, we have The overall kernel bound now follows from |Y | ≤ |Z k | ≤ 3k.We complete the proof by bounding the running time.Clearly, Rule 4 can be exhaustively applied in linear time.The applicability of Rule 5 can be checked in O(m • n) time by considering each edge in F and labeling the vertices on its feedback edge path.After computing an all-pairs shortest path matrix in O(n 3 ) time, the applicability of Rule 6 can be checked in O(m • n) time.The overall running time now follows from the fact that Rule 5 and Rule 6 can be applied at most n times.

A.6 Proof 5 (Theorem 3)
Proof.We give a polynomial time and parameter reduction [4] from Clique parameterized by vertex cover to 2-Club parameterized by vertex cover.Unless NP ⊆ coNP/poly, Clique does admit a polynomial kernel with respect to the size of a vertex cover [5].Let (G = (V, E), X, k) be an instance of Clique parameterized by the size of the vertex cover X.We construct a graph G as follows (for an illustration see Figure 3, appendix).First, add for each vertex v i ∈ X exactly n vertices {v 1 i , . . ., v n i } to G .The construction will ensure that these n vertices are twins in G .Next, add a set V E set of "edge-vertices" as follows.For each edge {v i , v j } ∈ E between two vertex cover vertices v i , v j ∈ X add an edge-vertex e i,j to G and make e i,j adjacent to all vertices in {v 1 i , . . ., v n i , v 1 j , . . ., v n j }.Then, add edges such that V E is a clique.The idea of the construction is to ensure that if a 2-club contains two vertices v x i and v y j , then v i and v j are adjacent in G .Hence, a 2-club containing such vertices corresponds to a clique in G.
In order to handle the case where a size-k clique K in G contains a vertex from V \ X, add the vertex set V \ X to G .Then, for each added vertex v ∈ V \ X and each edge-vertex e i,j ∈ V E add an edge if v is adjacent to v j and v i in G. Observe that the construction runs in polynomial time, that it ensures that V E is a vertex cover for G , and that Thus, it is a polynomial time and parameter reduction.We complete the proof by showing that G has a clique of size k ⇔ G has a 2-club of size at least "⇒": Let K be a size-k clique in G.Then, every pair of vertices v i , v j ∈ K ∩ X has the common neighbor e i,j in G .Hence, by Observation 1, the vertex set S containing the twins of all vertices in K ∩X and and it is also a 2-club: each vertex v x i ∈ S \ V E has with v the common neighbor e i,j where v j is some other vertex in K; similarly, each vertex in V E has a common neighbor with v. "⇐": Let S be a 2-club of size at least that does not contain twins.First, since |V \ X| < n + 1, it follows that S contains a twin-free set of size at least k − 1.Moreover, for each vertex pair {v i , v j } in a twin-free set, the vertex e i,j has to be contained in S as well: otherwise v i and v j have distance greater than two in G[S].Thus, v i is adjacent to v j in G. Therefore, a twin-free set in S corresponds to a clique in G. Hence, if there is a twin-free set of size at least k, then there is a size-k clique in G.It thus remains to consider the case where a largest twin-free set T is of size k − 1.In this case, S contains at least one vertex v ∈ V \ X.Since S is a 2-club, there is for each vertex v i ∈ T at least one edge-vertex e i,j ∈ S that is adjacent to v i and v.By construction, this implies that v i is adjacent to u in G. Consequently, T ∪ {v} is a size-k clique in G.

A.7 Proof 6 (Theorem 4)
Proof.Let (G = (V, E), X, s, ) be an s-Club instance where X with |X| = k is a vertex cover of G. First, branch into all possibilities to choose the subset X ⊆ X that is contained in the desired s-club.Then, remove X \ X and all vertices that are not within distance s to all vertices in X .Clearly, V \ X forms an independent set.Moreover, by Observation 1, it follows that two vertices u, v ∈ V \ X that are twins with respect to X are either both contained in a maximal s-club or none of them.Since there are at most 2 |X | ≤ 2 k different twins, branching into all possibilities to choose them into the s-club takes 2 2 k time.In total, s-Club can be solved in 2 k • 2 2 k • nm time.
A.8 Proof 7 (Theorem 5) Proof.Let (G, k) be an input instance of 2-Club and let ( {X i | i ∈ I} , E) be a nice tree decomposition for G of width ω.By Lemma 1 there is a vertex v ∈ S such that N [v] ∩ S ⊆ X for a bag X.Thus, branch into the O(n • ω • 2 ω ) cases for choosing the bag X, the vertex v and its neighbors in X.
and, afterwards, all vertices that do not have a neighbor in N v .(This is correct, since N v is a dominating set in the desired 2-club.)Set X to be the root of the resulting nice tree decomposition.Next, we describe a bottom-up dynamic programming algorithm on it.Let X i be an arbitrary bag and let v i 1 , v i 2 , . . ., v i n i , |X i | = n i , be the vertices in X i .Furthermore, let {T i 1 , T i 2 , . . ., T i 2 n i } be the set of all possible subsets of X i .We say a vertex u ∈ V is of type T i j if N (u) ∩ X i = T i j .We store a table Tab i for X i that has 2 n i +2 n i rows and the rows contain all 0-1 sequences of length n i + 2 n i .Denoting by r[j] the jth entry of row r, we define V i (r) to be the subset of all vertices in X i whose entry in r is one, formally V i (r) := {v i j ∈ X i | r[j] = 1}, and let T i (r) := {T i j | r[n i + j] = 1} be the set of types whose entry is one.Then, the integer value associated to r is the size of a largest vertex set K i (r) that fulfills the following properties: 1. K i (r) is a subset of vertices occurring in the subtree rooted by X i with is of one of the types in T i (r), 3. for each type in T i j ∈ T i (r) there is at least one vertex u ∈ K i (r) \ V i (r) of type T i j , and 4. in G[K i (r)] each vertex v ∈ K i (r) has distance at most two to all vertices in K i (r) \ V i (r).
If there is no such vertex set K i (r) then set Tab i (r) = −∞.Furthermore, the row r has to be consistent, that is, for every T i j ∈ T i (r) it holds that T i j ⊆ V i (r).If r is not consistent, then again set Tab i (r) = −∞.Once we computed these values in each bag, we look into the root X of the tree decomposition and then take the maximum values of the rows r with N v = V (r).
Computation of the table entries.We now specify how to compute the table Tab i by distinguishing the following cases: Whether the bag X i is a leaf, an introduce node, a join node, or a forget node.First initialize all table entries with −∞.We only look at consistent rows in the following.
Leaf node: Let X i be a leaf in the tree decomposition.Clearly, since K i (r) has to be a subset of vertices in the subtree of X i , we only have to consider the case where T i (r) = ∅.Then K i (r) is equal to V i (r) and, hence, we set Tab i (r) = |V i (r)|.
Introduce node: Let X i be an introduce node with the child node X and let u ∈ X i \ X be the introduced vertex.First, consider rows r of Tab i with u / ∈ V i (r).Then, clearly, we can take the value of the corresponding row r in Tab with V i (r) = V (r ) and T i (r) = T (r ).Second, consider the rows r in Tab i with u ∈ V i (r).Since u / ∈ X , we can set Tab i (r) = −∞ for all rows r containing a set T i j ∈ T i (r) with u ∈ T i j or N (u) ∩ T i j ∩ V i (r) = ∅ (property 4.).For the other rows r take one plus the value of the corresponding row r in Tab with V i (r) = V (r ) and T i (r) = T (r ).
Next, consider the case that the bag X i is a join node and X and X q are the two child nodes with X i = X = X q .For a row r we define R ,q (r) as the set of pairs of rows that "fit" to r: R join ,q (r) := {(r , r Then, Tab i (r) = max (r ,r )∈R join ,q (r) {Tab (r )+Tab (r )}−V i (r).Note that the subtraction of V i (r) avoids double counting the vertices V i (r).
Forget node: Let X i be a forget node with the child node X and u ∈ X \ X i .Then we have to consider the cases that u ∈ K i (r) and u / ∈ K i (r) for each row r in Tab i .Again we define the "fitting" rows: Observe that the first set in the definition of R del (r) catches the cases where u ∈ K i (r) and the second set catches the case that u / ∈ K i (r).Then, Tab i (r) = max r ∈R del (r) {Tab (r )}.
Running time.Clearly, the table Tab i for a leaf X i can be computed in O(2 O(2 ω ) ) time.
The computation of the table for an introduce node X i with child node X can be done in O(2 2•(ω+2 ω ) • 2 2ω ) time: For each of the at most O(2 ω+2 ω ) rows in Tab i we can compute Tab i (r) in O(2 ω+2 ω • 2 2ω ) time: For a row r where the introduced vertex u is not chosen, that is, u / ∈ V i (r) the lookup in the corresponding row in the child bag clearly can be done in the stated time.For a row r where u is chosen the check whether there is a set T i j ∈ T i (r) with u ∈ T i j or N (u) ∩ T i j ∩ V i (r) = ∅ and the lookup in the corresponding row in the child bag also can be done in the stated time.
The computation for a join node X i with the two child nodes X and X q can be done in O(2 3•(ω+2 ω ) • 2 3ω ): Simply check for each combination of rows r ∈ Tab i , r ∈ Tab , r ∈ Tab q whether the pair (r , r ) fulfill the conditions to be contained in R join ,q (r) in O(2 3ω ) and then take the maximum corresponding value of all fitting pairs.The computation for a forget node X i with the child node X can be done in O(2 2•(ω+2 ω ) •2 2ω ) time: Checking for each pair of rows r ∈ Tab i , r ∈ Tab whether r fits to r and then take the maximum of all fitting rows.The checking whether r fits to r can be done in at most O(2 2ω ) time.
Together with the first step where we have guessed the bag X and N v , the total running time can be bound by 2 O(2 ω ) • n 2 .
Correctness.Since our root X contains the vertex set N v and N v is the neighborhood of the vertex v guessed to be contained the desired maximum 2-club S, one can easily verify that S contains max r {Tab(r) | V (r) = N v } vertices.(Because of property 4. and since v dominates N v , each set K i (r) for a row r with V (r) = N v is a 2-club.) It remains to show that the properties 1 to 4 are satisfied in the table of each bag in the tree decomposition.Observe, that the properties are fulfilled for the leafs of the tree decomposition: Since in this case K i (r) = V i (r) there are no vertices in K i (r) \ V i (r).
Next, consider an introduce node X i with child node X , introduced vertex {u} = X i \X , and the table of X satisfy the properties 1 to 4. Let r be some row in the table Tab i .If u / ∈ V i (r) the largest vertex set K i (r) fulfilling the properties 1 to 4 is clearly the set K (r ) with V i (r) = V (r ) and T i (r) = T (r ).Thus, the corresponding table entry is Tab i (r) = Tab (r ).Now consider the other case when u ∈ V i (r).Let K i (r) be the largest vertex set fulfilling the properties.Since property 4 is satisfied u has distance at most two to every vertex in K i (r) \ V i (r).Since u / ∈ X this implies for every vertex w ∈ ∪ {u} and T i (r) = T (r ).Thus, the computed table Tab i fulfills the properties.
Next, consider a join node X i with the two child nodes X and X q , X i = X = X q .First observe that for any two vertex sets K (r ) and K q (r ) fulfilling the properties 1 to 4 it holds that K (r ) ∩ K q (r ) ⊆ X i .Thus, if for a row r the set K i (r) contains a vertex u that appears somewhere in the subtree rooted by X and a vertex w that appears somewhere in the subtree rooted by X q and u, w / ∈ X i , then it is clear that u and w are connected by a vertex in X i , that is N (u) ∩ N (w) ⊆ X i and N (u) ∩ N (w) = ∅.Hence there are two rows r and r such that K i (r) = K (r ) ∪ K q (r ), it holds that V i (r) = V (r ) = V q (r ), for each pair u ∈ K (r ) \ V (r), w ∈ K q (r ) \ V i (r ) there is a vertex x ∈ V i (r) with x ∈ N (u) ∩ N (w), and T i (r) = T (r ) ∪ T q (r ).Note that (r , r ) ∈ R join ,q (r) and, thus, Tab i (r) is indeed the size of a maximum vertex set fulfilling properties 1 to 4.
Finally, consider a forget node X i with the child node X and {u} = X \ X i .There are two cases for the set K i (r): u ∈ K i (r) and u / ∈ K i (r).First consider the case u ∈ K i (r).Then there is a row r such that K i (r) = K (r ) and V i (r)∪{u} = V (r ).Note that the sets T i (r) and T (r ) have to be somewhat "consistent": The vertex u has to be of some type T i j ∈ T i (r) because u ∈ K i (r) \ V i (r) and for all other sets T i j ∈ T i (r), T i j = T i j , there has to be a vertex in K i (r) \ (V i (r) ∪ {u}) being of type T i j .Since u / ∈ X i , this implies that T i j ∈ T (r ) or T i j ∪ {u} ∈ T (r ).Reversely, each set T j ∈ T (r ) need some corresponding set in T i (r), that is, if u ∈ T j , then (T j \ {u}) ∈ T i (r), otherwise T i ∈ T i (r).Note that by definition of R del (r) this implies r ∈ R del (r).Hence, the computed entry Tab i (r) fulfill the properties 1 to 4.

A.9 Proof 8 (Lemma 2)
Proof.We give a parameterized reduction from Cnf-Sat parameterized by the number n of variables to s-Club parameterized by the dual parameter k .Let F be a formula in conjunctive normal form with n variables.Assume without loss of generality that F does not contain a clause that contains the positive and the negative literal of the same variable.In the following, we construct an n -vertex graph G such that for k := n the graph G has an s-club of size at least n − k if and only if F has a satisfying assignment.
First, add the literal vertex set V to G, that is, a set that contains for each variable x in F two vertices, one corresponding to the positive literal x and the other corresponding to ¬x.Next, add for each clause in F two vertices, one called the left clause vertex and the second called the right clause vertex, and make them adjacent to all literal vertices that correspond to the literals occurring in the clause.Denote the set of clause vertices by K. We will ensure that G has the three following properties: 1.The distance between the positive literal vertex and the negative literal vertex of a variable is at least s + 1.All other literal vertices have pairwise distance at most s. 2. For each clause, every path from the left clause vertex v to the right clause vertex w that does not contain any literal vertex from N (v) ∩ N (w) has length at least s + 1.All other clause vertices have pairwise distance at most s. 3.Each literal vertex has a path to each clause vertex that is of length at most s and does not contain any other literal vertex.
From the properties above it is easy to prove the correctness of the reduction: Suppose that by deleting at most k vertices, G can be transformed into an s-club.Since the positive and negative literal vertex of each variable have distance at least s + 1 (property 1), at least one of them has to be deleted.This forces n = k deletions, one for each variable.Consequently, only literal vertices are deleted and the remaining literal vertices correspond to an assignment.Because of property 2, for each left and right vertex of a clause there has to be at least one remaining literal vertex that is a common neighbor.Thus, the remaining literal vertices correspond to a satisfying assignment for F. In the other direction, because of property 3, it is straightforward to argue that deleting all literal vertices that do not correspond to a satisfying assignment results in an s-club.
In the following, we will extend our graph G such that properties 1-3 are fulfilled.Moreover, we ensure that the vertices that we add for this purpose have distance at most s to all other vertices, no matter which of the literal vertices will be deleted.Let A be the set containing all vertex pairs of V ∪ K except the pairs {v 1 , v 2 } where either v 1 and v 2 refer to the same clause (left and right clause vertex) or to the same variable (positive and negative literal vertex).For each vertex pair {v, v } of A add a new vertex {v,v } to the graph.Denote this newly added vertex set by C. Next, connect each vertex ({v,v } ∈ C with v and v by a path of length s/2 each.In case 2 ≤ s ≤ 3, we simply connect the corresponding vertices by an edge.Denote the vertices on the paths without the end points by P .Thus, V (G) = C ∪ P ∪ V ∪ K.
To complete the construction, we make a case distinction between odd and even s.If s is odd, then we complete the construction by adding a distinguished vertex x to C that is adjacent to all vertices in C. If s is even, then we make C a clique.
We now prove for the two cases of odd and even s that G fulfills properties 1-3: Clearly, for each vertex pair v, w ∈ A there is a vertex in {v,w} ∈ C such that v and w have distance s/2 to {v,w} , implying property 3.Moreover, observe that for the positive and negative literal of one variable there is no vertex in C that is reachable within distance s/2 from both vertices and hence their distance is s + 1 (property 1).The same argument holds for the left and right vertex of a clause: All paths that do not contain any literal vertex from the common neighborhood contain at least two vertices from C and thus have length at least s + 1 (property 2).
To complete the proof we show in the following case distinction that the vertices in P ∪ C have distance at most s to all other vertices: Case 1: s ≥ 3 is odd.Let v C ∈ C. First, observe that because of vertex x, C is a 2-club.Moreover, each vertex in P ∪ V ∪ K has distance at most s/2 to at least one vertex in C and thus v C has distance at most 2 + s/2 ≤ s to each vertex in V (G).Consider a vertex v P ∈ P .Clearly, v p has distance at most s/2 −1 to one vertex in C and thus can reach any other vertex in P via x by a path of length at most 2 + 2( s/2 − 1) = s − 1.Note that from this, since each vertex in V ∪ K has at least one neighbor in P , it also follows that v P has distance at most s to each vertex in V ∪ K.
Case 2: s ≥ 2 is even.Let v C ∈ C. Since C is a clique and any vertex in P ∪ V ∪ K has distance at most s/2 to at least one vertex in C, v C has distance at most s/2 + 1 ≤ s to all vertices in V (G).Now, let v P ∈ P .Clearly, v P has distance at most s/2 − 1 to one vertex in C and thus distance at most s − 1 to all other vertices in P .Since any vertex in V ∪ K has at least one neighbor in P , it thus follows that v P has distance at most s to each vertex in V ∪ K.

Preliminaries.
We only consider undirected and simple graphs G = (V, E) where n := |V | and m := |E|.For a vertex set S ⊆ V , let G[S] denote the subgraph induced by S and G − S := G[V \ S].We use dist G (u, v) to denote the distance between u and v in G, that is, the length of a shortest path between u and v.For a vertex v ∈ V and an integer t ≥ 1, denote by N t (v) := {u ∈ V \{v} | dist(u, v) ≤ t} the set of vertices within distance at most t to v.Moreover, set N t [v] := N t (v) ∪ {v}, N [v] := N 1 [v], and N (v) := N 1 (v).Two vertices v and w are twins if N (v)\{w} = N (w)\{v}.The following simple observation will be used throughout this work.Observation 1.Let S be an s-club in a graph G = (V, E) and let u, v ∈ V be twins.If u ∈ S and |S| > 1, then S ∪ {v} is also an s-club in G.

Rule 1 .Rule 2 .Observation 2 .
If there is a cluster C in G − V (D) with |C| ≥ , then reduce to a trivial yes-instance.It follows that any 2-club of size at least has a nonempty intersection with V (D), implying the correctness of the following data reduction rule.If there is a cluster C in G − V (D) such that N (v) ∩ V (D) = ∅ for all v ∈ C, then delete C.After exhaustive application of Rule 2, at most |V (D)| ≤ 2k clusters remain in G − V (D).Since Rule 1 has been applied, each cluster in G − V (D) has size at most − 1.Hence, if ≤ 2k + 1, then there are at most 4k 2 + 2k vertices left and we are done.Now, consider the case where > 2k + 1.To bound the size of the clusters in G−V (D) we use the following observation.Its correctness follows from the fact that two vertices in different clusters of G − V (D) are not adjacent and have no common neighbor.For every 2-club S in G there is at most one cluster C in G − V (D) such that S has a nonempty intersection with C. Observation 2 implies that every 2-club of size at least contains at least − 2k vertices from exactly one cluster C of G − V (D).Since all vertices in C are twins, Observation 1 now implies that in an inclusion-maximal 2club either all or no vertices from C or are contained.Hence, for > 2k + 1 decreasing and the size of each cluster C by − 2k − 1 produces an equivalent instance.This leads to the following data reduction rule.Rule 3. Delete − 2k − 1 arbitrary vertices in each cluster C of G − V (D) and set := 2k + 1.Note that in case |C| ≤ l − 2k − 1 we simply delete all vertices of C.After exhaustive application of Rule 3 for each cluster C it holds that 1 ≤ |C| < 2k + 1.Thus, we arrive at the following.Theorem 1. 2-Club parameterized by the cluster editing set size k admits an O(k 2 )-vertex kernel that can be computed in O(n + m) time.

Theorem 3 . 2 -
Club parameterized by vertex cover has no polynomial kernel unless NP ⊆ coNP/poly.

A. 2
Proof 1 (Theorem 1)Proof.Let I = (G, , D) be an instance that is reduced with respect to Rules 1, 2 & 3. Since I is reduced with respect to Rule 2, there are at most 2k cluster in G − V (G).Each of them has size at most − 1 since I is reduced with respect to Rule 1. Finally, ≤ 2k + 1 since I is reduced with respect to Rule 3. Altogether this implies that G contains at most 4k 2 + 2k vertices.As to the running time, the clusters in G and G − V (D) can be computed in O(n + m) time.Having computed the clusters the data reduction rules can be applied exhaustively in linear time: First, checking the size of a cluster C i or deleting arbitrary vertices in C i is clearly doable in O(|C i |) time.Second, the reduction rules can be applied in one pass by applying Rule 1, then Rule 2, and then Rule 3 (note that Rule 3 does not trigger Rule 1 since it reduces l and |C i | to an equal extent).Hence, the problem kernel can be computed in O(n + m) time.A.3 Proof 2 (Proof of correctness for Rule 5)

Fig. 1 .
Fig.1.Illustration of the definitions in the proof of Theorem 2. Herein, bold edges are feedback edges, regular edges are edges of T .The path P {u,v} connects the endpoints of the feedback edge {u, v} in T .The feedback edge {u, w} covers the feedback edge {u, v}; the feedback edge {u, v} is u-minimal; the u-neighbor of {u, v} is x, the v-neighbor is z; the vertices x, y and z are all satisfied.

Fig. 2 .
Fig. 2. Illustration of the vertices in Zv and of the corresponding spanning edges.

Fig. 3 .
Fig. 3. Example of the construction in the proof of Theorem 3. The graph G is an input for Clique parameterized by vertex cover.The gray vertices are a vertex cover in G.The graph G is constructed as described in the proof of Theorem 3.
[22]number of variables in a boolean formula by n, the Strong Exponential Time Hypothesis (SETH) fails if Cnf-Sat can be solved in O * ((2 − ) n ) time for some > 0[15].Thus, by Lemma 2 an algorithm for s-Club running in O * ((2 − ) k ) time for some > 0 would disprove the SETH.This bound is tight since s-Club can be solved in O * (2 k ) time[22].

Table 1 .
Experimental results on random instances.For each combination of density, n, a, b the other values are the average over 50 instances.
I4 Degree-one vertices: Remove each vertex v that has degree one.If v is marked, then abort this branch.The correctness of Rules I1-I3 is obvious.Rule I4 is correct since we initialized our lower bound by a 2-club formed by a maximum degree vertex and thus a larger 2-club cannot contain degree-one vertices (note that Rule I4 is a special case of Rule 5).

Table 2 .
[10]rimental results on instance from the DIMACS implementation[10]taken from the clustering and the coauthor/citation category.

Table 3 .
Experimental results on random instances.For each combination of density, a, b, and n (number of vertices) the other columns indicate the average values over 50 instances.Thereby, m denotes the number of edges, FES the feedback edge size, max deg the maximum degree, avg deg the average degree, and size the maximum size 2-club found by our algorithm.

Table 4 .
[10]rimental results on instances from the DIMACS implementation[10]taken from the clustering and the coauthor/citation category.