ESyS-Particle  2.3.4
CRotBondedInteraction Class Reference

Elastic interaction between bonded particles between rotational particles. More...

#include <RotBondedInteraction.h>

Inheritance diagram for CRotBondedInteraction:
Collaboration diagram for CRotBondedInteraction:

Public Types

typedef CRotBondedIGP ParameterType
 
typedef BondedInteractionCpData CheckPointable
 
typedef double(CRotBondedInteraction::* ScalarFieldFunction) () const
 
typedef pair< bool, double >(CRotBondedInteraction::* CheckedScalarFieldFunction) () const
 
typedef Vec3(CRotBondedInteraction::* VectorFieldFunction) () const
 

Public Member Functions

 CRotBondedInteraction ()
 
 CRotBondedInteraction (CRotParticle *, CRotParticle *, const CRotBondedIGP &)
 
virtual ~CRotBondedInteraction ()
 
int getTag () const
 
void setTag (int tag)
 
void calcForces ()
 
bool broken ()
 
double getPotentialEnergy () const
 
double getNormalPotentialEnergy () const
 
double getShearPotentialEnergy () const
 
double getTwistPotentialEnergy () const
 
double getBendPotentialEnergy () const
 
double getCriterion () const
 
Vec3 getForce () const
 
Vec3 getNormalForce () const
 
Vec3 getTangentialForce () const
 
virtual Vec3 getPos () const
 
Vec3 getCentrePtDiff () const
 
Vec3 getInitialCentrePtDiff () const
 
Vec3 getInitialMidPoint () const
 
Vec3 getP2ShearForcePt () const
 
Vec3 getP1ShearForcePt () const
 
Vec3 getContactPoint () const
 
Vec3 getShearDiff () const
 
virtual void saveCheckPointData (std::ostream &oStream)
 
virtual void loadCheckPointData (std::istream &iStream)
 
virtual void saveRestartData (std::ostream &oStream)
 
virtual void loadRestartData (std::istream &iStream)
 
- Public Member Functions inherited from ARotPairInteraction
 ARotPairInteraction ()
 
 ARotPairInteraction (CRotParticle *, CRotParticle *)
 
virtual ~ARotPairInteraction ()
 
const CParticlefirst () const
 
const CParticlesecond () const
 
CRotParticlefirst ()
 
CRotParticlesecond ()
 
pair< int, int > getPairID () const
 
void checkIDs ()
 
virtual bool hasTag (int, int) const
 
virtual Vec3 getPosFirst () const
 
virtual Vec3 getPosSecond () const
 
void setPP (CRotParticle *, CRotParticle *)
 
void setPP (const vector< CRotParticle * >)
 
esys::lsm::quintuple< Vec3, double, Vec3, double, Vec3getRaw2Data () const
 
virtual void calcHeatTrans ()
 
virtual void calcHeatFrict ()
 
- Public Member Functions inherited from AInteraction
 AInteraction ()
 
virtual ~AInteraction ()
 
bool initialized () const
 
vector< int > getAllID () const
 
int getID ()
 
double Count () const
 

Static Public Member Functions

static ScalarFieldFunction getScalarFieldFunction (const string &)
 
static CheckedScalarFieldFunction getCheckedScalarFieldFunction (const string &)
 
static VectorFieldFunction getVectorFieldFunction (const string &)
 
static string getType ()
 

Private Attributes

double m_dist
 current distance, cached from last calcForces() More...
 
double m_r0
 equilibrium separation More...
 
double m_kr
 spring constant More...
 
double m_ks
 
double m_kb
 
double m_kt
 
double m_max_nForce
 
double m_max_shForce
 
double m_max_tMoment
 
double m_max_bMoment
 
double m_nForce
 
double m_shForce
 
double m_tMoment
 
double m_bMoment
 
Vec3 m_force
 current force, cached for E_pot calculation More...
 
Vec3 m_moment
 
Vec3 m_cpos
 
Vec3 m_D
 initial positions of the particles More...
 
int m_tag
 
bool m_scaling
 
bool m_meanR_scaling
 
double m_truncated
 
double m_beta1
 
double m_beta2
 

Friends

class TML_PackedMessageInterface
 
ostream & operator<< (ostream &, const CRotBondedInteraction &)
 

Additional Inherited Members

- Protected Attributes inherited from ARotPairInteraction
CRotParticlem_p1
 
CRotParticlem_p2
 
- Protected Attributes inherited from AInteraction
vector< int > m_id
 id's of the particles involved More...
 
int m_iid
 interaction id More...
 
bool m_init
 

Detailed Description

Elastic interaction between bonded particles between rotational particles.

Author
Shane Latham, Steffen Abe $Revision$ $Date$

Member Typedef Documentation

◆ CheckedScalarFieldFunction

typedef pair<bool,double>(CRotBondedInteraction::* CRotBondedInteraction::CheckedScalarFieldFunction) () const

◆ CheckPointable

Used by PIS to save/load check-point data for objects of this type.

