NodeRigidBodyEP

A 3D rigid body node based on Euler parameters for rigid bodies or beams; the node has 3 displacement coordinates (representing displacement of reference point \(\LU{0}{{\mathbf{r}}}\)) and four rotation coordinates (Euler parameters = unit quaternions).

Additional information for NodeRigidBodyEP:

  • This Node has/provides the following types = Position, Orientation, RigidBody, RotationEulerParameters
  • Short name for Python = RigidEP
  • Short name for Python visualization object = VRigidEP

The item NodeRigidBodyEP with type = ‘RigidBodyEP’ has the following parameters:

  • name [type = String, default = ‘’]:
    node’s unique name
  • referenceCoordinates [\({\mathbf{q}}\cRef = [q_0,\,q_1,\,q_2,\,\psi_0,\,\psi_1,\,\psi_2,\,\psi_3]\tp\cRef = [{\mathbf{p}}\tp\cRef,\,\tpsi\tp\cRef]\tp\), type = Vector7D, size = 7, default = [0.,0.,0., 0.,0.,0.,0.]]:
    reference coordinates (3 position coordinates and 4 Euler parameters) of node ==> e.g. ref. coordinates for finite elements or reference position of rigid body (e.g. for definition of joints)
  • initialCoordinates [\({\mathbf{q}}\cIni = [q_0,\,q_1,\,q_2,\,\psi_0,\,\psi_1,\,\psi_2,\,\psi_3]\tp\cIni = [{\mathbf{u}}\tp\cIni,\,\tpsi\tp\cIni]\tp\), type = Vector7D, size = 7, default = [0.,0.,0., 0.,0.,0.,0.]]:
    initial displacement coordinates and 4 Euler parameters relative to reference coordinates
  • initialVelocities [\(\dot {\mathbf{q}}\cIni = [\dot q_0,\,\dot q_1,\,\dot q_2,\,\dot \psi_0,\,\dot \psi_1,\,\dot \psi_2,\,\dot \psi_3]\tp\cIni = [\dot {\mathbf{u}}\tp\cIni,\,\dot \tpsi\tp\cIni]\tp\), type = Vector7D, size = 7, default = [0.,0.,0., 0.,0.,0.,0.]]:
    initial velocity coordinates: time derivatives of initial displacements and Euler parameters
  • addConstraintEquation [type = Bool, default = True]:
    True: automatically add Euler parameter constraint for node; False: Euler parameter constraint is not added, must be done manually (e.g., with CoordinateVectorConstraint)
  • visualization [type = VNodeRigidBodyEP]:
    parameters for visualization of item

The item VNodeRigidBodyEP has the following parameters:

  • show [type = Bool, default = True]:
    set true, if item is shown in visualization and false if it is not shown
  • drawSize [type = float, default = -1.]:
    drawing size (diameter, dimensions of underlying cube, etc.) for item; size == -1.f means that default size is used
  • color [type = Float4, size = 4, default = [-1.,-1.,-1.,-1.]]:
    Default RGBA color for nodes; 4th value is alpha-transparency; R=-1.f means, that default color is used

DESCRIPTION of NodeRigidBodyEP

The following output variables are available as OutputVariableType in sensors, Get…Output() and other functions:

  • Position: \(\LU{0}{{\mathbf{p}}}\cConfig = \LU{0}{[p_0,\,p_1,\,p_2]}\cConfig\tp= \LU{0}{{\mathbf{u}}}\cConfig + \LU{0}{{\mathbf{p}}}\cRef\)
    global 3D position vector of node; \({\mathbf{u}}\cRef=0\)
  • Displacement: \(\LU{0}{{\mathbf{u}}}\cConfig = [q_0,\,q_1,\,q_2]\cConfig\tp\)
    global 3D displacement vector of node
  • Velocity: \(\LU{0}{{\mathbf{v}}}\cConfig = [\dot q_0,\,\dot q_1,\,\dot q_2]\cConfig\tp\)
    global 3D velocity vector of node
  • Acceleration: \(\LU{0}{{\mathbf{a}}}\cConfig = [\ddot q_0,\,\ddot q_1,\,\ddot q_2]\cConfig\tp\)
    global 3D acceleration vector of node
  • Coordinates: \({\mathbf{c}}\cConfig = [q_0,\,q_1,\,q_2, \,\psi_0,\,\psi_1,\,\psi_2,\,\psi_3]\tp\cConfig\)
    coordinate vector of node, having 3 displacement coordinates and 4 Euler parameters
  • Coordinates\_t: \(\dot{\mathbf{c}}\cConfig = [\dot q_0,\,\dot q_1,\,\dot q_2, \,\dot \psi_0,\,\dot \psi_1,\,\dot \psi_2,\,\dot \psi_3]\tp\cConfig\)
    velocity coordinates vector of node
  • Coordinates\_tt: \(\ddot{\mathbf{c}}\cConfig = [\ddot q_0,\,\ddot q_1,\,\ddot q_2, \,\ddot \psi_0,\,\ddot \psi_1,\,\ddot \psi_2,\,\ddot \psi_3]\tp\cConfig\)
    acceleration coordinates vector of node
  • RotationMatrix: \([A_{00},\,A_{01},\,A_{02},\,A_{10},\,\ldots,\,A_{21},\,A_{22}]\cConfig\tp\)
    vector with 9 components of the rotation matrix \(\LU{0b}{\Rot}\cConfig\) in row-major format, in any configuration; the rotation matrix transforms local (\(b\)) to global (0) coordinates
  • Rotation: \([\varphi_0,\,\varphi_1,\,\varphi_2]\tp\cConfig\)
    vector with 3 components of the Euler/Tait-Bryan angles in xyz-sequence (\(\LU{0b}{\Rot}\cConfig=:\Rot_0(\varphi_0) \cdot \Rot_1(\varphi_1) \cdot \Rot_2(\varphi_2)\)), recomputed from rotation matrix
  • AngularVelocity: \(\LU{0}{\tomega}\cConfig = \LU{0}{[\omega_0,\,\omega_1,\,\omega_2]}\cConfig\tp\)
    global 3D angular velocity vector of node
  • AngularVelocityLocal: \(\LU{b}{\tomega}\cConfig = \LU{b}{[\omega_0,\,\omega_1,\,\omega_2]}\cConfig\tp\)
    local (body-fixed) 3D angular velocity vector of node
  • AngularAcceleration: \(\LU{0}{\talpha}\cConfig = \LU{0}{[\alpha_0,\,\alpha_1,\,\alpha_2]}\cConfig\tp\)
    global 3D angular acceleration vector of node

Detailed information: All coordinates \({\mathbf{c}}\cConfig\) lead to second order differential equations. The first 3 equations are residuals of translational forces in global coordinates, while the last 4 equations are residual of local torques left-multiplied with \(\LU{b}{{\mathbf{G}}\tp}\) or global torques left-multiplied with \(\LU{0}{{\mathbf{G}}\tp}\), see Eq. (45), compare the equations of motion of the rigid body.

There is one additional (algebraic) constraint equation for the quaternions. The additional constraint equation, which needs to be provided by the object, reads

\[1 - \sum_{i=0}^{3} \theta_i^2 = 0.\]

The rotation matrix \(\LU{0b}{\Rot}\cConfig\) transforms a local (body-fixed) 3D position \(\pLocB = \LU{b}{[b_0,\,b_1,\,b_2]}\tp\) to global 3D positions,

\[\LU{0}{\pLoc}\cConfig = \LU{0b}{\Rot}\cConfig \LU{b}{\pLoc}\]

Note that the Euler parameters \(\ttheta\cCur\) are computed as sum of current coordinates plus reference coordinates,

\[\ttheta\cCur = \tpsi\cCur + \tpsi\cRef.\]

The rotation matrix is defined as function of the rotation parameters \(\ttheta=[\theta_0,\,\theta_1,\,\theta_2,\,\theta_3]\tp\)

\[\LU{0b}{\Rot} = \mr{-2\theta_3^2 - 2\theta_2^2+1}{-2\theta_3\theta_0+2\theta_2\theta_1}{2*\theta_3\theta_1+2*\theta_2\theta_0} {2\theta_3\theta_0+2\theta_2\theta_1}{-2\theta_3^2-2\theta_1^2+1}{2\theta_3\theta_2-2\theta_1\theta_0} {-2\theta_2\theta_0+2\theta_3\theta_1}{2\theta_3\theta_2+2\theta_1\theta_0}{-2\theta_2^2-2\theta_1^2+1}\]

The derivatives of the angular velocity vectors w.r.t.the rotation velocity coordinates \(\dot \ttheta=[\dot \theta_0,\,\dot \theta_1,\,\dot \theta_2,\,\dot \theta_3]\tp\) lead to the \({\mathbf{G}}\) matrices, as used in the equations of motion for rigid bodies,

(45)\[\begin{split}\LU{0}{\tomega} &=& \LU{0}{{\mathbf{G}}} \dot \ttheta, \\ \LU{b}{\tomega} &=& \LU{b}{{\mathbf{G}}} \dot \ttheta.\end{split}\]

For creating a NodeRigidBodyEP together with a rigid body, there is a rigidBodyUtilities function AddRigidBody, see Section Function: AddRigidBody, which simplifies the setup of a rigid body significantely!

Relevant Examples and TestModels with weblink:

The web version may not be complete. For details, consider also the Exudyn PDF documentation : theDoc.pdf