Joint
Model ElementJoint is used to create an idealized connector between two bodies.
Class Name
Joint
Description
Joint defines a set of lower pair constraints. Physically, the joint consists of two mating surfaces that allow relative translational and/or rotational movement in certain specific directions only. The surfaces are abstracted away, and the relationships are always expressed as a set of algebraic constraint equations between points and directions on two bodies.
Attribute Summary
Name | Property | Modifiable by command? | Designable? |
---|---|---|---|
id | Int () | ||
label | Str () | ✓ | |
i | Reference (Marker) | ✓ | Yes |
j | Reference (Marker) | ✓ | Yes |
type | Enum (Type, default= "SPHERICAL", required=True) | ||
pd | Double () | ✓ | FD Only |
pitch | Double () | ✓ | FD Only |
ic | Double (None, count=2) | FD Only | |
ictran | Double (None, count=2) | FD Only | |
icrot | Double (None, count=2) | FD Only | |
active | Bool () | ✓ |
* Type=("CONVEL","CYLINDRICAL","FIXED",HOOKE",PLANAR","RACKPIN",REVOLUTE","SCREW","SPHERICAL", "TRANSLATIONAL","UNIVERSAL")
Usage
Joint (i=objmarker, j=objmarker, type=string_joint_type, optional_attributes)
Attributes
- i
- Reference to an existing marker.
- j
- Reference to an existing marker.
- type
- String that is one of ("CONVEL", "CYLINDRICAL", "FIXED", "HOOKE", "PLANAR", "RACKPIN", "REVOLUTE", "SCREW", "SPHERICAL", "TRANSLATIONAL", "UNIVERSAL")
- id
- Integer
- label
- String
- pitch
- Double
- pd
- Double
- ic
- List of two doubles
- ictran
- List of two doubles
- icrot
- List of two doubles
- active
- Boolean
Example 1
Create a cylindrical joint between bodies p3 and p4.
Location specified by an existing point, pc
zpval = pc + Vector(1,0,0)
p3.C = Marker (body=p3, qp=pc, zp=zpval, label="p3.C")
p4.C = Marker (body=p4, qp=pc, zp=zpval, label="p4.C")
jcyl = Joint (i=p4.C, j=p3.C, type="CYLINDRICAL", label="Joint #1")
Example 2
jcyl.ictran = (3.142, 2.71828)
Example 3
#Define the function first
def CylindricalJoint (ibody, jbody, location, axis, label, **kwds):
"""
ibody - A rigid body, point mass or flex-body
jbody - A rigid body, point mass or flex-body
location - A Point
axis - A Vector
label - A name for the joint
"""
#Coordinates of a point along the axis of rotation
zpval = location + axis
i = Marker (body=ibody, qp=location, zp=zpval)
j = Marker (body=jbody, qp=location, zp=zpval)
jcyl = Joint (type="REVOLUTE", i=i, j=j, label=label, **kwds)
i.label = label + " I Marker"
j.label = label + " J Marker"
return jcyl
#Create a cylindrical joint using the convenience function described above
pc = Point (23.1, -46.2, 69.3*math.sin(0.436332))
zaxis = Vector(1,0,0)
label = "Joint #1"
jcyl = CylindricalJoint (p3, p4, pc, zaxis, label, ictran=(3.142, 2.71828))
Example 4
#Define the joint
pc = Point (23.1, -46.2, 69.3*math.sin(0.436332))
zaxis = Vector(1,0,0)
label ="Joint #1"
jcyl = CylindricalJoint (p3, p4, pc, zaxis, label, ictran=(3.142, 2.71828))
#Now define the request
comment = jcyl.label + " Displacement"
r1 = Request (type="DISPLACEMENT", i=jcyl.i, j=jcyl.j, comment=comment)
Example 5
Using the "dot" operator to "get" the attributes of a joint.
jcyl = Joint (i=p4.C, j=p3.C, type="CYLINDRICAL", label="Joint #1")
iMarker = jcyl.i # The I marker for the joint jcyl
jtype = jcyl.type # The type of the joint jcyl
iBody = iMarker.body # The body to which iMarker belongs
iMass = iBody.mass # The mass of the body to which the iMarker belongs
Comments
- See Properties for an explanation about what properties are, why they are used, and how you can extend these.
- Use the Jprim (...) method to define a Joint
Primitive modeling element with this API. The following joint types in the XML syntax are
considered to be joint primitives:
- "INLINE", "INPLANE", "ORIENTATION", "PARALLEL_AXES", "PERPENDICULAR", "PLANAR"
- For a more detailed explanation about Joint, see Constraint: Joint.