Deprecated Language Elements
The current implementation of AIMMS supports the following deprecated
features, but it may cease to do so in a future implementation. The
current implementation does so to support converted GAMS and AIMMS 2
applications.
Deprecated Keywords
The keywords for which direct replacements are available are documented in Table 1.
Deprecated |
Modern equivalent |
|---|---|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The Deprecated Keyword abort
The keyword abort is a GAMS keyword that can be followed by a
condition and a list of identifiers to be displayed. The execution run
is interrupted after executing this statement. Suggested rewrite: use a
display statement followed by a halt statement or a
raise error statement. See also
display(see The DISPLAY Statement of the Language Reference),halt(see The HALT Statement of the Language Reference) andraise error(see Raising Errors and Warnings of the Language Reference).
The Deprecated Keywords yes and no
The keywords yes and no are GAMS keywords that can be used in
assignments to sets in order to add or remove elements. Suggested
rewrite: use the AIMMS set syntax. For instance, replace
s1(i) $ cond1(i) := yes ;
s2(i) $ cond2(i) := no ;
by the following code:
s1 += { i | cond1(i) } ;
s2 -= { i | cond2(i) } ;
The Deprecated Keyword system
The GAMS keyword system is followed by a suffix. The AIMMS language
supports the following equivalent code for selected system suffixes
as documented in Table Table 2.
Deprecated |
Modern equivalent |
|---|---|
|
|
|
|
|
|
|
|
The system suffixes .ifile, .ofile, .rdate, .rfile,
.rtime, .sfile, and .title are pointless within the AIMMS
environment.
Deprecated Intrinsic Procedures and Functions
The mapping of the removed matrix manipulation procedures to GMP procedures and functions is documented in Matrix Manipulation Procedures. The following GMP procedures are deprecated:
The procedure
GMP::Instance::DeleteSolverSessionhas been replaced by the procedureGMP::SolverSession::Delete.
The following intrinsic functions are deprecated, but can be replaced by an equivalent call to an existing intrinsic procedure or function:
FindRString( SearchString, Key, CaseSensitive, WordOnly, IgnoreWhite)can be replaced by a call toFindNthString( SearchString, Key, -1, CaseSensitive, WordOnly, IgnoreWhite)where-1indicates that searching should be done right to left, see alsoFindNthString.One may replace
SQLDirectwithDirectSQLOne may replace
StringToLabelwithStringToElement
The deprecated iterative operators are documented in Table 3.
Deprecated |
Modern equivalent |
|---|---|
|
|
|
|
|
|
Deprecated Suffixes
Deprecated |
Modern equivalent |
|---|---|
Variables |
|
|
|
|
|
|
|
|
|
|
|
Files |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Mathematical programs |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Most deprecated suffixes can be directly translated into their modern equivalents, as documented in Table 4. The following suffixes deserve some more consideration:
.apThe append mode of a file, 0: replace contents when opening the file, 1: append to file. This functionality is now covered by themodeattribute of that file, see The File Declaration of the Language Reference..mThe marginal value of a variable or constraint. For a constraint the suffix.mshould be replaced by the suffix.ShadowPrice. For a variable the suffix.mshould be replaced by the suffix.ReducedCost..modelstatThis suffix of a mathematical program is numeric, it should be replaced by the element valued suffix.ProgramStatus. Note thatElement( AllSolutionStates, mp.solvestat+1 ) = mp.ProgramStatus. See also Mathematical program and solver status of the Language Reference andAllSolutionStates..solvestator.solverstatThese suffixes of a mathematical program are numeric, they should be replaced by the element valued suffix.SolverStatus. Note thatElement( AllSolutionStates, mp.solvestat+15 ) = mp.SolverStatus. See also Mathematical program and solver status of the Language Reference andAllSolutionStates..dimThis should be replaced by a call toIdentifierDimension..txtThis should be replaced by a call toIdentifierText..typeThis should be replaced by a call toIdentifierType.