ESyS-Particle  2.3.2
CSphereBody Class Reference

base class for spherical non-inertial bodies (similar to simple walls) More...

#include <SphereBody.h>

Collaboration diagram for CSphereBody:

Public Member Functions

 CSphereBody ()
 
 CSphereBody (const Vec3 &, const double &)
 
virtual ~CSphereBody ()
 
void moveBy (const Vec3 &v)
 
void moveTo (const Vec3 &v)
 
void setVel (const Vec3 &v)
 
Vec3 getVel ()
 
const Vec3getCentre () const
 
const double & getRadius () const
 
void addForce (const Vec3 &force)
 
void zeroForce ()
 
const Vec3getForce ()
 
const Vec3getPos ()
 
double getDisplacement ()
 
Vec3 getTotalDisplacement ()
 
void resetDisplacement ()
 
virtual void writeCheckPoint (ostream &, const string &) const
 
virtual void loadCheckPoint (istream &)
 

Protected Attributes

Vec3 m_centre
 
double m_radius
 
Vec3 m_force
 
Vec3 m_oldpos
 
Vec3 m_vel
 

Friends

ostream & operator<< (ostream &, const CSphereBody &)
 

Detailed Description

base class for spherical non-inertial bodies (similar to simple walls)

Author
Dion Weatherley $Revision$ $Date$

Constructor & Destructor Documentation

CSphereBody::CSphereBody ( )

Default constructor. Zeroes all variables. Does not construct a useable sphere body!

References m_centre, m_force, m_oldpos, m_radius, m_vel, and Vec3::ZERO.

CSphereBody::CSphereBody ( const Vec3 c,
const double &  r 
)

constructor

Parameters
cthe centre of the sphere body
rthe radius of the sphere body

References m_centre, m_force, m_oldpos, m_radius, m_vel, and Vec3::ZERO.

virtual CSphereBody::~CSphereBody ( )
inlinevirtual

Member Function Documentation

void CSphereBody::addForce ( const Vec3 force)
inline
const Vec3& CSphereBody::getCentre ( ) const
inline

References m_centre.

double CSphereBody::getDisplacement ( )
inline

Referenced by ASphereBodyInteractionGroup< T >::getDisplacement().

Here is the caller graph for this function:

const Vec3& CSphereBody::getForce ( )
inline

References m_force.

const Vec3& CSphereBody::getPos ( )
inline

References m_centre.

const double& CSphereBody::getRadius ( ) const
inline

References m_radius.

Vec3 CSphereBody::getTotalDisplacement ( )
inline
Vec3 CSphereBody::getVel ( )
inline

References m_vel.

void CSphereBody::loadCheckPoint ( istream &  ist)
virtual

load wall data from a restartable checkpoint

Parameters
istthe input stream from which the checkpoint is read

References m_centre, m_oldpos, and m_radius.

Referenced by TSubLattice< T >::loadCheckPointData().

Here is the caller graph for this function:

void CSphereBody::moveBy ( const Vec3 v)
inline

Referenced by ASphereBodyInteractionGroup< T >::moveSphereBodyBy().

Here is the caller graph for this function:

void CSphereBody::moveTo ( const Vec3 v)
inline
void CSphereBody::resetDisplacement ( )
inline

References m_centre.

Referenced by ASphereBodyInteractionGroup< T >::resetDisplacement().

Here is the caller graph for this function:

void CSphereBody::setVel ( const Vec3 v)
inline
void CSphereBody::writeCheckPoint ( ostream &  ost,
const string &  delim 
) const
virtual

write restartable checkpoint data to an output stream

Parameters
ostthe output stream
delim

References m_centre, m_oldpos, and m_radius.

void CSphereBody::zeroForce ( )
inline

Referenced by ASphereBodyInteractionGroup< T >::zeroForce().

Here is the caller graph for this function:

Friends And Related Function Documentation

ostream& operator<< ( ostream &  ost,
const CSphereBody w 
)
friend

Member Data Documentation

Vec3 CSphereBody::m_force
protected

Referenced by CSphereBody(), and getForce().

Vec3 CSphereBody::m_oldpos
protected
double CSphereBody::m_radius
protected
Vec3 CSphereBody::m_vel
protected

Referenced by CSphereBody(), and getVel().


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