Files with extension .cnd contain all the information about the conditions that can be applied to different entities. The condition can adopt different field values for every entity. This type of information includes, for instance, all the displacement constraints and applied loads in a structural problem or all the prescribed and initial temperatures in a thermial analysis.

An important characteristic of the conditions is that they must define what kind of entity they are going to be applied over, i.e. over points, over lines, over surfaces, over volumes, over layers or over groups, and what kind of mesh entity they will be transferred over, i.e. over nodes, over face elements or over body elements.

  • Over nodes This means that the condition will be transferred to the nodes contained in the geometrical entity where the condition is assigned.
  • Over face elements ?multiple? If this condition is applied to a line that is the boundary of a surface or to a surface that is the boundary of a volume, this condition is transferred to the higher elements, marking the affected face. If it is declared as multiple, it can be transferred to more than one element face (if more than one exists). By default it is considered as single, and only one element face will be marked.
  • Over body elements If this condition is applied to lines, it will be transferred to line elements. If assigned to surfaces, it will be transferred to surface elements. Likewise, if applied to volumes, it will be transferred to volume elements.

Note: For backwards compatibility, the command 'over elements' is also accepted; this will transfer the condition either to elements or to faces of higher level elements.

Another important feature is that all the conditions can be applied to different entities with different values for all the defined intervals of the problem.

Therefore, a condition can be considered as a list of fields containing the name of the particular condition, the geometric entity over which it is applied, the mesh entity over which it will be transferred, its corresponding properties and their values.

The format of the file is as follows:

CONDITION: condition_name

CONDTYPE: 'over points', 'over lines', 'over surfaces', 'over volumes', 'over layers', 'over groups'

CONDMESHTYPE: 'over nodes', 'over face elements','over face elements multiple', 'over body elements'

GROUPALLOW: points lines surfaces volumes nodes elements faces

QUESTION: field_name['#CB#'(...,optional_value_i,...)]

VALUE: default_field_value['#WIDTH#'(optional_entry_length)]


QUESTION: field_name['#CB#'(...,optional_value_i,...)]

VALUE: default_field_value['#WIDTH#'(optional_entry_length)]


CONDITION: condition_name



Note: CONDTYPE and CONDMESHTYPE are compulsory, and only a kind of type must be set.

Note: GROUPALLOW is only valid for conditions 'over groups' , is an special optional field to restrict allowed categories of enties of the group to the ones listed (if this field is missing then all kind of entities are allowed). A list of multiple types could be set.

Note: #CB# means Combo Box.

Note: #WIDTH# means the size of the entry used by the user to enter the value of the condition. Specifies an integer value indicating the desired width of the entry window, in average-size characters of the widget's font.

Local Axes

QUESTION: field_name['#LA#'('global','automatic','automatic alternative','automatic main')]

VALUE: default_field_value['#WIDTH#'(optional_entry_length)]

This type of field refers to the local axes system to be used. The position of the values indicates the kind of local axes.

If it only has a single default value, this will be the name of the global axes.

If two values are given, the second one will reference a system that will be computed automatically for every node and will depend on geometric constraints, like whether or not it is tangent, orthogonal, etc.

If a third value is given, it will be the name of the automatic alternative axes, which are the automatic axes rotated 90 degrees.

If a fourth value is given, it will be the name of the automatic main axes, valid only for sufaces using the main curvature directions. (note that sometimes main curvatures are not well defined, e.g. for a planar surface or a sphere all directions are main directions, because the curvature is constant)

All the different user-defined systems will automatically be added to these default possibilities.

To enter only a specific kind of local axes it is possible to use the modifiers #G#,#A#,#L#,#M#.

  • #G#: global axes;
  • #A#: automatic axes;
  • #L#: automatic alternative axes.
  • #M#: main curvature axes

When using these modifiers the position of the values does not indicate the kind of local axes.


QUESTION: Local_Axes#LA#(Option automatic#A#,Option automatic_alt#L#)

VALUE: -Automatic-

Note: All the fields must be filled with words, where a word is considered as a string of characters without any blank spaces. The strings signaled between quotes are literal and the ones inside brackets are optional. The interface is case-sensitive, so any uppercase letters must be maintained. The default_field_value entry and various optional_value_i entries can be alphanumeric, integers or reals. GiD treats them as alphanumeric until the moment they are written to the solver input files.

Global axes:

X=1 0 0

Y=0 1 0

Z=0 0 1

Automatic axes:

For surfaces, this axes are calculated from the unitary normal N:


if N is coincident with the global Y direction (Nx or Nz > some tolerance) then

x'=Y x N / |Y x N|


x'=Z x N / |Z x N|

y'=N x x'


For lines, this axes are calculated from the unitary tangent T:


if T is coincident with the global Z direction (Nx or Ny > some tolerance) then

y'=Y x x' / |Y x x'|


y'=Z x x' / |Z x x'|

z'=x' x y'

Automatic alternative axes:

They are calculated like the automatic case and then swap x and y axes:

x''= y'

y''= - x'

z''= z'

For curves

x'=unitary tangent to the curve on the place where the condition is applied

If this tangent is different of the Z global axe=(0,0,1) then

y'=Y x x'


y'=Z x x'

z'=x' x y'

Note: the tangent x' is considered different of (0,0,1) is the first or second component is greater than 1/64

Main curvature axes:

They are calculated for surfaces finding on a point the directions where the curvatures are maximum and minimum, but these directions are not always well defined.

e.g. in a planar point the curvature is zero in all directions, all directions could be seen as main directions, and in a sphere the curvature is constant=1/Radius and it happen the same.

Multiple assign:

By default a condition can be applied only once to the same entity and last assignation replace previous one, but this behavior can be changed:

One flag that can optionally be added to a condition is:


It is written after CONDMESHTYPE and means that one condition can be assigned to the same entity several times.

Self Calculated #FUNC# fields:

Another type of field that can be included inside a condition is a #FUNC# to do some calculation,

where the key #FUNC#, means that the value of this field will be calculated just when the mesh is generated. It can be considered as a function that evaluates when meshing.

Valid variables for a #FUNC# field are:

  • NumEntity: to track the numerical id of the geometric source entity
  • x y z : to use the coordinates of the node or entity center where the condition is applied
  • Cond(num_field,REAL): to use the value of other fields of this condition (REAL or INT declare that must be considered as a real or a integer number)
  • Valid mathematical operations are the same as the used for the *Operation template command.


QUESTION: Surface_number#FUNC#(NumEntity)


In the above example, NumEntity is one of the possible variables of the function. It will be substituted by the label of the geometrical entity from where the node or element is generated.

QUESTION: X_press#FUNC#(Cond(3,REAL)*(x-Cond(1,REAL))/ (Cond(2,REAL)-Cond(1,REAL)))


In this second example, the x variable is used, which means the x-coordinate of the node or of the center of the element. Others fields of the condition can also be used in the function. Variables y and z give the y- and z-coordinates of this point.

Note: There are other options available to expand the capabilities of the Conditions window (see Special fields).