• No results found

QPALM: A Newton-type Proximal Augmented Lagrangian Method for Quadratic Programs

N/A
N/A
Protected

Academic year: 2021

Share "QPALM: A Newton-type Proximal Augmented Lagrangian Method for Quadratic Programs"

Copied!
6
0
0

Bezig met laden.... (Bekijk nu de volledige tekst)

Hele tekst

(1)

QPALM: A Newton-type Proximal Augmented Lagrangian Method for Quadratic Programs

Ben Hermans,

1

Andreas Themelis

2

and Panagiotis Patrinos

2

Abstract— We present a proximal augmented Lagrangian based solver for general quadratic programs (QPs), relying on semismooth Newton iterations with exact line search to solve the inner subproblems. The exact line search reduces in this case to finding the zero of a one-dimensional monotone, piece- wise affine function and can be carried out very efficiently.

Our algorithm requires the solution of a linear system at ev- ery iteration, but as the matrix to be factorized depends on the active constraints, efficient sparse factorization updates can be employed like in active-set methods. Both primal and dual residuals can be enforced down to strict tolerances and oth- erwise infeasibility can be detected from intermediate iterates.

A C implementation of the proposed algorithm is tested and benchmarked against other state-of-the-art QP solvers for a large variety of problem data and shown to compare favorably against these solvers.

I. Introduction

This paper deals with convex quadratic programs (QPs) minimize

x∈’n 1

2

hx, Qxi + hq, xi subject to ` ≤ Ax ≤ u, (QP) where Q ∈ ’

n×n

is symmetric and positive semidefinite, q ∈

’

n

, A ∈ ’

m×n

, and `, u ∈ ’

m

.

E fficiently and reliably solving QPs is a key challenge in optimization [15, §16]. QPs cover a wide variety of appli- cations and problem classes, such as portfolio optimization, support vector machines, sparse regressor selection, real-time linear model predictive control (MPC), etc. QPs also often arise as subproblems in general nonlinear optimization tech- niques such as sequential quadratic programming. Therefore, substantial research has been performed to develop robust and e fficient QP solvers. State-of-the-art solvers are typi- cally based on interior point methods, such as MOSEK [1]

and Gurobi [14], or active-set methods, such as qpOASES [11]. Both methods have their advantages and disadvantages.

Interior point methods typically require few but expensive it- erations, involving the solution of a linear system at every iteration. In contrast, active-set methods require more but

1Ben Hermans is with the Department of Mechanical Engineering, KU Leuven, and DMMS lab, Flanders Make, Leuven, Belgium. His research benefits from KU Leuven-BOF PFV/10/002 Centre of Excellence: Opti- mization in Engineering (OPTEC), from project G0C4515N of the Research Foundation - Flanders (FWO - Flanders), from Flanders Make ICON: Avoid- ance of collisions and obstacles in narrow lanes, and from the KU Leuven Research project C14/15/067: B-spline based certificates of positivity with applications in engineering.

2Andreas Themelis and Panagiotis Patrinos are with the Department of Electrical Engineering (ESAT-STADIUS) – KU Leuven, Kasteelpark Aren- berg 10, 3001 Leuven, Belgium. This work was supported by the Research Foundation Flanders (FWO)research projects G086518N and G086318N;

Research Council KU Leuven C1 project No. C14/18/068; Fonds de la Recherche Scientifique — FNRS and the Fonds Wetenschappelijk Onder- zoek — Vlaanderenunder EOS project no 30468160 (SeLMA).

{ben.hermans2,andreas.themelis,panos.patrinos}@kuleuven.be

cheaper iterations, as the linear system changes only slightly and low-rank factorization updates can be used instead of having to factorize from scratch. As a result, active-set meth- ods can be e fficiently warm started when solving a series of similar QPs, which is common in applications such as MPC, whereas interior-point methods in general do not have this capability. Recently, proximal algorithms, also known as op- erator splitting methods [16], have experienced a resurgence in popularity. Relying only on first-order information of the problems, such methods have as their advantage operational simplicity and cheap iterations, but they may exhibit slow asymptotic convergence for poorly scaled problems. The re- cently proposed OSQP solver [21], based on the alternating direction method of multipliers (ADMM), addresses this cru- cial issue by means of a tailored o ffline scaling that performs very well on some QP problems, although a more thorough benchmarking confirms the known limitations of proximal algorithms. Indeed, parameter tuning is typically set before the execution, with possibly minor online adjustments, and as such operator splitting methods do not take into account cur- vature information about the problem that can greatly speed up convergence.

In this work we propose a novel and reliable QP solver

based on the augmented Lagrangian method (ALM) [5] and

in particular proximal ALM [18], which is e fficient and ro-

bust against ill conditioning. ALM involves penalizing the

constraints and solving a series of unconstrained minimiza-

tions, where fast smooth optimization techniques can be em-

ployed. QPs turn out to be particularly amenable for this ap-

proach, as optimal stepsizes of exact line searches are avail-

able in closed form, similiar to what was shown in previous

work [17], resulting in an extremely fast minimization strat-

egy. In each unconstrained optimization, the iterates rely on

the solution of a linear system, dependent on the set of ac-

tive constraints. As such, similarly to active-set methods, our

iterates can benefit from low-rank factorization update tech-

niques and are therefore cheaper than in interior point meth-

ods. However, in contrast to active-set methods and more

in the flavor of other algorithms such as the dual gradient