◆ ParameterType

◆ ScalarFieldFunction

typedef double(CRotBondedInteraction::* CRotBondedInteraction::ScalarFieldFunction) () const

◆ VectorFieldFunction

typedef Vec3(CRotBondedInteraction::* CRotBondedInteraction::VectorFieldFunction) () const

Constructor & Destructor Documentation

◆ CRotBondedInteraction() [1/2]

◆ CRotBondedInteraction() [2/2]

◆ ~CRotBondedInteraction()

CRotBondedInteraction::~CRotBondedInteraction ( )
virtual

Member Function Documentation

◆ broken()

bool CRotBondedInteraction::broken ( )

Check if the fracture criterion has been exceeded. If so, flag the particles (for the rebuilding of the other interactions) and return "true", so the update of this interaction group can remove the interaction.

References m_beta1, m_beta2, m_bMoment, m_max_bMoment, m_max_nForce, m_max_shForce, m_max_tMoment, m_nForce, ARotPairInteraction::m_p1, ARotPairInteraction::m_p2, m_shForce, m_tMoment, m_truncated, NULL, and CParticle::setFlag().

Here is the call graph for this function:

◆ calcForces()

◆ getBendPotentialEnergy()

double CRotBondedInteraction::getBendPotentialEnergy ( ) const

References m_bMoment, and m_kb.

Referenced by getScalarFieldFunction().

Here is the caller graph for this function:

◆ getCentrePtDiff()

Vec3 CRotBondedInteraction::getCentrePtDiff ( ) const

References CBasicParticle::getPos(), ARotPairInteraction::m_p1, and ARotPairInteraction::m_p2.

Referenced by getContactPoint().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getCheckedScalarFieldFunction()

CRotBondedInteraction::CheckedScalarFieldFunction CRotBondedInteraction::getCheckedScalarFieldFunction ( const string &  name)
static

Get the particle member function which returns a checked scalar field of a given name.

Parameters
namethe name of the field

References NULL.

◆ getContactPoint()

Vec3 CRotBondedInteraction::getContactPoint ( ) const

◆ getCriterion()

double CRotBondedInteraction::getCriterion ( ) const

References m_bMoment, m_max_bMoment, m_max_nForce, m_max_shForce, m_max_tMoment, m_nForce, m_shForce, and m_tMoment.

Referenced by getScalarFieldFunction().

Here is the caller graph for this function:

◆ getForce()

Vec3 CRotBondedInteraction::getForce ( ) const

References m_force.

Referenced by getVectorFieldFunction().

Here is the caller graph for this function:

◆ getInitialCentrePtDiff()

Vec3 CRotBondedInteraction::getInitialCentrePtDiff ( ) const

References CParticle::getInitPos(), ARotPairInteraction::m_p1, and ARotPairInteraction::m_p2.

Referenced by getInitialMidPoint().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getInitialMidPoint()

Vec3 CRotBondedInteraction::getInitialMidPoint ( ) const

References getInitialCentrePtDiff(), CParticle::getInitPos(), CBasicParticle::getRad(), ARotPairInteraction::m_p1, ARotPairInteraction::m_p2, and Vec3::norm().

Referenced by getP1ShearForcePt(), and getP2ShearForcePt().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getNormalForce()

Vec3 CRotBondedInteraction::getNormalForce ( ) const

References CBasicParticle::getPos(), m_force, ARotPairInteraction::m_p1, and ARotPairInteraction::m_p2.

Referenced by getTangentialForce(), and getVectorFieldFunction().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getNormalPotentialEnergy()

double CRotBondedInteraction::getNormalPotentialEnergy ( ) const

References m_kr, and m_nForce.

Referenced by getScalarFieldFunction().

Here is the caller graph for this function:

◆ getP1ShearForcePt()

Vec3 CRotBondedInteraction::getP1ShearForcePt ( ) const

References getInitialMidPoint(), CParticle::getInitPos(), CBasicParticle::getPos(), CRotParticle::getQuat(), ARotPairInteraction::m_p1, and Quaternion::to_matrix().

Referenced by getShearDiff().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getP2ShearForcePt()

Vec3 CRotBondedInteraction::getP2ShearForcePt ( ) const

References getInitialMidPoint(), CParticle::getInitPos(), CBasicParticle::getPos(), CRotParticle::getQuat(), ARotPairInteraction::m_p2, and Quaternion::to_matrix().

Referenced by getShearDiff().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getPos()

virtual Vec3 CRotBondedInteraction::getPos ( ) const
inlinevirtual

Implements ARotPairInteraction.

References m_cpos.

◆ getPotentialEnergy()

double CRotBondedInteraction::getPotentialEnergy ( ) const

References m_bMoment, m_kb, m_kr, m_ks, m_kt, m_nForce, m_shForce, and m_tMoment.

Referenced by getScalarFieldFunction().

Here is the caller graph for this function:

◆ getScalarFieldFunction()

CRotBondedInteraction::ScalarFieldFunction CRotBondedInteraction::getScalarFieldFunction ( const string &  name)
static

