mpsge14.gms : MPSGE sync test: .GEN/integer1/nsolves

Description

Each solve with MPSGE should get its own include of the GEN file.  If
this is not done correctly, MPSGE should abort with a warning about
the issue.

This worked properly in 20.1 (2001).
It did not work with 20.7 (2005) through 24.7.4 (2016).
It is fixed in 24.8.0 with r59712.

Contributor: Steve Dirkse, Dec 2016


Small Model of Type : MPSGE


Category : GAMS Test library


Main file : mpsge14.gms

$title 'MPSGE sync test: .GEN/integer1/nsolves' (MPSGE14,SEQ=713)

$onText
Each solve with MPSGE should get its own include of the GEN file.  If
this is not done correctly, MPSGE should abort with a warning about
the issue.

This worked properly in 20.1 (2001).
It did not work with 20.7 (2005) through 24.7.4 (2016).
It is fixed in 24.8.0 with r59712.

Contributor: Steve Dirkse, Dec 2016
$offText

SETS
i       / i1 * i2 /,
j       / j1 * j2 /,
h       / h1 * h2 /;

parameter       d0(i,h)         Reference demands,
                e0(i,h)         Reference endowments;

d0(i,h) = uniform(0,1);
e0(i,h) = uniform(0,1);

$onText

$model:exchange

$commodities:
        price(i,j)

$consumers:
        ra(h)


$demand:ra(h) s:1
        d:price(i,j)    q:d0(i,h)
        e:price(i,j)    q:e0(i,h)

$offText

$sysInclude mpsgeset exchange

* if we include the GEN file things work
$include EXCHANGE.GEN
solve exchange using mcp;
abort$[exchange.solvestat <> %solveStat.normalCompletion%] 'wrong solvestat';
abort$[exchange.modelstat <> %modelStat.optimal%]          'wrong modelstat';

* if we fail to include the GEN file MPSGE will reject the model
* $include EXCHANGE.GEN
solve exchange using mcp;
abort$[exchange.solvestat <> %solveStat.setupFailure%]     'wrong solvestat';
abort$[exchange.modelstat <> %modelStat.errorNoSolution%]  'wrong modelstat';