# Integer Programming Approaches to Balanced Connected k-Partition

We address the problem of partitioning a vertex-weighted connected graph into k connected subgraphs that have similar weights, for a fixed integer k≥ 2. This problem, known as the balanced connected k-partition problem (BCP_k), is defined as follows. Given a connected graph G with nonnegative weights on the vertices, find a partition {V_i}_i=1^k of V(G) such that each class V_i induces a connected subgraph of G, and the weight of a class with the minimum weight is as large as possible. It is known that BCP_k is NP-hard even on bipartite graphs and on interval graphs. It has been largely investigated under different approaches and perspectives. On the practical side, BCP_k is used to model many applications arising in police patrolling, image processing, cluster analysis, operating systems and robotics. We propose three integer linear programming formulations for the balanced connected k-partition problem. The first one contains only binary variables and a potentially large number of constraints that are separable in polynomial time. Some polyhedral results on this formulation, when all vertices have unit weight, are also presented. The other formulations are based on flows and have a polynomial number of constraints and variables. Preliminary computational experiments have shown that the proposed formulations outperform the other formulations presented in the literature.

## Authors

• 4 publications
• 3 publications
• 2 publications
• 4 publications
• ### Approximation and parameterized algorithms to find balanced connected partitions of graphs

Partitioning a connected graph into k vertex-disjoint connected subgraph...
08/23/2021 ∙ by Phablo F. S. Moura, et al. ∙ 0

• ### The Graphical Traveling Salesperson Problem has no Integer Programming Formulation in the Original Space

The Graphical Traveling Salesperson Problem (GTSP) is the problem of ass...
06/18/2021 ∙ by Matthias Walter, et al. ∙ 0

• ### R-BBG_2: Recursive Bipartition of Bi-connected Graphs

Given an undirected graph G(V, E), it is well known that partitioning a ...
10/29/2018 ∙ by Ngoc-Tu Nguyen, et al. ∙ 0

• ### Connected k-partition of k-connected graphs and c-claw-free graphs

A connected partition is a partition of the vertices of a graph into set...
07/10/2021 ∙ by Ralf Borndörfer, et al. ∙ 0

• ### An Exact Approach for the Balanced k-Way Partitioning Problem with Weight Constraints and its Application to Sports Team Realignment

In this work a balanced k-way partitioning problem with weight constrain...
09/05/2017 ∙ by Diego Recalde, et al. ∙ 0

• ### Balanced Crown Decomposition for Connectivity Constraints

We introduce the balanced crown decomposition that captures the structur...
11/09/2020 ∙ by Katrin Casel, et al. ∙ 0

• ### Developing Approaches for Solving a Telecommunications Feature Subscription Problem

Call control features (e.g., call-divert, voice-mail) are primitive opti...
01/16/2014 ∙ by David Lesaint, et al. ∙ 0

##### This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

## 1 Introduction

The graphs considered here are simple, connected and undirected. If  is a graph, then denotes its vertex set and denotes its edge set. Later, for some formulations, we shall refer to directed graphs (or simply, digraphs) , with vertex set and arc set . For an integer , as usual, the symbol  denotes the set . Throughout this text, denotes a positive integer number.

Let be a connected graph. A -partition of  is a collection  of nonempty subsets of  such that , and for all , . We refer to each set as a class of the partition. In this context, we assume that , otherwise  does not admit a -partition. We say that a -partition of is connected if , the subgraph of  induced by , is connected for each . Let  be a function that assigns weights to the vertices of . For every subset , we define . To simplify notation, we write  when  is a graph. In the balanced connected -partition problem (), we are given a vertex-weighted connected graph, and we seek a connected -partition such that the weight of a lightest class of this partition is maximized. A more formal definition of this problem is given below, as well as an example of an instance for (see Figure 1). For some fixed positive integer , each input of  is given by a pair . We denote by  the weight of a lightest set in an optimal connected -partition of ; but write simply when  is clear from the context. Furthermore, we simply denote by  the instance in which  is an assignment of a constant value to all vertices (which we may assume to be ).

###### Problem 1.

Balanced Connected -Partition ()
Instance: a connected graph and a vertex-weight function .
Find: a connected -partition of .
Goal: maximize .

There are several problems in police patrolling, image processing, data base, operating systems, cluster analysis, education and robotics that can be modeled as a balanced connected partition problem [2, 14, 15, 16, 17, 22]. These different real-world applications indicate the importance of designing algorithms for , and reporting on the computational experiments with their implementations. Not less important are the theoretical studies of the rich and diverse mathematical formulations and the polyhedral investigations leads to.

