[Ipopt] How to define a non-zero constraint?
Kelly, Jeff (ON0F)
jeff.kelly at honeywell.com
Thu Nov 11 08:39:47 EST 2010
It seems that the class of constraints you are trying to solve are called “dis-inequalities” i.e., a <> 0 and maybe be modeled and solved approximately by replacing a with a+ - a- and adding a+ > eps and a- > eps’ where eps and eps’ are a small and different numbers (maybe randomized as well).
As the name implies these are dis-junctive (either-or) and can be very difficult to solve with an LP without a spatial branch-and-bound search – I find that these types are constraints are the most difficult to solve for mathematical programs and hence I try to avoid them.
Some success for particular problems have been found in constraint programming applications such as using the “all-different” construct but CP has other issues with respect to continuous variables and optimizing.
The other approach is complementarity and smoothing functions but these can also be difficult to solve in practice due to primal and dual degeneracies and sharp dis-continuities of the underlying problem.
If all else fails you may just what to try a simple heuristic and check if your dis-inequalities are violated at a solution (you may get lucky), if yes at least one is violated then add a “cut” or “nogood” to move away from that solution and solve again in a greedy fashion. If you solve and the modified problem is infeasible then delete a cut, etc.
Jeff
From: ipopt-bounces at list.coin-or.org [mailto:ipopt-bounces at list.coin-or.org] On Behalf Of R Tavakoli
Sent: Thursday, November 11, 2010 2:57 AM
To: Lewis I
Cc: ipopt at list.coin-or.org
Subject: Re: [Ipopt] How to define a non-zero constraint?
yes, it might leads to A=B=0.
I do not have further comment, so wait for others response, but it is more helpful that you post details of your optimization problem.
On Thu, Nov 11, 2010 at 11:21 AM, Lewis I <lewis369lewis at yahoo.com> wrote:
But for some reasons, I do not want A and B to become zero after the optimization.
And A and B may become zero after the optimization.
Thank you so much.
Lewis
--- On Thu, 11/11/10, R Tavakoli <rohtav at gmail.com> wrote:
From: R Tavakoli <rohtav at gmail.com>
Subject: Re: [Ipopt] How to define a non-zero constraint?
To: "Lewis I" <lewis369lewis at yahoo.com>
Cc: ipopt at list.coin-or.org
Date: Thursday, November 11, 2010, 7:33 AM
then why not solve for something like this:
A*B - (A+B) = 0
On Thu, Nov 11, 2010 at 10:59 AM, Lewis I <lewis369lewis at yahoo.com <http://mc/compose?to=lewis369lewis@yahoo.com> > wrote:
In fact, now I have many constraints as the following form : (A*B)/(A+B)=1
I need to constrain A and B be no-zero in order to prevent the constraints become invalid.
Thank you so much.
Lewis
--- On Thu, 11/11/10, R Tavakoli <rohtav at gmail.com <http://mc/compose?to=rohtav@gmail.com> > wrote:
From: R Tavakoli <rohtav at gmail.com <http://mc/compose?to=rohtav@gmail.com> >
Subject: Re: [Ipopt] How to define a non-zero constraint?
To: "Lewis I" <lewis369lewis at yahoo.com <http://mc/compose?to=lewis369lewis@yahoo.com> >
Cc: ipopt at list.coin-or.org <http://mc/compose?to=ipopt@list.coin-or.org>
Date: Thursday, November 11, 2010, 7:20 AM
I think hat if you describe the structure of your problem in more details, peoples may give you better solutions. in general there might be several strategies, formulation depend on structure of problem, number of variables (constraints) and behavior of problem in practice.
e.g., did you tried your problem without constraints like x!=0, and if the see if any variable violate your constraints, and if doing a little shift in variable and see the objective function value ...
On Thu, Nov 11, 2010 at 10:35 AM, Lewis I <lewis369lewis at yahoo.com <http://mc/compose?to=lewis369lewis@yahoo.com> > wrote:
Hi
But how about if I have more than one non-zero constraints (a!=0,b!=0, c!=0,.....)?
Thank you.
Lewis
--- On Thu, 11/11/10, R Tavakoli <rohtav at gmail.com <http://mc/compose?to=rohtav@gmail.com> > wrote:
From: R Tavakoli <rohtav at gmail.com <http://mc/compose?to=rohtav@gmail.com> >
Subject: Re: [Ipopt] How to define a non-zero constraint?
To: "Lewis I" <lewis369lewis at yahoo.com <http://mc/compose?to=lewis369lewis@yahoo.com> >
Cc: ipopt at list.coin-or.org <http://mc/compose?to=ipopt@list.coin-or.org>
Date: Thursday, November 11, 2010, 6:29 AM
as almost the same alternative: (a-b)(a+b)>0 and b>0
a comment: if you have only one constraint like a!=0 there is a more robust strategy: solve two distinct
optimization problems, one with constraint a>0 and one with constraints a<0 (you may replace 0 with a small positive number you want), then the actual solution is the solution to one of these problems with the least objective functional (benefit is the convexity of constraint set in this way).
On Thu, Nov 11, 2010 at 9:33 AM, Lewis I <lewis369lewis at yahoo.com <http://mc/compose?to=lewis369lewis@yahoo.com> > wrote:
Hello,
I am try to define a non-zero constraint. i.e. a!=0
I am trying to use: a*a-0.000001>=0.
where 0.000001 is the tolerance from zero.
But I found the outcome was not so good.
Do anyone has any ideas on modeling a non-zero constraint.
Thank you so much
Regards,
Lewis
_______________________________________________
Ipopt mailing list
Ipopt at list.coin-or.org <http://mc/compose?to=Ipopt@list.coin-or.org>
http://list.coin-or.org/mailman/listinfo/ipopt
_______________________________________________
Ipopt mailing list
Ipopt at list.coin-or.org <http://mc/compose?to=Ipopt@list.coin-or.org>
http://list.coin-or.org/mailman/listinfo/ipopt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://list.coin-or.org/pipermail/ipopt/attachments/20101111/31e59362/attachment-0001.html
More information about the Ipopt
mailing list