dspl(3)

NAME
trsfToDspl, dsplToTrsf, scaleDspl, extrapTrsfByDspl, unitDspl -- RCCL routines associated with the DSPL data type.

USAGE
#include <robotTypes.h> /* included as part of <rccl.h> */

DSPL *trsfToDspl (dr, t1)
  DSPL *dr;
  TRSF *t1;

TRSF *dsplToTrsf (tr, d1)
  TRSF *tr;
  DSPL *d1;

DSPL *scaleDspl (dr, s, d1)
  DSPL *dr;
  float s;
  DSPL *d1;

TRSF *extrapTrsfByDspl (tr, s, d1)
  TRSF *tr;
  float s;
  DSPL *d1;

DSPL *unitDspl (dr, d1)
  DSPL *dr, *d1;

ARGUMENTS

dr --
    Result displacement.

tr --
    Result transform.

d1 --
    Input displacement.

t1 --
    Input transform.

s --
    Scaling constant.

DESCRIPTION
A DSPL data type represents a general displacement in Cartesian coordinates as a translation followed by a rotation about an axis. The components of DSPL include a translation vector p, a unit vector u describing the axis of rotation, and the rotation angle a (in radians). To avoid ambiquities, the angle a is defined to be positive, since negative rotations can be obtained by changing the direction of u. Routines which return a DSPL enforce this convention.

The following routines perform operations on the DSPL data type.

trsfToDspl() converts a transform t1 into the corresponding displacment dr. If the resulting value of a is zero, then u is set to zero as well.

dsplToTrsf() converts a displacement d1 into the corresponding transform tr.

scaleDspl() scales the displacment d1 by s, and returns the result in dr. The scale is applied to the translation vector and the rotation angle a. If the resulting value of a is negative, then it is changed to a positive value and the direction of u is reversed.

extrapTrsfByDspl() is a combination of scaleDspl() and dsplToTrsf(): it scales the displacement d1 by s, and then converts this into the transform tr.

unitDpsl() copies d1 into dr, normalizing the value of a (and changing the direction of u, if necessary) so that a <=0 <=PI. If a = 0, then u is set to zero as well.

Each of these routines returns a pointer to its result argument.

SEE ALSO
multTrsf(3).