19.3.4. Defining Result Identifiers

Using the Identifier property, you can assign a unique name to a result.

Requirements

Note the rules for creating an identifier. An Identifier entry:

  • Can begin with a letter or an underscore character.

  • Can contain any number of letters, digits, or underscores.

  • Is not case sensitive, however, functions should always use lowercase (sqrt, max, min, etc.).

  • Is not affected by the order in which they are entered. For example, for Identifiers A and B, the expression for:

    • Result 1 can equal: B = 2*A, and:

    • Result 2 can equal: A = UX

    Ansys recommends that you use the proper order and try to define dependents first. For example, define A, B, C and then D = A^2+B^2+C^2

  • Cyclic dependencies are blocked, such as the following:

    • Result 1: A = UX + C

    • Result 2: C = 2 * A - 1

  • Correspond to an array over all nodes (or all elements):

    • Length = number of nodes (or elements)

    • Width = 1, 3, or 6 columns

Combining with Expressions

You can use a previously specified user-defined result to create a new user-defined result by including its Identifier in an Expression if both the previously specified and the new user-defined result are scoped to the same geometry. When you include an Identifier in an Expression, settings in the previously specified user-defined result (parent) can cause property settings in the new user-defined result (child) to be ignored. For example, if you scope the parent result to shell elements and the Position property is set to Top/Bottom, the application evaluates the child object using the Top/Bottom setting regardless of the Position property setting of the child result.


Recommendation:  Ansys recommends that when you assign an identifier to the expression, that you rename the object with the same name/identifier.


Evaluated Results and Downstream Processing

You can edit the Identifier property for an evaluated result. Doing so affects any downstream results that use the Identifier as part of their Expression. The application will automatically clear these results and mark them Obsolete.


Note:  The application includes a preference that will attempt to automatically update downstream Expression fields that include revised Identifiers. In the preference dialog, under the Results category, set the Update Dependent Expressions on Identifier Change to Yes. The default is No.



Important:  Be careful when using this preference. Automatically replacing expressions may cause failures or result in inadvertent errors.


Limitations of the Identifier Property

There are several problematic scenarios that can arise when you use the Identifier property for an existing result to create a new result. For each scenario, changing an item in the Details of the new result causes the new result to be unreliable.

For example, the Display Time of a result is only relevant when the expression consists of built-in identifiers. Unlike user-defined identifiers, built-in identifiers retain their time dependence through the evaluation of the expression. To reveal the built-in identifiers for a given solver, examine the Worksheet view on the Solution folder.


Note:  Mechanical may not necessarily issue a warning or error message for these situations.


For example, what if the Identifier of the original result is "Original". Further, suppose that the Expression of the new result is "2 * Original". Consider the following:

  • Different choices of By Time or By Result Set

  • Different choices of the value of Display Time or Set

  • Different choices of Coordinate System

  • Different choices of Yes/No for Calculate Time History

  • Different choices for Use Average