Subranges 
Top Previous Next 
One Subscript Range is said to be a Subrange of a second Subscript Range if all of its elements (Subscript Elements) are included in the second Subscript Range. The use of Subranges can often simplify equation writing and improve the clarity of a model's structure. Subranges can overlap, and need not be exhaustive (so that some Subscript Elements might belong to two Subranges, and others to none). However, all the members of a Subrange must be contained in a single Subscript Range. Subranges of other Subranges are permissible, but will simply be treated as additional Subranges of the original Subscript Range. You can build up a Subscript Range by using Subranges, or define the Subscript Range and the subranges independently. Example A modeler wants to group seven models of General Motors cars into three categories (compact,full size, and luxury) because each of these automobile groups requires a substantially different equation to describe its performance and economics. (If the only specification differences between auto types were parametric, the modeler could use subscripted constants to represent the differences.) Further, suppose that four of the cars fall into a particular group with respect to emission standards, and performance/economics aggregates for these vehicles frequently need to be computed. To define Subranges, the modeler writes a separate expression for each Subrange desired. model : little, not too big, middle, center, half, big, excessive
 compact : little, not too big
 mid size : middle, center, half
 luxury : big, excessive

 To build up subranges into a full range just define the different subranges and use those in the equation for the full Subscript Range. For example the equation for model above could be replaced with model : compact, mid size, luxury
 This has exactly the same meaning as the first equation for model. Note that the units of measure for the subscripts ranges have been left blank in this example. The units of measure for Subscripts are not used. You can leave the units on Subscripts blank, or mark them Nil or Index to remind anyone reading the model that Subscripts are not dimensioned variables. 