projection method of [2], our method allows for substan-

tial changes in the active set at each iteration and converges

therefore much faster on average. To some extent, our al-

gorithm strikes a balance between interior point and active-

set methods. In regard to state-of-the-art ALM solvers, not

much research is available. The authors of [13] presented

an ALM solver for QPs, OQLA /QPALM, which solves the

inner minimization problems using a combination of active-

set and gradient projection methods. Although the authors of

(2)

[9] discuss second order updates based on a generalized Hes- sian, similar to our method, their approach deals with convex (composite) optimization problems in general, and as such it can not make use of the e fficient factorization updates and optimal stepsizes that are key to the e fficiency of our algo- rithm. Finally, a link with proximal algorithms can also be established, in the sense that the form of an iterate of uncon- strained minimization is very similar to what is obtained by applying ADMM to (QP). Di fferently from an ADMM ap- proach where parameters are set before the execution, in our method penalties are adjusted online. Moreover, penalty ma- trices are used instead of scalars to allow for more flexibility in penalizing the constraints. As a result of the online ad- justments, our algorithm requires in general fewer, although slightly more expensive, iterations.

The contribution of this paper is QPALM, a full-fledged QP solver based on proximal ALM. We describe the relevant theory and outline in detail the algorithmic steps for both the outer and inner minimization procedures. We also provide an open-source C implementation of the algorithm,

1

which we benchmark with state-of-the-art QP solvers, showing that QPALM can compete with and very often outperform them both in runtime and robustness in regard to problem scaling.

The remainder of this paper is structured as follows. Sec- tion II introduces notation used in the paper and underlying theoretical concepts. Section III outlines the application of the proximal ALM to (QP). Section IV discusses in detail the algorithmic steps, regarding both inner and outer minimiza- tion, of QPALM. Section V addresses some of the crucial implementation details that contribute to making QPALM an e fficient and robust solver. Section VI presents simulation results on QPs of varying sizes and problem conditioning, benchmarking QPALM’s performance against state-of-the- art solvers. Finally, Section VII draws concluding remarks and mentions future directions of research.

II. Preliminaries

We now introduce some notational conventions and briefly list some known facts needed in the paper. The interested reader is referred to [4] for an extensive discussion.

A. Notation and known facts

We denote the extended real line by ’ B ’ ∪ {∞}.

The scalar product on ’

n

is denoted by h · , · i. With [x]

+

B max {x, 0} we indicate the positive part of vector x ∈ ’

n

, meant in a componentwise sense. A sequence of vectors (x

k

)

k∈Ž

is said to be summable if P

k∈Ž

kx

k

k < ∞.

With Sym(’

n

) we indicate the set of symmetric ’

n×n

ma- trices, and with Sym

+

n

) and Sym

++

n

) the subset of those which are positive semidefinite and positive definite, respectively. Given Σ ∈ Sym

++

n

) we indicate with k · k

Σ

the norm on ’

n

induced by Σ, namely kxk

Σ

B

√ hx, Σxi.

Given a nonempty closed convex set C ⊆ ’

n

, with Π

C

(x) we indicate the projection of a point x ∈ ’

n

onto C, namely

1https://github.com/Benny44/QPALM

Π

C

(x) = arg min

y∈C

ky − xk or, equivalently, the unique point z ∈ C satisfying the inclusion

x − z ∈ N

C

(z), (1)

where N

C

(z) B {v ∈ ’

n

| hv, z − z

0

i ≤ 0 ∀z

0

∈ C} is the nor- mal cone of C at z. dist(x, C) and dist

Σ

(x, C) denote the distance from x to set C in the Euclidean norm and in that induced by Σ, respectively, while δ

C

is the indicator function of set C, namely δ

C

(x) = 0 if x ∈ C and ∞ otherwise.

B. Convex functions and monotone operators

The Fenchel conjugate of a proper closed convex function ϕ : ’

n

→ ’ is the convex function ϕ

: ’

n

→ ’ defined as ϕ

(y) = sup

x

hx, yi − ϕ(x). The subdi fferential of ϕ at x ∈

’

n

is ∂ϕ(x) B {v ∈ ’

n

| ϕ(x

0

) ≥ ϕ(x) + hv, x

0

− xi ∀x

0

∈ ’

n

}.

Having y ∈ ∂ϕ(x) is equivalent to x ∈ ∂ϕ

(y).

A point-to-set mapping M : ’

n

⇒ ’

n

is monotone if hx− x

0

, ξ−ξ

0

i ≥ 0 for all x, x

0

∈ ’

n

, ξ ∈ M(x) and ξ

0

∈ M(x

0

).

It is maximally monotone if, additionally, there exists no monotone operator M

0

, M such that M(x) ⊆ M

0

(x) for all x ∈ ’

n

. The resolvent of a maximally monotone operator M is the single-valued (in fact, Lipschitz-continuous) map- ping (id + M)

−1

, where (id + M)

−1

(x) is the unique point

¯x ∈ ’

n

such that x − ¯x ∈ M( ¯x). zer M B {x | 0 ∈ M(x)} de- notes the zero-set of M, and for a linear mapping Σ, ΣM is the operator defined as ΣM(x) B {Σy | y ∈ M(x)}.

The subdi fferential of a proper convex lower semicontin- uous function ϕ is maximally monotone, and its resolvent is the proximal mapping prox

ϕ

B (id + ∂ϕ)

