SDPT3 does not support integer variables

(thanh long do) #1

Hello every one!
I have my code:
c= [-1 4];
a= [-10 20;
5 10 ;
1 0 ];
variable x(2) integer;
maximize( cx );
subject to
x <= b;

and when I complie , it have error:


Calling SDPT3 4.0: 7 variables, 5 equality constraints

Status: Error
Optimal value (cvx_optval): NaN

Error using cvx_sdpt3>solve (line 131)
SDTP3 does not support integer variables.

Error in cvxprob/solve (line 429)
[ x, status, tprec, iters ] = shim.solve( At, b, c, cones, quiet, prec, solv.settings, eargs{:} );

Error in cvx_end (line 88)
solve( prob );

Error in matching (line 12)

Can you help me!!

(Mark L. Stone) #2

Your thread title sums it up quite nicely, SDPT3 does not support integer variables.

Gurobi, CPLEX, MOSEK, and GLPK do support integer (and binary) variables. The table of solver capabilities is at . provides the solver capability matrix for CVX 3.0beta. Neither of the two additional solvers, ECOS and SCS, which are available under 3.0beta but not 2.1, support integer variables.