Conic Programming in GAMS
Conic Programming in GAMS
Armin Pruessner,
Michael Bussieck, Steven Dirkse, Alex Meeraus
2
Overview
Model Generality
Less More
General General
(Convex) (Convex)
LP SOCP SDP
QP QCQP
Less More
Difficult Difficult
Solution Difficulty
5
Cone Programs
• General form of conic program
min f T x
s.t. Ax ≤ b
x ∈ C, x ∈ l x , u x [ ]
where C is a second order cone (dim=k):
x1:( k −1)
Ck = : x1:( k −1) ≤ xk
xk
2
6
Example (quadratic cone)
Quadractic cone C sometimes also called
Lorentz cone (or ice cream cone)
2 2
z ≥ x +y
7
Second Order Cone Programs
min f Tx
s.t . C i x + d i ≤ a x + bi ,
T
i i = 1,..., N
x ∈ ℜ n f , a i ∈ ℜ n C i ∈ ℜ ( k i −1)× n d i ∈ ℜ k i −1 bi ∈ ℜ
Equivalent to conic program
xy ≥ ∑ z − xy 2
i +x +y2 2
z
(x + y ) ≥ Quadratic cone
( x − y )
10
General Transformation
• If x ∈ C ⇔ Ax ∈ C
r q
where
12
Quadratic Cone in GAMS
Set s /s1,s2,…,sn/;
Set t(s) / s2,…,sn/;
Variable x(s);
15
Example (Continued)
Complex L1 Norm Minimization
min ∑ t (i)
i
16
GAMS Model (Quadratic Cone)
Objective.. obj =E= sum(i, t(i));
17
Portfolio Optimization
∑ x jσ j , j ' x j ' = α Dx Objective is to
2
min
j, j'
2 minimize variance
(risk), subject to an
s.t. ∑xj
j = 1, xi ≥ 0 expected return
σj,j’ = covariance
∑p x
j
j j ≥ rmin
H=1 / (numdays-1)
xj = % of investment in stock j
pj = price change (return) for stock j
rmin = minimum expected return
Dj,d = Deviation per day d of stock j wrt to mean return
18
Portfolio Optimization (Cont.)
2
Can rewrite: min α Dx 2
By introducing intermediate variables p,q, and w:
minimize α 2r
subject to w(d ) = ∑ D( j , d ) x( j )
j
q =1
≥ ∑ w(d)
2
2qr
d
19
GAMS Model (Rotated Cone)
Objective.. obj =E= a*(2*r);
cone_eq1.. q =E= 1;
21
Numerical Examples
• SOCP models:
– Sum of norms
– Antenna array weight design
– Scheduling problems
• 18 SOCP problems
– In SeDuMi (MATLAB) format
– MOSEK: extended QPS format (based on MPS)
23
DIMACS Results (H. Mittelmann)
Problem LOQO MOSEK SDPT3 SeDuMi
Nb 11 3 11 9
Nb_L1 9 3 20 11
Nb_L2 16 8 18 24
Nb_L2_Bessel 7 2 11 12
Nql30 11 2 4 4
Nql60 151 9 14 9
Nql180 MM 182 232 459
Qssp30 15 2 6 3
Qssp60 221 9 29 18
Qssp180 MM 355 504 780
Sched_50_50_orig 5 1 6 6
Sched_100_50_orig 22 2 17 13
Sched_100_100_orig 94 4 28 29
Sched_200_100_orig 409 10 95 138
Sched_50_50_orig 7 1 6 5
Sched_100_50_orig 28 2 13 9
Sched_100_100_orig 107 5 22 32
Sched_200_100_orig 445 10 68 75
Figure 1 26
CONE World
• An online forum for
discussion and
information on cone
programming
• CONELib library of
models
– GAMS cone format
– NLP formulation
• Conic programming
solvers
28
ConeLib – Conic Models in GAMS
29
Cone Versus NLP Formulation
80
70
60
50
40
30
MOSEK
20 NLP-1
NLP-2
10 NLP-3
0
1 10 100 1000
Time Factor
Figure 2 31
Reproducibility of Results
32
Reproducibility of Results
33
Reproducibility of Results
34
Conclusions
• Addition of conic programming capability within
GAMS