−1

.

III. Proximal ALM for QPs

This section is devoted to establishing the theoretical ground in support of the proposed Algorithm 1. We will show that our scheme amounts to proximal ALM and derive its convergence guarantees following the original analysis in [18], here generalized to account for scaling matrices (as op- posed to scalars) and by including the possibility of having di fferent Lagrangian and proximal weights. We start by ob- serving that problem (QP) can equivalently be expressed as

minimize

x∈’n

f (x) + g(Ax), (2)

where f (x) B

12

hx, Qxi + hq, xi, g(z) B δ

C

(z) and C B {z ∈ ’

m

| ` ≤ z ≤ u}. The KKT conditions of (2) are

0 ∈ M(x, y) B ∇f (x) + A

>

y

−Ax + ∂g

(y)

! .

Let V

?

B zer M be the set of primal-dual solutions. Since M is maximally monotone, as first observed in [18] one can find KKT-optimal primal-dual pairs by recursively applying the resolvent of c

k

M, where (c

k

)

k∈Ž

is an increasing sequence of strictly positive scalars. This scheme is known as proximal point algorithm (PPA) [18]. We now show that these scalars can in fact be replaced by positive definite matrices.

Theorem 1. Suppose that (2) has a solution. Starting from (x

0

, y

0

) ∈ ’

n

× ’

m

, let (x

k

, y

k

)

k∈Ž

be recursively defined as

(x

k+1

, y

k+1

) = (id + Σ

k

M)

−1

(x

k

, y

k

) + ε

k

(3) for a summable sequence (ε

k

)

k∈Ž

, and where Σ

k

B 

Σ

x,k Σy,k



for some Σ

x,k

∈ Sym

++

n

) and Σ

y,k

∈ Sym

++

m

). If Σ

k



(3)

Σ

k+1

 Σ

∈ Sym

++

n

ג

m

) holds for all k, then (x

k

, y

k

)

k∈Ž

converges to a KKT-optimal pair for (2).

Proof. We start by observing that for all k it holds that zer( Σ

k

M) = zer(M) = V

?

and that Σ

k

M is maximally monotone with respect to the scalar product induced by Σ

−1k

. The resolvent (id + Σ

k

M)

−1

is thus firmly nonexpansive in that metric (see [4, Prop. 23.8 and Def. 4.1]): that is, denot- ing v

k

B (x

k

, y

k

) and ˜v

k+1

B v

k+1

− ε

k

= (id + Σ

k

M)

−1

(v

k

),

k˜v

k+1

− v

?

k

2

Σ−1k

≤ kv

k

− v

?

k

2

Σ−1k

− k˜v

k+1

− v

k

k

2

Σ−1k

(4) holds for every v

?

∈ V

?

. Therefore, since kv

k+1

− v

?

k

Σ−1

k+1

kv

k+1

− v

?

k

Σ−1

k

≤ k˜v

k+1

− v

?

k

Σ−1

k

+kε

k

k

Σ−1

k

≤ kv

k

− v

?

k

Σ−1

k

+kε

k

k

Σ−1 k

(where the first inequality owes to the fact that Σ

−1k+1

 Σ

−1k

), it follows from [8, Thm. 3.3] that the proof reduces to showing that any limit point of (v

k

)

k∈Ž

belongs to V

?

.

From [8, Prop. 3.2(i)] it follows that the sequence is bounded and that v

k+1

− v

k

→ 0 as k → ∞. Suppose that a subsequence (v

kj

)

j∈Ž

converges to v; then, so do v

kj+1

and

˜v

kj+1

= v

kj+1

− ε

kj

= (id + Σ

kj

M)

−1

v

kj

. We have Σ

−1kj

(v

kj

− ˜v

kj+1

) ∈ M(˜v

kj+1

);

since ( Σ

−1k

)

k∈Ž

is upper bounded, the left-hand side converges to 0, and from outer semicontinuity of M [19, Ex. 12.8(b)]

it then follows that 0 ∈ M(v), proving the claim.  Let us consider the iterates (3) under the assumptions of Theorem 1, and let us further assume that Σ

y,k

is diagonal for all k. Let ( ˜x

k+1

, ˜y

k+1

) B (x

k+1

, v

k+1

)−ε

k

= (id+Σ

k

M)

−1

(x

k

, y

k

).

Equation (3) reads

0 = Σ

−1x,k

( ˜x

k+1

− x

k

) + ∇f ( ˜x

k+1

) + A

>

˜y

k+1

(5a) 0 ∈ ˜y

k+1

− y

k

+ Σ

y,k

(∂g

(˜y

k+1

) − A ˜x

k+1

). (5b) The second condition is in fact equivalent to

˜y

k+1

= prox

Σy,kg

(y

k

+ Σ

y,k

A ˜x

k+1

)

= y

k

+ Σ

y,k

A ˜x

k+1

− Σ

y,k

prox

Σ−1

y,kg

(A ˜x

k+1

+ Σ

−1y,k

y

k

)

= Σ

y,k



A ˜x

k+1

+ Σ

−1y,k

y

k

− Π

C

(A ˜x

k+1

+ Σ

−1y,k

y

k

), where the first equality follows from the Moreau decompo- sition [4, Thm. 14.3(ii)], and the second one from the fact that Σ

y,k

is diagonal and set C is separable, hence that the projection on C with respect to the Euclidean norm and that induced by Σ

y,k

coincide. Notice that A

>

˜y

k+1

is the gradient of

12

dist

2Σ

y,k

(A · + Σ

−1y,k

y

k

, C) at ˜x

k+1

. Using this in (5a), by in- troducing an auxiliary variable z

k

we obtain that an (exact) resolvent step ( ˜x

k+1

, ˜y

k+1

) = (id + Σ

k

M)

−1

(x

k

, y

k

) amounts to

 

 

 

 

˜x

k+1

= arg min

x

ϕ

k

(x)

˜z

k+1

= Z

k

( ˜x

k+1

)

˜y

k+1

= y

k

+ Σ

y,k

A ˜x

k+1

− ˜z

k+1

 ,

(6) where

Z

k

(x) B arg min

z∈C 1

2

kz − (Ax + Σ

−1y,k

y

k

)k

2Σ

y,k

= Π

C

(Ax + Σ

−1y,k

y

k

)

= Ax+Σ

−1y,k

y

k

+[`−Ax−Σ

−1y,k

y

k

]

