*align_entities

Projects entities to a line, surface, or plane.

Syntax

*align_entities <option1>=<value1> <option2>=<value2> ... <optionN>=<valueN>

Type

HyperMesh Tcl Modify Command

Description

The command projects entities to a line, surface, or plane.

Inputs

mode=<value>
The projection mode. Valid values are aligntoline and aligntoplane.
source_entity=<value>
The type of source entities. Valid values for mode=aligntoline are nodes, points and elements. Valid values for mode=aligntoplane are nodes, points, elements and lines.
target_entity=<value>
The type of target entities. Valid values for mode=aligntoline are nodes, lines and elements. Valid value for mode=aligntoplane is surfaces. Omit this option if TargetEntityType=Plane.
source_list=<value>
The ID of the source entity list. Valid values are 1 and 2.
target_list =<value>
The ID of the target entity list. Valid values are 1 and 2.
target_locations={<values>}
The list of x, y, z coordinates for selected locations. Valid only for mode=aligntoplane.
ProjectionType=<value>
The type of projection.
1 - Project by vector.
2 - Project normal to surfaces. Valid only for TargetEntityType set to plane or surface.
SourceEntityType=<value>
The entity type to project. Valid values are elements, nodes, lines and points. This is a mandatory option if TargetEntityType=Plane or target_entity=surf.
TargetEntityType=<value>
The entity type to project onto. Valid values are surfaces. This is a mandatory option if target_entity=surf.
along_vector_x=<value>
The x component of the vector. For TargetEntityType=Plane or surf valid only when ProjectionType=1.
along_vector_y=<value>
The y component of the vector. For TargetEntityType=Plane or surf valid only when ProjectionType=1.
along_vector_z=<value>
The z component of the vector. For TargetEntityType=Plane or surf valid only when ProjectionType=1.
proj_dir=<value>
This input is used only when mode=aligntoline. Valid values are 0,1, and 2.
0 – Project normally
1 – Project along vector defined by along_vector_x, along_vector_y, and along_vector_z
2 – Remap
finite_targ_line=<value>
This input is used only when mode=aligntoline and target_list contains two nodes/locations.
0 – project to infinite line
1 – project to finite line
offset_val=<value>
This input is used only when mode=aligntoline. Specifies the offset distance in backward direction from target line to source entity.

Examples

To project three nodes to an infinite line created from 2 nodes in node list ID 2 along specified vector:
*createlist nodes 1 4157 4141 4143
*createlist nodes 2 4163 4128
*align_entities mode="aligntoline" proj_dir=1 source_list=1 source_entity=nodes along_vector_x=-0.983433 along_vector_y=0.018948 along_vector_z=-0.180277 target_list=2 target_entity=nodes
To project three nodes to a finite line specified by two locations with using offset 10.0:
*createlist nodes 1 3977 3987 3993
*align_entities mode="aligntoline" proj_dir=1 offset_val=10.000000 source_list=1 source_entity=nodes finite_targ_line=1 target_locations="4701.068001 -614.007177 1160.689055 4815.746991 -615.284962 1161.839578"
To project elements ID 3100-3500 to a plane:
*createlist elements 1 3100-3500
*align_entities mode="aligntoplane" source_list=1 source_entity=elems SourceEntityType=elems TargetEntityType=plane Plane_Base_X=4756.576660 Plane_Base_Y=-116.110229 Plane_Base_Z=885.111145 Plane_X=0.000000 Plane_Y=1.000000 Plane_Z=0.000000

Errors

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

Version History

2022.3