Tworld Struct Reference

Detailed Description

All the necessary information to generate equations for mechanisms and the equations themselves.

It also includes the information about the obstacles around the mechanisms and, thus, provide methods to detect collisions.

Finally, the functions associated to this structure allow to animate solution paths (i.e. to move the mechanisms along a set of configurations).

Definition at line 229 of file world.h.

Data Fields

unsigned int stage
 
Tenvironment e
 
Tmechanism m
 
unsigned int nl
 
unsigned int nb
 
unsigned int nj
 
unsigned int no
 
unsigned int np
 
unsigned int endEffector
 
double maxCoord
 
boolean ** checkCollisionsLL
 
boolean ** checkCollisionsLO
 
TCuikSystem kinCS
 
unsigned int nvars
 
unsigned int nsvars
 
booleansystemVars
 
unsigned int * sortedLinks
 
unsigned int * jointTo
 
Tbranchbranch2Link
 
Tequations refEqs
 
TJacobian refEqsJ
 
booleanopenLink
 
unsigned int nwcd
 
TworldCDwcd
 
unsigned int ndof
 
unsigned int * link2dof
 
unsigned int * dof2link
 
unsigned int * dof2param
 
unsigned int * joint2dof
 
unsigned int * dof2joint
 
unsigned int * dof2range
 

Field Documentation

unsigned int Tworld::stage

Stage of the world structure: EMPTY_WORLD, WORLD_WITH_GEOMETRY, WORLD_WITH_COLLISIONS, WORLD_WITH_EQUATIONS. Latter stages imply the previous ones.

Definition at line 230 of file world.h.

Referenced by AddJoint2World(), AddLink2World(), AddObstacle2World(), AnimateWorld(), CheckAllCollisions(), CheckLinkLinkCollision(), CheckLinkObstacleCollision(), CheckSelfCollisions(), DeleteWorld(), EvaluateWorldJacobian(), FixLinks(), FixZToZero(), GenerateForceEquilibriumEquations(), GenerateWorldEquations(), GenerateWorldSingularityEquations(), GetLinkTransformsFromSolutionPoint(), GetWorldInitialBox(), GetWorldJacobian(), GetWorldNumSystemVariables(), GetWorldNumVariables(), GetWorldSimpInitialBox(), GetWorldSimpJacobian(), GetWorldSimpTopology(), GetWorldSimpVariableMask(), GetWorldSystemVarName(), GetWorldSystemVars(), GetWorldTopology(), GetWorldVarNames(), InitWorld(), InitWorldCD(), IsWorldPolynomial(), MaxWorldReduction(), MoveWorld(), MoveWorldDOF(), NewtonInWorld(), NoCheckAllCollisions(), NoCheckLinkLinkCollision(), NoCheckLinkObstacleCollision(), NoCheckSelfCollisions(), PlotWorld(), PrintWorldAxes(), PrintWorldCS(), RegenerateWorldOriginalPoint(), RegenerateWorldSolutionPoint(), WorldCoupleTensegrityVariable(), WorldDOF2Sol(), WorldErrorInEquations(), WorldErrorInSimpEquations(), WorldErrorInSimpInequalities(), WorldEvaluateEquations(), WorldEvaluateSimpEquations(), WorldEvaluateSubSetSimpEquations(), WorldForceField(), WorldForceVars(), WorldGenerateSimplifiedPoint(), WorldGenerateSimplifiedPointFromSystem(), WorldInequalitiesHold(), WorldInitDOFInfo(), WorldManifoldDimension(), WorldPotentialEnergy(), WorldSample2DOF(), WorldSimpInequalitiesHold(), and WorldSimpKinematicVars().

unsigned int Tworld::nb

Number of convex bodies forming the links.

Definition at line 239 of file world.h.

Referenced by AddLink2World(), GetWorldNConvexBodiesInLinks(), and InitWorld().

unsigned int Tworld::no
unsigned int Tworld::np

Number of convex bodies in the links and in the environment (nb+no).

Definition at line 242 of file world.h.

Referenced by AddLink2World(), AddObstacle2World(), GetWorldNConvexBodies(), and InitWorld().

unsigned int Tworld::endEffector

Identifier of the link that has to be considered as the manipulated object (or end effector).

Definition at line 245 of file world.h.

Referenced by AddLink2World(), InitWorld(), and PrintWorldCollisionInfo().

double Tworld::maxCoord

Sum of the maximum coordinate values for all objects in the mechanism.

Definition at line 247 of file world.h.

Referenced by GenerateEquationsFromBranch(), GenerateWorldEquations(), GenerateWorldSingularityEquations(), GetWorldRangeDOF(), and InitWorldKinCS().

