Model.CE_ConnectorCreateByMarkAndRealizeWithDetails#

Model.CE_ConnectorCreateByMarkAndRealizeWithDetails(entitycollection, ce_style, num_ents, linkentcollection, solvername, config, fe_type, tolerance, area_mesh_type=1, area_mesh_size=0.0, link_elems_geom='geom', link_rule='none', relink_rule='none', tol_flag=0, tol=1, line_spacing=1.0, line_density=0, line_offset_flag=0, line_offset=0, seam_area_group=0, area_width=1.0, area_offset=0.0, ce_propertyid=0, ce_systems=0, ce_connectivity=0, ce_forcecollinear=0, ce_diameter=0.0, ce_areathicknesstype=0, ce_areaconstthickness=0.0, ce_areastacksize=0, ce_boltmindiameter=0.0, ce_boltmaxdiameter=10.0, ce_appliedmass=0.0, ce_appliedmassdis=0, ce_configfile='', ce_dvstfile='', ce_propertyscript='', ce_fevectorrevers=0)#

Creates a certain style of connectors at locations specified by collection using certain rules and details, and realize them using specified details.

Parameters:
  • entitycollection (Collection) –

    The collection containing the input entities. Valid entities are:

    points Valid for Spot, Bolt, and Apply Mass connectors.

    nodes Valid for Spot, Bolt, and Apply Mass connectors.

    lines Valid for Spot, Bolt, and Seam connectors.

    elements Valid only for Area connectors.

    surfaces Valid only for Area connectors.

  • ce_style (hwString) – Style of connectors. Valid options are “spot”, “bolt”, “apply_mass”, “seam”, “area”.

  • num_ents (int) – Number of links.

  • linkentcollection (Collection) – The collection containing the entities to use for link.

  • solvername (hwString) – The target solver for realization.

  • config (int) –

    The element type for realization:

    2 - plot

    3 - weld

    5 - rigid

    21 - spring

    55 - rigidlink

    60 - bar2

    61 - rod

    70 - gap

    104 - quads

    1001 - custom

  • fe_type (int) – The type ID for the current solver specified in the FEconfig file. Only used for custom config (1001).

  • tolerance (double) – The maximum distance allowed between the connector (on collection) and each of its links during realization.

  • area_mesh_type (int) –

    Mesh type for area connectors when using SURFS as the location:

    0 - Trias

    1 - Quads

    2 - Mixed

    3 - Right trias

  • area_mesh_size (double) – Mesh size for area connectors when using SURFS as the location.

  • link_elems_geom (hwString) – Connecting element (“elems”) or geometry (“geom”).

  • link_rule (hwString) – Link rule. Valid values are “now”, “at_fe_realize” and “none”.

  • relink_rule (hwString) – Relink rule. Valid values are “id”, “name” and “none”.

  • tol_flag (int) –

    Indicates whether to use tolerance.

    0 = Yes

    1 = No

  • tol (double) – Add entities as links only within this distance of the specified location.

  • line_spacing (double) – Spacing for spot or seam connectors on lines.

  • line_density (unsigned int) – Density for spot or seam connectors on lines.

  • line_offset_flag (unsigned int) –

    Indicates whether to offset connector.

    0 = Yes

    1 = No

  • line_offset (double) – Offset value from the ends of line for spot or seam connectors.

  • seam_area_group (int) –

    Group flag for seam or area connector.

    0 = No

    1 = Yes

  • area_width (double) – Width of area connectors created from node lists or line lists.

  • area_offset (double) – Offset area connnector(s) created from node or line lists from the selected location by this value.

  • ce_propertyid (unsigned int) – Property ID value.

  • ce_systems (int) –

    Build system flag.

    0 = No

    1 = Yes

  • ce_connectivity (int) –

    Connectivity type:

    0 - Mesh independent

    1 - Mesh dependent + remesh

    2 - Mesh dependent + ensure projection

    3 - Mesh dependent + quad transition

    4 - Mesh dependent + projection and find nodes

    5 - Mesh dependent + find nearest nodes

  • ce_forcecollinear (int) –

    Collinear flag:

    0 = Non-collinear

    1 = Collinear

  • ce_diameter (double) – Diameter value for some custom types (acm, cweld, mat100, etc.).

  • ce_areathicknesstype (int) –

    Thickness type for area connector:

    0 = (T1+T2)/2

    1 = Shell gap

    2 = Mid thickness

    3 = Const thickness

  • ce_areaconstthickness (double) – Constant thickness value for area connector.

  • ce_areastacksize (int) – Density for area connector.

  • ce_boltmindiameter (double) – Minimum diameter for a hole to be accepted as a bolt hole.

  • ce_boltmaxdiameter (double) – Maximum diameter for a hole to be accepted as a bolt hole.

  • ce_appliedmass (double) – Mass value for apply massx.

  • ce_appliedmassdis (int) –

    Mass distribution type for apply mass:

    0 = Apply to all nodes.

    1 = Divide by nodes.

    2 = Divide by area.

    3 = Unit area.

  • ce_configfile (hwString) – fe configuration file.

  • ce_dvstfile (hwString) – Diameter vs. thickness file.

  • ce_propertyscript (hwString) – Property script file.

  • ce_fevectorrevers (int) –

    Reverse direction flag for seam connectors:

    0 = No reverse

    1 = Reverse

Example#

Create a spot connector at the location of node with ID 10 to connect component with IDs 3 and 4 using rigid element#
import hm
import hm.entities as ent

model = hm.Model()

model.CE_ConnectorCreateByMarkAndRealizeWithDetails(
    entitycollection=hm.Collection(model, ent.Node, [10]),
    ce_style="spot",
    num_ents=2,
    linkentcollection=hm.Collection(model, ent.Component, [3, 4]),
    solvername="nastran",
    config=5,
    fe_type=0,
    tolerance=6.0,
    link_elems_geom="elems",
    link_rule="now",
    relink_rule="none",
    tol_flag=1,
    tol=6.0,
    ce_systems=0,
    ce_connectivity=0,
    ce_nonnormal=0,
)