Upload
others
View
1
Download
0
Embed Size (px)
Citation preview
Bounds and Algorithms for the
Knapsack Problem with Conflict Graph
Andrea Bettinelli, Valentina Cacchiani, Enrico Malaguti
DEI, Universita di Bologna, Viale Risorgimento 2,40136 Bologna, Italy
{andrea.bettinelli, valentina.cacchiani, enrico.malaguti}@unibo.it
Abstract
We study the Knapsack Problem with Conflict Graph (KPCG), anextension of the 0-1 Knapsack Problem, in which a conflict graph describ-ing incompatibilities between items is given. The goal of the KPCG isto select the maximum profit set of compatible items while satisfying theknapsack capacity constraint. We present a Branch-and-Bound approachto derive optimal solutions to the KPCG in short computing times. Alter-native dual bound procedures are compared, as well as different branchingstrategies, and new effective ones are proposed. Extensive computationalexperiments are reported, showing that the proposed method outperformsan existing approach from the literature and a Mixed Integer Program-ming formulation tackled through a general purpose solver.
Keywords: Knapsack Problem, Maximum Weight Stable Set Problem, Branch-and-Bound, Combinatorial Optimization, Computational Experiments.
1 Introduction
The Knapsack Problem with Conflict Graph (KPCG) is an extension of theNP-hard 0-1 Knapsack Problem (0-1 KP, see Martello and Toth [17]) whereincompatibilities between pairs of items are defined. A feasible KPCG solutioncannot include pairs of incompatible items; in particular, a conflict graph isgiven, which has one vertex for each item and one edge for each pair of items thatare incompatible. The KPCG is also referred to as Disjunctively ConstrainedKnapsack Problem.
Formally, in the KPCG, we are given a knapsack with capacity c and aset of n items, each one characterized by a positive profit pi and a positiveweight wi (i = 1, . . . , n). In addition, we are given an undirected conflict graphG = (V, E), where each vertex i ∈ V corresponds to an item (i.e., n = |V|)and an edge (i, j) ∈ E denotes that items i and j cannot be packed together.The goal is to select the subset of items of maximum profit to be packed intothe knapsack, while satisfying the capacity and the incompatibility constraints.The KPCG can also be seen as an extension of the NP-hard Maximum WeightStable Set Problem (MWSSP), where one has to find a stable set of maximum
1
profit. The KPCG generalizes the MWSSP by defining weights for the verticesand by considering a capacity constraint for the set of selected vertices.
Without loss of generality, we assume that∑
i=1,...,n wi > c and that wi ≤ c(i = 1, . . . , n). We also assume that items are sorted by non increasing profit-over-weight ratio, i.e.
p1w1
≥ p2w2
≥ . . . ≥ pnwn
.
Some definitions will be useful in the following. Given a graph G = (V, E),a clique C ⊆ V is a subset of the vertices that induces a complete subgraph. Astable set S ⊆ V is a subset of pairwise non-adjacent vertices. The density of agraph G = (V, E) is defined as the ratio between |E| and the cardinality of theedge set of the complete graph having the same number of vertices.
In this paper, we describe four Branch-and-Bound algorithms to derive op-timal solutions of the KPCG. Alternative dual bound procedures and differentbranching strategies are compared and new effective ones are proposed. The pro-posed algorithms are tested on randomly generated instances, with correlatedand uncorrelated profits and weights, having conflict graph densities between0.1 and 0.9. The performance of the algorithms is compared with a previous ap-proach from the literature, and with a Mixed Integer Programming formulation(MIP) solved through a general purpose solver.
The paper is organized as follows. Section 1.1 reviews exact and heuristicalgorithms proposed for the problem. In Section 1.2, we present two standardMIP formulations of the problem. Sections 2.1 and 2.2 are devoted to thedescription of existing branching rules and bounds, as well as new ones proposedin this paper. In Section 3, we present the computational results obtained bythe proposed algorithms.
1.1 Literature review
The KPCG has been introduced by Yamada et al. [20], in which a greedy al-gorithm, enhanced with a 2-opt neighborhood search, is proposed, as well as aBranch-and-Bound algorithm which exploits a dual bound obtained through aLagrangian relaxation of the constraints representing incompatibilities betweenitems. The algorithms are tested on randomly generated instances with up-to1000 items and very sparse conflict graphs (densities range between 0.001 and0.02). The profits and the weights are assumed uncorrelated (random and in-dependent, ranging between 1 and 100). Hifi and Michrafy [12] present severalversions of an exact algorithm for the KPCG which solves a MIP model. Astarting lower bound is obtained through a heuristic algorithm, then, reductionstrategies are applied, which fix some decision variables to their optimum val-ues, based on the current lower bound value. Finally, the reduced problem issolved by a Branch-and-Bound algorithm. Improved versions apply dichotomoussearch combined with the reduction strategies and different ways of modelingthe conflict constraints. The three versions of the algorithm are tested on in-stances with 1000 items and very sparse conflict graphs (densities range between0.007 and 0.016).
Several heuristic methods have been proposed in the literature. Hifi andMichrafy [11] present a reactive local search based algorithm. It consists indetermining a feasible solution by applying a greedy algorithm, and improving itby a swapping procedure and a diversification strategy. The algorithm is tested
2
on instances randomly generated by the authors by following the generationmethod of [20]. They consider 20 instances with 500 items and capacity equalto 1800, with conflict graph densities between 0.1 and 0.4. In addition theyconsider 30 larger correlated instances with 1000 items and capacity equal to1800 or 2000, with conflict graph densities between 0.05 and 0.1. Akeb et al. [1]investigates the use of local branching techniques (see Fischetti and Lodi [7])for approximately solving instances of the KPCG. The algorithm is tested onthe instances proposed in [11]. Hifi and Otmani [13], propose a scatter searchmetaheuristic algorithm. The algorithm is tested on the instances proposed in[11] and compared with the algorithm therein presented, showing that it is ableto improve many of the best known solutions of the literature. Recently, aniterative rounding search based algorithm has been proposed in Hifi [10]. Thealgorithm is tested on the instances from [11] and compared with the algorithmproposed in [13] and is able to improve many solutions from the literature.
Concerning theoretical studies, Pferschy and Schauer [18] present algorithmswith pseudo-polynomial time and space complexity for two special classes ofconflict graphs: graphs with bounded treewidth and chordal graphs. Fullypolynomial-time approximation schemes are derived from these algorithms. Inaddition, it is shown that the KPCG remains strongly NP-hard for perfectconflict graphs.
The interest in the KPCG is not only as a stand-alone problem, but alsoas a subproblem arising in the solution of other complex problems, such asthe Bin Packing Problem with Conflicts (BPPC) (see e.g., Gendreau et al. [8],Fernandes-Muritiba et al. [6], Elhedhli et al. [4] and Sadykov and Vanderbeck[19]). In this case, the KPCG corresponds to the pricing subproblem of a col-umn generation based algorithm and is solved several times. In this context,it is therefore fundamental to develop a computationally fast algorithm for theKPCG. In Fernandes-Muritiba et al. [6], the KPCG is solved by a greedy heuris-tic and, if the latter fails to produce a negative reduced cost column, the generalpurpose solver CPLEX is used to solve to optimality the KPCG formulated asa MIP. Elhedhli et al. [4] solve the MIP formulation of the KPCG by CPLEX,after strengthening by means of clique inequalities. In Sadykov and Vanderbeck[19], an exact approach for the KPCG is proposed. They distinguish betweeninterval conflict graphs, for which they develop a pseudo-polynomial time algo-rithm based on dynamic programming, and arbitrary conflict graphs, for whichthey propose a depth-first Branch-and-Bound algorithm. The latter algorithmis taken as reference in our computational experiments (Section 3).
1.2 MIP models
This section presents two standard MIP models for the KPCG, where binaryvariables xi ( i = 1, . . . , n) are used to denote the selection of items. These mod-els are solved by a general purpose MIP solver and compared to the algorithmswe proposed (see Section 3).
3
Maximize∑
i=1,...,n
pixi (1a)
s.t.∑
i=1,...,n
wixi ≤ c (1b)
xi + xj ≤ 1 (i, j) ∈ E (1c)
xi ∈ {0, 1} i = 1, . . . , n. (1d)
The objective (1a) is to maximize the sum of the profits of the selecteditems. Constraint (1b) requires not to exceed the capacity of the knapsack.Constraints (1c) impose to choose at most one item for each conflicting pair.Finally, constraints (1d) require the variables to be binary.
Let C be a family of cliques on G, such that for each edge (i, j) ∈ E , i, j ∈ Cfor some clique C ∈ C. A MIP model, equivalent to (1a)-(1d) but having astronger (i.e., smaller) LP-relaxation bound, is the following (see, e.g., Malagutiet al. [16] for a discussion on the heuristic strengthening of edge constraints toclique constraints):
Maximize∑
i=1,...,n
pixi (2a)
s.t.∑
i=1,...,n
wixi ≤ c (2b)
∑i∈C
xi ≤ 1 C ∈ C (2c)
xi ∈ {0, 1} i = 1, . . . , n. (2d)
2 Branch-and-Bound algorithm
A Branch-and-Bound algorithm is based on two main operations: branching,that is, dividing the problem to be solved in smaller subproblems, in such a waythat no feasible solution is lost; and bounding, that is, computing a dual bound(upper bound for a maximization problem) on the optimal solution value of thecurrent subproblem, so that eventually the subproblem can be fathomed. In theBranch-and-Bound algorithm that we propose, a subproblem (associated witha node in a Branch-and-Bound exploration tree) is defined by:
• a partial feasible solution to the KPCG, i.e., a subset S ∈ V of itemsinserted in the knapsack such that S is a stable set and the sum of theweights of the items in S does not exceed the capacity c;
• a set of available items F , i.e., items that can enter the knapsack and forwhich a decision has not been taken yet.
In the next section, we first review the branching rule in Sadykov andVanderbeck [19], and then propose an improvement. The scheme in [19] is
4
derived from the one proposed by Carraghan and Pardalos [2] for the MWSSP.In addition, we discuss a possible adaptation to the KPCG of the branchingrule used by Held et al. [9] for the MWSSP.
In Section 2.2 we introduce possible dual bounds to be integrated with abranching scheme in a Branch-and-Bound algorithm.
In Figure 1 we introduce the notation we need for the description of proce-dures used in the proposed Branch-and-Bound algorithm.
- S: set of items inserted in the knapsack in a given subproblem, i.e.,node of the Branch-and-Bound tree;
- F : set of free items in a given subproblem, i.e., items that can enterthe knapsack and for which a decision has not been taken yet;
- p(V ): sum of the profits of the items in the set V ⊆ V;
- w(V ): sum of the weights of the items in the set V ⊆ V;
- KP (V, c): value of the integer optimal solution of the 0-1 KP withcapacity c on the subset of items V ;
- αp(G(V )): value of the integer optimal solution of the MWSSP withweight vector p on the subgraph induced on the conflict graph G bythe subset of vertices (items) V ;
- LB: current global lower bound;
- N(i): the set of vertices in the neighborhood of vertex i.
Figure 1: Summary of the used notation.
2.1 Branching scheme
2.1.1 Next item KP [19] (nextKP )
Given S and F , at a node of the Branch-and-Bound tree, let p(S) and w(S)be the sum of the profits and of the weights, respectively, of the items in theset S. The idea of the branching in [2, 19] is that a new subproblem has to begenerated for each item i ∈ F , where the corresponding item i is inserted in theknapsack, unless this choice would produce an upper bound not better than thecurrent best known solution value LB.
More in detail, items i ∈ F are sorted by non increasing profit-over-weightratio (pi/wi). Iteratively, the next item i ∈ F in the ordering is considered,F is updated to F = F \ {i}, and an upper bound UBi on the maximumprofit which can be obtained by inserting i in the knapsack is computed asUBi = p(S) + (c − w(S))(pi/wi). UBi is the profit which is obtained by usingthe residual capacity of the knapsack for inserting multiple (fractional) copiesof item i. If UBi > LB, a new child node is created with S = S ∪ {i}, F =F \ ({j ∈ F, j < i} ∪ {j ∈ F, j ∈ N(i)}), where the condition j < i is evaluated
5
according to the ordering. As soon as UBi ≤ LB, the iteration loop is stoppedsince the next items in F would not generate a solution improving on LB, onceinserted in the knapsack.
2.1.2 Presolved KP (preKP )
Let KP (V, c) be the value of the optimal integer solution of the 0-1 KP withcapacity c on the subset of items V . Recalling that items are ordered by non in-creasing profit-over-weight ratio, in a preprocessing phase we compute KP (V, c)for all i = 1, . . . , n, V = {i, . . . , n}, c = 0, . . . , c. This can be done in O(nc) byusing a Dynamic Programming algorithm.
When branching, we iterate on the items i ∈ F sorted by non increas-ing pi/wi ratio. The next item i ∈ F in the ordering is considered and Fis updated to F = F \ {i}. An upper bound on the maximum profit whichcan be obtained by considering items in F ∩ {i, . . . , n} is computed as ˜UBi =p(S)+KP ({i, . . . , n}, c−w(S)). KP ({i, . . . , n}, c−w(S)) is the profit which isobtained by optimally solving the knapsack problem with the items in {i, . . . , n}and the residual capacity, and by disregarding the conflicts.
It is easy to see that, given F , ˜UBi ≤ UBi for each i ∈ F , and thus thebranching rule based on optimally presolving the KP for all the residual ca-pacities would not generate some nodes that are instead generated by the ruleproposed in [19].
In Figure 2 we report the pseudocode for a the generic Branch-and-Boundalgorithm BB based on the scheme from [19] or the improvement described inthis section. The algorithm receives in input sets S, F and the value of theincumbent solution LB, and includes a call to a generic dual bounding pro-cedure (DualBound()) for evaluating the profit which can be obtained fromitems in F and the residual capacity c − w(S). Variuos dual bounding proce-dures are described in Section 2.2. The algorithm can be started by invokingBB(∅, {1, . . . , n}, 0).
2.1.3 Stable set branching
We conclude this section by briefly discussing the branching rules used in theBranch-and-Bound algorithm presented in Held et al. [9] for the MWSSP. LetF ′ ⊆ F be a subset of the free items such that αp(G(F ′)) + p(S) ≤ LB, whereαp(G(F ′)) denotes the value of the integer optimal solution of the MWSSP withweight vector p on the subgraph induced on the conflict graph G by the subsetF ′ of vertices (items). The idea is that, to improve on the current LB, at leastone of the items in F \ F ′ must be used in a solution of the Branch-and-Boundtree descending from a node associated with a set S. Therefore, one can branchby generating from the node one child node for each item in F \F ′. In Held et al.[9] some ideas on how to compute F ′ given the conflict graph G are presented,e.g., one possibility is to compute an upper bound on αp(G(F ′)) by exploitingthe weighted clique cover bound (see Section 2.2.2) . Similarly, pruning rulespresented in Held et al. [9] can be extended to the KPCG. We adapted andtested these ideas for the KPCG but preliminary computational experimentsshowed this extension is not effective.
6
//items are ordered by non increasing profit-over-weight ratioBB(S, F, LB)if LB < p(S) then
LB = p(S)endcompute DualBound(F, c− w(S))if DualBound(F, c− w(S)) + p(S) ≤ LB then
returnendfor i ∈ F do
compute UBi
if UBi > LB thenF = F \ {i}BB(S ∪ {i}, F \N(i), LB)
endelse
breakend
end
Figure 2: Generic Branch-and-Bound scheme for the KPCG.
2.2 Dual bounds
In this section we describe dual bounding (i.e., upper bounding) procedures forthe KPCG.
2.2.1 LP-relaxation of the 0-1 KP
A first possibility for deriving a dual bound for the KPCG is to consider theLP-relaxation of model (1a)-(1d) and neglect the conflict constraints (1c). Theresulting relaxed problem corresponds to the LP-relaxation of a 0-1 KP. Theproblem can be solved in O(n) time (recall that items are ordered by non-increasing profit over weight ratio), by using a greedy algorithm (see Kellereret al. [15]). This dual bound is used in the Branch-and-Bound algorithm pro-posed in Sadykov and Vanderbeck [19], and it is denoted as fractional KP(fracKP ) in the following.
2.2.2 Weighted clique cover bound
As mentioned in Section 1, the KPCG can be interpreted as a MWSSP withan additional capacity constraint, as follows. In the MWSSP, we consider theconflict graph G and assign to each vertex i ∈ V a weight equal to the profit pi ofthe corresponding item i. In addition, each vertex is assigned a second weight,called load in the following, which corresponds to the item weight wi. The goalis to determine a stable set of G of maximum weight (profit), while satisfyingthe capacity constraint (i.e. the sum of the loads of the vertices in the stableset is smaller or equal to the available capacity). By neglecting the capacity
7
p′i := pi ∀i ∈ Vr := 0while ∃i ∈ V : p′i > 0 do
i := argmin{p′i : p′i > 0, i ∈ V}r := r + 1Find a clique Kr ⊆ {j ∈ N (i) : p′j > 0}Kr := Kr ∪ {i}Πr := p′
ip′j := p′j − p′
i∀j ∈ Kr
end
Figure 3: Weighted clique cover algorithm of Held et al. [9].
constraint, dual bounds for the MWSSP are valid dual bounds for the KPCGas well. In particular, we consider the weighted clique cover bound proposed inHeld et al. [9].
A weighted clique cover is a set of cliques K1,K2, . . . ,KR of G, each withan associated positive weight Πr (r = 1, . . . , R), such that, for each vertexi ∈ V,
∑r=1,...,R:i∈Kr
Πr ≥ pi. The weight of the clique cover is defined as∑Rr=1 Πr. The weighted stability number (i.e. the optimal solution value of
MWSSP without capacity constraint) is less or equal to the weight of any cliquecover of G (see [9]). Therefore, the weight of any clique cover is a dual boundfor the MWSSP and consequently it is a dual bound for the KPCG.
Determining the minimum weight clique cover is a NP-hard problem (seeKarp [14]). Held et al. [9] propose a greedy algorithm to compute a weightedclique cover, summarized here for sake of clarity. Recall that N(i) identifies theset of vertices in the neighborhood of vertex i. Initially the residual weight p′iof each vertex i is set equal to its weight pi (profit). Iteratively, the algorithmdetermines the vertex i with the smallest residual weight p′
i, heuristically finds a
maximal clique Kr containing i, assigns weight Πr = pi to Kr, and subtracts Πr
from the residual weight of every vertex in Kr. The algorithm terminates whenno vertex has positive residual weight. A sketch of the algorithm is reported inFigure 3. We denote the dual bound obtained by applying the weighted cliquecover algorithm as CC.
2.2.3 Capacitated weighted clique cover bound
The weighted clique cover bound, described in Section 2.2.2, neglects the ca-pacity constraint. This can lead to a weak dual bound for the KPCG when thecapacity constraint is tight.
We propose a new dual bound, which extends the weighted clique coverbound by taking into account the capacity constraint. We associate with eachclique Kr a load
Wr = Πr minj∈Kr
{wj
pj
}.
The load-over-weight ratio of the clique corresponds to the smallest ratio among
8
p′i := pi ∀i ∈ Vr := 0while p′ 6= 0 ∧
∑rh=0 Wh < c do
i := argmin{wi
pi: p′i > 0, i ∈ V}
r := r + 1Find a clique Kr ⊆ {j ∈ N (i) : p′j > 0}Kr := Kr ∪ {i}t := argmin{p′t : p′t > 0, t ∈ Kr}Wr := min{p′t
wi
pi, c−
∑rh=0 Wh}
Πr := min{p′t, Wr
wi/pi}
p′j := p′j − p′t ∀j ∈ Kr
end
Figure 4: Capacitated weighted clique cover algorithm.
all the vertices in the clique.Having defined the load of a clique, the following result, for which a proof is
given at the end of the section, holds:
Theorem 1. The weight∑
Kr∈K Πr of a partial weighted clique cover K satis-fying ∑
Kr∈KWr = c (3)
and
minKr∈K
{Πr
Wr
}≥ max
j∈V
pjwj
:∑
Kr∈K:j∈Kr
Πr < pj
. (4)
is a valid upper bound for the KPCG.
We define as Minimum Weight Capacitated Clique Cover the problem offinding a (possibly partial) clique cover of minimum weight that either: i) is acomplete clique cover, or ii) satisfies (3) and (4).
Determining the minimum weight capacitated clique cover is NP-hard, sinceit is a generalization of the minimum weight clique cover. Therefore we de-veloped a greedy algorithm, denoted as capacitated weighted clique cover algo-rithm, that iteratively builds a clique cover while satisfying (4). The algorithmis stopped as soon as (3) is satisfied or the clique cover is complete.
A sketch of the algorithm is reported in Figure 4. The algorithm iterativelydetermines the vertex i with the best (i.e., the smallest) load-over-weight ratio,and heuristically constructs a maximal clique Kr containing i. The weight Πr
is subtracted from the weight of every vertex in Kr. The algorithm terminateswhen all the vertices have been covered according to their corresponding weightsor when the capacity is saturated. We denote the dual bound obtained byapplying the capacitated weighted clique cover algorithm as capCC.
The above algorithm has a worst case computational complexity of O(n3),realized when G is a complete graph, c = ∞ and all the profits are different.
9
The complexity decreases for sparser graphs, and becomes linear for a graphwith empty edge set.
Proof of Theorem 1
We introduce the following notation for convenience, to be used in the proof ofTheorem 1:
- p(K) :=∑
Kr∈K Πr,
- w(K) :=∑
Kr∈K Wr.
Let S∗ be an optimal solution of the KPCG. We partition S∗ into S∗, thatdenotes the set of items in the optimal solution that are fully covered by cliquesin K, and S∗ = S∗ \ S∗. Similarly, we partition K into K, that denotes the setof cliques containing one item in S∗ (note that each clique in K contains exactlyone item of S∗ because S∗ does not contain conflicting items), and K = K \ K.
Without loss of generality, we can assume that no item is overcovered, i.e.∑Kr∈K Πr ≤ pi, i ∈ V. Therefore, for all items in S∗, since they are fully
covered, it holds: ∑Kr∈K:i∈Kr
Πr = pi, i ∈ S∗. (5)
In order to prove Theorem 1, we need the following lemma.
Lemma 2. w(K) ≥ w(S∗).
Proof. We first show that w(K) ≤ w(S∗).Let Kr be a clique in K containing an item i ∈ S∗. By definition of the
clique weight: Wr = Πr minh∈Kr
{wh
ph
}, therefore: Wr ≤ Πr
wi
pi.
By summing over all the cliques in K that contain item i, we obtain:∑Kr∈K:i∈Kr
Wr ≤ wi
pi
∑Kr∈K:i∈Kr
Πr.
Since no item is overcovered and i ∈ S∗, by applying (5), we get that∑Kr∈K:i∈Kr
Wr ≤ wi
pipi = wi.
Now let us sum over all items in S∗:∑
i∈S∗∑
Kr∈K:i∈KrWr ≤
∑i∈S∗ wi.
By the definition of the partitions, and recalling that each clique in K con-tains exactly one item in S∗, we obtain that: w(K) ≤ w(S∗).
Now, since S∗ is an optimal solution of the KPCG, then it satisfies thecapacity constraint. Therefore: w(S∗) ≤ c. In addition, from (3), w(K) = c.Then w(S∗) + w(S∗) = w(S∗) ≤ c = w(K) = w(K) + w(K).
Since w(K) ≤ w(S∗), then w(K) ≥ w(S∗).
We can now prove Theorem 1.
Proof. We want to show that p(K) ≥ p(S∗), i.e. p(K) is a valid upper bound forthe KPCG. We will prove it by showing that: p(K) = p(S∗) and p(K) ≥ p(S∗).
• p(K) = p(S∗)
From (5) we have:∑
Kr∈K:i∈KrΠr = pi, i ∈ S∗. By summing over all
items in S∗, we get:∑
i∈S∗∑
Kr∈K:i∈KrΠr =
∑i∈S∗ pi.
Taking into account that each clique contains exactly item of S∗, we have:p(K) = p(S∗).
10
• p(K) ≥ p(S∗)
p(S∗) =∑
i∈S∗ pi; if we multiply and divide by wi, and replace pi
wiwith
maxj∈S∗
{pj
wj
}, we have:∑
i∈S∗ pi =∑
i∈S∗ piwi
wi≤
∑i∈S∗ maxj∈S∗
{pj
wj
}wi = maxj∈S∗
{pj
wj
}w(S∗).
Now, let us replace in (4) K with K and V with S∗: the inequality stillholds since K ⊆ K and S∗ ⊆ V:
minKr∈K
{Πr
Wr
}≥ maxj∈S∗
{pj
wj
}.
Then, we obtain:
maxj∈S∗
{pj
wj
}w(S∗) ≤ minKr∈K
{Πr
Wr
}w(S∗).
By applying Lemma 2, we obtain:
minKr∈K
{Πr
Wr
}w(S∗) ≤ minKr∈K
{Πr
Wr
}w(K).
By definition of the partitions and by replacing the minimum over K withthe corresponding sum:
minKr∈K
{Πr
Wr
}w(K) = minKr∈K
{Πr
Wr
}∑Kh∈K Wh ≤
∑Kh∈K Wh
Πh
Wh=
p(K).
By combining the inequalities, we finally obtain: p(K) ≥ p(S∗).
2.3 Dual bounds relations
In this section we discuss the theoretical relations between dual bounds. Wesay that bound A dominates bound B if the value of A is never larger than thevalue of B, thus providing a better information on the optimal solution value ofthe KPCG.
Since clique inequalities (2c) are a strengthening of inequalities (1c), we havethat:
Proposition 3. The LP-relaxation of model (2a)-(2d) dominates the LP-relaxationof model (1a)-(1d) .
Proposition 4. If C is the set of all cliques of G, then the LP-relaxation ofmodel (2a)-(2d) dominates the bound obtained by optimally solving the minimumweight clique cover problem.
Proof. The minimum weight clique cover problem is the dual of the LP-relaxationof model (2a)-(2d) without the capacity constraint (2b).
Enumerating in C all the cliques of G is NP-hard and impractical, thus in ourimplementation C is a subset of the clique set and, similarly, the clique coverproblem is heuristically solved by considering a subset of the clique set. For thesereasons, the dominance property of Proposition 4 is not valid. Nevertheless,as discussed in Section 3, the LP-relaxation of model (2a)-(2d) gives tighterbounds.
11
Proposition 5. The bound obtained by optimally solving the minimum weightcapacitated clique cover problem dominates the bound obtained by optimally solv-ing the minimum weight clique cover problem.
Proof. Any clique cover can be transformed into a partial clique cover thatsatisfies (3) by removing the cliques with worst load-over-weight ratio. Theresulting partial clique cover, by construction, satisfies (4).
Proposition 6. The bound obtained by optimally solving the minimum weightcapacitated clique cover problem dominates fracKP .
As previously mentioned, we do not solve to optimality the minimum weightclique cover and minimum weight capacitated clique cover problems, instead,these problems are tackled by means of heuristic algorithms, producing thedual bounds CC and capCC, respectively. Concerning the relation betweenCC, capCC and fracKP , by applying similar arguments to those above, wehave:
Proposition 7. If CC and capCC consider the same cliques in the same order,then capCC dominates CC.
and
Proposition 8. capCC dominates fracKP .
3 Computational experiments
The procedures described in the previous sections were coded in C, and theresulting algorithms were tested on a workstation equipped with an Intel XeonE3-1220 3.1 GHz CPU and 16 GB of RAM, running a Linux operating system.
3.1 Benchmark instances
When considering exact algorithms, two different groups of instances of knap-sack problems with the addition of a conflict graph were proposed in the liter-ature.
A first group of instances considers conflict graphs with densities rangingfrom 0.1 to 0.9. It includes instances from papers solving to optimality the BinPacking Problem with Conflict Graph through a Branch-and-Price algorithm [6,4, 19]. In the latter case the KPCG arises as subproblem in column generation,and the profits associated with the items vary from iteration to iteration. All thelast three mentioned papers derive their instances from the set of Bin Packingproblems proposed by Falkenauer [5]. They consist of 8 classes each composedby 10 instances; in the first 4 classes the items have a weight with uniformdistribution in [20, 100] and the knapsack capacity is c = 150. The number nof items is 120, 250, 500 and 1000, respectively. The last 4 classes have weightswith uniform distribution in [250, 500] and c = 1000. Items are generated bytriplets and they consist of 60, 120, 349, 501 items. Each triplet in this class isgenerated so as to form an exact packing in the knapsack. Following [19], wehave generated random conflict graphs for each instance with density values inthe range from 0.1 to 0.9. We have also added a profit associated with each
12
item (profits are not defined for the Bin Packing Problem with Conflict Graph).We have considered two settings: random profits uniformly distributed in therange [1, 100], and correlated profits: pi = wi + 10 (i = 1, . . . , n). Finally, sincein the original setting only a small number of items can be accommodated inthe knapsack, we have considered the same instances with larger capacity of theknapsack (i.e., the original capacity is multiplied by an integer coefficient). Eachdataset1 is denoted by a capital letter, identifying the setting used for the profit(“R” for random profits and “C” for correlated profits) and a number denotingthe multiplying coefficient for the knapsack capacity. In addition, 20 instancesintroduced in [11], for which only heuristic results are reported in the literature,have similar densities. However, these instances are not available anymore.
A second group of instances considers very sparse conflict graphs, with den-sities ranging from 0.001 to 0.02, as the ones considered in [20, 11, 12]. Forthese instances, the algorithms proposed in this paper are not effective, mainlybecause the conflict graphs are too sparse, and methods which rely on explicitlyexploiting conflicts, like the ones we consider, are ineffective.
3.2 Dual bounds comparison
In Tables 1 and 2 we report the results obtained by applying the dual boundspresented in Section 2.2, and compare them with the 0-1 Knapsack bound (KP )obtained by disregarding the incompatibility constraints in model (1a)-(1d), andwith the linear relaxation of model (1a)-(1d) (lp(1a)−(1d)) and of model (2a)-(2d) (lp(2a)−(2d)). In particular, we consider the linear relaxation of the 0-1KP (fractional knapsack, fracKP ), the weighted clique cover algorithm (CC)and the capacitated weighted clique cover algorithm (capCC). In Table 1 theinstances are grouped by dataset, and in Table 2 the instances are grouped bydensity, reported in the first column of the corresponding table, respectively.Then, for each considered dual bound UB, the tables report the percentageoptimality gap computed as: 100UB−z∗
z∗ , where z∗ is the optimal (or the bestknown) solution value.
As expected, the quality of the bound based on the linear relaxation ofthe 0-1 KP constraints only (column fracKP ) decreases with the increase ofthe density of the incompatibility graph. We observe that solving the 0-1 KPto optimality (column KP ) would not produce significant improvements (andis computationally expensive). The CC bound, that takes into account theincompatibility constraints and drops the knapsack constraints, is very weakeven on dense instances. The capCC bound, which combines the information onincompatibilities and capacity, outperforms the other combinatorial bounds. Asmentioned in Section 2.2.3, it dominates fracKP and it dominates CC as wellif the clique cover is the same. Since we use a greedy heuristic to compute theclique cover, this theoretical property is no longer valid. Nevertheless, in all theconsidered instances, capCC gives a stronger dual bound than CC. There is nofull dominance between KP and capCC. However KP produces a better boundonly on instances with very tight knapsack constraint and sparse conflict graph.Finally, the linear relaxation lp(2a)−(2d), where incompatibilities are expressedby clique constraints, is tighter than all the other bounds, with the exceptionof the capCC for very dense conflict graphs (density = 0.9) and correlated
1Instances are available at www.or.deis.unibo.it
13
instances with very large capacity (C10). lp(2a)−(2d) is the bound which isexploited when solving model (2a)-(2d) with a MIP solver. However, we pointout that this dual bound is more expensive from the computational viewpoint.
dataset fracKP KP CC capCC lp(1a)−(1d) lp(2a)−(2d)
R1 29.69 17.15 1608.59 18.50 22.69 12.38R3 97.59 95.35 764.15 41.07 76.60 24.40R10 378.01 377.25 641.81 104.01 290.52 89.30C1 4.25 3.07 2446.71 2.89 3.65 2.11C3 20.41 19.84 823.44 14.43 18.80 13.63C10 176.93 176.58 416.07 92.54 171.73 98.96
Table 1: Upper bounds percentage optimality gaps. Instances aggregated bydataset.
density fracKP KP CC capCC lp(1a)−(1d) lp(2a)−(2d)
0.1 11.96 9.43 1572.31 6.64 5.70 3.880.2 26.66 24.05 1322.58 15.37 17.26 9.240.3 46.61 44.04 1192.75 26.64 34.21 16.850.4 69.07 66.45 1119.96 38.89 54.00 25.510.5 95.90 93.08 1060.65 50.36 77.26 34.240.6 124.97 122.05 1015.25 59.43 102.89 43.040.7 164.72 161.52 974.07 69.05 138.18 54.670.8 217.79 214.39 923.03 74.84 185.32 70.860.9 302.65 298.85 870.56 68.93 261.15 102.89
Table 2: Upper bounds percentage optimality gaps. Instances aggregated bydensity.
3.3 Exact algorithms comparison
In this section we investigate the behavior of the Branch-and-Bound algorithmswhich are obtained by combining the fracKP and capCC dual bound withthe branching rules nextKP and preKP . We have a total of four combina-tions: fracKP -nextKP , which is the algorithm proposed in [19], fracKP -preKP ,
capCC-fracKP and capCC-preKP . In addition, we also solved model (1a)-(1d)and model (2a)-(2d) by the MIP solver of CPLEX 12.6. The time limit is setto 1800 seconds.
We group correlated and random instances separately; for each group, wereport in Figures 5 and 6 the performance profiles, drawn according to themethodology introduced in [3], of the four Branch-and-Bound algorithms andof the MIP models (1a)-(1d) and (2a)-(2d) solved with CPLEX 12.6. The per-formance profile for an algorithm is the cumulative distribution function for aperformance metric: in Figures 5 and 6, the metric is the computing time forsolving an instance of the KPCG. For each algorithm and for each instance, weconsider the time τ needed by the algorithm to solve the instance, normalized
14
with respect to the fastest algorithm. For each value τ on the horizontal axis,a performance profile reports on the vertical axis the fraction of the dataset forwhich the algorithm is at most τ times slower than the fastest algorithm.
1 2 3 4 5 6 7 8 9 10τ
0.0
0.2
0.4
0.6
0.8
1.0
P(r
p,s≤τ
:1≤s≤n
s) fracKP−nextKP
capKP−nextKP
fracKP−preKP
capCC−preKP
(1a)-(1d)(2a)-(2d)
Figure 5: Performance profiles for the KPCG random instances. Each curverepresents the probability to have a computing time ratio smaller or equal to τwith respect to the best performing algorithm.
The first information that clearly appears from performance profiles is thatthe KPCG is difficult for the CPLEX MIP solver, and that it is worth to designa specialized algorithm, although exploiting the stronger clique model (2a)-(2d)has some advantages on the weaker model (1a)-(1d).
Among the four considered Branch-and-Bound algorithms, according to per-formance profiles, the best configuration is capCC-preKP , i.e., the algorithmfeaturing the new procedures introduced in this paper, for both random andcorrelated instances.
Concerning branching rules, the configurations using the preKP branchingalways perform better than the respective counterpart using the same boundingprocedure and the nextKP branching rule. Thus we can conclude that the
preKP branching is superior. The same happens for dual bounds, where theconfigurations using the capCC bound always perform better than the respectivecounterpart using the same branching rule and the fracKP bound. Thus wecan conclude that the capCC bound is superior.
In Tables 3 and 4 we report detailed results for the random and correlatedinstances, respectively, grouped by classes; in Tables 5 and 6 we report detailedresults for random and correlated instances, grouped by density. In all tables,the average computing time and number of nodes are computed with respect to
15
1 2 3 4 5 6 7 8 9 10τ
0.0
0.2
0.4
0.6
0.8
1.0P(r
p,s≤τ
:1≤s≤n
s) fracKP−nextKP
capKP−nextKP
fracKP−preKP
capCC−preKP
(1a)-(1d)(2a)-(2d)
Figure 6: Performance profiles for the KPCG correlated instances. Each curverepresents the probability to have a computing time ratio smaller or equal to τwith respect to the best performing algorithm.
the solved instances only.By analyzing these detailed results, we see that the gap between the two
branching rules is more evident in datasets with a very tight knapsack constraint.For example capCC-preKP is able to solve all the instances of C3, while capCC-
nextKP could not solve 56 instances of the dataset (see Table 4); instead, if welook at C10, capCC-preKP solves only 9 instances more than capCC-nextKP (seeTable 4).
Concerning the difficulty of the instances, datasets with tight knapsack con-straints (C1 and R1) are easy for the Branch-and-Bound algorithms and requirea smaller number of visited nodes, indeed, all algorithms can solve all instances.In such dataset it turns out that it is not convenient to use the capCC bound.Even if it allows to reduce the number of visited nodes, this does not compensatethe computing time spent calculating the bound at each node (computing times,however, remain very short). We recall that fracKP bound can be computed inlinear time (after ordering), while capCC requires O(n3) time in the worst case.
Instead, on datasets with large values of the knapsack capacity (C10 andR10), which are in general more difficult for all the Branch-and-Bound algo-rithms, the use of capCC allows to reduce the number of nodes by over twoorders of magnitude and leads to shorter computing times.
By considering the density of the conflict graphs, we see that instances withhigh density are easier: all the Branch-and-Bound algorithms can solve all theinstances with densities larger or equal to 0.6, while no algorithm can solve all
16
instances with densities smaller or equal to 0.4 in datasets C10 and R10Finally, by considering the classes of instances, class 4 (instances with 1000
items and uniform weights) is the most difficult one, as testified by the number ofnodes, the computing times and the number of unsolved instances. In particularfor datasets C10 and R10, which are the most difficult ones, 50 and 40 instancesremain unsolved, respectively, when considering the best performing algorithm(capCC-preKP ).
4 Conclusion
The Knapsack Problem with Conflict Graph is a relevant extension of the 0-1Knapsack Problem where incompatibilities between pairs of items are defined.It received attention in the literature as a stand-alone problem, as well as asubproblem arising in solving, e.g., the Bin Packing Problem with Conflicts. Theproblem is computationally challenging, and cannot be easily tackled through aMixed-Integer formulation solved with a general purpose MIP solver.
In this paper we propose several upper bounding and branching procedures,which are combined in four different Branch-and-Bound algorithms, whose per-formance is tested on a set of instances derived from classical Bin Packing Prob-lems. The algorithms obtained by combining the newly proposed branching andbounding procedures outperform, in our implementation, a recent algorithmfrom the literature.
References
[1] H. Akeb, M. Hifi, and M. E. Ould Ahmed Mounir. Local branching-basedalgorithms for the disjunctively constrained knapsack problem. Computers& Industrial Engineering, 60(4):811–820, 2011.
[2] R. Carraghan and P. M. Pardalos. An exact algorithm for the maximumclique problem. Operations Research Letters, 9(6):375–382, 1990.
[3] E. D. Dolan and J. J. More. Benchmarking optimization software withperformance profiles. Mathematical Programming, 91:201–213, 2002.
[4] S. Elhedhli, L. Li, M. Gzara, and J. Naoum-Sawaya. A branch-and-pricealgorithm for the bin packing problem with conflicts. INFORMS Journalon Computing, 23(3):404–415, 2011.
[5] E. Falkenauer. A hybrid grouping genetic algorithm for bin packing. Jour-nal of heuristics, 2(1):5–30, 1996.
[6] A.E. Fernandes-Muritiba, M. Iori, E. Malaguti, and P. Toth. Algorithms forthe bin packing problem with conflicts. INFORMS Journal on Computing,22(3):401–415, 2010.
[7] M. Fischetti and A. Lodi. Local branching. Mathematical programming, 98(1-3):23–47, 2003.
[8] M. Gendreau, G. Laporte, and F. Semet. Heuristics and lower bounds forthe bin packing problem with conflicts. Computers & Operations Research,31:347–358, 2004.
17
R1
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d)
class
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
190
0.00
045.2
900.00
036
.190
0.00
032
.190
0.000
26.4
90
0.056
290
0.000
73.2
900.00
055
.090
0.00
054
.090
0.000
41.2
90
0.242
390
0.001
166.6
900.00
211
7.8
900.00
111
8.6
900.00
182
.790
1.153
490
0.001
333.4
900.00
921
1.1
900.00
125
7.2
900.00
916
0.9
904.66
25
900.000
87.8
900.00
082
.990
0.00
018
.390
0.000
16.6
90
0.011
690
0.000
390.1
900.00
038
1.2
900.00
033.9
900.00
032.2
900.04
37
900.00
323
78.9
900.00
723
51.8
900.00
164
.890
0.000
62.6
90
0.218
890
0.033
149
82.2
900.08
71490
8.4
900.00
198
.190
0.002
96.8
90
1.030
R3
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d)
class
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
190
0.00
010
91.5
900.00
033
4.8
900.00
0886.1
90
0.000
279
.090
0.495
290
0.00
339
41.1
900.01
098
4.4
900.00
234
05.9
90
0.009
866
.990
3.696
390
0.04
521
626.8
900.11
044
34.1
900.03
919
299.9
90
0.100
405
3.8
9061.06
64
90
0.52
412
5983
.190
1.22
92177
7.0
900.48
011
5794.8
901.15
2204
81.3
65
461.74
25
90
0.00
041
8.8
900.00
013
9.4
900.00
032
0.8
900.00
010
7.5
900.09
76
900.000
1465
.790
0.00
036
0.1
900.00
012
36.2
900.00
030
4.2
900.54
97
900.006
5807
.790
0.01
213
71.6
900.00
549
69.0
900.01
210
49.5
90
4.379
890
0.07
443
100.0
900.18
02438
5.3
900.04
319
476.5
90
0.090
391
6.6
9078.18
9
R10
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d)
class
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
190
0.47
084
5744
.290
0.03
393
96.9
900.29
859
4284.8
900.02
873
36.2
90
1.101
290
30.75
529
1717
76.1
904.09
436
6222
.290
22.202
2415
5612
.590
3.587
311
343.0
9096.02
73
6920
7.03
510
7696
773.2
8421
6.89
390
2881
3.7
7019
3.13
910
3734
151.0
84
199.58
582
0249
0.5
40536
.021
440
106.03
522
1164
93.5
5019
7.43
250
1286
1.0
4010
4.15
021
5355
85.0
50195
.765
489
5498
.48
979.02
95
900.00
831
518.4
900.00
055
6.9
900.00
416
925.6
90
0.000
389.9
900.11
06
901.261
2314
126.5
90
0.05
816
714.0
900.77
515
2140
0.5
900.04
7122
37.5
90
1.166
788
105
.037
9772
3100
.290
7.59
068
3501
.389
92.894
9646
1963.3
906.76
658
6538
.990
144.99
38
70178
.822
7904
7091
.880
168.60
771
4998
8.3
7015
6.73
568
1545
66.4
80
159.75
166
4950
6.5
40508
.469
Table
3:Exactmethodson
therandom
datasets.
Resultsag
gregated
byclasses.
18
C1
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d)
class
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
190
0.00
0495
.790
0.00
039
9.0
900.00
080
.190
0.000
71.4
90
0.168
290
0.01
283
45.8
900.02
071
99.0
900.00
012
2.3
900.00
110
7.2
900.94
63
900.022
8510
.390
0.03
359
04.7
900.00
0214
.290
0.003
177
.790
5.630
490
11.82
819
1375
3.8
9013
.720
1332
809.2
900.00
251
0.1
900.01
045
1.6
9040.03
05
900.000
4359
.690
0.00
041
52.8
900.00
0171
.990
0.000
164
.590
0.021
690
0.01
625
241.2
900.02
924
440.9
900.00
0242
.490
0.000
230
.190
0.067
790
0.09
865
014.7
900.16
263
460.8
900.00
1211
.990
0.001
203
.690
0.339
890
0.73
525
5015
.190
1.16
52491
35.5
900.00
234
5.8
900.00
233
8.2
902.84
3
C3
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d)
class
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
190
0.00
512
930.4
900.00
644
33.4
900.00
056
81.5
90
0.003
1948
.490
1.563
290
0.089
790
40.6
900.10
523
805.2
900.03
133
929.5
90
0.061
111
26.6
90
32.572
390
2.00
8102
9233
.190
2.23
13474
53.6
900.53
127
6857
.490
0.955
803
68.4
72
413.52
84
88
64.828
1762
4047
.388
68.480
772427
8.0
9014
.192
3336
875
.290
19.443
7616
90.3
21
209.63
15
90
0.03
110
9383
.590
0.04
574
587.1
900.00
028
75.9
90
0.000
827.9
900.13
56
8869
.174
1204
8434
1.8
86
45.456
4533
8924
.690
0.00
411
713.1
90
0.005
2831
.390
1.470
770
8.198
7365
262.0
70
8.82
237
1762
4.8
900.06
762
558.4
90
0.064
140
61.9
90
35.566
860
34.744
1475
0601
.360
27.132
430294
2.6
900.80
937
0541
.090
0.686
824
63.3
79
342.02
6
C10
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d)
class
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
190
24.50
846
5350
34.1
901.08
354
0916
.990
15.520
3286
3218.1
900.84
7390
718.0
902.34
92
6121.30
018
5581
65.0
8291
.876
1785
8781
.865
87.355
1078
17656
.686
149.85
627
2005
83.0
75
212.90
53
5018
2.78
168
6851
61.7
5312
1.09
315
6540
31.7
5017
5.70
466
0283
77.7
54
149.38
518
9549
04.4
24
712.53
44
3053.27
512
7023
23.9
4015
4.87
111
1142
34.9
3052
.503
1253
5168.3
40151
.904
109
6882
7.5
00
590
0.81
129
5406
7.7
900.01
013
658.0
900.46
816
5335
0.6
900.00
8945
4.4
900.18
96
8876.57
314
9901
735.6
904.00
620
0378
6.5
9066
.768
1438
59332
.490
2.765
126
6635
.181
2.718
760
17.97
113
9267
64.8
7378
.711
1598
9539
.460
14.550
1284
9670.0
77114
.528
213
6272
9.7
63250
.630
850
184.60
468
9340
62.6
5022
.767
2927
501.9
5221
0.97
094
9044
49.8
50
22.482
284
3795
.320
800.99
6
Tab
le4:Exactmethodson
thecorrelated
datasets.
Resultsag
gregated
byclasses.
19
R1
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d
)
density
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
0.1
800.01
268
11.3
800.02
867
95.5
800.00
031.7
80
0.001
31.6
800.12
60.2
80
0.00
944
82.8
800.02
544
65.4
800.00
035.8
80
0.000
35.1
800.25
00.3
80
0.00
629
98.1
800.01
829
77.3
800.00
047.5
80
0.001
44.9
800.40
80.4
80
0.00
625
88.0
800.01
725
59.7
800.00
067.7
80
0.001
60.2
800.54
10.5
80
0.00
518
96.8
800.01
318
64.4
800.00
074.6
80
0.001
62.6
800.68
50.6
80
0.00
295
0.1
800.00
791
1.0
800.00
196.0
80
0.002
75.1
800.79
20.7
80
0.00
153
7.4
800.00
548
3.7
800.00
011
9.5
800.00
386
.380
1.206
0.8
800.00
0302
.580
0.00
423
6.0
800.00
013
7.6
800.00
294
.180
1.678
0.9
800.00
0197
.680
0.00
311
9.3
800.00
015
1.4
800.00
394
.480
2.656
R3
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d
)
density
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
0.1
800.02
620
333.5
800.07
617
534.7
800.00
3940
.780
0.004
274
.180
0.12
40.2
800.02
813
781.9
800.06
873
81.3
800.01
250
97.9
80
0.031
1241
.280
0.54
30.3
80
0.06
721
820.6
800.15
434
36.8
800.05
417
969.4
800.13
229
23.2
805.63
00.4
80
0.13
735
977.3
800.30
558
62.9
800.11
932
038.5
800.27
953
12.3
8044.32
50.5
80
0.18
044
764.2
800.42
483
74.1
800.16
941
525.6
800.40
178
77.4
7789.02
20.6
80
0.15
842
919.7
800.40
387
82.0
800.14
940
770.4
800.38
784
15.2
7397.66
10.7
80
0.09
029
528.4
800.21
457
24.1
800.08
728
466.9
800.20
855
53.8
7180.62
60.8
80
0.03
714
777.2
800.07
324
83.3
800.03
714
385.2
800.07
224
25.7
74118
.057
0.9
80
0.01
149
61.3
800.01
893
1.0
800.01
248
68.2
80
0.018
918.3
80
136.01
7
R10
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d
)
density
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
0.1
6911
0.36
9880
2391
3.8
7019
.287
8874
86.7
7097
.796
77265
050.7
7014.34
0652
371.4
78105
.306
0.2
4821
2.42
520
0328
771.6
5411
4.23
05097
783.5
4918
2.06
019
2784
106.7
54100
.734
441
2874
.250
144.00
90.3
5026
.802
219
8485
2.8
7033
2.46
61418
7544
.350
20.366
19116
736.8
70315
.999
132
5131
4.6
50139
.575
0.4
7026
0.59
210
1365
617.8
7024
.676
1184
679.2
7023
6.71
494
4852
45.7
70
23.951
112
5284
.550
65.728
0.5
7020
.220
7493
461.6
8011
5.57
82978
218.5
7019
.217
7059
077.5
80114
.559
290
4611
.650
38.771
0.6
8050
.684
107
7096
7.7
809.52
127
2966
.780
49.709
10465
953.3
809.43
4267
046.5
5025.66
00.7
803.96
810
1143
9.6
801.19
545
087.5
803.90
2985
075.8
801.19
044
200.2
70402
.629
0.8
800.35
8111
981.9
800.18
981
56.4
800.35
1109
088.6
800.19
179
77.5
70167
.614
0.9
80
0.03
112
384.8
800.02
415
41.4
800.03
312
060.0
800.02
615
09.0
7038.56
4
Tab
le5:Exactmethodson
therandom
datasets.
Resultsag
gregated
byden
sity.
20
C1
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d
)
density
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
0.1
8012
.337
1972
293.4
8014
.283
1386
498.8
800.00
179.1
80
0.000
79.0
800.10
10.2
80
0.88
018
8977
.580
1.02
812
8355
.580
0.00
090
.680
0.00
090
.680
0.248
0.3
800.27
290
194.7
800.41
780
978.6
800.00
011
2.1
800.00
011
1.0
80
0.464
0.4
80
0.14
763
056.6
800.23
860
854.6
800.00
020
3.3
800.00
120
2.6
80
0.607
0.5
80
0.30
210
4502
.780
0.46
710
1574
.080
0.00
117
2.2
800.00
116
8.3
80
1.028
0.6
80
0.24
691
745.9
800.38
688
715.9
800.00
128
1.1
800.00
427
0.1
80
4.088
0.7
80
0.08
337
551.2
800.13
836
007.9
800.00
129
4.5
800.00
327
4.5
80
4.823
0.8
80
0.02
714
043.1
800.05
012
951.9
800.00
140
9.0
800.00
435
7.4
80
17.450
0.9
80
0.00
634
63.0
800.01
425
02.4
800.00
1493
.980
0.005
408
.680
27.49
1
C3
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d
)
density
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
0.1
5616
3.73
120
6171
329.1
5413
8.27
18289
1808
.180
0.00
9417
6.2
800.05
1366
7.9
79
8.640
0.2
603.79
218
3706
9.9
603.25
856
9920
.880
0.19
2830
93.6
80
0.567
260
78.8
80
34.728
0.3
7015
.724
9309
906.6
7015
.233
3928
321.9
802.26
8706
694.1
803.42
2120
223.8
7255.22
10.4
8032
.466
122
2955
9.4
8027
.078
3374
424.5
803.93
610
0345
1.2
805.56
8190
780.4
6990.40
90.5
8011
.195
2494
963.8
8011
.026
5085
08.3
806.47
314
2543
2.4
808.27
9351
816.9
66198
.429
0.6
805.59
814
5106
9.2
805.59
835
3574
.080
3.15
3867
379.4
804.30
0252
950.2
5283.90
70.7
801.95
0594
962.3
801.70
712
8152
.480
1.13
4377
021.7
801.32
095
969.1
64336
.618
0.8
800.53
0168
275.2
800.37
534
213.9
800.35
5120
752.5
800.30
526
311.1
70135
.991
0.9
800.08
028
463.3
800.05
871
76.6
800.07
0256
59.7
80
0.058
693
4.7
70
77.380
C10
fracKP- n
extKP([19
])capCC- n
extKP
fracKP- p
reKP
capCC- p
reKP
(2a)-(2d
)
density
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
nodes
solved
time
0.1
2919
5.02
238
4555
162.0
4317
3.58
23409
6526
.437
322.55
650
6597
270.8
47203
.917
368
2887
3.3
35100
.320
0.2
3011
6.99
722
1125
214.2
3295
.527
1893
7220
.930
79.749
1680896
64.6
36
260.33
446
6197
65.3
30
2.970
0.3
303.20
455
5285
5.4
5059
.864
1471
5355
.630
2.24
246
7704
8.9
5057.20
713
4843
06.0
38
319.94
40.4
5039
.479
308
0801
4.2
5310
3.34
61374
1842
.350
31.796
28297
877.8
54132
.369
171
0441
5.3
50218
.665
0.5
7025
0.27
5940
8291
7.5
7029
.906
3894
207.2
7024
0.15
790
3447
16.8
70
29.312
377
6521
.350
79.238
0.6
7013
.200
5351
330.9
8074
.153
5434
574.4
7012
.548
5191
147.3
8072.69
553
5903
0.3
5046.12
50.7
8019
.800
4900
728.8
805.47
144
6757
.580
19.486
4831
206.5
805.40
5441
719.0
5026.42
20.8
801.16
3343
428.4
800.37
932
683.0
801.13
8339
931.3
800.37
532
385.0
70281
.333
0.9
800.07
828
554.0
800.05
971
79.4
800.08
128
356.0
800.06
171
39.2
70162
.185
Tab
le6:
Exactmethodson
thecorrelated
datasets.
Resultsag
gregated
byden
sity.
21
[9] S. Held, W. Cook, and E.C. Sewell. Maximum-weight stable sets and safelower bounds for graph coloring. Mathematical Programming Computation,4:363–381, 2012.
[10] M. Hifi. An iterative rounding search-based algorithm for the disjunc-tively constrained knapsack problem. Engineering Optimization, 46(8):1109–1122, 2014.
[11] M. Hifi and M. Michrafy. A reactive local search-based algorithm for thedisjunctively constrained knapsack problem. Journal of the OperationalResearch Society, 57(6):718–726, 2006.
[12] M. Hifi and M. Michrafy. Reduction strategies and exact algorithms forthe disjunctively constrained knapsack problem. Computers & operationsresearch, 34(9):2657–2673, 2007.
[13] M. Hifi and N. Otmani. An algorithm for the disjunctively constrainedknapsack problem. International Journal of Operational Research, 13(1):22–43, 2012.
[14] R. M. Karp. Reducibility among combinatorial problems. In R. E. Miller,J. W. Thatcher, and J. D. Bohlinger, editors, Complexity of ComputerComputations, The IBM Research Symposia Series, pages 85–103. SpringerUS, 1972.
[15] H. Kellerer, U. Pferschy, and D. Pisinger. Knapsack problems. Springer,2004.
[16] E. Malaguti, M. Monaci, and P. Toth. An exact approach for the vertexcoloring problem. Discrete Optimization, 8:174–190, 2011.
[17] S. Martello and P. Toth. Knapsack problems. Wiley New York, 1990.
[18] U. Pferschy and J. Schauer. The knapsack problem with conflict graphs.J. Graph Algorithms Appl., 13(2):233–249, 2009.
[19] R. Sadykov and F. Vanderbeck. Bin packing with conflicts: a genericbranch-and-price algorithm. INFORMS Journal on Computing, 25(2):244–255, 2013.
[20] T. Yamada, S. Kataoka, and K. Watanabe. Heuristic and exact algorithmsfor the disjunctively constrained knapsack problem. Information ProcessingSociety of Japan Journal, 43(9), 2002.
22