User Tools

Site Tools


solver:division_by_a_variable_makes_model_infeasible

Division by a Variable makes model infeasible

Q: Within a NLP I wrote an equation like this at first:

POWER_DEMAND( I ) =E= SUBSTATION_SUPPLY( I ) + ADDTIONAL_SUPPLY( I )

and got a good solution back. But if I write that equation this way:

POWER_DEMAND( I ) / SUBSTATION_SUPPLY( I )=E= 1 + ADDTIONAL_SUPPLY( I ) / SUBSTATION_SUPPLY( I )

with SUBSTATION_SUPPLY( I ) > 0 I get an infeasible solution. Why is that the case?

Your first equation was 'linear' meaning all your Jacobian entires were constant. The second one (although mathematically equivalent) is treated completely different by the NLP solver (which is called by GAMS). Try to stay linear where ever you can.

I recommend the GAMS/CONOPT manual for reading since it contains plenty of modeling tips for nonlinear modeling.

solver/division_by_a_variable_makes_model_infeasible.txt · Last modified: 2017/09/02 17:40 by support