sofa::component::mass::UniformMass< DataTypes, MassType > Class Template Reference

#include <UniformMass.h>

Inheritance diagram for sofa::component::mass::UniformMass< DataTypes, MassType >:

Inheritance graph
[legend]
Collaboration diagram for sofa::component::mass::UniformMass< DataTypes, MassType >:

Collaboration graph
[legend]

Public Types

typedef
core::componentmodel::behavior::Mass
< DataTypes > 
Inherited
typedef DataTypes::VecCoord VecCoord
typedef DataTypes::VecDeriv VecDeriv
typedef DataTypes::Coord Coord
typedef DataTypes::Deriv Deriv
typedef Coord::value_type Real

Public Member Functions

 UniformMass ()
 ~UniformMass ()
void setMass (const MassType &mass)
const MassType & getMass () const
double getTotalMass () const
void setTotalMass (double m)
virtual void parse (core::objectmodel::BaseObjectDescription *arg)
 Parse the given description to assign values to this object's fields and potentially other parameters.
void init ()
 Initialization method called at graph modification, during bottom-up traversal.
void addMDx (VecDeriv &f, const VecDeriv &dx, double factor=1.0)
 f += factor M dx
void accFromF (VecDeriv &a, const VecDeriv &f)
 dx = M^-1 f
void addForce (VecDeriv &f, const VecCoord &x, const VecDeriv &v)
 Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.
double getKineticEnergy (const VecDeriv &v)
 vMv/2 using dof->getV()
double getPotentialEnergy (const VecCoord &x)
 Mgx potential in a uniform gravity field, null at origin.
void addMDxToVector (defaulttype::BaseVector *resVect, const VecDeriv *dx, SReal mFact, unsigned int &offset)
void addGravityToV (double dt)
 perform v += dt*g operation. Used if mass wants to added G separately from the other forces to v.
void addMToMatrix (defaulttype::BaseMatrix *mat, double mFact, unsigned int &offset)
 Add Mass contribution to global Matrix assembling.
double getElementMass (unsigned int index)
 return the mass relative to the DOF index
void draw ()
 Render internal data of this object, for debugging purposes.
bool addBBox (double *minBBox, double *maxBBox)
template<>
void parse (core::objectmodel::BaseObjectDescription *arg)
 Parse the given description to assign values to this object's fields and potentially other parameters.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
double getPotentialEnergy (const Rigid3dTypes::VecCoord &x)
template<>
double getPotentialEnergy (const Rigid2dTypes::VecCoord &x)
template<>
double getElementMass (unsigned int)
 return the mass relative to the DOF index
template<>
sofa::defaulttype::Vector3::value_type getElementMass (unsigned int)
 return the mass relative to the DOF index
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void addMDxToVector (defaulttype::BaseVector *resVect, const VecDeriv *dx, double mFact, unsigned int &offset)
template<>
void parse (core::objectmodel::BaseObjectDescription *arg)
 Parse the given description to assign values to this object's fields and potentially other parameters.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
double getPotentialEnergy (const Rigid3fTypes::VecCoord &x)
template<>
double getPotentialEnergy (const Rigid2fTypes::VecCoord &x)
template<>
double getElementMass (unsigned int)
 return the mass relative to the DOF index
template<>
double getElementMass (unsigned int)
 return the mass relative to the DOF index
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void addMDxToVector (defaulttype::BaseVector *resVect, const VecDeriv *dx, SReal mFact, unsigned int &offset)
template<>
void parse (core::objectmodel::BaseObjectDescription *arg)
 Parse the given description to assign values to this object's fields and potentially other parameters.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void parse (core::objectmodel::BaseObjectDescription *arg)
 Parse the given description to assign values to this object's fields and potentially other parameters.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void addMDx (VecDeriv &res, const VecDeriv &dx, double factor)
 f += factor M dx
template<>
void accFromF (VecDeriv &a, const VecDeriv &f)
 dx = M^-1 f
template<>
void addForce (VecDeriv &f, const VecCoord &, const VecDeriv &)
 Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.
template<>
bool addBBox (double *minBBox, double *maxBBox)
template<>
double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
template<>
double getElementMass (unsigned int)
 return the mass relative to the DOF index
template<>
void draw ()
 Render internal data of this object, for debugging purposes.
template<>
void addMDx (VecDeriv &res, const VecDeriv &dx, double factor)
 f += factor M dx
template<>
void accFromF (VecDeriv &a, const VecDeriv &f)
 dx = M^-1 f
template<>
void addForce (VecDeriv &f, const VecCoord &, const VecDeriv &)
 Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.
template<>
bool addBBox (double *minBBox, double *maxBBox)
template<>
void addMDx (VecDeriv &res, const VecDeriv &dx, double factor)
 f += factor M dx
template<>
void accFromF (VecDeriv &a, const VecDeriv &f)
 dx = M^-1 f
template<>
void addForce (VecDeriv &f, const VecCoord &, const VecDeriv &)
 Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.
template<>
bool addBBox (double *minBBox, double *maxBBox)
template<>
void addMDx (VecDeriv &res, const VecDeriv &dx, double factor)
 f += factor M dx
template<>
void accFromF (VecDeriv &a, const VecDeriv &f)
 dx = M^-1 f
template<>
void addForce (VecDeriv &f, const VecCoord &, const VecDeriv &)
 Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.
template<>
bool addBBox (double *minBBox, double *maxBBox)
template<>
double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
template<>
double getElementMass (unsigned int)
 return the mass relative to the DOF index
template<>
void draw ()
 Render internal data of this object, for debugging purposes.

Data Fields

Data< MassType > mass
 the mass of each particle
Data< double > totalMass
 if >0 : total mass of this body
Data< bool > showCenterOfGravity
 to display the center of gravity of the system
Data< float > showAxisSize

Detailed Description

template<class DataTypes, class MassType>
class sofa::component::mass::UniformMass< DataTypes, MassType >

Definition at line 46 of file UniformMass.h.


Member Typedef Documentation

template<class DataTypes , class MassType >
typedef DataTypes::Coord sofa::component::mass::UniformMass< DataTypes, MassType >::Coord

Reimplemented from sofa::core::componentmodel::behavior::Mass< DataTypes >.

Definition at line 52 of file UniformMass.h.

template<class DataTypes , class MassType >
typedef DataTypes::Deriv sofa::component::mass::UniformMass< DataTypes, MassType >::Deriv

Reimplemented from sofa::core::componentmodel::behavior::Mass< DataTypes >.

Definition at line 53 of file UniformMass.h.

template<class DataTypes , class MassType >
typedef core::componentmodel::behavior::Mass<DataTypes> sofa::component::mass::UniformMass< DataTypes, MassType >::Inherited

Definition at line 49 of file UniformMass.h.

template<class DataTypes , class MassType >
typedef Coord::value_type sofa::component::mass::UniformMass< DataTypes, MassType >::Real

Definition at line 54 of file UniformMass.h.

template<class DataTypes , class MassType >
typedef DataTypes::VecCoord sofa::component::mass::UniformMass< DataTypes, MassType >::VecCoord

Reimplemented from sofa::core::componentmodel::behavior::Mass< DataTypes >.

Definition at line 50 of file UniformMass.h.

template<class DataTypes , class MassType >
typedef DataTypes::VecDeriv sofa::component::mass::UniformMass< DataTypes, MassType >::VecDeriv

Reimplemented from sofa::core::componentmodel::behavior::Mass< DataTypes >.

Definition at line 51 of file UniformMass.h.


Constructor & Destructor Documentation

template<class DataTypes , class MassType >
sofa::component::mass::UniformMass< DataTypes, MassType >::UniformMass (  )  [inline]

Definition at line 54 of file UniformMass.inl.

template<class DataTypes , class MassType >
sofa::component::mass::UniformMass< DataTypes, MassType >::~UniformMass (  )  [inline]

Definition at line 62 of file UniformMass.inl.


Member Function Documentation

template<>
void sofa::component::mass::UniformMass< CudaVec3f1Types, float >::accFromF ( VecDeriv &  a,
const VecDeriv &  f 
) [inline, virtual]

template<>
void sofa::component::mass::UniformMass< CudaVec3fTypes, float >::accFromF ( VecDeriv &  a,
const VecDeriv &  f 
) [inline, virtual]

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaVec3f1Types, float >::accFromF ( VecDeriv &  a,
const VecDeriv &  f 
) [inline, virtual]

dx = M^-1 f

This method must be implemented by the component.

Implements sofa::core::componentmodel::behavior::Mass< DataTypes >.

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaVec3fTypes, float >::accFromF ( VecDeriv &  a,
const VecDeriv &  f 
) [inline, virtual]

dx = M^-1 f

This method must be implemented by the component.

Implements sofa::core::componentmodel::behavior::Mass< DataTypes >.

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::accFromF ( VecDeriv &  a,
const VecDeriv &  f 
) [inline, virtual]

template<>
bool sofa::component::mass::UniformMass< gpu::cuda::CudaVec3f1Types, float >::addBBox ( double *  minBBox,
double *  maxBBox 
) [inline]

template<>
bool sofa::component::mass::UniformMass< gpu::cuda::CudaVec3fTypes, float >::addBBox ( double *  minBBox,
double *  maxBBox 
) [inline]

template<>
bool sofa::component::mass::UniformMass< gpu::cuda::CudaVec3f1Types, float >::addBBox ( double *  minBBox,
double *  maxBBox 
) [inline]

template<>
bool sofa::component::mass::UniformMass< gpu::cuda::CudaVec3fTypes, float >::addBBox ( double *  minBBox,
double *  maxBBox 
) [inline]

template<class DataTypes , class MassType >
bool sofa::component::mass::UniformMass< DataTypes, MassType >::addBBox ( double *  minBBox,
double *  maxBBox 
) [inline]

template<>
void sofa::component::mass::UniformMass< CudaVec3f1Types, float >::addForce ( VecDeriv &  f,
const VecCoord &  x,
const VecDeriv &  v 
) [inline, virtual]

Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.

If the ForceField can be represented as a matrix, this method computes $ f += B v + K x $

This method must be implemented by the component, and is usually called by the generic ForceField::addForce() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

Definition at line 120 of file CudaUniformMass.inl.

References sofa::core::objectmodel::BaseObject::getContext(), sofa::core::objectmodel::Data< T >::getValue(), sofa::component::mass::UniformMass< DataTypes, MassType >::mass, and sofa::gpu::cuda::UniformMassCuda3f1_addForce().

template<>
void sofa::component::mass::UniformMass< CudaVec3fTypes, float >::addForce ( VecDeriv &  f,
const VecCoord &  x,
const VecDeriv &  v 
) [inline, virtual]

Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.

If the ForceField can be represented as a matrix, this method computes $ f += B v + K x $

This method must be implemented by the component, and is usually called by the generic ForceField::addForce() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

Definition at line 79 of file CudaUniformMass.inl.

References sofa::core::objectmodel::BaseObject::getContext(), sofa::core::objectmodel::Data< T >::getValue(), sofa::component::mass::UniformMass< DataTypes, MassType >::mass, and sofa::gpu::cuda::UniformMassCuda3f_addForce().

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaVec3f1Types, float >::addForce ( VecDeriv &  f,
const VecCoord &  x,
const VecDeriv &  v 
) [inline, virtual]

Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.

If the ForceField can be represented as a matrix, this method computes $ f += B v + K x $

This method must be implemented by the component, and is usually called by the generic ForceField::addForce() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaVec3fTypes, float >::addForce ( VecDeriv &  f,
const VecCoord &  x,
const VecDeriv &  v 
) [inline, virtual]

Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.

If the ForceField can be represented as a matrix, this method computes $ f += B v + K x $

This method must be implemented by the component, and is usually called by the generic ForceField::addForce() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::addForce ( VecDeriv &  f,
const VecCoord &  x,
const VecDeriv &  v 
) [inline, virtual]

Given the current position and velocity states, update the current force vector by computing and adding the forces associated with this ForceField.

If the ForceField can be represented as a matrix, this method computes $ f += B v + K x $

This method must be implemented by the component, and is usually called by the generic ForceField::addForce() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

Definition at line 140 of file UniformMass.inl.

