CellModules
DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t > Class Template Reference

Class for managing Delaunay triangulation and mass-spring-based physics. More...

#include <BodyDelaunayMassSpringDamper.hpp>

Inheritance diagram for DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >:
MecaCell::Movable BaseBody< plugin_t >

Public Member Functions

 BodyDelaunayMassSpringDamper (const MecaCell::Vector3D &pos=MecaCell::Vector3D::zero())
 Constructor. More...
 
double getBoundingBoxRadius () const
 Gets the bounding box radius. More...
 
void setRadius (double rad)
 Sets the radius. More...
 
double getRadius ()
 Gets the radius. More...
 
double getBaseRadius () const
 Gets the base radius. More...
 
void setBaseRadius (double _baseRadius)
 Sets the base radius. More...
 
void growth (double delta)
 Increases the radius so that the volume is multiplied by 1 + delta. More...
 
void setDensity (double d)
 Sets the density. More...
 
double getAdhesion () const
 Gets the adhesion coefficient. More...
 
void setAdhesion (double a)
 Sets the adhesion coefficient. More...
 
void moveTo (const MecaCell::Vec &v)
 Moves a cell to position v. More...
 
bool isMovementEnabled ()
 
void disableMovement ()
 
void enableMovement ()
 
Vec getPosition () const
 
Vec getPrevposition () const
 
Vec getVelocity () const
 
Vec getForce () const
 
double getMass () const
 
void setPosition (const Vec &p)
 
void setPrevposition (const Vec &p)
 
void setVelocity (const Vec &v)
 
void setForce (const Vec &f)
 
void setMass (const double m)
 
void receiveForce (const double &intensity, const Vec &direction, const bool &compressive)
 
void receiveForce (const Vec &f)
 
void resetVelocity ()
 
void resetForce ()
 
void setCellPlugin (plugin_t *_cellPlugin)
 
void onCellPluginLinking ()
 

Protected Attributes

Vec position = Vec::zero()
 
Vec prevposition = Vec::zero()
 
Vec velocity = Vec::zero()
 
Vec force = Vec::zero()
 
bool movementEnabled = true
 
double mass = Config::DEFAULT_CELL_MASS
 
double totalForce = 0
 
plugin_t * cellPlugin
 

Private Attributes

double baseRadius
 
double radius
 
double density
 
double adhesion
 

Detailed Description

template<typename cell_t, class plugin_t>
class DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >

Class for managing Delaunay triangulation and mass-spring-based physics.

Template Parameters
cell_tType of the cell.
plugin_tType of the plugin.

Definition at line 33 of file BodyDelaunayMassSpringDamper.hpp.

Constructor & Destructor Documentation

◆ BodyDelaunayMassSpringDamper()

template<typename cell_t , class plugin_t >
DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::BodyDelaunayMassSpringDamper ( const MecaCell::Vector3D pos = MecaCell::Vector3D::zero())
inlineexplicit

Constructor.

Initializes the radius to 10 µm and the density to the water density.

Parameters
posInitial position of the body.

Definition at line 49 of file BodyDelaunayMassSpringDamper.hpp.

Member Function Documentation

◆ disableMovement()

void MecaCell::Movable::disableMovement ( )
inlineinherited

Definition at line 24 of file movable.h.

◆ enableMovement()

void MecaCell::Movable::enableMovement ( )
inlineinherited

Definition at line 25 of file movable.h.

◆ getAdhesion()

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::getAdhesion ( ) const
inline

Gets the adhesion coefficient.

Returns
Adhesion coefficient.

Definition at line 121 of file BodyDelaunayMassSpringDamper.hpp.

◆ getBaseRadius()

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::getBaseRadius ( ) const
inline

Gets the base radius.

Returns
Base radius.

Definition at line 87 of file BodyDelaunayMassSpringDamper.hpp.

◆ getBoundingBoxRadius()

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::getBoundingBoxRadius ( ) const
inline

Gets the bounding box radius.

Returns
Radius.

Definition at line 62 of file BodyDelaunayMassSpringDamper.hpp.

◆ getForce()

Vec MecaCell::Movable::getForce ( ) const
inlineinherited

Definition at line 29 of file movable.h.

◆ getMass()

double MecaCell::Movable::getMass ( ) const
inlineinherited

Definition at line 30 of file movable.h.

◆ getPosition()

Vec MecaCell::Movable::getPosition ( ) const
inlineinherited

Definition at line 26 of file movable.h.

◆ getPrevposition()

Vec MecaCell::Movable::getPrevposition ( ) const
inlineinherited

Definition at line 27 of file movable.h.

◆ getRadius()

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::getRadius ( )
inline

Gets the radius.

Returns
Radius.

Definition at line 80 of file BodyDelaunayMassSpringDamper.hpp.

◆ getVelocity()

Vec MecaCell::Movable::getVelocity ( ) const
inlineinherited

Definition at line 28 of file movable.h.

◆ growth()

template<typename cell_t , class plugin_t >
void DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::growth ( double  delta)
inline

Increases the radius so that the volume is multiplied by 1 + delta.

Parameters
deltaVolume augmentation ratio.

