$title 'Test that eps in nonlinear code is kept' (CONVERT8,SEQ=605)
* This tests that a GAMS eps a nonlinear expression is written
* as eps in CONVERT's GAMS output instead of 0.
variable x;
equation e;
e.. sqrt(eps*x) =e= 0;
model m / all /;
option nlp = convert;
solve m using nlp min x;
* we should find sqrt(eps*x1) in gams.gms, in which case grep should return 0
execute 'grep -q "sqrt(eps\*x1)" gams.gms'
abort$errorlevel "eps did not survive convert"
* and again with convertd
option nlp = convertd;
solve m using nlp min x;
execute 'grep -q "sqrt(eps\*x1)" gams.gms';
abort$errorlevel "eps did not survive convertd"