Model.linearsurfacebetweennodesandline#
- Model.linearsurfacebetweennodesandline(list1, linelist1, endpoints, reverse, setmeshparam=0)#
Creates a ruled surface between a node list and a trimmed line list, and optionally, prepares it for immediate use within the automesher. It can also identify a region in the shape of a ruled surface for the automesher to use under the mesh without surface option.
- Parameters:
list1 (EntityList) – The list of node entities forming one side of the surface.
linelist1 (EntityList) – The list of line entities forming one side of the surface.
endpoints (EntityList) – The list of two node entities which lie on the lines in the line list which will be used to trim the line during surface creation. If no nodes are lie in
linelistthen in the argument please pass theent.Node.getentitylist()value.reverse (int) –
Indicates whether the lines should be tested for a “bow tie” condition and reversed if necessary. Valid options are:
0 - No testing the lines for a “bow tie” condition and no reversing.
1 - Testing the lines for a “bow tie” condition and reversing.
setmeshparam (int) – Flag defining if the mesh parameter is set for the orphan nodes selection (1 for yes, 0 for no).
Example#
Create a ruled surface and bring it into the automesher , create 16 quad elements , and store the elements to the HyperMesh database#import hm import hm.entities as ent model = hm.Model() """ Creating a ruled surface (model.linearsurfacebetweennodesandline()) and bringing it into the automesher (model.surfacemode(mode=1),model.set_meshedgedparams()), creates 16 quad elements (model.automesh()), and stores the elements to the HyperMesh database (model.storemeshtodatabase()). """ model.surfacemode(mode=1) node_list = [ ent.Node(model, 160), ent.Node(model, 161), ent.Node(model, 164), ent.Node(model, 168), ent.Node(model, 172), ] line_list = [ent.Line(model, 1)] model.linearsurfacebetweennodesandline( list1=node_list, linelist1=line_list, endpoints=ent.Node.getentitylist(), reverse=1 ) model.set_meshedgeparams( edge_index=0, elem_density=4.0, alg_type=1, bias_style=0, bias=0.0, min_size=0.0, max_size=0.0, chordal_dev=0.0, max_angle=0.0, ) model.set_meshedgeparams( edge_index=1, elem_density=4.0, alg_type=1, bias_style=0, bias=0.0, min_size=0.0, max_size=0.0, chordal_dev=0.0, max_angle=0.0, ) model.set_meshedgeparams( edge_index=2, elem_density=4.0, alg_type=1, bias_style=0, bias=0.0, min_size=0.0, max_size=0.0, chordal_dev=0.0, max_angle=0.0, ) model.set_meshedgeparams( edge_index=3, elem_density=4.0, alg_type=1, bias_style=0, bias=0.0, min_size=0.0, max_size=0.0, chordal_dev=0.0, max_angle=0.0, ) model.set_meshfaceparams( face_index=0, shape_type=1, elem_type=1, alg_type=0, elem_size=0, smooth_method=0, smooth_tol=0.1, size_control=0, skew_control=0, ) model.automesh(face_index=0, algorithm=1, elem_type=1) model.storemeshtodatabase(elemstosurfcomp=0) model.ameshclearsurface()