Let us denote by  the restricted version of  in which all vertices have unit weight. One may easily check that  on 2-connected graphs can be solved in polynomial time. This problem also admits polynomial-time algorithms on graphs such that each block has at most two articulation vertices [1, 5, 10, 11]. Dyer and Frieze [8] showed that, for every ,   is -hard on bipartite graphs. Wu [21] proved that is -hard even on interval graphs, for all .

For the  (weighted version), Chlebíková [5] showed that this problem is -hard to approximate within an absolute error guarantee of , for all . In that same paper, Chlebíková designed a -approximation algorithm for that problem. For  and on -connected and -connected graphs, respectively, there exist -approximation algorithms proposed by Chataigner et al. [4].

Wu [21] showed the first pseudo-polynomial algorithm for  restricted to interval graphs. Based on this algorithm and using a scaling technique, Wu obtained a -approximation with running time , where  is the number of vertices of the input graph.

Borndörfer et al. [3] designed a -approximation for , where  is the maximum degree of an arbitrary spanning tree of the given graph. This is the first known approximation algorithm on general graphs.

Mixed integer linear programming (MILP) formulations were proposed for  by Matic [18] and for  by Zhou et al. [22]

. Additionally, Matic presented an heuristic algorithm based on a variable neighborhood search (VNS) technique for

, and Zhou et al. devised a genetic algorithm for

. In both works, the authors showed results of computational experiments to illustrate the quality of the solutions constructed by the proposed heuristics and their running times compared to the exact algorithms based on the MILP formulations. No polyhedral study of their formulations was reported.

This paper is organized as follows. In Section 2, we present a natural cut formulation for  and also two stronger valid inequalities for this formulation. A further polyhedral study of this formulation, when all vertices have unit weight, is presented in Section 3. Two of the inequalities in the formulation are shown to define facets, and one of them is characterized when it is facet-defining. In Section 4, we present a flow and a multicommodity flow based formulations for . In Section 5, we report on the computational experiments with our formulations and also with those presented by Matic [18] and Zhou et al. [22]. We summarize our theoretical and practical contributions for  in Section 6.

## 2 Cut formulation

In this section, the following concept will be useful. Let  and  be two non-adjacent vertices in a graph . We say that a set  is a -separator if and belong to different components of . We define  as the collection of all minimal -separators in .

Let be an input for . We propose the following natural integer linear programming formulation  for . For that, for every vertex  and , we define a binary variable  representing that  belongs to the -th class if and only if . In this formulation, to get hold of a class with the smallest weight, we impose an ordering of the classes, according to their weights, so that the first class becomes the one whose weight we want to minimize.

 max ∑v∈V(G)w(v)xv,1 s.t. ∑v∈V(G)w(v)xv,i≤∑v∈V(G)w(v)xv,i+1 ∀v∈V(G),i∈[k−1], (1) ∑i∈[k]xv,i≤1 ∀v∈V(G), (2) xu,i+xv,i−∑z∈Sxz,i≤1 ∀uv∉E(G),S∈Γ(u,v),i∈[k], (3) xv,i∈{0,1} ∀v∈V(G) and i∈[k]. (4)

Inequalities (1) imply a non-decreasing weight ordering of the classes. Inequalities (2) impose that every vertex is assigned to at most one class. Inequalities (3) guarantee that every class induces a connected subgraph. The objective function maximizes the weight of the first class. Thus, in an optimal solution no class will be empty, and therefore it will always correspond to a connected -partition of .

We observe that the separation problem associated with inequalities (3) can be solved in polynomial time by reducing it to the minimum cut problem. Thus, the linear relaxation of  can be solved in polynomial time because of the equivalence of separation and optimization (see [12]).

Since the feasible solutions of the formulation above may have empty classes, to refer to these solutions we introduce the following concept. A connected -subpartition of  is a connected -partition of a subgraph (not necessarily proper) of . Henceforth, we assume that if   is a connected -subpartition of , then for all . For such a -subpartition , we denote by

the binary vector such that its non-null entries are precisely

for all  and  (that is, denotes the incidence vector of ).

We next show that the previous formulation correctly models . For that, let  be the polytope associated with that formulation, that is,

 Pk(G,w)=convex-hull{x∈Bnk:x satisfies inequalities (???)−(???) of Ck(G,w)}.

In the next proposition we show that is the convex hull of the incidence vectors of connected -subpartitions of .

###### Proposition 1.

