Use an identifier-expression to refer to a variable, objective, constraint, parameter or problem location in expressions or initializations. This is the syntax for identifier-expressions :
name [ expression-1 , …expression-n ] . suffix [ expression ]
To refer to a location in an array, follow the array name with a list of scalar expressions in square brackets ([ ]). The expression values are compared to the index set that was
used to declare name. If there is more than one expression, then the values are formed into a tuple. The expression values for a valid array location
must match a member of the array’s index set. For example, the following statements define a parameter array A
that has two valid indices that match the tuples <1,2> and <3,4>:
proc optmodel; set<number, number> ISET = {<1,2>, <3,4>}; number A{ISET}; a[1,2] = 0; /* OK */ a[3,2] = 0; /* invalid index */
The first assignment is valid with this definition of the index set, but the second fails because <3,2> is not a member of
the set parameter ISET
.
Specify a suffix to refer to auxiliary locations for variables or objectives. For more information, see the section Suffixes. Certain suffixes can be followed by a numeric index expression that selects a particular solution saved by the SOLVE statement. For more information about solution indices, see the section Multiple Solutions.