<p>Hello,<br>I am trying to solve a quadratic problem with non-linear constraints with Ipopt and AMPL. I have one model that works with the following constraint:</p>
<p>sum{s1 in securities} ExpReturn[s1]*x[s1]-sqrt((1/card(T))*sum{t1 in T}(sum{s1 in securities} dif[t1, s1]*x[s1])^2)&gt;=R</p>
<p><br>I want to break this constraint in two parts:</p>
<p>sum{s1 in securities} dif[t1, s1]*x[s1]=q[t1]</p>
<p>and</p>
<p>sum{s1 in securities} ExpReturn[s1]*x[s1]-sqrt((1/card(T))*sum{t1 in T}(q[t1])^2))&gt;=R</p>
<p>I am doing this because I want to decrease the number of operations of the model given that I want to solve many of these problems and I want to use q[t1] in other operations also.<br>Ipopt is not being able to solve this second problem, I do not know why.<br>
Do you have some suggestion?</p>
<div>Thanks,<br>Tiago</div>
<div> </div>
<div>PS: the error message is the following:</div>
<div>EXIT: Invalid number in NLP function or derivative detected.<br>Error in an AMPL evaluation. Run with &quot;halt_on_ampl_error yes&quot; to see details.<br>Exception of type: Eval_Error in file &quot;C:\cygwin\home\svigerske\BuildDir\Bonmin\releases-0.99.3\Ipopt\src\Algorithm\IpOrigIpoptNLP.cpp&quot; at line 550:<br>
 Exception message: success &amp;&amp; IsFiniteNumber(unscaled_c-&gt;Nrm2()) evaluated false: Error evaluating the equality constraints</div>
<div>EXIT: Some uncaught Ipopt exception encountered.<br>can&#39;t open at2520.sol</div>
<div> </div>