HyperWorks Solvers

Coupler

Coupler

Previous topic Next topic No expanding text in this topic  

Coupler

Previous topic Next topic JavaScript is required for expanding text JavaScript is required for the print function  

Model Element

Class Name

Coupler

Description

Coupler defines an algebraic relationship between the degrees of freedom of two or three joints. This constraint element may be used to model idealized spur gears, rack and pinion gears, and differentials as simple constraints that relate the displacements in a set of joints.

Attribute Summary

Name

Property

Modifiable by command?

id    

Int ()

 

label

Str ()

 

Types

"T R"

 

joints

Reference  ("Joint", count=3)

 

type

EnumString (Types,   count=3)

 

scales

Double  ([1,0,0], count=3)

 

function

Function ("COUSUB", xxfunc="COUXX", xx2func="COUXX2")

 

routine

Routine ()

 

script

Script ()

 

active

Bool ()

Usage

#1: Linear coupler specified in the input deck

Coupler (joints=list, scales=list, optional__attattributes)

 

#2: Nonlinear coupler specified in a user-written subroutine in compiled DLL

Coupler (joints=list, function=userString, routine=string, optional_attributes)

 

#3: Nonlinear coupler specified in a Python function

Coupler (joints=list, function=userString, routine=functionPointer, optional_attributes)

Attribute Description

#1: Linear coupler specified in the input deck

joints

List of references to joint objects.

joints specifies a list of joints (j1, j2, and so on) whose internal degrees of freedom are to be coupled with a COUPLER. The list must contain at least two joints. A maximum of three joint freedoms may be coupled.

This attribute is required.

Only revolute, translational, and cylindrical joints may participate in a COUPLER.

scales

List of doubles.

Defined as the scale factors to be used when defining the constraint associated with a coupler.

When only two joints are used to specify the coupler constraint, the ratio is given two real values.

When three joints are used, the ratio must be provided with three real values.

This attribute is optional.

Note     The attribute scales is exclusive to the attribute function. scales may not be defined when function is defined and vice versa. However, one of the two must be specified.

#2: Nonlinear coupler specified in a user-written subroutine in compiled DLL

joints

List of references to joint objects.

joints specifies a list of joints (j1, j2, and so on) whose internal degrees of freedom are to be coupled with a COUPLER. The list must contain at least two joints. A maximum of three joint freedoms may be coupled.

This attribute is required.

Only revolute, translational, and cylindrical joints may participate in a COUPLER.

function

 

The list of parameters that are passed from the data file to the user defined subroutine.

This attribute is optional.

Note: The attribute function is exclusive to the attribute scales. function may not be defined when scales is and vice versa. However, one of the two must be specified.

routine
 

String

Specifies an alternative name for the user subroutine. The name consists of two pieces of information, separated by “”. The first is the pathname to the shared library containing the function that computes the response of the user-defined Variable. The second is the name of the function in the shared library that does the computation.

For example: routine=”/staff/Altair/engine.dllmyCoupler

”/staff/Altair/ engine.dll is the dll
“myCoupler” is the function within this DLL that performs the calculations

The attribute routine is optional.

When not specified, routine defaults to COUSUB.

#3: Nonlinear coupler specified in a Python function

joints

List of references to joint objects.

joints specifies a list of joints (j1, j2, etc.) whose internal degrees of freedoms are to be coupled with a COUPLER. The list must contain at least two joints. A maximum of 3 joint freedoms may be coupled.

This attribute is required.

Only revolute, translational, and cylindrical joints may participate in a COUPLER.

function

 

The list of parameters that are passed from the data file to the user defined subroutine.

This attribute is optional.

Note     The attribute function is exclusive to the attribute scales. function may not be defined when scales is, and vice versa. However, one of the two must be specified.

routine
 

Pointer to a callable function in Python.

For example: routine=myCousub

myCousub is a Python function or method that can be called from wherever the model resides.

The attribute routine is optional.

When not specified, routine defaults to COUSUB.

Optional attributes – Available to all variants

type

 

 

List containing the string "T” or “R”.

type defines a list that describes the freedom type that is being used for each of the joints.

"T" indicates that the translational degree of freedom in the joint is to be used.

"R" indicates that the rotational degree of freedom in the joint is to be used.

This attribute is optional, unless one of the joints is a cylindrical joint. In this case, the length of the types list must be the same as the length of the joints list.

label

string

The name of the COUPLER element.

This attribute is optional. When not specified, MotionSolve creates a label for you.

id

Integer

Specifies the element identification number for the COUPLER.  This number must be unique among all the COUPLER objects in the model.

This attribute is optional. MotionSolve automatically creates an ID when one is not specified.

Range of values: id > 0

active

Bool

Select one from True or False.

True indicates that the element is active in the model and it affects the behavior of the system.
False indicates that the element is inactive in the model and it does not affect the behavior of the system. It is almost as if the entity was removed from the model, with the exception that can be turned “ON”  when desirable.

The attribute active is optional. When not specified, active defaults to True.

Comments

1.See Properties for an explanation about what properties are, why they are used, and how you can extend these.
2.For a more detailed explanation about Couplers, see the Comments in the XML syntax section.

Examples

1.A linear COUPLER connecting a revolute and translational joint.

jt1  = Joint (label=”Joint-1”, i=i1, j=j1, type="REVOLUTE")

jt2  = Joint (label=”Joint-2”, i=i2, j=j2, type="TRANSLATIONAL")

Coupler (label="Coupler-0", joints=[jt1, jt2], type=[“R”, “T”], scales=[1, 2.5])

2.A linear COUPLER connecting a revolute, translational, and cylindrical joint.

jt1  = Joint (label=”Joint-1”, i=i1, j=j1, type="REVOLUTE")

jt2  = Joint (label=”Joint-2”, i=i2, j=j2, type="TRANSLATIONAL")

jt3  = Joint (label=”Joint-3”, i=i3, j=j3, type="CYLINDRICAL")

Coupler (id=2, label="Coupler-2", joints=[jt1, jt2, jt3], type=[“R”, “T”, “R”],

        scales=[1, 2.5, 3.7])

3.A nonlinear COUPLER with default routine names connecting two translational joints.

trans1  = Joint (label=”Joint-2”, i=i2, j=j2, type="TRANSLATIONAL")

trans2  = Joint (label=”Joint-2”, i=i2, j=j2, type="TRANSLATIONAL")

Coupler (label="Coupler-3", joints=[trans1, trans2], type=[“T”, “T”], function=user(1,2,3))