*equationcreate

Creates an equation between a dependent node and multiple independent nodes.

Syntax

*equationcreate mark_id independent_dofs dof_size independent_weights weight_size dependent dof weight constant

Type

HyperMesh Tcl Modify

Description

This command creates an equation between a dependent node and multiple independent nodes.

Inputs

mark_id
The mark ID containing the independent nodes. Valid values are 1 and 2.
independent_dofs
The array ID containing the degrees of freedom for which each respective independent node of the equation is active. This array is created with the *createarray command.
The DOFs use bit operations to represent the value. In order to specify multiple DOFs for a node, corresponding values for the required DOFs must be summed.
  • DOF1 - 1
  • DOF2 - 2
  • DOF3 - 4
  • DOF4 - 8
  • DOF5 - 16
  • DOF6 - 32
For example, there are 2 independent nodes with DOF1 and DOF3. The array of independent DOFs will be [5 5].
dof_size
The size of the independent_dofs array. This should be equal to the number of independent nodes.
independent_weights
The array ID containing the weight for each respective independent node. The size of array is 6* dof_size. This array is created with the *createdoublearray command.
For example, there are 2 independent nodes with DOF1 weights 1.2 and DOF3 weights 1.3. The array of independent weights will be [1.2 1.2 1.2 1.2 1.2 1.2 1.3 1.3 1.3 1.3 1.3 1.3].
weight_size
The size of the independent_weights array. This should be equal to 6*dof_size.
dependent
The dependent node ID.
dof
The degree of freedom for which the dependent node of the equation is active. Valid values are 1 through 6.
weight
The dependent node weight.
constant
The constant value assigned to all independent and dependent nodes.

Example

To create an equation with dependent node 100 and independent nodes 101-103 with all independent nodes having DOF1, DOF3 and DOF4, a weight of 1.23 and a constant of 5.0, and the dependent node having DOF5:
*createmark nodes 1 101-103
*createarray 3 13 13 13
*createdoublearray 18 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23 1.23
*equationcreate 1 1 3 1 18 100 5 1.23 5.0

Errors

Incorrect usage results in a Tcl error. To detect errors, you can use the catch command:
if { [ catch {command_name...} ] } {
   # Handle error
}