Model.tetmesh_create_size_ctrl#
- Model.tetmesh_create_size_ctrl(string)#
Generates a special component representing an elem-size-control/refinement box for use with the
tetmesh()orModel.tetmesh_set_input()functions. The name of the created component has the prefix “^elem_size_ctrl_”, followed by an instance number and then the elem size (e.g. “^elem_size_ctrl_0_0.02”). An instance number is used to distinguish different boxes having the same elem size.- Parameters:
string (hwString) – A double quoted string of 25 space or comma separated real numbers. The first 24 numbers are the 3D coordinates of the 8 vertices of the box (x1 y1 z1 x2 y2 z2…x8 y8 z8). The order of these vertices is the same as a first order hex element (vertices 1-4 on the bottom face with counter-clockwise orientation, vertices 5-8 on the top face with the same orientation). The last value is the user specified tetra element size for inside and near the box. A well-defined box should be convex.
Example#
Create a size control box with a mesh size of 0.02#import hm import hm.entities as ent model = hm.Model() model.tetmesh_create_size_ctrl( string="205.163,-144.90,24.91,255.09,-144.90,24.91,255.09,-33.68,24.91,205.16,-33.68,24.91,205.16,-144.90,144.90,255.09,-144.90,144.90,255.09,-33.68,144.90,205.16,-33.68,144.90,0.02" )