boolean** Tworld::checkCollisionsLL

TRUE if we have to chek the collision between the corresponding pair of links. Note that in the wold definition file we can not activate/desactive the collision checking for sub-parts of a link. To get this effect you can use assign the DECOR type to the link sub-parts not to be considered in the collision detection.

Definition at line 250 of file world.h.

Referenced by AddLink2World(), AnyCollision(), CheckLinkLinkCollision(), CheckSelfCollisions(), DeleteWorldCollisionInfo(), InitWorld(), InitWorldCD(), NoCheckLinkLinkCollision(), NoCheckSelfCollisions(), and PrintCollisions().

boolean** Tworld::checkCollisionsLO

TRUE if we have to chek the collision between the corresponding link and object in the environment. Note that in the wold definition file we can not activate/desactive the collision checking for sub-parts of a link. To get this effect you can use assign the DECOR type to the link sub-parts not to be considered in the collision detection.

Definition at line 259 of file world.h.

Referenced by AddLink2World(), AddObstacle2World(), AnyCollision(), CheckAllCollisions(), CheckLinkObstacleCollision(), DeleteWorldCollisionInfo(), InitWorld(), InitWorldCD(), NoCheckAllCollisions(), NoCheckLinkObstacleCollision(), and PrintCollisions().

TCuikSystem Tworld::kinCS

The cuiksystem derived form the mechanism.

Definition at line 270 of file world.h.

Referenced by AnimateWorld(), DeleteWorldCS(), EvaluateWorldJacobian(), FixLinks(), FixZToZero(), GenerateForceEquilibriumEquations(), GenerateMEquationFromBranch(), GenerateTransEquationsFromBranch(), GenerateWorldEquations(), GenerateWorldSingularityEquations(), GetLinkTransformsFromSolution(), GetLinkTransformsFromSolutionPoint(), GetSolutionPointFromLinkTransforms(), GetWorldInitialBox(), GetWorldJacobian(), GetWorldNumSystemVariables(), GetWorldNumVariables(), GetWorldSimpInitialBox(), GetWorldSimpJacobian(), GetWorldSimpTopology(), GetWorldSimpVariableMask(), GetWorldSystemVarName(), GetWorldSystemVars(), GetWorldTopology(), GetWorldVarNames(), GetWorldVarTopology(), InitWorldCS(), InitWorldKinCS(), IsWorldPolynomial(), MaxWorldReduction(), MoveWorld(), NewtonInWorld(), PrintWorldAxes(), PrintWorldCS(), RegenerateWorldOriginalPoint(), RegenerateWorldOriginalSystemPoint(), RegenerateWorldSolutionPoint(), WorldCoupleTensegrityVariable(), WorldDOF2Sol(), WorldErrorInEquations(), WorldErrorInSimpEquations(), WorldErrorInSimpInequalities(), WorldEvaluateEquations(), WorldEvaluateSimpEquations(), WorldEvaluateSubSetSimpEquations(), WorldFixTensegrityAddon(), WorldForceField(), WorldForceVars(), WorldGenerateSimplifiedPoint(), WorldGenerateSimplifiedPointFromSystem(), WorldInequalitiesHold(), WorldManifoldDimension(), WorldPotentialEnergy(), WorldSimpCuikNewton(), WorldSimpInequalitiesHold(), and WorldSimpKinematicVars().

unsigned int Tworld::nvars

Number of variables in the kinCS

Definition at line 272 of file world.h.

Referenced by GenerateWorldEquations(), InitWorld(), WorldForceField(), WorldForceVars(), and WorldSimpKinematicVars().

unsigned int Tworld::nsvars

Number of system variables in the kinCS

Definition at line 273 of file world.h.

Referenced by GenerateWorldEquations(), and InitWorld().

boolean* Tworld::systemVars

Array of booleans with as many elements as variables has the cuiksystem and where each entry is TRUE if the corresponding variable is a system variable.

Definition at line 274 of file world.h.

Referenced by DeleteWorldCS(), GenerateWorldEquations(), GetSolutionPointFromLinkTransforms(), InitWorld(), MaxWorldReduction(), RegenerateWorldOriginalSystemPoint(), RegenerateWorldSolutionPoint(), and WorldForceVars().

unsigned int* Tworld::sortedLinks

Links as they are encountered when expanding graph implicitly defined by links and joints.

Definition at line 279 of file world.h.

Referenced by DeleteWorldCS(), GenerateKinTree(), and GetLinkTransformsFromDOF().

unsigned int* Tworld::jointTo