+

−[Ax +Σ

−1y,k

y

k

−u]

+

(7) is a Lipschitz-continuous mapping, and

ϕ

k

(x) B f (x) +

12

dist

2Σ

y,k

(Ax + Σ

−1y,k

y

k

, C) +

12

kx − x

k

k

2

Σ−1x,k

(8) is a (Lipschitz) di fferentiable and strongly convex function with gradient

∇ϕ

k

(x) = ∇f (x) + A

>

y

k

+ Σ

y,k

(Ax − Z

k

(x))  + Σ

−1x,k

(x − x

k

). (9)

Algorithm 1 Quadratic Program ALM solver (QPALM) Require x

0

∈ ’

n

, y

0

∈ ’

m

, ε, ε

a

, ε

r

> 0, ϑ, ρ ∈ (0, 1)

x

, ∆

y

> 1, σ

maxx

, σ

maxy

> 0, σ

y

> 0 Initialize σ

x

= Π

[10−4,104]

(20

max(1,| f (x0)|)

max(1,kAx0−ΠC(Ax0)k2)

) [6, §12.4]

Σ

x,0

= σ

x

I

m

, Σ

y,0

= σ

y

I

m

Repeat for k = 0, 1, . . .

1.1:

x ← x

k

. Let ϕ

k

, ∇ϕ

k

and J

k

be as in (8), (9) and (12)

1.2:

while k∇ϕ

k

(x)k

Σx,k

> ρ

k

ε do

1.3:

x← x +τ

?

d with d as in (14) and τ

?

as in Algorithm 2

1.4:

x

k+1

= x, z

k+1

= Π

C

(Ax

k+1

+ Σ

−1y,k

y

k

)

1.5:

y

k+1

= y

k

+ Σ

y,k

(Ax

k+1

− z

k+1

)

1.6:

if (x

k+1

, z

k+1

, y

k+1

) satisfies (11 ) then return x

k+1

; end if

1.7:

( Σ

y,k+1

)

i,i

= ((Σ

y,k

)

i,i

if |(Ax

k+1

−z

k+1

)

i

| ≤ ϑ|(Ax

k

− z

k

)

i

|, min  ∆

y

( Σ

y,k

)

i,i

, σ

maxy

otherwise,

1.8:

( Σ

x,k+1

)

i,i

= min ∆

x

( Σ

x,k

)

i,i

, σ

maxx

Remark 2 (Connection with the proximal ALM [18]). The (x, z)-update in (6) can equivalently be expressed as

(x

k+1

, z

k+1

) = arg min

(x,z)∈’nגm

L

Σ

y,k

(x, z, y

k

) +

12

kx − x

k

k

2

Σ−1x,k

, where for Σ

y

∈ Sym

++

m

)

L

Σ

y

(x, z, y) B f (x) + δ

C

(z) + hy, Axi +

12

kAx − zk

2Σ

y

is the Σ

y

-augmented Lagrangian associated to minimize

x∈’n,z∈’m

f (x) + δ

C

(z) subject to Ax = z, (10) a formulation equivalent to (2). In fact, the iterative scheme (6) simply amounts to the proximal ALM applied to (10). 

IV. The QPALM algorithm

We now describe the proposed proximal ALM based Al- gorithm 1 for solving (QP). Steps 1.1-1.5 amount to an it- eration of proximal ALM. As detailed in Section IV-A, the minimization of ϕ

k

needed for the computation of x

k+1

can be carried out inexactly. In fact, this is done by means of a tailored extremely fast semismooth Newton method with exact line search, discussed in Sections IV-B and IV-C. Fi- nally, step 1.7 increases the penalty parameters where the constraint norm has not su fficiently decreased [5, §2].

A. Outer and inner loops: early termination criteria Since the x-update is not available in closed form, each proximal ALM iteration (x

k

, z

k

, y

k

) 7→ (x

k+1

, z

k+1

, y

k+1

) in (6)

— which we refer to as an outer step — requires an inner procedure to find a minimizer x

k+1

of ϕ

k

. In this subsection we investigate termination criteria both for the outer loop, indicating when to stop the algorithm with a good candidate solution, and for the inner loops so as to ensure that x

k+1

is computed with enough accuracy to preserve the convergence guarantees of Theorem 1.

1) Outer loop termination: Following the criterion in [21], for fixed absolute and relative tolerances ε

a

, ε

r