Let be an input for . Then, the following holds.

 Pk(G,w)=convex-hull{ξ(V)∈Bnk:V is a connected k-subpartition of G}.
###### Proof.

Consider first an extreme point . For each , we define the set of vertices . It follows from inequalities (1) and (2) that  is a -subpartition of  such that  for all .

To prove that is a connected -subpartition, we suppose to the contrary that there exists  such that is not connected. Hence, there exist vertices  and  belonging to two different components of . Moreover, there is a minimal set of vertices  that separates  and  and such that . This implies that , a contradiction to the fact that   satisfies inequalities (3). Therefore, is a connected -subpartition of .

To show the converse, consider now a connected -subpartition  of . By the definition of , it is clear that this vector satisfies inequalities (1) and (2). Take a fixed . For every pair  , of non-adjacent vertices in , and every -separator  in , it holds that , because   is connected. Therefore, satisfies inequalities (3). Consequently, belongs to . ∎

In the remainder of this section we present two further classes of valid inequalities for that strenghten the formulation . We start showing a class that dominates the class of inequalities (3).

###### Proposition 2.

Let  be an input for . Let  and  be two non-adjacent vertices of , and let  be a minimal -separator. Let , where is a minimum-weight path between  and  in  that contains . For every , the following inequality is valid for :

 xu,i+xv,i−∑z∈S∖Lxz,i≤1. (5)
###### Proof.

Consider an extreme point  of , and define  for each . Suppose to the contrary that there is  such that . Since  satisfies inequalities (1), it holds that , a contradiction. Thus, if  and  belong to , then there exists a vertex  such that  also belongs to . Therefore, satisfies inequality (5). ∎

Inspired by the inequalities devised by de Aragão and Uchoa [6] for a connected assignment problem, we propose the following class of inequalities for .

###### Proposition 3.

Let  be an input for , and be an integer. Let be a subset of , the set of neighbors of , and   a subset of  containing  distinct pair of vertices , , . Moreover, let  be an injective function, and let  denote the image of , that is, . If there is no collection of  vertex-disjoint -paths in , then the following inequality is valid for :

 ∑i∈[q](xsi,σ(i)+xti,σ(i))+∑v∈N(S)∑i∈[k]∖Ixv,i≤2q+|N(S)|−1. (6)
###### Proof.

Suppose, to the contrary, that there exists an extreme point  of  that violates inequality (6). Let and . From inequalities (2), we have that . Since violates (6), it follows that . Thus  (because satisfies inequalities (2)). Hence, every vertex in belongs to a class that is different from those indexed by . This implies that every class indexed by contains precisely one of the distinct pairs . Therefore, there exists a collection of  vertex-disjoint -paths in , a contradiction. ∎

Kawarabayashi et al. [13] proved that, given an -vertex graph  and a set of  pairs of terminals in , the problem of deciding whether  contains  vertex-disjoint paths linking the given pairs of terminals can be solved in time . Hence, inequalities (6) can be separated in polynomial time when .

## 3 Polyhedral results for \textsc1−BCPk

In this section we focus on , the special case of in which all vertices have unit weight. In this case, instead of , we simply write , the polytope defined as the convex hull of .

Note that, if the input graph has no matching of size , then has no feasible connected -subpartition  such that  for all , and thus , and it is easy to find an optimal solution. Thus, we assume from now on that  has a matching of size  (a property that can be checked in polynomial time [9]), and that , where .

For each   and  we shall construct a binary vector  that belongs to . Let us denote by  the unit vector such that its single non-null entry is indexed by  and . Now consider any set , , and a bijective function . Since , such a set exists. Fix a pair , where and are as previously defined. Let  be the vector . Note that belongs to , it is the incidence vector of a -subpartition, say of , in which belongs to the class , and each vertex of belongs to one of the classes , all of which are singletons.

To be rigorous, we should write as different choices of and give rise to different vectors, but we simply write with the understanding that it refers to some and bijection .

###### Proposition 4.

is full-dimensional, that is, .

###### Proof.

Let  be the set of  vectors previously defined, that is,  . Assume that . We suppose, with no loss of generality, that the indices of a vector in  are ordered as .

Let be the matrix whose columns are precisely the vectors in (in the following order): . One may easily check that  is a lower triangular square matrix of dimension . Note that the columns of  are precisely the vectors in . Hence the vectors in  are linearly independent. Since , we conclude that , that is, is full-dimensional. ∎

