Inductive linearization for binary quadratic programs with linear constraints: a computational study
Abstract
EconStor is a publication server for scholarly economic literature, provided as a non-commercial public service by the ZBW.
Full text
Mallach, Sven Article — Published Version Inductive linearization for binary quadratic programs with linear constraints: a computational study 4OR Provided in Cooperation with: Springer Nature Suggested Citation: Mallach, Sven (2023) : Inductive linearization for binary quadratic programs with linear constraints: a computational study, 4OR, ISSN 1614-2411, Springer, Berlin, Heidelberg, Vol. 22, Iss. 1, pp. 47-87, https://doi.org/10.1007/s10288-023-00537-5 This Version is available at: https://hdl.handle.net/10419/317731 Standard-Nutzungsbedingungen: Die Dokumente auf EconStor dürfen zu eigenen wissenschaftlichen Zwecken und zum Privatgebrauch gespeichert und kopiert werden. Sie dürfen die Dokumente nicht für öffentliche oder kommerzielle Zwecke vervielfältigen, öffentlich ausstellen, öffentlich zugänglich machen, vertreiben oder anderweitig nutzen. Sofern die Verfasser die Dokumente unter Open-Content-Lizenzen (insbesondere CC-Lizenzen) zur Verfügung gestellt haben sollten, gelten abweichend von diesen Nutzungsbedingungen die in der dort genannten Lizenz gewährten Nutzungsrechte. Terms of use: Documents in EconStor may be saved and copied for your personal and scholarly purposes. You are not to copy documents for public or commercial purposes, to exhibit the documents publicly, to make them publicly available on the internet, or to distribute or otherwise use the documents in public. If the documents have been made available under an Open Content Licence (especially Creative Commons Licences), you may exercise further usage rights as specified in the indicated licence. http://creativecommons.org/licenses/by/4.0/
4OR (2024) 22:47–87 https://doi.org/10.1007/s10288-023-00537-5 RESEARCH PAPER Inductive linearization for binary quadratic programs with linear constraints: a computational study Sven Mallach1 Received: 18 March 2022 / Revised: 21 October 2022 / Accepted: 7 February 2023 / Published online: 23 March 2023 © The Author(s) 2023 Abstract The computational utility of inductive linearizations for binary quadratic programs when combined with a mixed-integer programming solver is investigated for several combinatorial optimization problems and established benchmark instances. Keywords Non-linear programming ·Binary quadratic programming · Mixed-integer programming ·Linearization Mathematics Subject Classification 68R01 ·90C05 ·90C09 ·90C10 ·90C11 · 90C20 ·90C30 1 Introduction Given a binary quadratic program (BQP) comprising linear (and possibly quadratic) constraints, the inductive linearization technique (Mallach 2021) may serve as a computationally attractive compromise between the well-known “standard” linearization as of Glover and Woolsey (1974), and a complete application of the Reformulation Linearization Technique [RLT, see e.g. Adams and Sherali (1999,1986)]. In several relevant cases, inductive linearizations are more constraint-side compact than the “standard” linearization and provide a continuous relaxation that is at least as tight. Prominent combinatorial optimization problems where this applies are for instance the QuadraticAssignment,theQuadraticMatching,andtheQuadraticTravelingSalesman Problem. Given this theoretical basis, the central contribution of this paper is a systematic computational study in order to address a number of research questions: Does the mentioned symbiosis of compactness and continuous relaxation strength translate BSven Mallach [email protected] 1High Performance Computing and Analytics Lab, University of Bonn, Friedrich-Hirzebruch-Allee 8, 53115 Bonn, Germany 123
48 S. Mallach into a faster solution time of the corresponding mixed-integer programs? How do the obtained relaxation bounds compare with the “standard” linearization and the RLT at a broader scope? For which problem structures is the inductive linearization technique (not) well-suited and why? Can an inductive linearization be obtained quickly in practice, and if so, how? Tothis end, weinvestigatetheperformanceofthe inductiveas wellasthe “standard” linearization in combination with (and in comparison to) a professional mixed-integer programming solver on various BQPs with linear constraints. More precisely, we look atthe Quadratic Assignment Problem, theQuadratic KnapsackProblem, the Quadratic Matching Problem, the Quadratic Shortest Path Problem, and on further instances of the well-established QPLIB1and MINLPLib.2Besides that, an algorithmic frame to derive inductive linearizations in practice, and thus complementing the mixed-integer programming (MIP) approach from Mallach (2021), is presented. The outline of this paper is as follows: In the beginning of Sect.2, we briefly review the main concepts of the inductive linearization technique and then strongly emphasize on its practical application. In Sect.3, we present the aforementioned applications along with the respective problem formulations as well as the benchmark instances used for the computational study, and a detailed discussion of the respective results. Finally, a conclusion is given in Sect.4. 2 Inductive linearization The inductive linearization technique addresses optimization problems adhering to or comprising the structure min xTC0x+cTx s.t. xTCkx+gT kx≤βkk=1,...,mQ Ax b x∈{0,1}n, where,forn,mL∈N\{0}andmQ∈N,thematrices A∈RmL×naswellasCk∈Rn×n for k∈{0,...,mQ}, the vectors gk∈Rnfor k∈{1,...,mQ}and c∈Rn, and finally thescalars baswell as βk∈Rfor k∈{1,...,mQ}aregivenas inputdata. Throughout this paper, we will denote by N:= {1,...,n}the index set of the binary variables x∈{0,1}n. Moreover, the set of products Ptruly present in the problem is determined by the the objective function and the quadratic restrictions as follows: P:= {(i,j)⊆N×N|∃k∈{0,...,mQ}:Ckij = 0} Naturally, we assume that Pis non-empty and, since we have for binary solutions that xixj=xjxifor i,j∈N,i= j, and xi=x2 ifor all i∈N, we assume further that the matrices Ck,k∈{0,...,mQ}, are strictly upper triangular so that we have i<jfor each (i,j)∈P. 1https://qplib.zib.de. 2https://www.minlplib.org. 123
Inductive linearization for binary quadratic programs with… 49 While quadratic constraints may or may not be present, some linear constraints on the binary variables are actually necessary to apply the inductive linearization technique. We assume w.l.o.g. that these are given as equations and less-or-equal inequalities, hence denoted Ax b. More precisely, the requirement is that each binary variable xi,i∈N, being a factor of a product in P(to be linearized with the technique proposed), appears in at least one of these constraints (with a non-zero coefficient). Clearly, this can be assumed (or established) for a binary problem without loss of generality. Indeed, if there is a factor xi,i∈N, that is entirely free w.r.t. the linear constraints then in principle any linear equation or less-or-equal inequality may be employed that is valid for its feasible set (even, though rather not so desirable, xi≤1). Moreover, if some factor is left free w.r.t. the linear constraints, then this does not affect a successful inductive linearization of other products that do have linearly constrained factors. For simplicity, we thus assume from now on that all factors appearing in Pare linearly constrained. The inductive linearization technique is a generalization of a principle proposed by Liberti (2007) for the special case of equations with right hand side and left hand side coefficients equal to one, and of its later revision (cf. Mallach (2018)). In his original article, Liberti coined the name “compact linearization” because it typically adds fewer constraints to the mentioned problems than the “standard” linearization as of Glover and Woolsey (1974). For the problem under consideration, a general form of the latter reads: min dTy+cTx s.t. hT ky+gT kx≤βkk=1,...,mQ Ax b(1) yij −xi≤0(i,j)∈P(2) yij −xj≤0(i,j)∈P(3) xi+xj−yij ≤1(i,j)∈P(4) y≥0 x∈{0,1}n With m:= |P|, we here use y∈Rmto denote the linearized products, d∈Rm to denote their corresponding objective coefficients, and hk∈Rm,k=1,...,mQ, to express their coefficients in the original quadratic constraints. Thereby, we use the subscriptnotation yij fori<jandanalogouslydefinedij =(C0)ij andhkij =(Ck)ij. Of course, if dij <0(4) can be omitted, and if dij >0(2) and (3) can be omitted for (i,j)∈P. As we will see, in many cases, inductive linearizations are constraint-side compact aswell.However,thiscannotbeguaranteedforanykindofBQPwithlinearconstraints. Moreover, depending on how the method is applied, more than |P|linearization variables may be induced (although this can, in principle, always be circumvented as described in Sect.2.3). Therefore, and to have a clear distinction from other linearizations being called “compact”, as well as to emphasize that the proposed method aims at “inducing” the products associated to the set Pby multiplying original constraints 123
50 S. Mallach with original variables, the technique is referred to as “inductive linearization” since its generalization first presented in Mallach (2021). 2.1 Mathematical derivation of inductive linearizations Givenaproblemas introducedat thebeginningof this section, suppose that we identify aworking(sub-)set ofthe linearconstraints Ax bto actually induce the linearization with. Let us denote the index set of the selected equations and inequalities with KE and KI, respectively. That is, we consider the constraints i∈Ik ai kxi=bkfor all k∈KE(5) i∈Ik ai kxi≤bkfor all k∈KI(6) where Ik:= {i∈N|ai k= 0}denotes the respective support index set for each k∈KEor k∈KI. As already mentioned, we require w.l.o.g. a choice of K:= KE∪KIsuch that there exist indices k, ∈Kwith i∈Ikand j∈Ifor all (i,j)∈P. To refer to the respective constraints, we will use the notation K(i):= {k∈K:i∈Ik},aswell as KE(i)and KI(i)analogously defined if more preciseness is in order. Moreover, although we do not require this for the original problem, let us temporarily assume in addition that bk>0 for all k∈Kand ai k>0 for all i∈Ik,k∈K. We will elaborate in Sect.2.4 on how to handle constraints not fulfilling these prerequisites. Thefirststepoftheinductivelinearization approach nowassociatestoeachequation k∈KEanother index set ME k⊆Nthat is supposed to specify original variables used as multipliers. To each inequality k∈KI, two such index sets M+ k,M− k⊆Nare associated. The corresponding interpretation is as follows: If j∈ME k(j∈M+ k) the equation k∈KE(inequality k∈KI) is multiplied by xj, and if j∈M− k,the inequality k∈KIis multiplied by (1−xj). This leads to the following set of first-level RLT constraints: i∈Ik ai kxixj=bkxjfor all j∈ME k,k∈KE(7) i∈Ik ai kxixj≤bkxjfor all j∈M+ k,k∈KI(8) i∈Ik ai kxi(1−xj)≤bk(1−xj)for all j∈M− k,k∈KI(9) Let Mk:= ME kif k∈KE, and Mk:= M+ k∪M− kif k∈KI. Then Q:= {(i,j)|i≤jand ∃k∈K:i∈Ikand j∈Mk,orj∈Ikand i∈Mk} is the index set of the products induced by (7)–(9). 123
Inductive linearization for binary quadratic programs with… 51 For ease of reference, we also define M:= k∈K Mk which is to be regarded as a multiset of multiplier indices. Remark 1 In the general approach described above, the induced set Qmay contain tuples that correspond to squares. It is a simple and worthwhile optimization to replace these by their linear counterparts before actually deriving the respective linearization constraint (see also Sect.2.2 and Mallach (2021)). If we now rewrite (7)–(9) by substituting for each (i,j)∈Qthe product xixjby a continuous linearization variable yij that has explicit lower and upper bounds, i.e., 0≤yij ≤1, we obtain the linearization constraints: i∈Ik,(i,j)∈Q ai kyij + i∈Ik,( j,i)∈Q ai kyji =bkxjfor all j∈ME k,k∈KE(10) i∈Ik,(i,j)∈Q ai kyij + i∈Ik,( j,i)∈Q ai kyji ≤bkxjfor all j∈M+ k,k∈KI(11) i∈Ik,(i,j)∈Q ai k(xi−yij)+ i∈Ik,( j,i)∈Q ai k(xi−yji)≤bk(1−xj)for all j∈M− k,k∈KI(12) Now, as is expressed by the following theorem, for all the induced (i,j)∈Qand binary xi,xj, one has yij =xixjif the following three consistency conditions are met: Condition 1 There is a k ∈K(i)such that j ∈ME kor j ∈M+ k, respectively. Condition 2 There is a k ∈K(j)such that i ∈ME kor i ∈M+ k, respectively. Condition 3 There is a k ∈K(i)such that j ∈ME kor j ∈M− k, respectively, or a k∈K(j)such that i ∈ME kor i ∈M− k, respectively. Theorem 4 [Mallach (2021)] For any integer solution x ∈{0,1}n, the linearization constraints (10)–(12)imply yij =xixjfor all (i,j)∈Q if and only if Conditions 1–3 are satisfied. So altogether, if we choose Mconsistently in terms of the three conditions and such that Qcontains P, we obtain a linearization for our original problem. In fact, at the potential expense of losing some continuous relaxation strength, it is always possible to have Q=Pas is described in Sect.2.3. 123
52 S. Mallach 2.2 Linear relaxation strength of inductive linearizations The case where the constraint set Kemployed satisfies bk=1 for all k∈K, and ai k=1for alli∈Ikisan example of practical relevance wherethe linear programming relaxation obtained from an inductive linearization is provably at least as tight as the one obtained from the “standard” linearization. The same is true for equations with a right hand side of two and zero–one left hand side coefficients if these equations are multiplied by all variables on their left hand sides (i.e., Mk=Ik) and squares are ruled out. More generally, the corresponding proofs in Mallach (2021) make apparent that the tightness of the relaxations of inductively linearized BQPs relates (besides other criteria) to the ratio between the right hand side and the left hand side coefficients. It also provides an example case where an inductive linearization provably has a strictly stronger continuous relaxation than the “standard” linearization. In our computational study, we will identify experimentally further cases where this relation is achieved and further investigate how far the bounds deviate in practice. 2.3 Practical derivation of inductive linearizations and their compactness Given a problem formulation on sheet, a multiset Mthat induces a set Q⊇Pand establishes a consistent linearization can often be derived by inspection once the necessary implications imposed by Conditions 1–3are understood (see also Sect.2.4). For instance if the factor pairs in Por the constraints at hand have a complicated structure, it may nevertheless be non-trivial to find a consistent combination of constraints and multipliers, especially if the outcome is supposed to be compact or to meet other objectives. Moreover, an automated derivation is desirable for larger problem instances and allows for a linearization framework to be coupled with a mixed-integer programming solver. Concerning the computation of an inductive linearization, it has been shown in Mallach (2021) that the associated optimization problem (allowing e.g. to derive a linearizationthatisascompactaspossibleintermsofadditionalvariablesandconstraints) is NP-hard. This result is however rather of theoretic prominence as it considers the general case of any possible input program whereas common inputs are usually structured and the associated “covering problems” turn out to be often simple to solve. Indeed they can frequently be solved even exactly, using e.g. a mixed-integer program or combinatorial polynomial-time algorithms for more specifically structured BQPs. Typically, the number of candidate constraints to induce a certain product, respectively to satisfy one of the three conditions, is anyway rather small. Likewise, for many applications, the complexity can also be reduced by carefully preselecting the set Kof original constraints considered for inductions. It is further apparent from the hardness proof as well as the mixed-integer program in Mallach (2021) that the compactness of the resulting linearization is influenced by the support of the employed constraint set Kand its relation to the factor pairs given by P. In this context, it is also worth to mention that the presolve routines of a MIP solver may well eliminate some of the variables and constraints imposed by an inductive 123
Inductive linearization for binary quadratic programs with… 53 linearization that is not “most compact”. Moreover, a few additional constraints may sometimes improve the relaxation strength, so compactness need not necessarily be an ultimate goal. Notwithstanding, it is also possible to eliminate (all) variables in Q\Pif (all of) these have been generated from inequalities (possibly obtained from equations in a preprocessing step). As is clear from inequalities (11) and (12), removing summands on their left hand sides will neither harm their validity nor their necessary implications on the respective remaining linearization variables. In general, however, the feasible region of the continuous relaxation may of course be enlarged by this procedure (referred to as weakened inductive linearization in Sect.3). As a particularly practical approach to derive inductive linearizations, we present (the heuristic) Algorithm 1which is an extension of a special-case combinatorial algorithmfrom Mallach (2018) to the general case. It also serves to derive the inductive linearizations during the computational study in Sect.3. Algorithm 1 Main routine of the heuristic to construct an inductive linearization. function ConstructSets(Sets P,K,w) for all k∈KEdo ME k←∅ for all k∈KIdo M+ k←∅;M− k←∅ Q←P Qnew ←P while ∅ = Qadd ←Append(Q,Qnew,K,M)do Q←Q∪Qadd Qnew ←Qadd return Qand M Algorithm 1consists of two simple components. First, the major routine ConstructSets which is to be supplied with the input sets Pand Kas well as weights wE kj, respectively w+ kj and w− kj, indicating a “cost” of creating a linearization constraint bymultiplying constraintk∈Kwith originalvariable xj,respectively 1−xj,justasin the mixed-integer program in Mallach (2021). The major routine then invokes the subroutine Append (listed as Algorithm 2) which extends a partial inductive linearization represented by Qand M. It does so by inducing additional linearization constraints in order to satisfy Conditions 1–3for the variables Qnewadded in the previous iteration (initially, Qnew=P), and by appending the variables Qadd newly induced when creating these linearization constraints. Algorithm 1terminates if a steady state is reached, i.e., if no further constraint-factor multiplications are necessary to satisfy Conditions 1–3for the current Q, which is then, together with the constraint multiplier set M, returned. 123
54 S. Mallach Algorithm 2 Subroutine used by the heuristic to construct an inductive linearization. function Append(Sets Q,Qnew,K,M,w) Qadd ←∅ for all (i,j)∈Qnew do if j/∈ME k∀k∈KE(i)∧j/∈M+ k∀k∈KI(i)then If Condition 1 is not satisfied ¯ k←nil;¯w←0 if KE(i)=∅then ¯ k←arg mink∈KE(i)wE kj;¯w←wE ¯ kj if KI(i)=∅∧(¯ k=nil ∨mink∈KI(i)w+ kj <¯w) then ¯ k←arg mink∈KI(i)w+ kj M+ ¯ k←M+ ¯ k∪{j} else ME ¯ k←ME ¯ k∪{j} for all a∈I¯ kdo if a≤j∧(a,j)/∈Q∪Qadd then Qadd ←Qadd ∪{(a,j)} else if a>j∧(j,a)/∈Q∪Qadd then Qadd ←Qadd ∪{(j,a)} if i/∈ME ∀∈KE(j)∧i/∈M+ ∀∈KI(j)then If Condition 2 is not satisfied ¯ ←nil;¯w←0 if KE(j)=∅then ¯ ←arg min∈KE(j)wE i;¯w←wE ¯ i if KI(j)=∅∧(¯ =nil ∨min∈KI(j)w+ i<¯w) then ¯ ←arg min∈KI(j)w+ i M+ ¯ ←M+ ¯ ∪{i} else ME ¯ ←ME ¯ ∪{i} for all a∈I¯ do if a≤i∧(a,i)/∈Q∪Qadd then Qadd ←Qadd ∪{(a,i)} else if a>i∧(i,a)/∈Q∪Qadd then Qadd ←Qadd ∪{(i,a)} if j/∈Mk∀k∈KE(i)∧j/∈M− k∀k∈KI(i)∧i/∈M∀∈KE(j)∧i/∈M− ∀∈KI(j) then If Condition 3 is not satisfied ¯ k←nil;¯ ←nil;¯w1←0; ¯w2←0 if KE(i)=∅then ¯ k←arg mink∈KE(i)wE kj;¯w1←wE ¯ kj if KI(i)=∅∧(¯ k=nil ∨mink∈KI(i)w− kj <¯w1)then ¯ k←arg mink∈KI(i)w− kj;¯w1←w− ¯ kj if KE(j)=∅then ¯ ←arg min∈KE(j)wE i;¯w2←wE ¯ i if KI(j)=∅∧(¯ =nil ∨min∈KI(j)w− i<¯w2)then ¯ ←arg min∈KI(j)w− i;¯w2←w− ¯ i if ¯w1≤¯w2then if ¯ k∈KE(i)then ME ¯ k←ME ¯ k∪{j} else M− ¯ k←M− ¯ k∪{j} for all a∈I¯ kdo if a≤j∧(a,j)/∈Q∪Qadd then Qadd ←Qadd ∪{(a,j)} else if a>j∧(j,a)/∈Q∪Qadd then Qadd ←Qadd ∪{(j,a)} 123
Inductive linearization for binary quadratic programs with… 61 Fig. 1 Optimality gaps obtained with continuous relaxations (in percent) for the QAPLIB instances solved by using at least one of the linearizations (time limit 48 h) Instance Description With the only exception of esc16f (that has T=0), we report on those of the established QAPLIB (Burkard et al. 1997) instances that could be solved within the 48 h limit using either IL or one of the standard linearizations SLC and SLR. Thereby, the density 100|P|/|N| 2of the 42 instances solved spreads between 1 and 87%. LP Relaxation Bounds and MIP Performance As shown in Fig.1, for all considered instances, the “standard” linearization SLC provides a lower bound of zero which translates into an optimality gap of 100%. For someesc instances, the computedinductivelinearizationILand even a first-levelRLT (here derived using square reductions as of Remark 1in addition) do not improve on this bound. More typically, a strong first-level RLT bound is obtained and IL delivers an optimality gap that is closer to the one of the RLT than to the one of SLC. As is displayed in Table 1, using Gurobi with IL clearly outperforms its combination with each of the two “standard” linearizations SLC and SLR. With the only exception of esc32e, the running times with IL are faster in all the remaining 41 cases, frequently by orders of magnitude. Supported further by the compactness of the derived inductive linearizations, their usually better relaxation strength translates into a superior performance compared with the “standard” linearizations. We find that assignment constraints prove typically (but not always) suitable for inductive linearizations, even though they are of course not competitive to state-of-the- artmethodsforthepureQAP.WhilewehereobservethatonlythoseQAPLIBinstances with up to about 20000 products can be handled within the time limit, it is observed in Sects.3.5 and 3.6 that inductive linearizations turn out to be frequently attractive for related problems with additional structure in terms of further variables and constraints. This is also in line with results that have been obtained earlier for e.g. quadratic semi-assignmentproblems (Billionnet andElloumi 2001),graphpartitioning (Mallach 2018), multiprocessor scheduling (Mallach 2017), or graph layering (Mallach 2019). Table 1further shows that the task to find a good combination satisfying Conditions 1and 2for all induced products could be solved very quickly with Algorithm 1 for the considered QAPLIB instances. In some further experiments, the mixed-integer program from Mallach (2021) could also be solved by Gurobi at the root of its branch- and-bound tree. 123
62 S. Mallach Table 1 MIP results for QAPLIB instances solved within 48 h by using at least one of the linearizations (except esc16f) Instance |N||P|SLC SLR IL Solve[s] Solve[s] |Q||M|NZ+ A1[s] Solve[s] esc32e 1024 4992 1.08 0.51 5952 384 12,288 0.29 0.90 esc32g 1024 7488 83.06 50.58 8928 576 18,432 0.25 18.68 esc16j 256 2112 2.47 0.94 2880 384 6144 0.02 0.85 chr25a 625 14,400 – – 14,400 1200 30,000 0.11 43.00 esc16i 256 2640 3.95 3.22 3600 480 7680 0.02 2.07 chr22a 484 9702 – – 9702 924 20,328 0.07 3.84 chr22b 484 9702 – – 9702 924 20,328 0.07 2.47 chr20a 400 7220 15,265.27 13,445.08 7220 760 15,200 0.05 3.66 chr20b 400 7220 – – 7220 760 15,200 0.05 7.58 chr20c 400 7220 461.58 1178.36 7220 760 15,200 0.05 10.14 chr18a 324 5202 3020.19 3993.45 5202 612 11,016 0.03 1.50 chr18b 324 5202 – – 5202 612 11,016 0.03 0.64 esc16d 256 3696 19.56 80.49 5040 672 10,752 0.02 14.13 esc16e 256 3696 20.61 4.75 5040 672 10,752 0.02 3.74 esc16g 256 3696 10.77 12.11 5040 672 10,752 0.02 4.80 chr15a 225 2940 238.84 245.43 2940 420 6300 0.02 0.81 chr15b 225 2940 38.39 33.93 2940 420 6300 0.02 0.97 chr15c 225 2940 476.93 1178.79 2940 420 6300 0.02 0.05 chr12a 144 1430 9.36 8.83 1452 264 3168 0.02 0.31 chr12b 144 1430 5.30 5.61 1452 264 3168 0.01 0.28 chr12c 144 1430 53.51 46.86 1452 264 3168 0.01 0.32 123
Inductive linearization for binary quadratic programs with… 63 Table 1 continued Instance |N||P|SLC SLR IL Solve[s] Solve[s] |Q||M|NZ+ A1[s] Solve[s] esc16a 256 6688 116.90 60.53 9120 1216 19,456 0.02 31.93 esc16c 256 8976 13,0344.85 94,465.73 12,240 1632 26,112 0.02 3804.05 els19 361 19,152 625.85 1014.66 19,152 2128 40,432 0.04 19.94 scr20 400 23,560 – – 23,560 2480 49,600 0.05 4443.16 scr15 225 8820 1805.14 3565.79 8820 1260 18,900 0.02 80.31 scr12 144 3696 34.04 104.92 3696 672 8064 0.01 6.64 esc16b 256 16,192 – – 21,184 2848 45,568 0.02 25.25 nug12 144 5940 20,650.09 21,190.65 5940 1080 12,960 0.01 105.32 nug16b 256 20,160 – – 20,160 2688 43,008 0.03 29,747.55 esc16h 256 20,240 10,0567.63 67,570.01 22,080 3120 49,920 0.02 675.30 nug15 225 15,750 – – 15,750 2250 33,750 0.03 12,409.31 tai10b 100 3150 55.71 59.47 3150 700 7000 0.01 1.52 nug14 196 12,376 – – 12,376 1904 26,656 0.02 12,910.87 tai15b 225 17,010 54,407.42 16,9093.38 17,010 2430 36,450 0.02 245.14 tai12b 144 7040 1376.05 3431.63 7934 1517 18,204 0.02 198.62 tai20b 400 60,040 – – 60,040 6320 126,400 0.06 1900.86 tai10a 100 3870 353.71 695.93 3870 860 8600 0.00 39.97 tai12a 144 8448 33,467.24 10,188.60 8448 1536 18,432 0.02 744.46 rou12 144 8580 59,224.34 32,873.04 8580 1560 18,720 0.02 3784.72 had12 144 8712 14,5050.52 11,3320.70 8712 1584 19,008 0.01 3078.47 had14 196 16,562 – – 16,562 2548 35,672 0.02 59,730.09 The instances are sorted in ascending order w.r.t. their density. Each of them has the value of n(here |N|=n2) in its name and positive objective coefficients only. Thus, SLR has |P|additional inequalities and 3|P|additional non-zeros. The additional non-zeros for IL are displayed in column “NZ+” The fastest solution times are printed in bold 123
64 S. Mallach 3.2 The quadratic 0–1 knapsack problem The certainly simplest inequality-only application for the inductive linearization technique is the quadratic 0–1 knapsack problem (QKP). It is particularly interesting for the computational study because here the left hand side coefficients (item sizes) and the right hand sides (knapsack capacity) vary and they relate to each other at different, and sometimes large, ratios. The canonical formulation with a capacity b∈R, and a variable xjfor each item jof a ground set Jwith size aj∈Rreads: max i,j∈J,i<j qijxixj+ i∈J cixi s.t. i∈J aixi≤b(17) xi∈{0,1}for all i∈J It has then been observed in the literature that inequalities of type (8) could be used in combination with the “standard” linearization (see e.g., Billionnet and Calmels (1996)), and also inequalities of type (9) have been applied in the context of semidefinite relaxations to improve the obtained dual bounds (Helmberg et al. 2000). A corresponding square-reduced inductive linearization is the following mixed-integer program: max i,j∈J,i<j qijyij + i∈J cixi s.t. i∈J aixi≤b i∈J,i= j aiyij ≤(b−aj)xjfor all j∈J i∈J,i= j ai(xi−yij)≤b(1−xj)for all j∈J yij ∈[0,1]for all i,j∈J,i<j xi∈{0,1}for all i∈J Irrespective of the cardinality of P, the Conditions 1–3must be established using (17) for any product which implies that all possible products are induced as soon as Pis non-empty. Thus, this formulation is constraint-side compact, and more and more superior over “standard” linearizations in this respect with increasing density. Assuming |J|=n, even a QKP involving all n 2possible products could be linearized using only 2n−1 constraints (n−1 inequalities of type (9) suffice to satisfy Condition 3for all of them while nof (8) are needed for Conditions 1and 2). However, in the general case of arbitrary aj,j∈J, and b, an implication of the “standard” linearization inequalities (2)–(4) cannot be expected. 123
Inductive linearization for binary quadratic programs with… 65 Fig. 2 Optimalitygapsobtainedwithcontinuousrelaxations(inpercent)forthesixtyselectedQKPinstances Instance Description As a benchmark set, we selected the 60 largest of the randomly generated instances by Billionnet and Soutif (2004) for presentation while the remaining ones with 100 elements could be solved more routinely using all methods. Their naming scheme follows the pattern jeu_n_d_i where nis the number of items, dindicates the approximate product density, and iis a running index. LP Relaxation Bounds and MIP Performance The optimality gaps obtained with ILW and SLC are shown in Fig. 2. They confirm what could be expected from theory: Due to the comparably large ratios between the constraint coefficients and right hand sides, the upper bounds obtained with ILW (the gap is 31.65% on average) are typically significantly weaker than with SLC (2.10%). While being considerably less compact in size, IL achieves the same bounds as ILW. Since there is only a single inequality comprising all original variables that serves as a basis for inductions, a first-level RLT basically coincides with IL, but involves a “standard” linearization in addition. While the latter is here already able to almost close the gaps standalone, side experiments showed that the much larger full first-level RLT did not suffice as well to close it entirely. The MIP results are displayed in Table 2. Only in two of the considered cases, it is slightly faster to use ILW than to pass a “standard” linearization to the MIP solver while considerably more timeouts are observed. As it turns out, the improved linearization variable-constraint linkage does not suffice in order to compensate for the weaker relaxation bounds of ILW. Moreover, whereas the numbers of linearization constraintsaresmallerwithILWthanwiththe“standard”linearizations,theconverseis true for the induced numbers of non-zeros. However, despite these preconditions apply broadly, one still observes a considerable variance in the solution times even within each size and product density group, with positive and negative outliers. Moreover, for the densest instances with 200 items in Table 2, only those with a comparably small knapsack capacity remain solvable using ILW while the left hand side coefficient ranges do (almost) not vary over the entire instance set. Even though there is less correlation for the other density groups, the theory-predicted sensitivity of the strength 123
66 S. Mallach Table 2 MIP results for sixty QKP instances with 200 and 300 items (time limit 48 h) Instance |P|LHS RHS SLC SLR ILW Solve[s] Solve[s] |M|NZ+ A1[s] Solve[s] jeu_200_25_1 5142 1–50 4027 68.64 24.79 399 31,125 0.01 99.28 jeu_200_25_2 5013 1–50 4271 1.45 1.16 399 30,351 0.02 8.44 jeu_200_25_3 4984 1–50 4763 2.33 0.99 399 30,173 0.01 10.12 jeu_200_25_4 5105 1–50 4518 12.76 27.15 399 30,895 0.01 22.76 jeu_200_25_5 4965 1–50 3688 6.07 14.19 399 30,063 0.01 19.47 jeu_200_25_6 5053 1–50 1700 102.65 40.33 399 30,591 0.01 48.35 jeu_200_25_7 4930 1–50 1242 11.40 27.46 399 29,849 0.01 88.51 jeu_200_25_8 4880 1–50 2861 5.92 15.14 399 29,555 0.01 15.86 jeu_200_25_9 4846 1–50 1012 10.17 7.43 399 29,353 0.01 78.14 jeu_200_25_10 4885 1–50 990 17.07 5.93 399 29,579 0.02 27.29 jeu_200_50_1 10,028 1–50 3547 1.76 1.37 399 60,321 0.01 10.03 jeu_200_50_2 10,047 1–50 2245 3526.24 1021.62 399 60,445 0.01 – jeu_200_50_3 9906 1–50 2120 175.45 46.06 399 59,609 0.01 17,308.21 jeu_200_50_4 10,002 1–50 2132 1.56 1.26 399 60,159 0.02 20.34 jeu_200_50_5 9910 1–50 4833 35.85 201.36 399 59,617 0.01 454.80 jeu_200_50_6 9930 1–50 4354 2183.73 5363.41 399 59,745 0.02 – jeu_200_50_7 9995 1–50 2430 2323.07 457.21 399 60,141 0.02 3460.83 jeu_200_50_8 9877 1–50 3159 5.49 11.05 399 59,419 0.02 84.13 jeu_200_50_9 9857 2–50 1105 246.87 71.67 399 59,313 0.02 – jeu_200_50_10 9881 1–50 2756 59.96 41.37 399 59,443 0.01 144.48 123
Inductive linearization for binary quadratic programs with… 67 Table 2 continued Instance |P|LHS RHS SLC SLR ILW Solve[s] Solve[s] |M|NZ+ A1[s] Solve[s] jeu_200_75_1 14,894 1–50 2866 152.85 282.07 399 89,425 0.01 – jeu_200_75_2 14,935 1–50 2139 5528.92 1407.65 399 89,685 0.01 – jeu_200_75_3 14,869 1–50 408 134.08 51.88 399 89,283 0.02 51.23 jeu_200_75_4 14,839 1–50 1220 72.01 168.76 399 89,105 0.02 – jeu_200_75_5 14,920 1–50 859 475.26 53.63 399 89,589 0.02 – jeu_200_75_6 14,898 1–50 1349 11.77 12.26 399 89,457 0.02 – jeu_200_75_7 15,051 1–50 1736 13.33 103.06 399 90,373 0.02 – jeu_200_75_8 14,836 1–50 3412 5.70 5.99 399 89,079 0.02 144.83 jeu_200_75_9 14,890 1–50 3412 2159.61 2397.77 399 89,407 0.01 – jeu_200_75_10 14,863 1–50 955 41.58 17.16 399 89,237 0.02 – jeu_200_100_1 19,900 1–50 4785 – – 399 119,401 0.02 – jeu_200_100_2 19,900 1–50 1325 1359.39 941.21 399 119,401 0.01 – jeu_200_100_3 19,900 1–50 173 15.63 13.16 399 119,401 0.02 6.17 jeu_200_100_4 19,900 1–50 498 15.32 10.68 399 119,401 0.01 34.79 jeu_200_100_5 19,900 1–50 4005 43.10 2557.07 399 119,401 0.01 – jeu_200_100_6 19,900 1–50 195 6.14 4.42 399 119,401 0.02 5.77 jeu_200_100_7 19,900 1–50 3583 127.29 2084.33 399 119,401 0.01 – jeu_200_100_8 19,900 1–50 3677 7122.79 16,832.06 399 119,401 0.02 – jeu_200_100_9 19,900 1–50 3256 395.66 1278.81 399 119,401 0.02 – jeu_200_100_10 19,900 1–50 1859 48,407.79 1853.81 399 119,401 0.02 – 123
68 S. Mallach Table 2 continued Instance |P|LHS RHS SLC SLR ILW Solve[s] Solve[s] |M|NZ+ A1[s] Solve[s] jeu_300_25_1 11,339 1–50 376 12.99 4.30 599 68,447 0.03 70.88 jeu_300_25_2 11,201 1–50 3878 207.73 130.67 599 67,623 0.03 133.93 jeu_300_25_3 11,157 1–50 3128 52.16 60.23 599 67,341 0.03 79.04 jeu_300_25_4 11,256 1–50 5759 69.01 61.69 599 67,951 0.03 125.63 jeu_300_25_5 11,403 1–50 197 7.70 15.95 599 68,833 0.03 42.70 jeu_300_25_6 11,406 1–50 3451 43.79 25.59 599 68,861 0.03 57.04 jeu_300_25_7 11,192 1–50 6282 31.04 94.61 599 67,569 0.03 103.40 jeu_300_25_8 11,157 1–50 114 2.61 1.74 599 67,351 0.03 7.15 jeu_300_25_9 11,212 1–50 3150 64.47 61.51 599 67,689 0.03 77.52 jeu_300_25_10 11,340 1–50 5322 111.64 190.87 599 68,431 0.03 146.62 jeu_300_50_1 22,534 1–50 3550 45,101.55 4177.61 599 135,457 0.03 – jeu_300_50_2 22,436 1–50 794 368.21 69.41 599 134,873 0.03 – jeu_300_50_3 22,351 1–50 5946 165.15 1385.97 599 134,359 0.03 4094.58 jeu_300_50_4 22,403 1–50 1957 1278.35 566.32 599 134,655 0.03 – jeu_300_50_5 22,400 1–50 4912 1092.21 1399.43 599 134,645 0.03 1122.80 jeu_300_50_6 22,444 1–50 5106 1768.96 6667.74 599 134,905 0.03 5813.68 jeu_300_50_7 22,580 1–50 328 43.23 41.20 599 135,725 0.03 69.51 jeu_300_50_8 22,253 1–50 5069 3717.43 2915.27 599 133,765 0.03 3103.92 jeu_300_50_9 22,321 1–50 4907 105.61 319.16 599 134,177 0.03 327.98 jeu_300_50_10 22,476 1–50 7040 74.54 3590.43 599 135,099 0.03 3189.32 The third column gives the interval of left hand side coefficients and the fourth column specifies the value of the right hand side of the knapsack constraint. Concerning the inductive linearization, the presentation is restricted to ILW that clearly outperformed IL. SLR has here 2|P|additional inequalities, and 4|P|additional non-zeros as all the instances have positive objective coefficients only. The additional non-zeros for ILW are displayed in column “NZ+” The fastest solution times are printed in bold 123
Inductive linearization for binary quadratic programs with… 69 of inductive linearizations to the “ratio” between the right hand side and the left hand side coefficients is here apparent. The suitability of using inductive linearizations for more complex problems with knapsack constraints may as well be influenced by the mentioned ratio and of course by the additional inherent structure. As mentioned above, deriving an inductive linearization is trivial when based on the knapsack inequality and the unique solution was also computed fast with Algorithm 1in our experiments. 3.3 The quadratic matching problem Given an undirected graph G=(V,E), a canonical BQP that models the quadratic matching problem (QMP) on G[see e.g. (Hupp et al. 2015)] can be expressed as max e,f∈E,e= f qef xexf+ e∈E cexe s.t. e:{i,j}∈E xe≤1 for all i∈V(18) xe∈{0,1}for all e∈E. Itiseasilyobservedthateachedge(factor)occursinexactlytwoconstraints, namely those inequalities (18) associated with its endpoints. In this sense, the situation is similar as in case of the QAP. However, the constraints need not be as regular as they depend on the structure of G. Notwithstanding, their coefficients and right hand sides ensure that (the relaxation of) an inductive linearization will imply the inequalities of a “standard linearization”. Instance Description For our experiments, we first employed all the instances used by Hupp et al. (2015), and finally selected a representative subset of those called “BM” in this reference, as the other ones with less variables or products could be solved quickly using all linearization approaches, and the other instances of about the same size produced similar results as has been the case also in the reference. The product densities of the selected instances lie between 63% and 83%, increasing from suffixes _80 to _100. LP Relaxation Bounds and MIP Performance As can be seen from Fig.3, the optimality gaps obtained when solving the relaxations of the 50 representative instances with ILW are close to the strong RLT bounds while the upper bounds obtained with SLC are weak. Over the entire “BM” set consisting of 150 instances, the bounds are always within 13% and 32% for ILW, within 5% and 30% using the RLT, and between 84% and 92% for SLC. Concerning the MIP solver performance, there is a clear picture: For all the “BM” instances (including the representative ones displayed in Table 3), Gurobi could solve the problems better using one of the inductive linearizations than when using SLC or SLR. In 101 of the entire 150 cases, the best results are obtained with ILW that, on average, took about 36% and 42% of the running time that was required with SLC and SLR, respectively. Besides the stronger relaxations, this performance of the 123
70 S. Mallach Fig. 3 Optimalitygapsobtainedwith continuousrelaxations(inpercent)forthefiftyselected QMPinstances inductive linearizations is further supported by the constraint-side compactness while the number of induced non-zeros is typically higher. Although using ILW turned out to be more effective than using IL, both are displayed in Table 3in order to support an assessment of the model size reduction obtained by the weakening. Roughly, the number of linearization constraints compared to IL was reduced by the weakening procedure by about 21%, 12%, and 2% for the instances with the suffixes _80,_90, and _100, respectively. The running times obtained indicate only a slight and inconsistent correlation to the three density levels, and with IL and ILW the numbers of additional constraints and the additional non-zeros generated by Algorithm 1are typically even smaller for the denser instances. We conclude that the matching constraints appear as rather attractive candidates for inductive linearizations. In additional experiments, computing an inductive linearization with a mixed-integer programs turned out to be comparably more difficult for the MIP solver employed. On the contrary, Algorithm 1delivered good linearizations routinely and quickly. 3.4 The quadratic shortest path problem Given a directed graph G=(V,A), a source node s∈Vand a target node t∈V,a canonical BQP that models the quadratic shortest s-t-path problem (QSPP) on G(see e.g. Rostami et al. (2018)) can be expressed as min a,b∈A,a=b qabxaxb+ a∈A caxa s.t. a:(i,j)∈A xa− a:(j,i)∈A xa=b(i)for all i∈V xa∈{0,1}for all a∈A, (19) where b(i)=0 for all i∈V\{s,t},b(s)=1, and b(t)=−1. 123
Inductive linearization for binary quadratic programs with… 77 Table 5 Confirmed optimal solution values for some generalized assignment problem instances from the MINLPLib Instance Optimal Value Instance Optimal value pb302035 3379359 pb351535 4456670 pb302055 3593105 pb351555 4639128 pb302075 4050938 pb351575 6301723 pb302095 5710645 pb351595 6670264 Fig. 5 Optimalitygapsobtainedwith continuous relaxations (in percent)fortheMINLPLibinstancessolved by using at least one of the linearizations (time limit 48 h). Some instance names where shortened, gpstands for graphpart- and mfor maxcsp- LP Relaxation Bounds and MIP Performance Figure 5displays the sustained relaxation optimality gaps for the instances that could be solved within 48 h using at least one method. The MIP results are shown in Tables 6and 7. Besidesthealreadymentionedcrossdock andpb instances,thetwocolor_lab instances are the only ones that do not have their non-zero left hand side coefficients and right hand sides all equal to one. As forward referenced from Sect.3.1, an inductive linearization is frequently (but not always) suited and superior to a “standard” linearization for instances with this structure. In several cases, this is also true when compared with Gurobi as a standalone solver. On the one hand, for the crossdock and the pb instances, the improved bounds withIL translateinto a better MIP performance, supported further by theideal situation that IL is here also very effective in terms of the number of linearization equations and additional non-zeros. Moreover, for celar6-sub0, the inductive linearization is orders of magnitude faster even though there are many products and induced nonzeros, and even though there is no according indication in terms of the relaxation optimality gaps. On the other hand, for the maximum constraint satisfiability problems, SLR performs clearly best with Gurobi while IL requires less linearization constraints but induces more non-zeros and linearization variables, and even its root linear program 123
78 S. Mallach Table 6 MIP results: Linearly constrained BQPs from the MINLPLib (1st part) Instance |N|mL|P|LHS RHS SLC SLR IL GRB Solve[s] Ineq NZ+ Solve[s] |Q||M|NZ+ A1[s] Solve[s] Solve[s] gp_2g-0044-1601 48 16 96 1–1 1–1 0.03 141 333 0.02 288 192 768 0.00 0.06 0.01 gp_2g-0055-0062 75 25 150 1–1 1–1 0.08 219 519 0.06 450 300 1200 0.00 0.11 0.06 gp_2g-0066-0066 108 36 216 1–1 1–1 0.27 342 774 0.15 648 432 1728 0.01 0.19 0.13 gp_2g-0077-0077 147 49 294 1–1 1–1 0.29 426 1014 0.27 882 588 2352 0.01 0.32 0.13 gp_2g-0088-0088 192 64 384 1–1 1–1 0.34 612 1380 0.24 1152 768 3072 0.02 0.50 0.18 gp_2g-0099-9211 243 81 486 1–1 1–1 0.50 711 1683 0.38 1458 972 3888 0.03 1.99 0.31 gp_2g-1010-0824 300 100 600 1–1 1–1 0.57 891 2091 0.36 1800 1200 4800 0.04 2.95 0.23 gp_2pm-0044-0044 48 16 96 1–1 1–1 0.03 144 336 0.03 288 192 768 0.00 0.07 0.01 gp_2pm-0055-0055 75 25 150 1–1 1–1 0.09 225 525 0.07 450 300 1200 0.01 0.11 0.08 gp_2pm-0066-0066 108 36 216 1–1 1–1 0.12 324 756 0.15 648 432 1728 0.01 0.29 0.08 gp_2pm-0077-0777 147 49 294 1–1 1–1 0.20 441 1029 0.22 882 588 2352 0.01 0.93 0.14 gp_2pm-0088-0888 192 64 384 1–1 1–1 0.22 576 1344 0.20 1152 768 3072 0.02 0.54 0.11 123
Inductive linearization for binary quadratic programs with… 79 Table 6 continued Instance |N|mL|P|LHS RHS SLC SLR IL GRB Solve[s] Ineq NZ+ Solve[s] |Q||M|NZ+ A1[s] Solve[s] Solve[s] gp_2pm-0099-0999 243 81 486 1–1 1–1 0.69 729 1701 0.50 1458 972 3888 0.03 17.93 0.31 gp_3g-0234-0234 72 24 180 1–1 1–1 0.17 264 624 0.13 540 360 1440 0.00 0.12 0.12 gp_3g-0244-0244 96 32 240 1–1 1–1 0.32 354 834 0.28 720 480 1920 0.01 0.19 0.20 gp_3g-0333-0333 81 27 243 1–1 1–1 0.16 345 831 0.14 729 486 1944 0.00 0.20 0.09 gp_3g-0334-0334 108 36 324 1–1 1–1 0.33 471 1119 0.21 972 648 2592 0.01 0.82 0.15 gp_3g-0344-0344 144 48 432 1–1 1–1 0.90 648 1512 0.46 1296 864 3456 0.01 0.61 0.32 gp_3g-0444-0444 192 64 576 1–1 1–1 1.56 900 2052 1.18 1728 1152 4608 0.02 5.17 3.35 gp_3pm-0234-0234 72 24 180 1–1 1–1 0.19 264 624 0.11 540 360 1440 0.00 0.24 0.08 gp_3pm-0244-0244 96 32 240 1–1 1–1 0.34 360 840 0.23 720 480 1920 0.01 0.66 0.14 gp_3pm-0333-0333 81 27 243 1–1 1–1 0.12 363 849 0.07 729 486 1944 0.00 0.67 0.07 gp_3pm-0334-0334 108 36 324 1–1 1–1 0.66 486 1134 0.50 972 648 2592 0.01 2.57 0.12 gp_3pm-0344-0344 144 48 432 1–1 1–1 0.84 648 1512 0.93 1296 864 3456 0.02 21.77 1.50 gp_3pm-0444-0444 192 64 576 1–1 1–1 21.40 864 2016 20.61 1728 1152 4608 0.02 259.74 11.72 The fifth column gives the interval of left hand side coefficients and the sixth column specifies the ranges of the right hand sides. For SLR, the varying exact number of additional inequalities (“Ineq”) and non-zeros (“NZ+”) are displayed explicitly. The same is true for IL. The columns labeled “GRB” display the wall clock time in seconds when passing the .lp-file directly to Gurobi. The prefix “gp” abbreviates “graphpart” The fastest solution times are printed in bold 123
80 S. Mallach Table 7 MIP results: Linearly constrained BQPs from the MINLPLib (time limit 48 h, 2nd part) Instance |N|mL|P|LHS RHS SLC SLR IL GRB Solve[s] Solve[s] |Q||M|NZ+ A1[s] Solve[s] Solve[s] cardqp_inlp / _iqp 50 1 1225 1–1 10–10 25.37 144.49 1225 50 2500 0.00 270.37 18.51 celar6-sub0 640 16 64,032 1–1 1–1 2515.80 1937.70 93,744 4624 192,112 0.11 31.78 142.34 color_lab3_3x0 316 80 2241 1–1 0–1 266.47 57.05 3984 1992 9960 0.04 14,349.98 70.78 color_lab3_4x0 395 80 3984 1–1 0–1 60,106.29 – 6225 2490 14,940 0.05 – – crossdock_15x7 210 44 2793 1–233 1–302 953.87 770.44 2793 798 6384 0.02 156.66 1562.87 crossdock_15x8 240 46 3648 1–209 1–233 1732.60 1141.33 3648 912 8208 0.02 401.92 29,883.15 gp_clique-20 60 20 570 1–1 1–1 1.01 0.44 1710 1140 4560 0.00 0.57 0.89 gp_clique-30 90 30 1305 1–1 1–1 9.09 6.49 3915 2610 10,440 0.01 8.07 6.74 gp_clique-40 120 40 2340 1–1 1–1 58.63 39.13 7020 4680 18,720 0.01 75.34 40.52 gp_clique-50 150 50 3675 1–1 1–1 746.27 766.82 11,025 7350 29,400 0.02 986.70 357.88 gp_clique-60 180 60 5310 1–1 1–1 5428.22 19,639.69 15,930 10,620 42,480 0.02 5524.39 18,400.19 gp_clique-70 210 70 7245 1–1 1–1 15,646.96 6931.17 21,735 14,490 57,960 0.02 82,306.97 – m-ehi-85-297-12 2071 297 101,333 1–1 1–1 64,617.37 1742.66 199,509 57,192 456,210 1.38 44,245.78 10,7791.48 m-ehi-85-297-36 2046 297 99,286 1–1 1–1 41,759.38 3147.43 196,266 56,782 449,314 1.36 61,696.60 78,597.00 m-ehi-85-297-71 2075 297 101,923 1–1 1–1 11,434.65 11,104.69 200,794 57,454 459,042 1.43 11,9508.18 40,835.13 m-ehi-90-315-70 2203 315 108,662 1–1 1–1 – 8260.88 214,502 61,338 490,342 1.88 90,374.67 – m-geo* 1000 50 33,837 1–1 1–1 5.98 0.33 135,600 13,560 284,760 0.28 1856.88 4.17 m-langford-3-11 627 33 14,196 1–1 1–1 48,399.07 63,878.86 182,604 18,908 384,116 0.13 – – pb302095 600 50 165,300 1–98 1–129 – – 173,884 17,400 365,168 0.15 136,298.34 – The fifth column gives the interval of left hand side coefficients and the sixth column specifies the ranges of the right hand sides. For SLR, the number of additional inequalities is equal to |P|(only inequalities (4)), and the number of non-zeros is thus equal to 3|P|. For IL, the number non-zeros are displayed explicitly (“NZ+”). The columns labeled “GRB” display the wall clock time in seconds when passing the .lp-file directly to Gurobi (up to timeouts). The prefix gpstands for graphpartwhile “m” abbreviates “maxcsp”, and the full name of m-geo* is maxcsp-geo50-20-d4–75-36 The fastest solution times are printed in bold 123
Inductive linearization for binary quadratic programs with… 81 Fig. 6 Optimality gaps obtained with continuous relaxations (in percent) for the QPLIB instances with linear inequality constraints that were solved by using at least one of the linearizations (time limit 48 h) proved difficult to solve with Gurobi. Moreover, the color_lab instances turn out to be difficult when using IL, even though the bound obtained with its continuous relaxation is much better than with SLC and also the model size is auspicious. For the “semi-assignment”-like graph partitioning instances (see also a more comprehensive study in Mallach (2018) with an additional normalization constraint), we seeadiversepictureaswell:Whilethegraphpart-2 and graphpart-3 instances prove rather simple for all methods (which also achieve the same relatively strong relaxation optimality gaps), the bounds obtained for the graphpart-clique- instances are equal to zero and they become especially challenging for IL with increasing size. In the latter instances, each node must be assigned to one of three partitions and the costs of placing any pair of nodes in the same partition are equal for all partitions. The initial number of products Pas well as the computed inductive linearizations are significantly larger than for the other graphpart instances mentioned before. Additional experiments revealed that the bounds for most of the instances, in particular the graphpart and the maxcsp instances, could not be improved even when multiplying all constraints with all variables which here leads to a (square-reduced) first-level RLT since the “standard” linearization inequalities are then implied for these instances. 3.6 QPLIB Finally, we look at the QPLIB (Furini et al. 2019), and we again chose the .lp format to pass the selected instances directly to Gurobi. Instance Description Here, we selected all BQPs with linear inequality constraints to be part of our testbed, especially since the MINLPLib experiments only involved instances with linear equation constraints, and since most instances of this kind in QPLIB are also part of the MINLPLib and QAPLIB experiments. LP Relaxation Bounds and MIP Performance For those selected instances that could be solved within 48 h using at least one method, Fig. 6shows the relaxation optimality gaps. For the majority of the instances, 123
82 S. Mallach Table 8 MIP results for the (linear) inequality-constrained BQPs from the QPLIB solved by using at least one of the linearizations (time limit 48 h) Instance |N|mL|P|LHS RHS SLC SLR ILW GRB Solve[s] Ineq NZ+ Solve[s] |M|NZ+ A1[s] Solve[s] Solve[s] 0067 80 1 2844 2–50 1555–1555 146.33 5688 11,376 103.97 159 17,067 0.00 162.18 141.61 0752 250 1 3114 −1–1 −1–1 87,163.98 4686 10,914 – 499 19,113 0.02 – 9450.56 2357 240 2240 2254 −1–1 0–1 1653.46 3418 7926 996.49 6687 22,661 1.23 5230.46 502.98 2359 306 3264 1740 −1–1 0–1 169.64 2553 6033 127.99 4752 15,909 2.30 1544.24 529.78 3752 462 6160 3988 −1–1 0–1 – 5836 13,812 – 11,666 39,601 6.32 – 63,118.56 3757 552 8096 1463 −1–1 0–1 1004.99 2189 5115 874.74 3887 12,039 10.12 2955.59 803.89 3762 90 480 1133 −1–1 0–1 47.19 1680 3946 213.76 3554 12,271 0.10 1387.61 39.31 3772 380 4560 2761 −1–1 0–1 19,452.10 4117 9639 5789.64 7887 26,577 3.84 31,669.27 3137.08 3803 190 2280 2538 −1–1 0–1 454.61 4250 9326 294.35 8833 28,905 1.00 52,979.55 405.58 3841 300 4600 4600 −1–1 0–1 97,036.34 7603 16,803 – 15,367 51,290 3.03 – 33,631.62 3883 182 1456 2947 −1–1 0–1 41,069.49 4324 10,218 7924.69 9068 31,406 0.58 – 19,768.73 5935 100 1237 4950 1–1 1–1 2860.17 8725 18,625 2365.87 7115 25,867 0.13 707.32 259.42 5944 100 2475 4950 1–1 1–1 131.00 8730 18,630 91.32 4757 17,301 0.21 75.36 16.99 5962 150 2793 11,175 1–1 1–1 70,407.89 19,705 42,055 94,666.80 16,447 59,671 0.41 20,114.83 11,003.64 5971 150 5587 11,175 1–1 1–1 3819.98 19,672 42,022 2741.02 10,974 39,902 0.65 585.06 112.71 5980 150 8381 11,175 1–1 1–1 157.74 19,649 41,999 109.84 5449 19,851 0.64 40.34 46.67 10040 125 6 7174 1–998 62–31,468 1315.91 10,822 25,170 771.56 247 43,045 0.01 – 0.01 123
Inductive linearization for binary quadratic programs with… 83 Table 8 continued Instance |N|mL|P|LHS RHS SLC SLR ILW GRB Solve[s] Ineq NZ+ Solve[s] |M|NZ+ A1[s] Solve[s] Solve[s] 10041 125 6 7615 1–998 62–31,468 – 11,395 26,625 – 247 45,691 0.01 – 0.30 10042 125 5 7619 2–1000 47,135–50,209 66,995.42 11,420 26,658 30,723.40 247 45,715 0.01 – 0.17 10043 150 10 10,513 1–1000 54,036–58,799 499.84 15,703 36,729 154.32 297 63,121 0.01 – 0.01 10044 150 6 10,549 1–999 50–57,547 953.01 15,852 36,950 297.66 291 63,295 0.01 – 2.55 10045 150 10 10,091 1–1000 54,036–58,799 – 15,202 35,384 – 285 60,547 0.01 – 0.02 10046 150 6 9875 1–999 50–57,547 344.86 14,894 34,644 161.52 287 59,253 0.01 – 0.16 10047 150 10 11,168 1–1000 54,036–58,799 – 16,811 39,147 – 299 67,009 0.01 – 0.01 10048 150 5 11,018 2–1000 55,564–60,822 – 16,475 38,511 – 297 66,109 0.01 – 138.17 10049 150 10 11,018 1–1000 54,036–58,799 – 16,528 38,564 – 297 66,109 0.01 – 0.01 10050 150 5 10,878 2–1000 55,564–60,822 – 16,287 38,043 – 295 65,269 0.01 – 0.63 10051 150 10 11,015 1–1000 54,036–58,799 – 16,438 38,468 – 297 66,091 0.01 – 4.76 10052 150 6 11,165 1–999 50–57,547 – 16,798 39,128 – 299 66,991 0.01 – 3.26 10053 150 10 11,019 1–1000 54,036–58,799 – 16,634 38,672 – 297 66,115 0.01 – 0.01 10054 175 11 13,398 1–1000 116–22,886 516.18 20,162 46,958 128.34 339 80,389 0.01 – 43.57 10055 175 5 13,918 2–1000 66,009–70,533 492.83 20,924 48,760 177.06 347 83,511 0.01 – 1.47 10056 175 5 14,535 2–1000 66,009–70,533 – 21,912 50,982 – 341 87,211 0.01 – 0.23 10057 200 11 15,056 1–1000 66–77,923 495.82 22,601 52,713 93.97 371 90,347 0.02 – 0.01 10058 200 11 17,491 1–1000 100–54,119 907.07 26,231 61,213 219.88 395 105,337 0.02 – 264.54 10059 200 10 14,135 1–1000 45,545–53,253 – 21,165 49,435 – 341 84,811 0.02 – 0.02 10060 200 10 17,474 1–1000 45,545–53,253 798.39 26,114 61,062 390.81 389 104,896 0.02 – 0.11 123
84 S. Mallach Table 8 continued Instance |N|mL|P|LHS RHS SLC SLR ILW GRB Solve[s] Ineq NZ+ Solve[s] |M|NZ+ A1[s] Solve[s] Solve[s] 10061 200 5 17,892 2–1000 73,590–80,431 – 26,912 62,696 – 381 107,353 0.01 – 0.97 10062 200 10 18,162 1–1000 45,545–53,253 – 27,215 63,539 – 383 108,973 0.02 – 0.06 10063 200 5 19,413 2–1000 73,590–80,431 5895.00 29,189 68,015 2174.58 395 116,479 0.01 – 0.09 10064 200 11 19,272 1–1000 66–77,923 – 28,885 67,429 – 393 115,633 0.02 – 0.02 10065 200 11 19,302 1–1000 100–50,591 – 28,925 67,529 – 393 115,813 0.02 – 2.19 10066 200 11 19,301 1–1000 100–54,119 – 28,747 67,349 – 393 115,807 0.02 – 0.45 10067 200 5 19,642 2–1000 73,590–80,431 – 29,462 68,746 – 397 117,853 0.02 – 0.39 10068 200 11 19,879 1–1000 100–54,119 – 29,898 69,656 – 399 119,275 0.02 – 1.26 10069 200 10 19,264 1–1000 45,545–53,253 1042.20 28,787 67,315 380.48 405 117,012 0.02 – 0.01 10070 200 11 19,478 1–1000 100–54,119 – 29,215 68,171 – 395 116,869 0.02 – 32.63 10071 200 11 19,698 1–1000 66–77,923 – 29,552 68,948 – 399 118,189 0.02 – 0.03 10072 75 10 2049 1–1000 23,837–30,414 5842.82 3104 7202 2566.77 133 12,295 0.01 – 0.00 10073 75 6 1928 1–999 37–10,480 8692.58 2889 6745 2172.87 133 11,697 0.01 – 0.00 10074 75 10 2774 1–1000 23,837–30,414 10,672.72 4141 9689 5733.37 149 16,645 0.01 – 0.00 The fifth column gives the interval of left hand side coefficients and the sixth column specifies the ranges of the right hand sides. For SLR, the varying exact number of additional inequalities (“Ineq”) and non-zeros (“NZ+”) are displayed explicitly. The same is true for ILW. The columns labeled “GRB” display the wall clock time in seconds when passing the .lp-file directly to Gurobi The fastest solution times are printed in bold 123
Inductive linearization for binary quadratic programs with… 85 these gaps are large irrespective of the method used. Zero lower bounds (100% gaps) are frequently observed for minimization problems like e.g. most instances with prefix 100 that have large ratios between the right hand sides and the left hand side coefficients. For a few of these with slightly better gaps, the SLC bound turns out to be superior. Also for instance 0067 (actually, a QKP), the ILW gap of 16.25% is weaker than the 1.26% gap obtained with SLC which is in line with Sect.3.2. Another example is instance 0752 where the ILW gap of 77.60% is considerably worse than the 39.83% gap obtained with SLC. Due to negative coefficients this instance requires normalization, and so do the instances with first digits 2and 3. Here, a similar effect as in Sect.3.4 concerning poorly linked linearization variables referring to the same pair of original variables applies. Only for the instances with first prefix 5,theILW bounds are slightly superior even though on a weak level. The MIP results are presented in Table 8. After the above discussion regarding the relaxation bounds and the impact of normalization, it could be expected that better results are obtained when using Gurobi as a standalone solver or sometimes also when supplying it with one of the “standard” linearization than when using ILW (which still worked better than IL). Indeed, while the instances with prefix 100 and their special coefficient ranges turn out to be unsuited for an inductive linearization, also the size of the linearizations for the instances starting with the digits 2and 3turns out to be unfavorable. Only for the instances with first digit 5, competitive model sizes and solution times are achieved with IL. 4 Conclusion A framework to derive inductive linearizations in practice has been outlined and it has been demonstrated that it can be effectively applied to a variety of binary quadratic programs with linear constraints. The experiments covered the Quadratic Assignment, Knapsack, Matching and Shortest Path Problems, as well as instances from the MINLPLib and QPLIB. Addressing the research questions mentioned in the introduction, the best results are typically obtained with an inductive linearization if its continuous relaxation is comparably tight and the number of linearization constraints and induced non-zero coefficients keep moderate at the same time. These ideal conditions are for example observed for Quadratic Assignment and Quadratic Matching Problems. If only the first property is fulfilled, for instance because the original constraints employed have right hand sides equal to one and zero–one left hand sides but the structure of the factor pairs or constraints impedes a compact model extension, or if the formulation is more compact without providing a strong relaxation, the results show that an inductive linearization may or may not compare well with a “standard” linearization. Whether one or the other case applies may then depend on further parameters such as the density of the given product terms and the actual distribution of their factors over the set of (employed) constraints, which in turn again also influence the achievable compactnessand relaxation strength of inductive linearizations.Moreover, if the ratios between right hand sides and (non-negative) left hand side coefficients are large, the relaxations of inductive linearizations tend to become weaker, and “standard” linearizations may 123
86 S. Mallach lead to superior running times with a mixed-integer programming solver as has been observed with the Quadratic Knapsack Problem. Until now, negative constraint coefficients may also impair the performance sustained with inductive linearizations. One reason is that the corresponding normalization step typically counteracts a compact reformulation, another is that often a poor linkage between linearization variables referring to the same pair of original variables is established by the induced constraints. Improvements in this respect are a natural subject for further research. The explanations for positive and negative observations at hand, it should be emphasized that they can only provide a partial image while exceptions from the respective rules of thumb exist naturally, especially since a MIP solution process depends on various further influences such as e.g. branching decisions or cutting place effectiveness. Across the instance sets considered, the inductive linearization technique frequently led to a continuous relaxation that is at least as tight as the one provided by a “standard” linearization. In several cases, the bounds also turned out to be equal or almost as good as those provided by a full first-level RLT even though being typically much more compact. The broad computational experiments further revealed that inductive linearizations can be computed quickly in an automated fashion for the various different application instances, and that this can typically be done well even with a simple combinatorial heuristic. Funding Open Access funding enabled and organized by Projekt DEAL. Declarations Conflict of interest The author declares that there is no conflict of interest. Open Access ThisarticleislicensedunderaCreativeCommonsAttribution4.0InternationalLicense,which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article’s Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/. References Adams WP, Johnson TA (1994) Improved linear programming-based lower bounds for the quadratic assignment problem. In: Pardalos PM, Wolkowicz H (eds) Quadratic assignment and related problems, vol 16. DIMACS Series on Discrete Mathematics and Computer Science. AMS, Providence, pp 43–75 Adams WP, Sherali HD (1986) A tight linearization and an algorithm for zero-one quadratic programming problems. Manag Sci 32(10):1274–1290. https://doi.org/10.1287/mnsc.32.10.1274 Adams WP, Sherali HD (1999) A reformulation-linearization technique for solving discrete and continuous nonconvex problems. In: Nonconvex optimization and its applications, vol 31. Springer. https://doi. org/10.1007/978-1-4757-4388-3 Billionnet A, Calmels F (1996) Linear programming for the 0–1 quadratic knapsack problem. Eur J Oper Res 92(2):310–325. https://doi.org/10.1016/0377-2217(94)00229-0 Billionnet A, Elloumi S (2001) Best reduction of the quadratic semi-assignment problem. Discrete Appl Math 109(3):197–213. https://doi.org/10.1016/S0166-218X(00)00257-2 123