Model.alternatejointcreate#
- Model.alternatejointcreate(type, n1, n2, orient1_x, orient1_y, orient1_z, orient2_x, orient2_y, orient2_z, orient1_node=Entity(), orient2_node=Entity(), set1=Entity(), set2=Entity())#
Creates a joint element that corresponds to a JOINT, MBPTCV, MBCVCV, MBPTDCV or MBPTDSF card.
- Parameters:
type (int) –
Joint element type. Supported values are:
8 - Ball
9 - Fixed
10 - Revolute
11 - Translational
12 - Cylindrical
13 - Universal
14 - Constant velocity
15 - Planar
16 - Inline
17 - Perpendicular
18 - Parallel axes
19 - Inplane
20 - Orient
21 - Point to Curve
22 - Curve to Curve
23 - Point to Deformable Curve
24 - Point to Deformable Surface
n1 (Entity) – The object describing the first node entity of the joint element.
n2 (Entity) – The object describing the second node entity of the joint element.
orient1_x (double) – x-coordinate defining the first orientation vector.
orient1_y (double) – y-coordinate defining the first orientation vector.
orient1_z (double) – z-coordinate defining the first orientation vector.
orient2_x (double) – x-coordinate defining the second orientation vector.
orient2_y (double) – y-coordinate defining the second orientation vector.
orient2_z (double) – z-coordinate defining the second orientation vector.
orient1_node (Entity) – The first orientation node entity of the joint element.
orient2_node (Entity) – The second orientation node entity of the joint element.
set1 (Entity) – The object describing the first entity set used to define the MBD curve.
set2 (Entity) – The object describing the second entity set used to define the MBD curve.
Note
All joint elements, except those with
type=23ortype=24, require bothn1andn2to be valid (nodes with non-zero IDs). For joints that are either of those two types,n2may be specified asNone. In addition, for those types, this function will always setn2to be equal ton1.Example#
Create a fixed joint connect nodes with IDs 10 and 25#import hm import hm.entities as ent model = hm.Model() model.alternatejointcreate( type=9, n1=ent.Node(model, 10), n2=ent.Node(model, 25), orient1_x=0.0, orient1_y=0.0, orient1_z=0.0, orient2_x=0.0, orient2_y=0.0, orient2_z=0.0, )
Create an inline joint connect nodes with IDs 20 and 100 , use node with ID 50 as the first orientation node#import hm import hm.entities as ent model = hm.Model() model.alternatejointcreate( type=16, n1=ent.Node(model, 20), n2=ent.Node(model, 100), orient1_x=0.0, orient1_y=0.0, orient1_z=0.0, orient2_x=0.0, orient2_y=0.0, orient2_z=0.0, orient1_node=ent.Node(model, 50), )
Create a point to curve joint element connect nodes with IDs 15 and 16 , use a MBD curve defined by an entity set of ID 4#import hm import hm.entities as ent model = hm.Model() model.alternatejointcreate( type=21, n1=ent.Node(model, 15), n2=ent.Node(model, 16), orient1_x=0.0, orient1_y=0.0, orient1_z=0.0, orient2_x=0.0, orient2_y=0.0, orient2_z=0.0, set1=ent.Set(model, 4), )