I am new using JuMP. In my code, I added a thermodynamic model (UNIQUAC). When xNT1 = 0.001 it work well. But when the value is almost zero (1e-11) it doesn’t work and JuMP give me “Warning: Cutting back alpha due to evaluation error”, “WARNING: Problem in step computation; switching to emergency mode.” and others warnings because of the term “ΨNT1/xNT1”.
@NLconstraint(m, log(gamNT1) == ((log(ΨNT1/xNT1) + (z/2.0)*q*log(θNT1/ΨNT1) + lj - (ΨNT1/xNT1)*(xNT1*lj+xNT2*lj+xNT3*lj+xNT4*lj)) + (q*(1.0-log(fNT1)-(dNT1))) ) )
I tried to use “ConditionalJuMP.jl” but I am using ipopt solver and it gives me that ipopt “Solver does not support discrete variables”
So, there is some way to avoid that problem?
In MATLAB I just use the if condition.
If xNT1 == 0
gamNT1 = 1
log(gamNT1) == ((log(ΨNT1/xNT1) +…,