*EntityMoveUsingArray

Organize a different group of elements to their respective collectors.

Syntax

*EntityMoveUsingArray entity_col IdSizeArray numRows numCols ent_to_move entityIds numEnts

Type

HyperMesh Tcl Modify

Description

Organize a different group of elements to their respective collectors.

Inputs

entity_col
Entity collector type that holds the entity IDs.
IdSizeArray
A 2D array that contains the collector IDs specified by the entity_col variable and a size value that specifies the number of entities that need to be moved from the entityIds array.
numRows
The number of rows for the 2D array.
numCols
The number of columns for the 2D array. This MUST always have a value of 2.
ent_to_move
The entity type to be organized in the collector.
entityIds
Array of specific entity type IDs to be organized into specific collectors.
numEnts
The size of the entity ID array.

Example

This command currently supports moving elements to components only. This is optimized for organizing a different group of elements to their respective collectors from a Tcl script. For example, elements with IDs 1 to 5 must be moved to component ID 1, elements with IDs 6 to 10 must be moved to comp ID 2 and elements with IDs 11 to 15 must be moved to comp ID 3.

The command below accepts a 3 X 2 matrix with its values specified in a single line. The number of rows is 3 and number of columns is 2. The rest of the parameter specifies that the first 5 elements from the entityIds array must be moved to comp ID 1, the next 5 elements moved to comp ID 2, and the last 5 elements moved to comp ID 3.
*createentityarray2d 3 2 1 5 2 5 3 5;
The following command accepts the number of elements to move and the IDs of all the elements that need to be moved.
*createarray 15 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15;
Note: The number of elements to move MUST be equal to the sum of the values specified for the number of elements to move in the 2D array.
*EntityMoveUsingArray COMPS 1 3 2 ELEMS 1 15;