SCL
1.0
Standard Control Library : Control, dynamics, physics, and simulation
|
abstract node class for articulated bodyA dynamics node = {Articulated Body Link + Set of associated Joints}. More...
#include <taoDNode.h>
Public Member Functions | |
taoDNode () | |
virtual void | sync (deFrame *local)=0 |
virtual deInt | isRoot () |
indicates if this node is root More... | |
virtual deInt | isParentRoot () |
indicates if parent of this node is root More... | |
virtual taoJoint * | getJointList ()=0 |
virtual taoJoint const * | getJointList () const =0 |
virtual taoArticulatedBodyLink * | getABNode () |
gets _abNode More... | |
virtual void | setABNode (taoArticulatedBodyLink *node) |
sets _abNode More... | |
virtual deInt | getPropagate () |
indicates if dynamics of node should be included for control More... | |
virtual void | setPropagate (deInt p) |
virtual deVector6 * | velocity ()=0 |
virtual deVector6 * | acceleration ()=0 |
virtual deFrame * | frameHome ()=0 |
virtual deFrame * | frameLocal ()=0 |
virtual deFloat * | mass ()=0 |
virtual deVector3 * | center ()=0 |
virtual deVector3 const * | center () const =0 |
virtual deMatrix3 * | inertia ()=0 |
virtual deVector6 * | force ()=0 |
virtual void | zeroForce ()=0 |
virtual void | addForce (const deVector6 *f)=0 |
virtual void | updateFrame ()=0 |
virtual void | integrate (deFloat dt)=0 |
virtual taoDNode * | getDParent ()=0 |
virtual taoDNode const * | getDParent () const =0 |
virtual void | setDChild (taoDNode *n)=0 |
virtual taoDNode * | getDChild ()=0 |
virtual taoDNode const * | getDChild () const =0 |
virtual taoDNode * | getDSibling ()=0 |
virtual taoDNode const * | getDSibling () const =0 |
virtual deFrame * | frameGlobal ()=0 |
global frame for the dynamics computation More... | |
virtual deFrame const * | frameGlobal () const =0 |
virtual void | getFrameGraphics (deFrame *Fg)=0 |
global frame for graphics display More... | |
virtual void | setID (const deInt id) |
virtual deInt | getID () const |
virtual void | setIsFixed (const deInt f) |
virtual deInt | getIsFixed () |
virtual deFloat | getCOR () |
virtual deFloat | getCOF_grip () |
virtual deFloat | getCOF_viscous () |
virtual deFloat | getCOF_static () |
virtual deFloat | getCOF_dynamic () |
virtual void | setCOR (deFloat c) |
coefficient of restitution More... | |
Private Attributes | |
taoArticulatedBodyLink * | _abNode |
deInt | _propagate |
Coefficients of friction | |
where
| |
deInt | _id |
deInt | _isFixed |
deFloat | _cor |
deFloat | _cofg |
deFloat | _cofv |
deFloat | _cofs |
deFloat | _cofd |
std::string | name_ |
virtual void | setCOF_grip (deFloat c) |
cofg : coefficient of grip friction when v != 0 and y != 0 : f_g = - sign(v_t) * More... | |
virtual void | setCOF_viscous (deFloat c) |
cofv : coefficient of viscous friction when v != 0 : f_v = - v_t * More... | |
virtual void | setCOF_static (deFloat c) |
cofs : coefficient of static friction when v == 0 and a != 0 : f_s = - sign(a_t) * More... | |
virtual void | setCOF_dynamic (deFloat c) |
cofd : coefficient of dynamic friction when v != 0 : f_d = - sign(v_t) * More... | |
virtual deFloat | effectiveMass (const deVector3 *Pie, const deVector3 *Ui) |
virtual void | linearVelocity (deVector3 *Vie, const deVector3 *Pie) |
virtual void | linearAcceleration (deVector3 *Aie, const deVector3 *Pie) |
virtual void | impulse (const deVector3 *Pie, const deVector3 *Yie) |
computes new velocity given impulse More... | |
virtual void | impulseDist (const deVector3 *Pie, const deVector3 *Yie) |
computes new position given pseudo impulse More... | |
virtual void | force (const deVector3 *Pie, const deVector3 *Fie) |
computes new force given force More... | |
virtual deInt | impact1 (const deVector3 *Pie, const deVector3 *Ui, const deFloat cor2, const deFloat cofg2) |
computes new velocity and force given pos, vel, acc More... | |
virtual deInt | impact2 (taoDNode *ni, const deVector3 *Pie, const deVector3 *Ui, taoDNode *nj, const deVector3 *Pje, const deVector3 *Uj) |
This method computes impulse/force and changes velocity/friction between two colliding nodes, ni and nj. More... | |
virtual deInt | penetration1 (const deVector3 *Pie, const deVector3 *Ui, const deVector3 *pdist, const deFloat dt) |
This method computes impulse and changes position/orientation using impulseDist() . More... | |
deInt | _Impact1 (const deVector3 *Pie, const deVector3 *Ui, const deVector3 *V, const deFloat m, const deFloat vp, const deFloat vm, const deFloat cofg2) |
void | _Friction (const deVector3 *Pie, const deVector3 *Ui, const deVector3 *Ut, const deFloat vtmag, const deFloat m) |
abstract node class for articulated body
A dynamics node = {Articulated Body Link + Set of associated Joints}.
This class should be used as a base class and implemented accordingly.
|
inline |
Copied from CNode
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
pure virtual |
fext | accumulate all external forces |
Implemented in taoNodeRoot, and taoNode.
computes new force given force
This method replaces the accumulated force with the given force.
Pie
- contact point expressed in local frame. Fie
- force at the contact point expressed in local frame. Reimplemented in taoNode.
|
pure virtual |
global frame for the dynamics computation
Implemented in taoNodeRoot, and taoNode.
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
inlinevirtual |
gets _abNode
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
pure virtual |
global frame for graphics display
Fg | is filled with the frame info for graphics sync. |
Implemented in taoNodeRoot, and taoNode.
|
inlinevirtual |
indicates if dynamics of node should be included for control
1 | to propagate dynamics of node for control |
0 | not to propagate dynamics of node for control |
|
virtual |
computes new velocity and force given pos, vel, acc
Pie
- contact point expressed in local frame. Ui
- unit contact direction vector expressed in local frame (outward normal vector) cor2
- coefficient of restitution of the other collision node. cof2
- coefficient of grip friction of the other collision node.
|
virtual |
This method computes impulse/force and changes velocity/friction between two colliding nodes, ni and nj.
Pie
- contact point expressed in frame i : Pie = ^iP_e - ^iP_i
Pje
- contact point expressed in frame j : Pje = ^jP_e - ^jP_j
Ui
- unit contact direction vector expressed in frame i : Ui = (^iP_j - ^iP_i)/|^iP_j - ^iP_i|
Uj
- Ui
expressed in frame j computes new velocity given impulse
This method changes velocity instantaneously by applying the given impulse.
Pie
- contact point expressed in local frame. Yie
- impulse at the contact point expressed in local frame. Reimplemented in taoNode.
computes new position given pseudo impulse
This method changes position and orientation instantaneously by applying the given pseudo impulse.
Pie
- contact point expressed in local frame. Yie
- pseudo impulse at the contact point expressed in local frame. Reimplemented in taoNode.
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
inlinevirtual |
indicates if parent of this node is root
1 | parent this node is root |
0 | parent this node in not root |
|
inlinevirtual |
indicates if this node is root
1 | this node is root |
0 | this node in not root |
|
pure virtual |
Implemented in taoNodeRoot, and taoNode.
|
virtual |
This method computes impulse and changes position/orientation using impulseDist()
.
Pie
- contact point expressed in local frame. Ui
- unit contact direction vector expressed in local frame (outward normal vector). pdist
- penetration distance vector : pdist = P_o - P_i
dt
- integration time step.
|
inlinevirtual |
sets _abNode
|
inlinevirtual |
cofd
: coefficient of dynamic friction when v != 0
: f_d = - sign(v_t) *
cofd
* f_n
|
inlinevirtual |
cofg
: coefficient of grip friction when v != 0
and y != 0
: f_g = - sign(v_t) *
cofg
* y_n
|
inlinevirtual |
cofs
: coefficient of static friction when v == 0
and a != 0
: f_s = - sign(a_t) *
cofs
* f_n
|
inlinevirtual |
cofv
: coefficient of viscous friction when v != 0
: f_v = - v_t *
cofv
|
inlinevirtual |
coefficient of restitution