Joint taking to a given link when expanding graph implicitly defined by links and joints.

Definition at line 281 of file world.h.

Referenced by DeleteWorldCS(), GenerateKinTree(), and GetLinkTransformsFromDOF().

Tbranch* Tworld::branch2Link

Sequence of joints taking from the ground link to each of the other links. This is used to compute the refEqs (see below) and to transfrom from dof to matrices. This informatin is redundant with the one encoded in 'sortedLinks' and 'joinsTo' but we keep it for convenience.

Definition at line 283 of file world.h.

Referenced by DeleteWorldCS(), FixLinks(), GenerateKinTree(), GenerateWorldEquations(), GetLinkTransformsFromDOF(), InitWorld(), and WorldFixTensegrityAddon().

Tequations Tworld::refEqs

Equations giving (part of) the forward kinemtics for all links. In matrix-like representations this includes three equations for each link giving the position of the frame of reference of each link in the global frame of reference. They define the translations using rotation variables and fixed vectors. When using a REP_DOF this includes matrix equations giving the homogeneous matrix for each link.

Definition at line 291 of file world.h.

Referenced by DeleteWorldCS(), GenerateWorldEquations(), GenerateWorldSingularityEquations(), GetLinkTransformsFromSolution(), and PrintWorldAxes().

TJacobian Tworld::refEqsJ

Jacobian of the equations in refEqs. This is computed in all the cases, but only actually used if the representation is DOF-based in the WorldAtomJacobian function. Note that the refEqs are given in the original variables (i.e., without any simplification) and so it is the Jacobian.

Definition at line 301 of file world.h.

Referenced by DeleteWorldCS(), GenerateWorldEquations(), and WorldAtomJacobian().

boolean* Tworld::openLink

TRUE if the link is at the end of an open branch. In this case the kinematic system includes variables with the position of this link and we have to take this into account when generating configurations from degrees of freedom (see WorldDOF2Sol)

Definition at line 309 of file world.h.

Referenced by DeleteWorldCS(), GenerateKinTree(), and WorldDOF2Sol().

unsigned int Tworld::nwcd

Number of wcd structures being initialized. When using OpenMP we initiliaze as many wcd structures as threads so that we can check for collision detection in parallel.

Definition at line 316 of file world.h.

Referenced by DeleteWorldCD(), InitWorldCD(), and MoveAndCheckCDFromTransforms().

TworldCD* Tworld::wcd

The collision detection information, if any.

Definition at line 320 of file world.h.

Referenced by DeleteWorldCD(), InitWorld(), InitWorldCD(), MoveAndCheckCD(), MoveAndCheckCDFromTransforms(), PlotWorld(), PrintWorldCollisionInfo(), WorldCanCollide(), and WorldContinuousCD().

unsigned int Tworld::ndof
unsigned int* Tworld::link2dof

Mapping fom joints to degrees of freedom.

Definition at line 324 of file world.h.

Referenced by GetLinkTransformsFromDOF(), WorldDeleteDOFInfo(), and WorldInitDOFInfo().

unsigned int* Tworld::dof2link

Mapping fom degrees of freedom to link.

Definition at line 325 of file world.h.

Referenced by GetWorldDOFLabel(), GetWorldRangeDOF(), WorldDeleteDOFInfo(), and WorldInitDOFInfo().

unsigned int* Tworld::dof2param

Mapping fom degrees of freedom to specific configuration of each link.

Definition at line 326 of file world.h.

Referenced by GetWorldDOFLabel(), GetWorldRangeDOF(), WorldDeleteDOFInfo(), and WorldInitDOFInfo().

unsigned int* Tworld::joint2dof

Mapping fom joints to degrees of freedom.

Definition at line 329 of file world.h.

Referenced by GetLinkTransformsFromDOF(), WorldDeleteDOFInfo(), WorldDOF2Sol(), and WorldInitDOFInfo().

unsigned int* Tworld::dof2joint

Mapping fom degrees of freedom to joints.

Definition at line 330 of file world.h.

Referenced by GetWorldDOFLabel(), GetWorldJointLabel(), GetWorldRangeDOF(), WorldDeleteDOFInfo(), WorldDOF2Sol(), WorldDOFTopology(), and WorldInitDOFInfo().

unsigned int* Tworld::dof2range

Mapping fom degrees of freedom to specific range of each joint.

Definition at line 331 of file world.h.

Referenced by GetWorldDOFLabel(), GetWorldJointLabel(), GetWorldRangeDOF(), WorldDeleteDOFInfo(), WorldDOF2Sol(), WorldDOFTopology(), and WorldInitDOFInfo().