In the forthcoming proofs, we have to refer to some connected -subpartitions of , defined (not uniquely) in terms of distinct vertices , of , and specific classes , , where . For that, we define a short notation to represent the incidence vectors of these connected -subpartitions. Given such , , and , , choose two set of vertices  and  in , both of cardinality , and bijections  and  such that

1. and ;

2. and .

Let  and be vectors in such that their non-null entries are precisely: for every , and for every . The vectors  and  clearly belong to . Moreover, note that  and  for all .

###### Proposition 5.

For every  and , the inequality  induces a facet of .

###### Proof.

Similarly to the proof of Proposition 4, let . Additionally, we define . Note that . Since the null vector and all vectors in  are all affinely independent, and they all belong to the face , we conclude that the inequality  induces a facet of . ∎

In what follows, considering that the polytope is full-dimensional, to prove that a face is a facet of , we show that if a nontrivial face  of  contains , then there exists a real positive constant  such that  and .

###### Proposition 6.

For every , the inequality induces a facet of .

###### Proof.

Fix a vertex . Let , where  corresponds to . Let  be a nontrivial face of  such that . We shall prove that  and  for every  and .

Since is nontrivial and connected, it is easy to see that has a set of nested connected subgraphs such that consists solely of the vertex , each  for , and . (It suffices to consider a spanning tree in , and starting from , define the subsequent subgraphs by adding at each step an appropriate edge and vertex from this spanning tree.)

Consider the set of vectors , where  for every . Since  for all , it follows that . As a consequence,  for all . Additionally,  since .

Let . Suppose that  and  for every  and . Now define the set of vectors . Note that , since  belongs to exactly one class of the partition corresponding to each vector in . By the induction hypothesis, we obtain  for each . Moreover, observe that belongs to . It follows from the induction hypothesis that .

Therefore, we conclude that . Since (otherwise would be a trivial face), it follows that is a multiple scalar of , and therefore  is a facet of . ∎

Let  and  be two non-adjacent vertices of  and let  be a minimal -separator in . We denote by  and  the components of  which contain  and , respectively. Since is minimal, it follows that every vertex in  has at least one neighbor in  and one in .

In this context of minimal -separator , for every , the following two concepts (and notation) will be important for the next result.

We denote by  a minimum size connected subgraph of  containing , with the following properties: If , then is contained in ; if , then is contained in . Otherwise, contains  and exactly one vertex of , that is, . Clearly, such a subgraph always exists. Moreover, if , then the subgraph is connected (that is, is not a cutvertex of ).

For any integer , we say that  admits a -robust subpartition if, for each , there is a connected -subpartition  of  such that for all .

###### Theorem 7.

Let  and  be non-adjacent vertices in , let  be a minimal -separator, and let . Then admits a -robust subpartition if and only if the following inequality induces a facet of :

 xu,i+xv,i−∑s∈Sxs,i≤1.

## 4 Flow formulations

We present in this section a mixed integer linear programming formulation for  based on flows in a digraph. For that, given an input for , we construct a digraph  as follows: First, we add to  a set  of new vertices. Then, we replace every edge of  with two arcs with the same endpoints and opposite directions. Finally, we add an arc from each vertex in  to each vertex of  (see Figure 2). More formally, the vertex set of  is and its arc set is

 A(D)={(u,v),(v,u):{u,v}∈E(G)}∪{(si,v):i∈[k],v∈V(G)}.

Now, the idea behind the formulation is the following: find in  a maximum flow from the  sources in  such that every vertex  in  receives flow only from a single vertex of  and consumes of the received flow. As we shall see, for every , the flow sent from source  corresponds to the total weight of the vertices in the -th class of the desired partition.

To model this concept, with each arc , we associate a non-negative real variable  that represents the amount of flow passing through , and a binary variable  that equals one if and only if arc  is used to transport a positive flow. The corresponding formulation, shown below, is denoted .

 max ∑a∈δ+(s1)fa s.t. ∑a∈δ+(si)fa≤∑a∈δ+(si+1)fa ∀i∈[k−1], (7) ∑a∈δ−(v)fa−∑a∈δ+(v)fa=w(v) ∀v∈V(D)∖S, (8) fa≤w(G)ya ∀a∈A(D), (9) ∑a∈δ+(si)ya≤1 ∀i∈[k], (10) ∑a∈δ−(v)ya≤1 ∀v∈V(D)∖S, (11) ya∈{0,1} ∀a∈A(D) (12) fa∈R≥ ∀a∈A(D) (13)