> 0 we say that (x, z, y) is an (ε

a

, ε

r

)-optimal triplet if y ∈ N

C

(z) and the following hold:

kQx +q+A

>

yk

≤ε

a

r

max n

kQxk

, kA

>

yk

, kqk

o (11a)

kAx−zk

≤ε

a

r

max{kAxk

, kzk

}. (11b)

(4)

Algorithm 2 Exact line search

Require x, d ∈ ’

n

, diagonal Σ ∈ Sym

++

n

) Provide optimal stepsize τ

?

∈ ’

2.1:

Let ψ

0

: ’ → ’, α, β ∈ ’ and δ, η ∈ ’

2m

be as in (15)

2.2:

Define the set of breakpoints of ψ

0

T = n

αi+`i

δi

,

αiδ+ui

i

| i = 1, . . . , 2m, δ

i

, 0 o

2.3:

Sort T = {t

1

, t

2

, . . .} such that t

i

< t

i+1

for all i

2.4:

Let t

i

∈ T be the smallest such that ψ

0

(t

i

) ≥ 0

2.5:

return τ

?

= t

i−1

ψ0 ti−ti−1

(ti)−ψ0(ti−1)

ψ

0

(t

i−1

)

(or τ?= t1 if i= 1)

From the expression of z

k+1

at step 1.4 it follows that Ax

k+1

+ Σ

−1y,k

y

k

− z

k+1

∈ N

C

(z

k+1

), cf. (1), and hence y

k+1

as in step 1.5 satisfies y

k+1

∈ N

C

(z

k+1

). A triplet (x

k

, z

k

, y

k

) generated by Algorithm 1 is thus (ε

a

, ε

r

)-optimal if it satisfies (11).

2) Inner loop termination: As shown in Theorem 1, con- vergence to a solution can still be ensured when the iterates are computed inexactly, provided that the errors have finite sum. Since ϕ

k

as in (8) is Σ

−1x,k

-strongly convex and Σ

x,k

is diagonal, from (6) we have that

k∇ϕ

k

(x)k

Σx,k

= k∇ϕ

k

(x) − ∇ϕ

k

( ˜x

k+1

)k

Σx,k

≥ kx − ˜x

k+1

k.

Consequently, condition at step 1.1 ensures that kx − ˜x

k+1

k ≤ ρ

k

ε holds for all k. In turn, ky

k+1

− ˜y

k+1

k ≤ kAkρ

k

ε follows from nonexpansiveness of Π

C

and finally ky

k+1

− ˜y

k+1

k ≤ 2k Σ

y,k

kkAkρ

k

ε ≤ 2kΣ

y,∞

kkAkρ

k

ε. As a result, the inner ter- mination criterion at step 1.1 guarantees that the error k(x

k+1

, y

k+1

) − (id + Σ

k

M)

−1

(x

k

, y

k

)k is summable as required in the convergence analysis of Theorem 1. In the rest of the section we describe how the x-update can be carried out with an e fficient minimization strategy.

B. Semismooth Newton method

The diagonal matrix P

k

(x) with entries

(P

k

(x))

ii

= (1 if `

i

≤ (Ax + Σ

−1y,k

y

k

)

i

≤ u

i

, 0 otherwise

is an element of the generalized Jacobian, [10, §7.1], of Π

C

at Ax +Σ

−1y,k

y

k

, see e.g. [23, §6.2.d]. Consequently, one element H

k

(x) ∈ Sym

++

m

) of the generalized Hessian of ϕ

k

is

H

k

(x) = Q + A

>

Σ

y,k

(I − P

k

(x))A + Σ

−1x,k

. Denoting

J

k

(x) B n

i | (Ax + Σ

−1y,k

y

k

)

i

