Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
545 views
in Technique[技术] by (71.8m points)

mathematical optimization - Writing hyperbolic inequalities as second order conic inequalities in GAMS

I coded a GAMS model that has hyperbolic inequalities and GAMS can solve it. However, when I transform the hyperbolic inequalities likesqr(th(j)) =l= u(j)*f(j); to second order conic inequalities as 2*th(j) =C= u(j) + f(j); the solution returns error, saying that ***Cannot handle Cone = C = equations. Does any one has idea what is wrong here or if how I have to write the conic constraints?

This transformation is need so that I can use use Conic equations "=C=" to solve the model using MOSEK solver in GAMS.

Update: I changed my code a bit, and now it looks like this in a simplest form.

   i / 1*2 /
alias(i,j)
Parameters

            al(i)  /1 2
                  2 4/
            be(i) /1 1.5/;

Scalar D /500/;


Positive Variable  f(i), th(i), u(i), mu(i);
Variable obj;

Equation defobj, cons(i), conic1(j), conic2(j), conic3(j), demand;

defobj..  obj =e= sum(j,al(j)*be(j)*mu(j));
conic1(j).. 2*f(j) =C= th(j)+1;
conic2(j)..  2*th(j) =C= u(j)+f(j);
conic3(j)..  2*u(j)=C= mu(j)+f(j);
demand ..    sum(j, f(j))=e=D;

Model mod / defobj, conic2, conic1, conic3, demand /;
option qcp = MOSEK;
solve mod using nlp min obj;

Now GAMS gives me "Exit code=3".

question from:https://stackoverflow.com/questions/66055383/writing-hyperbolic-inequalities-as-second-order-conic-inequalities-in-gams

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...