Inequalities (10) impose that from every source  at most one arc leaving it transports a positive flow to a single vertex in . Inequalities (11) require that every non-source vertex receives a positive flow from at most one vertex of . By inequalities (9), a positive flow can only pass through arcs that are chosen (arcs for which ). Inequalities (8) guarantee that each vertex  consumes  of the flow that it receives. Finally, inequalities (7) impose that the amount of flow sent by the sources are in a non-decreasing order. This explains the objective function.

Since each non-source vertex receives flow from at most one vertex, the flows sent by any two distinct sources do not pass through a same vertex. That is, if a source sends an amount of flow, say , this amount is distributed to a subset of vertices, say (with total weight ); and all subsets are mutually disjoint. Moreover, is exactly the sum of the weights of the vertices that receive flow from , and is a connected subgraph of . (See Figure 2.) It follows from these remarks that formulation  correctly models .

The proposed formulation  has a total of variables (half of them binary), and only  constraints, where and . The possible drawbacks of this formulation are the large amount of symmetric solutions and the dependency of inequalities (9) on the weights assigned to the vertices. To overcome such disadvantages, we propose in the next section another model based on flows that considers a total order of the vertices to avoid symmetries and uncouple the weights assigned to the vertices from the flow circulating in the digraph.

### 4.1 A second flow formulation

Our second formulation for , denoted by , is also based on a digraph  that is constructed from  as follows. It has vertex set and arc set

Moreover, it assumes that there is a total ordering  defined on the vertices of . For simplicity, for a vertex  and integer , we use the short notation instead of .

 max ∑v∈V(D)w(v)y(δ−(v),1) s.t. ∑v∈V(D)∖{s}w(v)y(δ−(v),i)≤∑v∈V(D)∖{s}w(v)y(δ−(v),i+1) ∀i∈[k−1], (14) ∑a∈δ+(s)ya,i≤1 ∀i∈[k], (15) ∑i∈[k]y(δ−(v),i)≤1 ∀v∈V(D)∖{s}, (16) ysv,i+y(δ−(u),i)≤1 ∀u,v∈V(D)∖{s},v≻u,i∈[k], (17) fa,i≤nya,i ∀a∈A(D),i∈[k], (18) ∑a∈δ+(v)fa,i≤∑a∈δ−(v)fa,i ∀v∈V(D)∖{s},i∈[k], (19) ∑i∈[k]∑a∈δ−(v)fa,i−∑i∈[k]∑a∈δ+(v)fa,i=1 ∀v∈V(D)∖{s}, (20) ya,i∈B ∀a∈A(D),i∈[k], (21) fa,i∈R≥ ∀a∈A(D),i∈[k]. (22)

To show that the above formulation indeed models , let us consider the following polytope:

 Qk(G,w)=convex-hull{(y,f)∈B(n+2m)k×R(n+2m)k:(y,f) satisfies ineq. (???)−(???)}.

Let  be a connected -subpartition of  such that  for all . Then, for each integer , there exists in  an out-arborescence  rooted at  such that  and  for all . Now, let  be the function defined as follows: if  is a leaf of , and , otherwise. It follows from this definition that .

We now define vectors  and such that, for every arc and , we have

 ρ(V)a,i={1, if a∈A(→Ti)∪{(s,ri)}0, otherwise,
 τ(V)a,i={gi(a), if a∈A(→Ti)∪{(s,ri)}0, otherwise.

We are now ready to prove the claimed statement on ,

###### Proposition 8.

The polytope is precisely the polytope

 convex-hull{(ρ(V),τ(V))∈B(n+2m)k×R(n+2m)k:V is a % connected k-partition of G}.
###### Proof.

Let be an extreme point of ; and for every , let . It follows from inequalities (16) that, for every vertex , at most one of the arcs entering it is chosen. Observe that inequalities (18) force that a flow of type  can only pass through an arc of type  if this arc is chosen. Hence, every vertex receives at most one type of flow from its in-neighbors. Furthermore, inequalities (19) and (20) guarantee that the flow that enters a vertex and leaves it are of the same type, and that each vertex consumes exactly one unit of such flow.

Inequalities (15) imply that all flow of a given type passes through at most one arc that has tail at the source . Therefore, we have that  is a connected -partition of .

To prove the converse, let  be a connected -partition of . We assume without loss of generality that for all . Let  be a vector such that  and . For each , every vertex in  has in-degree at most one, and  is the smallest vertex in  with respect to the order . Thus, inequalities (16) and (17) hold for . From the definition of , the entry of  indexed by  and  equals one, for all . Consequently,