< [`

i

, u

i

]o, (12) one has that (I − P

k

(x))

ii

is 1 if i ∈ J

k

(x) and 0 otherwise.

Consequently, we may rewrite the generalized Hessian ma- trix H

k

(x) in a more economic form as

H

k

(x) = Q + A

>Jk(x)

( Σ

y,k

)

Jk(x)

A

Jk(x)

+ Σ

−1x,k

, (13) where A

Jk(x)

is the stacking of the j-th rows of A with j ∈ J

k

(x), and similarly ( Σ

y,k

)

Jk(x)

is obtained by removing from Σ

y,k

all the i-th rows and columns with i < J

k

(x).

A semismooth Newton direction d at x solves H

k

(x)d =

−∇ϕ

k

(x). Denoting λ B (Σ

y,k

)

Jk(x)

A

Jk(x)

d, the computation of d is equivalent to solving the linear system

"Q + Σ

−1x,k

A

>Jk(x)

A

Jk(x)

( Σ

y,k

)

−1J

k(x)

#"d λ

#

= "−∇ ϕ

k

(x) 0

#

. (14)

C. An exact line search

∇ ϕ

k

(x) is piecewise linear, hence so are its sections

’ 3 τ 7→ ψ

k,(x,d)

(τ) B ϕ

k

(x + τd)

for any d ∈ ’

n

. This implies that, given a candidate update direction d, the minimization of ϕ

k

can be carried out without the need to perform backtrackings, as an optimal stepsize

τ

?

∈ arg min

τ∈’n

ψ

k,(x,d)

(τ)

can be explicitly computed, owing to the fact that ψ

0k,(x,d)

is a piecewise linear increasing function. Indeed, it follows from (7) and (9) that

ψ

0

(τ) = h∇ϕ

k

(x + τd), di

= hd, ∇f (x + τd) + Σ

−1x,k

(x + τd)i

+ hAd, y

k

+ Σ

y,k

A(x + τd) − Z

k

(x + τd)i

= hd,(Q + Σ

−1x,k

)x + qi + hΣ

y,k

Ad, Ax + Σ

−1y,k

y − u + τAd

+

i + τhd,(Q + Σ

−1x,k

)di − h Σ

y,k

Ad,  ` − Ax − Σ

−1y,k

y − τAd 

+

i

= ητ + β + hδ, [δτ − α]

+

i, (15a)

where

 

 

 

 

 

 

 

 

’ 3 η B hd, (Q + Σ

−1x,k

)di,

’ 3 β B hd, (Q + Σ

−1x,k

)x + qi,

’

2m

3 δ B −Σ

1y/,k2

Ad Σ

1y/,k2

Ad  ,

’

2m

3 α B Σ

y,k1/2

y + Σ

y,k

(Ax − `) Σ

y,k

(u − Ax) − y  . (15b)

Due to convexity, it now su ffices to find τ such that the expression in (15a) is zero, as done in Algorithm 2. We re- mark that, since ϕ

k

∈ C

1

is strongly convex and piecewise quadratic, the proposed nonsmooth Newton method with ex- act linesearch would converge in finitely many iterations even with zero tolerance [22].

V. Implementation aspects

This section discusses some of the implementation details that are necessary to make QPALM an e fficient and compet- itive algorithm, such as the solution of the linear system at every iteration, preconditioning and infeasibility detection.

A. Linear system

We solve the linear system (14) by means of sparse

Cholesky factorization routines. In the first iteration and af-

ter every outer iteration, a sparse LDL factorization of the

generalized Hessian matrix H

k

(x

k

) as in (13) is computed. In

between inner iterations, the set of active constraints J

k

typ-

ically does not change much. Consequently, instead of doing

an LDL factorization from scratch, two low rank updates are

su fficient, one for the constraints that enter the active set and

one for those that leave. As such, the algorithm allows for

active set changes where more than one constraint is added

and/or dropped, in contrast to active-set methods. Therefore,

our algorithm typically requires substantially fewer iterations

than active-set methods to find the set of constraints that is

active at the solution, while still having the advantage of

relatively cheap factorization updates. The aforementioned

routines are carried out with software package cholmod [7].

(5)

B. Preconditioning

Preconditioning of the problem data aims at mitigating possible adverse e ffects of ill conditioning. This amounts to scaling problem (QP) to

minimize

¯x∈’n 1

2

h ¯x, ¯ Q ¯xi + h¯q, ¯xi subject to ¯` ≤ ¯A ¯x ≤ ¯u, (16) with ¯x = D

−1

x, ¯ Q = c

f

DQD, ¯q = c

f

Dq, ¯ A = EAD, ¯` = E`

and ¯u = Eu. The dual variables in this problem are ¯y = c

f

E

−1

y. Matrices D ∈ ’

n×n

and E ∈ ’

m×m

are diagonal and computed by performing a modified Ruiz equilibration [20]

on the constraint matrix A, scaling its rows and columns to have an infinity norm close to 1, as we observed this tends to reduce the number and scope of changes of the active set.

The scaling factor c

f

for scaling the objective was obtained from [6, §12.5], namely c

f

= max(1, k∇f (x

0

)k

)

−1

.

We say the problem is solved when the unscaled termina- tion criteria (11) holds in a triplet ( ¯x

k

, ¯z

k

, ¯y

k

), resulting in the following unscaled criterion

c

−1f

kD

−1

( ¯ Q ¯x

k

+ ¯q + A

>

¯y

k

)k

≤ ε

a

+ ε

r

c

−1f

max n

kD

−1

Q ¯ ¯x

k

k

, kD

−1

A ¯

>

¯y

k

k

, kD

−1

¯qk

o, kE

−1

( ¯ A ¯x

k

− ¯z

k

)k

≤ ε

a

+ ε

r

max n

kE

−1

A ¯ ¯x

k

k

, kE

−1

¯z

k

k

o.

C. Infeasibility detection

The proposed method can also detect whether the problem is primal or dual infeasible from the iterates, making use of the criteria given in [3]. Let δ¯y denote the (potential) change in the dual variable, δ¯y = Σ

y

A ¯ ¯x − Π

C

( ¯ A ¯x + Σ

−1y

¯y), then the problem is primal infeasible if for δ¯y , 0

kD

−1

A ¯

>

δ¯yk

≤ ε

p

kEδ¯yk

,

¯u

>

[δ¯y]

+

+ ¯`

>

[δ¯y]

≤ −ε

p

kEδ¯yk

hold, with c

−1f

Eδ¯y the certificate of primal infeasibility. Let δ ¯x denote the update in the primal variable, then the problem is dual infeasible if for δ ¯x , 0 the following conditions hold

kD

−1

Qδ ¯ ¯xk

≤ c

f

ε

d

kDδ ¯xk

,

¯q

>

δ ¯x ≤ −c

f

ε

d

kDδ ¯xk

,

(E

−1

Aδ ¯ ¯x)

i

 

 

 

 

≥ ε

d

kDδ ¯xk

if ¯u

i

= +∞,

≤ −ε

d

kDδ ¯xk

if ¯`

i

= −∞,

∈ [−ε

d

, ε

d

]kDδ ¯xk

otherwise.

In that case, Dδ ¯x is the certificate of dual infeasibility.

VI. Numerical simulations

The C implementation of the proposed algorithm was tested for various sets of QPs and benchmarked against state-of-the-art QP solvers: the interior point solver Gurobi [14], the operator splitting based solver OSQP [21] and the active-set solver qpOASES [12]. The first two are also pro- grammed in C, and the third is programmed in C++. All simulations were performed on a notebook with Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz x 2 processor and 16 GB of memory. The problems are solved to medium accu- racy, with the tolerances ε

a

and ε

r

set to 10

−6

for QPALM and OSQP, as are terminationTolerance for qpOASES and OptimalityTol and FeasibilityTol for Gurobi. Apart

Number of primal variables

0 100 200 300 400 500 600

Runtime (s)

10-3 10-2 10-1 100 101 102

QPALM OSQP Gurobi

Fig. 1: Runtime comparison for random LPs of varying sizes.

from the tolerances, all solvers were run with their de- fault options. For QPALM, the default parameters in Algo- rithm 1 are: ε = 1, ρ = 10

−1

, θ = 0.25, ∆

x

= ∆

y

= 10, σ

maxx

= σ

maxy

= 10

8

, and σ

y

= 10

4

. For the test sets below, the runtime in the figures comprises the average runtime on ten problems of the mentioned problem size or conditioning.

A. Linear programs

The first set of tests are linear programs (LPs) with ran- domly generated data. Of course, an LP is a special case of a QP with a zero Q matrix. The LPs are constructed for 30 values of n equally spaced on a linear scale between 20 and 600. We take m = 10n, as typically optimization problems have more constraints than variables. The constraint matrix A ∈ ’

m×n

is set to have 50% nonzero elements drawn from the standard normal distribution, A

i j

∼ N (0, 1). The linear part of the cost q ∈ ’

n

is a dense vector, q

i

∼ N (0, 1). Fi- nally, the elements of the upper and lower bound vectors, u, l ∈ ’

m

, are uniformly distributed on the intervals [0, 1]

and [−1, 0] respectively. Figure 1 illustrates a comparison of the runtimes for QPALM, OSQP and Gurobi applied to ran- dom LPs of varying sizes. qpOASES is not included in this example, as according to its user manual [12, §4.5] it is not suited for LPs of sizes larger than few hundreds of primal variables, which was observed to be the case. Also OSQP is not suited for LPs as it hit the maximum number of itera- tions (10

5

) for 10 cases, solved inaccurately for 13 cases and solved only in the remaining 3 cases. QPALM is shown to be an efficient solver for LPs, outperforming the simplex and interior point methods that are concurrently tried by Gurobi.

B. Quadratic programs

The second set of tests are QPs with data randomly gener- ated in the same way as in Section VI-A, with an additional positive definite matrix Q = MM

>

, with M ∈ ’

n×n

and 50%

nonzero elements M

i j

∼ N (0, 1). Figure 2 illustrates the run- times of the four solvers for such random QPs. It is clear that QPALM outperforms the other state-of-the-art solvers regardless of the problem size.

C. Ill-conditioned problems

The third test set concerns the conditioning of quadratic

programs. In this example, the data from Section VI-B are

reproduced for a QP with n = 100, but now the impact of the

(6)

Number of primal variables

0 100 200 300 400 500 600

Runtime (s)

10-3 10-2 10-1 100 101 102

QPALM OSQP qpOASES Gurobi

Fig. 2: Runtime comparison for random QPs of varying sizes.

Condition number

100 105

Runtime (s)

10-2 10-1 100 101

QPALM OSQP qpOASES Gurobi

Fig. 3: Runtime comparison for random QPs with varying conditioning.

problem conditioning is investigated. For this, we set the con- dition number κ of the matrices Q and A (using sprandn in MATLAB), and also scale q with κ. Figure 3 shows the run- time results for 20 values of κ equally spaced on a logarith- mic scale between 10

0

and 10

5

. This figure clearly demon- strates that the first-order method OSQP su ffers from ill con- ditioning in the problem despite the o ffline Ruiz equilibration it operates. From condition number 38 and onwards, OSQP hit the maximum number of iterations (10

5

). Also qpOASES experienced di fficulties with ill-conditioned problems. From condition number 4833 onwards, it started reporting that the problem was infeasible, while QPALM and Gurobi solved to the same optimal solution. From these results it follows that QPALM, supported by preconditioning as discussed in Section V-B, is competitive with other solvers in terms of robustness to the scaling of the problem data.

VII. Conclusion

This paper presented QPALM, a proximal augmented La- grangian based solver for QPs that proved to be e fficient and robust against scaling in the problem data. Inner mini- mization procedures rely on semismooth Newton directions and an exact line search which is available in closed form.

The iterates, with sparse factorization update routines, allow for large updates in the active set and are more e fficient than those of interior point methods and more e ffective than those of active-set methods. QPALM was shown to compare favor- ably against state-of-the-art QP solvers, both in runtime and in robustness against problem ill conditioning.

Future work can be focused on considering warm-starting aspects, considering extensions to nonconvex QPs and SOCPs, and on executing a more thorough set of bench- marking examples, focused on problems arising from real applications instead of randomly generated ones.

References

[1] MOSEK ApS. Introducing the MOSEK Optimization Suite 8.1.0.80, 2019.

[2] D. Axehill and A. Hansson. A dual gradient projection quadratic programming algorithm tailored for model predictive control. In 2008 47th IEEE Conference on Decision and Control, pages 3057–3064.

IEEE, 2008.

[3] G. Banjac, P. Goulart, B. Stellato, and S. Boyd. Infeasibility detection in the alternating direction method of multipliers for convex optimiza- tion. optimization-online.org, 2017.

[4] H. H. Bauschke and P. L. Combettes. Convex analysis and mono- tone operator theory in Hilbert spaces. CMS Books in Mathematics.

Springer, 2017.

[5] D. P. Bertsekas. Constrained optimization and Lagrange multiplier methods. Athena Scientific, 1999.

[6] E. G. Birgin and J. M. Martínez. Practical augmented Lagrangian methods for constrained optimization, volume 10. SIAM, 2014.

[7] Y. Chen, T. A. Davis, W. W. Hager, and S. Rajamanickam. Algorithm 887: CHOLMOD, supernodal sparse Cholesky factorization and up- date/downdate. ACM Transactions on Mathematical Software (TOMS), 35(3):22, 2008.

[8] P. L. Combettes and B. C. V˜u. Variable metric quasi-Fejér monotonic- ity. Nonlinear Analysis, Theory, Methods and Applications, 78(1):17–

31, 2013.

[9] N. K. Dhingra, S. Z. Khong, and M. R. Jovanovi´c. A second or- der primal-dual algorithm for nonsmooth convex composite optimiza- tion. In 2017 IEEE 56th Annual Conference on Decision and Control (CDC), pages 2868–2873, Dec 2017.

[10] F. Facchinei and JS. Pang. Finite-dimensional variational inequalities and complementarity problems. Springer Science & Business Media, 2007.

[11] H. J. Ferreau, H. G. Bock, and M. Diehl. An online active set strategy to overcome the limitations of explicit MPC. International Journal of Robust and Nonlinear Control, 18(8):816–830, 2008.

[12] H. J. Ferreau, C. Kirches, A. Potschka, H. G. Bock, and M. Diehl.

qpOASES: A parametric active-set algorithm for quadratic program- ming. Mathematical Programming Computation, 6(4):327–363, 2014.

[13] J. C. Gilbert and É. Joannopoulos. OQLA/QPALM–Convex quadratic optimization solvers using the augmented Lagrangian approach, with an appropriate behavior on infeasible or unbounded problems. 2014.

[14] LLC Gurobi Optimization. Gurobi optimizer reference manual, 2018.

[15] J. Nocedal and S. Wright. Numerical optimization. Springer Science

& Business Media, 2006.

[16] N. Parikh and S. Boyd. Proximal algorithms. Foundations and Trends in Optimization, 1(3):127–239, 2014.R

[17] P. Patrinos, P. Sopasakis, and H. Sarimveis. A global piecewise smooth Newton method for fast large-scale model predictive control. Auto- matica, 47(9):2016–2022, 2011.

[18] R. T. Rockafellar. Augmented Lagrangians and applications of the proximal point algorithm in convex programming. Mathematics of operations research, 1(2):97–116, 1976.

[19] R. T. Rockafellar and R. JB. Wets. Variational analysis, volume 317.

Springer Science & Business Media, 2011.

[20] Daniel Ruiz. A scaling algorithm to equilibrate both rows and columns norms in matrices. Technical report, Rutherford Appleton Laboratorie, 2001.

[21] B. Stellato, G. Banjac, P. Goulart, A. Bemporad, and S. Boyd. OSQP:

An operator splitting solver for quadratic programs. In 2018 UKACC 12th International Conference on Control (CONTROL), pages 339–

339, Sep. 2018.

[22] J. Sun. On piecewise quadratic Newton and trust region problems.

Mathematical Programming, 76(3):451–467, Mar 1997.

[23] A. Themelis, M. Ahookhosh, and P. Patrinos. On the acceleration of forward-backward splitting via an inexact Newton method. In R. Luke, H. Bauschke, and R. Burachik, editors, Splitting Algorithms, Modern Operator Theory, and Applications. Springer. To appearhttps://

arxiv.org/abs/1811.02935.

Referenties

GERELATEERDE DOCUMENTEN

We have compared both initialization methods in terms of their direct performance for brain tumor segmentation using the Dice-scores, because a lower residual error does not warrant

In this section, we present simulation results for the pro- posed equalization techniques for SC and OFDM transmissions over doubly selective channels. In these simulations,

Acknowledgement This work benefits from KU Leuven-BOF PFV/10/002 Centre of Excellence: Optimization in Engineering (OPTEC), from project G0C4515N of the Research Foundation -

With this procedure, we are able to find a solution for A (the joint distribution of latent variable X and exogenous covariates Q) where the sum of the elements is equal to 1, where

The implementation failure of the cost-to-serve method (excellerate) is caused by as well “technical” as “organizational &amp; behavioral” factors. The technical factors for

Although originally we set out to construct incomplete preconditioners for the indefinite systems occurring in electronic circuit simulation, the fore- going sections clearly show

Abstract Augmented Lagrangian coordination (ALC) is a provably convergent coordination method for mul- tidisciplinary design optimization (MDO) that is able to treat both

This chapter describes how the control philosophy and algorithm was developed into a practical automated control product focussed on controlling any given water