References sofa::core::componentmodel::behavior::inertiaForce().

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::addGravityToV ( double  dt  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< CudaVec3f1Types, float >::addMDx ( VecDeriv &  f,
const VecDeriv &  dx,
double  factor 
) [inline, virtual]

template<>
void sofa::component::mass::UniformMass< CudaVec3fTypes, float >::addMDx ( VecDeriv &  f,
const VecDeriv &  dx,
double  factor 
) [inline, virtual]

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaVec3f1Types, float >::addMDx ( VecDeriv &  f,
const VecDeriv &  dx,
double  factor 
) [inline, virtual]

f += factor M dx

This method must be implemented by the component.

Implements sofa::core::componentmodel::behavior::Mass< DataTypes >.

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaVec3fTypes, float >::addMDx ( VecDeriv &  f,
const VecDeriv &  dx,
double  factor 
) [inline, virtual]

f += factor M dx

This method must be implemented by the component.

Implements sofa::core::componentmodel::behavior::Mass< DataTypes >.

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::addMDx ( VecDeriv &  f,
const VecDeriv &  dx,
double  factor = 1.0 
) [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Vec3fTypes, float >::addMDxToVector ( defaulttype::BaseVector *  resVect,
const VecDeriv *  dx,
SReal  mFact,
unsigned int &  offset 
) [inline]

template<>
void sofa::component::mass::UniformMass< Vec3dTypes, double >::addMDxToVector ( defaulttype::BaseVector *  resVect,
const VecDeriv *  dx,
double  mFact,
unsigned int &  offset 
) [inline]

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::addMDxToVector ( defaulttype::BaseVector *  resVect,
const VecDeriv *  dx,
SReal  mFact,
unsigned int &  offset 
) [inline]

Definition at line 114 of file UniformMass.inl.

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::addMToMatrix ( defaulttype::BaseMatrix *  mat,
double  mFact,
unsigned int &  offset 
) [inline, virtual]

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaRigid3fTypes, Rigid3fMass >::draw (  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< gpu::cuda::CudaRigid3fTypes, Rigid3fMass >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Vec6fTypes, float >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Rigid2fTypes, Rigid2fMass >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Vec6dTypes, double >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Rigid2dTypes, Rigid2dMass >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::draw (  )  [inline, virtual]

Render internal data of this object, for debugging purposes.

Reimplemented from sofa::core::objectmodel::BaseObject.

template<>
void sofa::component::mass::UniformMass< Vec6fTypes, float >::draw (  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Rigid2fTypes, Rigid2fMass >::draw (  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::draw (  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Vec6dTypes, double >::draw (  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Rigid2dTypes, Rigid2dMass >::draw (  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::draw (  )  [inline, virtual]

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::draw (  )  [inline, virtual]

template<>
double sofa::component::mass::UniformMass< gpu::cuda::CudaRigid3fTypes, sofa::defaulttype::Rigid3fMass >::getElementMass ( unsigned  index  )  [inline, virtual]

template<>
double sofa::component::mass::UniformMass< gpu::cuda::CudaRigid3fTypes, sofa::defaulttype::Rigid3fMass >::getElementMass ( unsigned  index  )  [inline, virtual]

return the mass relative to the DOF index

Implements sofa::core::componentmodel::behavior::BaseMass.

template<>
double sofa::component::mass::UniformMass< Rigid2fTypes, Rigid2fMass >::getElementMass ( unsigned  index  )  [inline, virtual]

template<>
double sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::getElementMass ( unsigned  index  )  [inline, virtual]

template<>
sofa::defaulttype::Vector3::value_type sofa::component::mass::UniformMass< Rigid2dTypes, Rigid2dMass >::getElementMass ( unsigned  index  )  [inline, virtual]

template<>
double sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::getElementMass ( unsigned  index  )  [inline, virtual]

template<class DataTypes , class MassType >
double sofa::component::mass::UniformMass< DataTypes, MassType >::getElementMass ( unsigned int  index  )  [inline, virtual]

template<class DataTypes , class MassType >
double sofa::component::mass::UniformMass< DataTypes, MassType >::getKineticEnergy ( const VecDeriv &  v  )  [inline, virtual]

template<class DataTypes , class MassType >
const MassType& sofa::component::mass::UniformMass< DataTypes, MassType >::getMass (  )  const [inline]

template<>
double sofa::component::mass::UniformMass< gpu::cuda::CudaRigid3fTypes, sofa::defaulttype::Rigid3fMass >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

Get the potential energy associated to this ForceField.

Used to extimate the total energy of the system by some post-stabilization techniques.

This method must be implemented by the component, and is usually called by the generic ForceField::getPotentialEnergy() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

Definition at line 149 of file CudaUniformMass.inl.

References sofa::core::objectmodel::BaseObject::getContext(), sofa::core::objectmodel::Data< T >::getValue(), and sofa::component::mass::UniformMass< DataTypes, MassType >::mass.

template<>
double sofa::component::mass::UniformMass< gpu::cuda::CudaRigid3fTypes, sofa::defaulttype::Rigid3fMass >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

Get the potential energy associated to this ForceField.

Used to extimate the total energy of the system by some post-stabilization techniques.

This method must be implemented by the component, and is usually called by the generic ForceField::getPotentialEnergy() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<>
double sofa::component::mass::UniformMass< Rigid2fTypes, Rigid2fMass >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

Get the potential energy associated to this ForceField.

Used to extimate the total energy of the system by some post-stabilization techniques.

This method must be implemented by the component, and is usually called by the generic ForceField::getPotentialEnergy() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<>
double sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

Get the potential energy associated to this ForceField.

Used to extimate the total energy of the system by some post-stabilization techniques.

This method must be implemented by the component, and is usually called by the generic ForceField::getPotentialEnergy() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<>
double sofa::component::mass::UniformMass< Rigid2dTypes, Rigid2dMass >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

Get the potential energy associated to this ForceField.

Used to extimate the total energy of the system by some post-stabilization techniques.

This method must be implemented by the component, and is usually called by the generic ForceField::getPotentialEnergy() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<>
double sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

Get the potential energy associated to this ForceField.

Used to extimate the total energy of the system by some post-stabilization techniques.

This method must be implemented by the component, and is usually called by the generic ForceField::getPotentialEnergy() method.

Implements sofa::core::componentmodel::behavior::ForceField< DataTypes >.

template<>
double sofa::component::mass::UniformMass< Rigid2fTypes, Rigid2fMass >::getPotentialEnergy ( const Rigid2fTypes::VecCoord &  x  )  [inline]

template<>
double sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::getPotentialEnergy ( const Rigid3fTypes::VecCoord &  x  )  [inline]

template<>
double sofa::component::mass::UniformMass< Rigid2dTypes, Rigid2dMass >::getPotentialEnergy ( const Rigid2dTypes::VecCoord &  x  )  [inline]

template<>
double sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::getPotentialEnergy ( const Rigid3dTypes::VecCoord &  x  )  [inline]

template<class DataTypes , class MassType >
double sofa::component::mass::UniformMass< DataTypes, MassType >::getPotentialEnergy ( const VecCoord &  x  )  [inline, virtual]

template<class DataTypes , class MassType >
double sofa::component::mass::UniformMass< DataTypes, MassType >::getTotalMass (  )  const [inline]

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::init ( void   )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::parse ( core::objectmodel::BaseObjectDescription *  arg  )  [inline, virtual]

Parse the given description to assign values to this object's fields and potentially other parameters.

Reimplemented from sofa::core::objectmodel::Base.

template<>
void sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::parse ( core::objectmodel::BaseObjectDescription *  arg  )  [inline, virtual]

Parse the given description to assign values to this object's fields and potentially other parameters.

Reimplemented from sofa::core::objectmodel::Base.

template<>
void sofa::component::mass::UniformMass< Rigid3fTypes, Rigid3fMass >::parse ( core::objectmodel::BaseObjectDescription *  arg  )  [inline, virtual]

template<>
void sofa::component::mass::UniformMass< Rigid3dTypes, Rigid3dMass >::parse ( core::objectmodel::BaseObjectDescription *  arg  )  [inline, virtual]

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::parse ( core::objectmodel::BaseObjectDescription *  arg  )  [inline, virtual]

Parse the given description to assign values to this object's fields and potentially other parameters.

Reimplemented from sofa::core::objectmodel::Base.

Definition at line 294 of file UniformMass.inl.

References sofa::core::objectmodel::Base::parse().

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::setMass ( const MassType &  mass  )  [inline]

template<class DataTypes , class MassType >
void sofa::component::mass::UniformMass< DataTypes, MassType >::setTotalMass ( double  m  )  [inline]


Field Documentation

template<class DataTypes , class MassType >
Data<MassType> sofa::component::mass::UniformMass< DataTypes, MassType >::mass

template<class DataTypes , class MassType >
Data< float > sofa::component::mass::UniformMass< DataTypes, MassType >::showAxisSize

template<class DataTypes , class MassType >
Data< bool > sofa::component::mass::UniformMass< DataTypes, MassType >::showCenterOfGravity

to display the center of gravity of the system

Definition at line 60 of file UniformMass.h.

Referenced by sofa::component::mass::UniformMass< DataTypes, MassType >::draw().

template<class DataTypes , class MassType >
Data<double> sofa::component::mass::UniformMass< DataTypes, MassType >::totalMass


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

Generated on Sun Nov 23 04:21:14 2008 for Sofa by  doxygen 1.5.7.1