Definition at line 101 of file BodyDelaunayMassSpringDamper.hpp.

◆ isMovementEnabled()

bool MecaCell::Movable::isMovementEnabled ( )
inlineinherited

Definition at line 23 of file movable.h.

◆ moveTo()

template<typename cell_t , class plugin_t >
void DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::moveTo ( const MecaCell::Vec v)
inline

Moves a cell to position v.

Parameters
vPosition vector.

Definition at line 133 of file BodyDelaunayMassSpringDamper.hpp.

◆ onCellPluginLinking()

void BaseBody< plugin_t >::onCellPluginLinking ( )
inlineinherited

Definition at line 15 of file BaseBody.hpp.

◆ receiveForce() [1/2]

void MecaCell::Movable::receiveForce ( const double &  intensity,
const Vec direction,
const bool &  compressive 
)
inlineinherited

Definition at line 39 of file movable.h.

◆ receiveForce() [2/2]

void MecaCell::Movable::receiveForce ( const Vec f)
inlineinherited

Definition at line 44 of file movable.h.

◆ resetForce()

void MecaCell::Movable::resetForce ( )
inlineinherited

Definition at line 46 of file movable.h.

◆ resetVelocity()

void MecaCell::Movable::resetVelocity ( )
inlineinherited

Definition at line 45 of file movable.h.

◆ setAdhesion()

template<typename cell_t , class plugin_t >
void DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::setAdhesion ( double  a)
inline

Sets the adhesion coefficient.

Parameters
aAdhesion coefficient.

Definition at line 127 of file BodyDelaunayMassSpringDamper.hpp.

◆ setBaseRadius()

template<typename cell_t , class plugin_t >
void DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::setBaseRadius ( double  _baseRadius)
inline

Sets the base radius.

Parameters
_baseRadiusBase radius.

Definition at line 94 of file BodyDelaunayMassSpringDamper.hpp.

◆ setCellPlugin()

void BaseBody< plugin_t >::setCellPlugin ( plugin_t *  _cellPlugin)
inlineinherited

Definition at line 14 of file BaseBody.hpp.

◆ setDensity()

template<typename cell_t , class plugin_t >
void DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::setDensity ( double  d)
inline

Sets the density.

Changes the mass knowing the current radius.

Parameters
dDensity.

Definition at line 112 of file BodyDelaunayMassSpringDamper.hpp.

◆ setForce()

void MecaCell::Movable::setForce ( const Vec f)
inlineinherited

Definition at line 34 of file movable.h.

◆ setMass()

void MecaCell::Movable::setMass ( const double  m)
inlineinherited

Definition at line 35 of file movable.h.

◆ setPosition()

void MecaCell::Movable::setPosition ( const Vec p)
inlineinherited

Definition at line 31 of file movable.h.

◆ setPrevposition()

void MecaCell::Movable::setPrevposition ( const Vec p)
inlineinherited

Definition at line 32 of file movable.h.

◆ setRadius()

template<typename cell_t , class plugin_t >
void DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::setRadius ( double  rad)
inline

Sets the radius.

Changes the mass knowing the current density.

Parameters
radRadius.

Definition at line 71 of file BodyDelaunayMassSpringDamper.hpp.

◆ setVelocity()

void MecaCell::Movable::setVelocity ( const Vec v)
inlineinherited

Definition at line 33 of file movable.h.

Member Data Documentation

◆ adhesion

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::adhesion
private

Adhesion coefficient

Definition at line 39 of file BodyDelaunayMassSpringDamper.hpp.

◆ baseRadius

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::baseRadius
private

Radius in µm

Definition at line 36 of file BodyDelaunayMassSpringDamper.hpp.

◆ cellPlugin

plugin_t * BaseBody< plugin_t >::cellPlugin
protectedinherited

Definition at line 9 of file BaseBody.hpp.

◆ density

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::density
private

Density in ng/µm³

Definition at line 38 of file BodyDelaunayMassSpringDamper.hpp.

◆ force

Vec MecaCell::Movable::force = Vec::zero()
protectedinherited

Definition at line 11 of file movable.h.

◆ mass

double MecaCell::Movable::mass = Config::DEFAULT_CELL_MASS
protectedinherited

Definition at line 13 of file movable.h.

◆ movementEnabled

bool MecaCell::Movable::movementEnabled = true
protectedinherited

Definition at line 12 of file movable.h.

◆ position

Vec MecaCell::Movable::position = Vec::zero()
protectedinherited

Definition at line 8 of file movable.h.

◆ prevposition

Vec MecaCell::Movable::prevposition = Vec::zero()
protectedinherited

Definition at line 9 of file movable.h.

◆ radius

template<typename cell_t , class plugin_t >
double DelaunayMassSpringDamper::BodyDelaunayMassSpringDamper< cell_t, plugin_t >::radius
private

Radius in µm

Definition at line 37 of file BodyDelaunayMassSpringDamper.hpp.

◆ totalForce

double MecaCell::Movable::totalForce = 0
protectedinherited

Definition at line 14 of file movable.h.

◆ velocity

Vec MecaCell::Movable::velocity = Vec::zero()
protectedinherited

Definition at line 10 of file movable.h.


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