sofa::component::forcefield::ConstantForceField< DataTypes > Class Template Reference

Apply constant forces to given degrees of freedom. More...

#include <ConstantForceField.h>

Inheritance diagram for sofa::component::forcefield::ConstantForceField< DataTypes >:

Inheritance graph
[legend]
Collaboration diagram for sofa::component::forcefield::ConstantForceField< DataTypes >:

Collaboration graph
[legend]

Public Types

typedef
core::componentmodel::behavior::ForceField
< DataTypes > 
Inherit
typedef DataTypes::VecCoord VecCoord
typedef DataTypes::VecDeriv VecDeriv
typedef DataTypes::Coord Coord
typedef DataTypes::Deriv Deriv
typedef Coord::value_type Real
typedef helper::vector< unsigned > VecIndex

Public Member Functions

 ConstantForceField ()
virtual void addForce (VecDeriv &f, const VecCoord &x, const VecDeriv &v)
 Add the forces.
virtual void addDForce (VecDeriv &, const VecDeriv &)
 Constant force has null variation.
virtual double getPotentialEnergy (const VecCoord &x)
 Get the potential energy associated to this ForceField.
void draw ()
 Render internal data of this object, for debugging purposes.
bool addBBox (double *minBBox, double *maxBBox)
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.
template<>
double getPotentialEnergy (const VecCoord &)
 Get the potential energy associated to this ForceField.

Data Fields

Data< VecIndex > points
Data< VecDeriv > forces

Detailed Description

template<class DataTypes>
class sofa::component::forcefield::ConstantForceField< DataTypes >

Apply constant forces to given degrees of freedom.

Definition at line 44 of file ConstantForceField.h.


Member Typedef Documentation

template<class DataTypes >
typedef DataTypes::Coord sofa::component::forcefield::ConstantForceField< DataTypes >::Coord

template<class DataTypes >
typedef DataTypes::Deriv sofa::component::forcefield::ConstantForceField< DataTypes >::Deriv

Definition at line 47 of file ConstantForceField.h.

template<class DataTypes >
typedef Coord::value_type sofa::component::forcefield::ConstantForceField< DataTypes >::Real

template<class DataTypes >
typedef DataTypes::VecCoord sofa::component::forcefield::ConstantForceField< DataTypes >::VecCoord

template<class DataTypes >
typedef DataTypes::VecDeriv sofa::component::forcefield::ConstantForceField< DataTypes >::VecDeriv

template<class DataTypes >
typedef helper::vector<unsigned> sofa::component::forcefield::ConstantForceField< DataTypes >::VecIndex

Definition at line 53 of file ConstantForceField.h.


Constructor & Destructor Documentation

template<class DataTypes >
sofa::component::forcefield::ConstantForceField< DataTypes >::ConstantForceField (  )  [inline]

Definition at line 50 of file ConstantForceField.inl.


Member Function Documentation

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

Definition at line 122 of file ConstantForceField.inl.

template<class DataTypes >
virtual void sofa::component::forcefield::ConstantForceField< DataTypes >::addDForce ( VecDeriv &  ,
const VecDeriv &   
) [inline, virtual]

Constant force has null variation.

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

Definition at line 65 of file ConstantForceField.h.

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

template<class DataTypes >
void sofa::component::forcefield::ConstantForceField< DataTypes >::draw (  )  [inline, virtual]

template<>
double sofa::component::forcefield::ConstantForceField< defaulttype::Rigid2fTypes >::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::forcefield::ConstantForceField< defaulttype::Rigid3fTypes >::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::forcefield::ConstantForceField< defaulttype::Rigid2dTypes >::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::forcefield::ConstantForceField< defaulttype::Rigid3dTypes >::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::forcefield::ConstantForceField< Rigid2fTypes >::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 101 of file ConstantForceField.cpp.

template<>
double sofa::component::forcefield::ConstantForceField< Rigid3fTypes >::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 94 of file ConstantForceField.cpp.

template<>
double sofa::component::forcefield::ConstantForceField< Rigid2dTypes >::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 85 of file ConstantForceField.cpp.

template<>
double sofa::component::forcefield::ConstantForceField< Rigid3dTypes >::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 79 of file ConstantForceField.cpp.

template<class DataTypes >
double sofa::component::forcefield::ConstantForceField< DataTypes >::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 71 of file ConstantForceField.inl.

References sofa::component::forcefield::ConstantForceField< DataTypes >::forces, and sofa::component::forcefield::ConstantForceField< DataTypes >::points.


Field Documentation


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

Generated on Sun Nov 23 04:18:41 2008 for Sofa by  doxygen 1.5.7.1