Get the particle member function which returns a scalar field of a given name.

Parameters
namethe name of the field

References AInteraction::Count(), getBendPotentialEnergy(), getCriterion(), getNormalPotentialEnergy(), getPotentialEnergy(), getShearPotentialEnergy(), getTwistPotentialEnergy(), and NULL.

Here is the call graph for this function:

◆ getShearDiff()

Vec3 CRotBondedInteraction::getShearDiff ( ) const

References getP1ShearForcePt(), getP2ShearForcePt(), CBasicParticle::getPos(), and ARotPairInteraction::m_p1.

Here is the call graph for this function:

◆ getShearPotentialEnergy()

double CRotBondedInteraction::getShearPotentialEnergy ( ) const

References m_ks, and m_shForce.

Referenced by getScalarFieldFunction().

Here is the caller graph for this function:

◆ getTag()

int CRotBondedInteraction::getTag ( ) const

References m_tag.

Referenced by saveRestartData().

Here is the caller graph for this function:

◆ getTangentialForce()

Vec3 CRotBondedInteraction::getTangentialForce ( ) const

References getNormalForce(), and m_force.

Referenced by getVectorFieldFunction().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTwistPotentialEnergy()

double CRotBondedInteraction::getTwistPotentialEnergy ( ) const

References m_kt, and m_tMoment.

Referenced by getScalarFieldFunction().

Here is the caller graph for this function:

◆ getType()

static string CRotBondedInteraction::getType ( )
inlinestatic

◆ getVectorFieldFunction()

CRotBondedInteraction::VectorFieldFunction CRotBondedInteraction::getVectorFieldFunction ( const string &  name)
static

Get the particle member function which returns a vector field of a given name.

Parameters
namethe name of the field

References getForce(), getNormalForce(), getTangentialForce(), and NULL.

Here is the call graph for this function:

◆ loadCheckPointData()

void CRotBondedInteraction::loadCheckPointData ( std::istream &  iStream)
virtual

◆ loadRestartData()

void CRotBondedInteraction::loadRestartData ( std::istream &  iStream)
virtual

load restart data from stream

Parameters
iStreamthe input stream

Reimplemented from ARotPairInteraction.

References m_beta1, m_beta2, m_D, AInteraction::m_id, AInteraction::m_init, m_kb, m_kr, m_ks, m_kt, m_max_bMoment, m_max_nForce, m_max_shForce, m_max_tMoment, m_meanR_scaling, m_scaling, m_truncated, and setTag().

Here is the call graph for this function:

◆ saveCheckPointData()

void CRotBondedInteraction::saveCheckPointData ( std::ostream &  oStream)
virtual

References BondedInteractionCpData::saveCheckPointData().

Here is the call graph for this function:

◆ saveRestartData()

void CRotBondedInteraction::saveRestartData ( std::ostream &  oStream)
virtual

save restart data to ostream

Parameters
oStreamthe output stream

Reimplemented from ARotPairInteraction.

References getTag(), m_beta1, m_beta2, m_D, AInteraction::m_id, AInteraction::m_init, m_kb, m_kr, m_ks, m_kt, m_max_bMoment, m_max_nForce, m_max_shForce, m_max_tMoment, m_meanR_scaling, m_scaling, and m_truncated.

Here is the call graph for this function:

◆ setTag()

void CRotBondedInteraction::setTag ( int  tag)

References m_tag.

Referenced by loadRestartData().

Here is the caller graph for this function:

Friends And Related Function Documentation

◆ operator<<

ostream& operator<< ( ostream &  ost,
const CRotBondedInteraction BI 
)
friend

◆ TML_PackedMessageInterface

friend class TML_PackedMessageInterface
friend

Member Data Documentation

◆ m_beta1

◆ m_beta2

◆ m_bMoment

◆ m_cpos

Vec3 CRotBondedInteraction::m_cpos
private

Referenced by calcForces(), and getPos().

◆ m_D

Vec3 CRotBondedInteraction::m_D
private

◆ m_dist

double CRotBondedInteraction::m_dist
private

current distance, cached from last calcForces()

Referenced by calcForces(), and CRotBondedInteraction().

◆ m_force

Vec3 CRotBondedInteraction::m_force
private

current force, cached for E_pot calculation

Referenced by calcForces(), CRotBondedInteraction(), getForce(), getNormalForce(), and getTangentialForce().

◆ m_kb

◆ m_kr

◆ m_ks

◆ m_kt

◆ m_max_bMoment

◆ m_max_nForce

◆ m_max_shForce

◆ m_max_tMoment

◆ m_meanR_scaling

◆ m_moment

Vec3 CRotBondedInteraction::m_moment
private

◆ m_nForce

◆ m_r0

double CRotBondedInteraction::m_r0
private

equilibrium separation

Referenced by CRotBondedInteraction().

◆ m_scaling

◆ m_shForce

◆ m_tag

◆ m_tMoment

◆ m_truncated


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