AbstractTwoBodyInteractionForce< DIM > Class Template Reference

#include <AbstractTwoBodyInteractionForce.hpp>

Inherits AbstractForce< DIM >.

Inherited by BuskeAdhesiveForce< DIM >, BuskeElasticForce< DIM >, GeneralisedLinearSpringForce< DIM >, and GeneralisedLinearSpringForce< 2 >.

Collaboration diagram for AbstractTwoBodyInteractionForce< DIM >:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 AbstractTwoBodyInteractionForce ()
bool GetUseCutOffLength ()
void SetCutOffLength (double cutOffLength)
double GetCutOffLength ()
virtual c_vector< double, DIM > CalculateForceBetweenNodes (unsigned nodeAGlobalIndex, unsigned nodeBGlobalIndex, AbstractCellPopulation< DIM > &rCellPopulation)=0
void AddForceContribution (std::vector< c_vector< double, DIM > > &rForces, AbstractCellPopulation< DIM > &rCellPopulation)
virtual void OutputForceParameters (out_stream &rParamsFile)

Protected Attributes

bool mUseCutOffLength
double mMechanicsCutOffLength

Private Member Functions

template<class Archive >
void serialize (Archive &archive, const unsigned int version)

Friends

class boost::serialization::access

Detailed Description

template<unsigned DIM>
class AbstractTwoBodyInteractionForce< DIM >

An abstract class for two-body force laws.

Definition at line 39 of file AbstractTwoBodyInteractionForce.hpp.


Constructor & Destructor Documentation

template<unsigned DIM>
AbstractTwoBodyInteractionForce< DIM >::AbstractTwoBodyInteractionForce (  )  [inline]

Constructor.

Definition at line 32 of file AbstractTwoBodyInteractionForce.cpp.


Member Function Documentation

template<unsigned DIM>
void AbstractTwoBodyInteractionForce< DIM >::AddForceContribution ( std::vector< c_vector< double, DIM > > &  rForces,
AbstractCellPopulation< DIM > &  rCellPopulation 
) [inline, virtual]

Overridden AddForceContribution() method.

Parameters:
rForces reference to vector of forces on nodes
rCellPopulation reference to the cell population

Implements AbstractForce< DIM >.

Reimplemented in RepulsionForce< DIM >, and LinearSpringWithVariableSpringConstantsForce< DIM >.

Definition at line 60 of file AbstractTwoBodyInteractionForce.cpp.

References AbstractTwoBodyInteractionForce< DIM >::CalculateForceBetweenNodes(), EXCEPTION, MeshBasedCellPopulation< DIM >::SpringsBegin(), and MeshBasedCellPopulation< DIM >::SpringsEnd().

template<unsigned DIM>
virtual c_vector<double, DIM> AbstractTwoBodyInteractionForce< DIM >::CalculateForceBetweenNodes ( unsigned  nodeAGlobalIndex,
unsigned  nodeBGlobalIndex,
AbstractCellPopulation< DIM > &  rCellPopulation 
) [pure virtual]

Calculates the force between two nodes.

Note that this assumes they are connected and is called by rCalculateVelocitiesOfEachNode()

Parameters:
nodeAGlobalIndex index of one neighbouring node
nodeBGlobalIndex index of the other neighbouring node
rCellPopulation the cell population
Returns:
The force exerted on Node A by Node B.

Implemented in BuskeAdhesiveForce< DIM >, BuskeElasticForce< DIM >, GeneralisedLinearSpringForce< DIM >, and GeneralisedLinearSpringForce< 2 >.

Referenced by AbstractTwoBodyInteractionForce< DIM >::AddForceContribution().

template<unsigned DIM>
double AbstractTwoBodyInteractionForce< DIM >::GetCutOffLength (  )  [inline]
template<unsigned DIM>
bool AbstractTwoBodyInteractionForce< DIM >::GetUseCutOffLength (  )  [inline]

Whether the force is using a cut of length.

Returns:
mUseCutOffLength

Definition at line 40 of file AbstractTwoBodyInteractionForce.cpp.

References AbstractTwoBodyInteractionForce< DIM >::mUseCutOffLength.

template<unsigned DIM>
void AbstractTwoBodyInteractionForce< DIM >::OutputForceParameters ( out_stream &  rParamsFile  )  [inline, virtual]
template<unsigned DIM>
template<class Archive >
void AbstractTwoBodyInteractionForce< DIM >::serialize ( Archive &  archive,
const unsigned int  version 
) [inline, private]
template<unsigned DIM>
void AbstractTwoBodyInteractionForce< DIM >::SetCutOffLength ( double  cutOffLength  )  [inline]

Use a cutoff point, ie specify zero force if two cells are greater than the cutoff distance apart.

Parameters:
cutOffLength the cutoff to use

Definition at line 46 of file AbstractTwoBodyInteractionForce.cpp.

References AbstractTwoBodyInteractionForce< DIM >::mMechanicsCutOffLength, and AbstractTwoBodyInteractionForce< DIM >::mUseCutOffLength.


Friends And Related Function Documentation

template<unsigned DIM>
friend class boost::serialization::access [friend]

Member Data Documentation

template<unsigned DIM>
double AbstractTwoBodyInteractionForce< DIM >::mMechanicsCutOffLength [protected]
template<unsigned DIM>
bool AbstractTwoBodyInteractionForce< DIM >::mUseCutOffLength [protected]

The documentation for this class was generated from the following files:
Generated on Thu Dec 22 13:01:30 2011 for Chaste by  doxygen 1.6.3