Function IdentifierDimension(identifierName)

IdentifierDimension

The function IdentifierDimension returns the data dimension of identifierName.

IdentifierDimension(
     identifierName)       ! (input) scalar element parameter

Arguments

identifierName

An element expression in the predefined set AllIdentifiers specifying the identifier for which the dimension should be obtained.

Return Value

This function returns a non-negative integer. If identifierName is not an identifier, an error message is issued. If identifierName is not an indexed parameter, variable or constraint, a 0 is returned without further warning.

Note

This function replaces the deprecated suffix .dim.

Example

Given the declaration of a two dimensional parameter p_d(i_a,i_b), the code:

1_ep_p := StringToElement(AllIdentifiers,
2    "chapterModel::sectionModelQuery::funcIdentifierDimension::p_d",
3    create: 0);
4_p_dim := IdentifierDimension( _ep_p );
5block where single_column_display := 1, listing_number_precision := 6 ;
6    display _p_dim ;
7endblock ;

produces in the listing file:

_p_dim := 2 ;

References