Description
This model demonstrates the use of compressed input files. Remember, if the file names contain spaces you need to use single or double quotes around the file names. Keywords: GAMS language features, compressed input files --- get model --- compress and run model --- check to see if we get the same result --- also works with include files
Small Model of Type : GAMS
Category : GAMS Model library
Main file : cefiles.gms
$title Compressed Input Files (CEFILES,SEQ=317)
$onText
This model demonstrates the use of compressed input files.
Remember, if the file names contain spaces you need
to use single or double quotes around the file names.
Keywords: GAMS language features, compressed input files
$offText
* --- get model
$onDollar
$call gamslib -q trnsport
* --- compress and run model
$compress trnsport.gms t1.gms
$decompress t1.gms t1.org
$call diff trnsport.gms t1.org > %system.nullfile%
$ifE errorLevel<>0 $abort files trsnport and t1 are different
* --- check to see if we get the same result
$call gams trnsport gdx=trnsport lo=%gams.lo%
$ifE errorLevel<>0 $abort model trnsport failed
$call gams t1 gdx=t1 lo=%gams.lo%
$ifE errorLevel<>0 $abort model t1 failed
$call gdxdiff trnsport t1 %system.redirlog%
$ifE errorLevel<>0 $abort results for trnsport and t1 are not equal
* --- also works with include files
$echo $include t1.gms > t2.gms
$call gams t2 gdx=t2 lo=%gams.lo%
$ifE errorLevel<>0 $abort model t2 failed
$call gdxdiff trnsport t2 %system.redirlog%
$ifE errorLevel<>0 $abort results for trnsport and t2 are not equal
$terminate