Hi,
I am trying to solve an optimization problem (in Matlab) with quadratic constraints. However, I am encountering an unexpected feasibility problem. I am listing a simplified version of the code below:
n=6;
A=10;
w=25;
cvx_begin
variable x(2.*n);
dual variables constr_0{n} constr_1 constr_2;
% Quadratic constraint: g'x + x'Hx <=0
for j=(n+1):(2.*n-1)
H=zeros(2.*n,2.*n);
H(j-n,j-n)=-1;
g=zeros(2.*n,1);
g(j+1)=1;
g(j)=-1;
constr_0{j-n}: abs(g'*x) + 2.*quad_form(x,H) <= 0;
end
% equality constraints
c1=zeros(2.*n,1);
c1(n+1)=1;
constr_1: c1'*x==A;
c2=zeros(2.*n,1);
c2(2.*n)=1;
constr_2: c2'*x==0;
cvx_end
When I try to solve this problem, cvx returns an Infeasible problem. This is unexpected since this problem is in fact feasible. For example, the solution
x=[0,5,10,15,20,25,10,10,6,4,2,0]'
satisfies all constraints in the above problem. I have tried using both SDPT3 and SeDuMi solvers with the same result. Changing the precision (both increase and decrease) also had no effect. Note that one slightly unusual feature of this problem is that H is negative semi-definite (rather than the more common positive semi-definite).
I am a novice at cvx, so any advice would be very much appreciated. Thanks!