# OptimizationMOI Ipopt violating inequality constraint

**URL:** <https://discourse.julialang.org/t/optimizationmoi-ipopt-violating-inequality-constraint/92608>\
**Category:** Optimization (Mathematical)\
**Tags:** optimization, ipopt\
**Created:** [January 6, 2023, 4:36pm UTC](https://discourse.julialang.org/t/optimizationmoi-ipopt-violating-inequality-constraint/92608 "2023-01-06T16:36:48Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![dpo](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/dpo/32/3335_2.png) [@dpo](https://discourse.julialang.org/u/dpo)\
**Post date:** [January 6, 2023, 6:39pm UTC](https://discourse.julialang.org/t/optimizationmoi-ipopt-violating-inequality-constraint/92608/5 "2023-01-06T18:39:34Z")

</div>

> [@ForceBru](#):
>
> As a side note, what’s the point of IPOPT being an [_Interior Point_ OPTimizer](https://en.wikipedia.org/wiki/IPOPT) when it produces points which are _not_ in the _interior_ of my constraints???

That’s a fair question. If you look at the assumptions underlying IPOPT, they say that all problem functions should be defined and differentiable over the entire space (\mathbb{R}^n). IPOPT belongs to the category of _infeasible_ interior-point methods, first developed for linear optimization.

_Feasible_ interior-point methods also exist in the literature, but are not typically implemented because they first require finding a strictly feasible initial guess (g(x) \< 0), which can be as difficult as solving the problem in the first place. But of course, as is the case in your problem, if the objective is only defined when g(x) \< 0, feasible methods are the only option.

All the details for implementing an efficient feasible interior-point method are in the literature. Alas, that’s a fairly nontrivial and time-consuming task.

You could get a trial version of KNITRO for free, at least to see if you manage to solve your problem to your satisfaction with it.

EDIT: since your problem is so small, you may be satisfied with a “prototype” implementation of a feasible interior-point method, one that doesn’t care about sparse linear algebra. It wouldn’t be too hard to get a preliminary version going.

I also notice in your [original post](https://discourse.julialang.org/t/optim-jl-violates-inequality-constraint/75573) that you have a strict inequality constraint. Optimization mostly considers closed feasible sets, so you’re unlikely to find a method that _guarantees_ that the inequality will be satisfied strictly. However, feasible interior-point methods are probably your best bet.

---

_[View the full topic](https://discourse.julialang.org/t/optimizationmoi-ipopt-violating-inequality-constraint/92608)._
