Defining Relations
This task describes how to define kinematic relations.
-
Select Kinematic Relations
.
You are prompted to select a robot. -
Select a robot.
A dialog box listing the noncommand joints of the mechanism appears.
- From the list of noncommand joints (or directly in the work area) for defining a kinematic relation, select a joint.
-
Click Add/Edit Relation to define and compile the
kinematic expression.
If the selected joint already has a kinematic expression defined for it, this expression is then displaying in the expression editor. You may edit the existing expression.
- Enter Joint expressions directly into the Define Joint Kinematic Relationship dialog without using the supplied dictionaries.
- Click OK to apply the defined relationship and close the dialog box.
-
Dictionary types
The substrings used to compile a kinematic expression are categorized into various dictionaries as shown in the Define Joint Kinematic Relationship dialog. Each dictionary contains a predefined set of strings.
The information of the Degree of Freedom (DOF) dictionary is dependent on the number of DOFs of the mechanism. For a mechanism with N degrees of freedom, the Degree of Freedom dictionary has DOF(1), DOF(2), ...DOF(N).
The User Variables dictionary lists all the created user-defined variables.
Operators Math Functions ; abs SASA
, acos, asin, atan SASS
= acosr, asinr, atanr SSSA
+ cos, sin, tan RANGE
- cosr,sinr, tanr INRANGE
* exp SASASA
/ Int SASASS
^ sqrt SASSSA1
% floor, ceil SASSSA2
( log,log10 RAMP
) The members of the Operators, Math, and Functions dictionaries are defined as follows:
Operators ; Separator for expressions. Useful in case of multiple expressions for a noncommand joint. , Arguments separator in a function = Assignment + Unary plus, binary addition - Unary minus, binary subtraction * Binary multiplication / Binary division ^ Exponent % Module operator ( Opening parenthesis ) Closing parenthesis Math abs(x) returns absolute value acos(x) asin(x) atan(x) returns arc cos, sin, tan in degrees acosr(x) asinr(x) atanr(x) returns arc cos, sin, tan in radians cos(x) sin(x) tan(x) Returns cos, sin, tan in degrees cosr(x) sinr(x) tanr(x) Returns cos, sin, tan in radians exp(x) Returns e raised to power x int(x) Returns integer value resulting from truncation sqrt(x) Returns square root floor(x) ceil(x) Returns floor, ceiling of x log(x) log10(x) Returns natural logarithm, logarithm base 10 Functions Usage The following functions are useful for solving triangles given three sides of the triangle (s1, s2, s3) and one of its angles (a1). All angles are in radians. sasa(s1,a1,s2) returns angle opposite side s1 sass(s1,a1,s2) returns length of side opposite angle a1 sssa(s1,s2,s3) returns angle opposite side s1 


The following functions are useful for solving convex quadrilaterals given four sides (s1, s2, s3, s4) and two of its angles (a1, a2). All angles are in radians. sasasa(s1, a1, s2, a2, s3) returns angle between sides s3 and s4 sasass(s1, a1, s2, a2, s3) returns length of unknown side s4 sasssa1(s1, a1, s2, s3, s4) returns angle between sides s2 and s3 sasssa2(s1, a1, s2, s3, s4) returns angle between sides s3 and s4 


A ramp function assists in calculating the joint values of a joint whose upper and lower bounds are dependent on the values of another joint. yy = ramp(xx,x1,y1,x2,y2) returns yy as a linear function of xx, where the inputs x1, y1, x2, y2 are used to define the ramp. inrange(a,b,c) returns 1 if b <= a < c and 0 otherwise range(a,b,c) returns a if b < a, c if b > c and b otherwise
Note:If xx is < x1, then yy stays at y1
If xx is > x2, then yy stays at y2
However, an expert user may directly key in the joint expression without using the dictionaries provided. You may create/edit/delete user-variables (if required) using Create, Edit, and Delete. Any new variable created by you is added to the User-defined Variables dictionary and subsequently can be used in the kinematic expression of the joints. The user variables thus defined are available for use in the kinematic expression of any NC joint of the mechanism. For a list of the values used in converting radians to degrees or vice versa, plus the value of PI used in this software, see Defining Travel Limits.
Result:
