dart
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes | Friends | List of all members
dart::dynamics::SoftBodyNode Class Reference

SoftBodyNode represent a soft body that has one deformable skin. More...

#include <SoftBodyNode.hpp>

Inheritance diagram for dart::dynamics::SoftBodyNode:
Inheritance graph
[legend]
Collaboration diagram for dart::dynamics::SoftBodyNode:
Collaboration graph
[legend]

Public Types

using UniqueProperties = detail::SoftBodyNodeUniqueProperties
 
using Properties = detail::SoftBodyNodeProperties
 
using Base = detail::SoftBodyNodeBase
 
- Public Types inherited from dart::common::EmbedStateAndPropertiesOnTopOf< DerivedT, StateDataT, PropertiesDataT, CompositeBases >
using Impl = EmbedStateAndProperties< DerivedT, StateDataT, PropertiesDataT >
 
using Derived = typename Impl::Derived
 
using AspectStateData = typename Impl::AspectStateData
 
using AspectState = typename Impl::AspectState
 
using AspectPropertiesData = typename Impl::AspectPropertiesData
 
using AspectProperties = typename Impl::AspectProperties
 
using Aspect = typename Impl::Aspect
 
using Base = CompositeJoiner< Impl, CompositeBases... >
 

Public Member Functions

SoftBodyNodeasSoftBodyNode () override
 
const SoftBodyNodeasSoftBodyNode () const override
 
void setProperties (const Properties &_properties)
 Set the Properties of this SoftBodyNode.
 
void setProperties (const UniqueProperties &_properties)
 Set the Properties of this SoftBodyNode.
 
void setAspectState (const AspectState &state)
 Set the AspectState of this SoftBodyNode.
 
void setAspectProperties (const AspectProperties &properties)
 Set the AspectProperties of this SoftBodyNode.
 
Properties getSoftBodyNodeProperties () const
 Get the Properties of this SoftBodyNode.
 
void copy (const SoftBodyNode &_otherSoftBodyNode)
 Copy the Properties of another SoftBodyNode.
 
void copy (const SoftBodyNode *_otherSoftBodyNode)
 Copy the Properties of another SoftBodyNode.
 
SoftBodyNodeoperator= (const SoftBodyNode &_otherSoftBodyNode)
 Copy the Properties of another SoftBodyNode.
 
PointMassNotifiergetNotifier ()
 Get the update notifier for the PointMasses of this SoftBodyNode.
 
const PointMassNotifiergetNotifier () const
 Get the update notifier for the PointMasses of this SoftBodyNode.
 
double getMass () const
 Get mass.
 
void setVertexSpringStiffness (double _kv)
 
double getVertexSpringStiffness () const
 
void setEdgeSpringStiffness (double _ke)
 
double getEdgeSpringStiffness () const
 
void setDampingCoefficient (double _damp)
 
double getDampingCoefficient () const
 
void removeAllPointMasses ()
 
PointMassaddPointMass (const PointMass::Properties &_properties)
 
std::size_t getNumPointMasses () const
 
PointMassgetPointMass (std::size_t _idx)
 
const PointMassgetPointMass (std::size_t _idx) const
 
const std::vector< PointMass * > & getPointMasses () const
 Return all the point masses in this SoftBodyNode.
 
void connectPointMasses (std::size_t _idx1, std::size_t _idx2)
 
void addFace (const Eigen::Vector3i &_face)
 
const Eigen::Vector3i & getFace (std::size_t _idx) const
 
std::size_t getNumFaces () const
 
void clearConstraintImpulse () override
 
- Public Member Functions inherited from dart::common::EmbedStateAndPropertiesOnTopOf< DerivedT, StateDataT, PropertiesDataT, CompositeBases >
template<typename... Args>
 EmbedStateAndPropertiesOnTopOf (Args &&... args)
 

Protected Member Functions

 SoftBodyNode (BodyNode *_parentBodyNode, Joint *_parentJoint, const Properties &_properties)
 Constructor called by Skeleton class.
 
BodyNodeclone (BodyNode *_parentBodyNode, Joint *_parentJoint, bool cloneNodes) const override
 Create a clone of this SoftBodyNode. More...
 
void configurePointMasses (ShapeNode *softNode)
 Used by SoftBodyAspect to have this SoftBodyNode reconstruct its SoftMeshShape.
 
void init (const SkeletonPtr &_skeleton) override
 
void clearExternalForces () override
 
void clearInternalForces () override
 
Recursive dynamics routines
void checkArticulatedInertiaUpdate () const
 Update articulated inertia if necessary.
 
void updateTransform () override
 
void updateVelocity () override
 
void updatePartialAcceleration () const override
 
void updateArtInertia (double _timeStep) const override
 
void updateBiasForce (const Eigen::Vector3d &_gravity, double _timeStep) override
 
void updateBiasImpulse () override
 
void updateAccelerationID () override
 
void updateAccelerationFD () override
 
void updateVelocityChangeFD () override
 
void updateTransmittedForceID (const Eigen::Vector3d &_gravity, bool _withExternalForces=false) override
 
void updateTransmittedForceFD () override
 
void updateTransmittedImpulse () override
 
void updateJointForceID (double _timeStep, bool _withDampingForces, bool _withSpringForces) override
 
void updateJointForceFD (double _timeStep, bool _withDampingForces, bool _withSpringForces) override
 
void updateJointImpulseFD () override
 
void updateConstrainedTerms (double _timeStep) override
 
Equations of motion related routines
void updateMassMatrix () override
 
void aggregateMassMatrix (Eigen::MatrixXd &_MCol, std::size_t _col) override
 
void aggregateAugMassMatrix (Eigen::MatrixXd &_MCol, std::size_t _col, double _timeStep) override
 
void updateInvMassMatrix () override
 
void updateInvAugMassMatrix () override
 
void aggregateInvMassMatrix (Eigen::MatrixXd &_InvMCol, std::size_t _col) override
 
void aggregateInvAugMassMatrix (Eigen::MatrixXd &_InvMCol, std::size_t _col, double _timeStep) override
 
void aggregateCoriolisForceVector (Eigen::VectorXd &_C) override
 
void aggregateGravityForceVector (Eigen::VectorXd &_g, const Eigen::Vector3d &_gravity) override
 
void updateCombinedVector () override
 
void aggregateCombinedVector (Eigen::VectorXd &_Cg, const Eigen::Vector3d &_gravity) override
 
void aggregateExternalForces (Eigen::VectorXd &_Fext) override
 

Protected Attributes

std::vector< PointMass * > mPointMasses
 List of point masses composing deformable mesh.
 
PointMassNotifiermNotifier
 An Entity which tracks when the point masses need to be updated.
 
WeakShapeNodePtr mSoftShapeNode
 Soft mesh shape belonging to this node.
 
math::Inertia mI2
 Generalized inertia with point masses.
 
math::Inertia mArtInertia2
 
math::Inertia mArtInertiaImplicit2
 

Friends

class Skeleton
 
class PointMass
 
class PointMassNotifier
 

Detailed Description

SoftBodyNode represent a soft body that has one deformable skin.

This class is implementation of Sumit Jain and C. Karen Liu's paper: http://www.cc.gatech.edu/graphics/projects/Sumit/homepage/projects/softcontacts/index.html

Member Function Documentation

◆ aggregateInvAugMassMatrix()

void dart::dynamics::SoftBodyNode::aggregateInvAugMassMatrix ( Eigen::MatrixXd &  _InvMCol,
std::size_t  _col,
double  _timeStep 
)
overrideprotected

mPointMasses.at(i)->aggregateInvAugMassMatrix(_InvMCol, _col, _timeStep);

◆ clone()

BodyNode * dart::dynamics::SoftBodyNode::clone ( BodyNode _parentBodyNode,
Joint _parentJoint,
bool  cloneNodes 
) const
overrideprotected

Create a clone of this SoftBodyNode.

This may only be called by the Skeleton class.

◆ updateInvAugMassMatrix()

void dart::dynamics::SoftBodyNode::updateInvAugMassMatrix ( )
overrideprotected

mInvM_c.head<3>() += (*it)->getLocalPosition().cross((*it)->mBiasForceForInvMeta); / mInvM_c.tail<3>() += (*it)->mBiasForceForInvMeta; / }


The documentation for this class was generated from the following files: