NLMech  0.1.0
material::pd::BaseMaterial Class Reference

A base class providing methods to compute energy density and force. More...

#include <baseMaterial.h>

Inheritance diagram for material::pd::BaseMaterial:
Inheritance graph
Collaboration diagram for material::pd::BaseMaterial:
Collaboration graph

Public Member Functions

 BaseMaterial (const size_t &dim, const double &horizon)
 Constructor. More...
 
virtual std::pair< util::Point3, double > getBondEF (size_t i, size_t j)
 Returns energy and force between bond. More...
 
virtual util::Point3 getBondForceDirection (const util::Point3 &dx, const util::Point3 &du) const
 Get direction of bond force. More...
 
double getDensity () const
 Returns the density of the material. More...
 
double getHorizon () const
 Returns horizon. More...
 
virtual double getInfFn (const double &r) const
 Returns the value of influence function. More...
 
virtual double getS (const util::Point3 &dx, const util::Point3 &du)
 Returns the bond strain. More...
 
virtual double getS (size_t i, size_t j)
 Returns the bond strain. More...
 
virtual double getSc (const double &r)
 Returns critical bond strain. More...
 
virtual double getSc (size_t i, size_t j)
 Returns critical bond strain. More...
 
virtual util::Matrix33 getStrain (size_t i)
 Returns strain tensor. More...
 
virtual util::Matrix33 getStress (size_t i)
 Returns stress tensor. More...
 
bool isStateActive () const
 Returns true if state-based potential is active. More...
 
std::string name () const
 Returns name of the material. More...
 
virtual void print (int nt=0, int lvl=0) const
 Prints the information about the instance of the object. More...
 
virtual std::string printStr (int nt=0, int lvl=0) const
 Returns the string containing information about the instance of the object. More...
 
virtual void update ()
 Let the material class in the quasi-static case know that there is a new loading step.
 

Private Attributes

double d_density
 Density.
 
size_t d_dimension
 Dimension.
 
double d_horizon
 Horizon.
 
std::string d_name
 Name of material.
 
bool d_stateActive
 Flag indicating if peridynamic state potential is active.
 

Detailed Description

A base class providing methods to compute energy density and force.

This is a base class which provides method to compute pairwise energy and force, as well as hydrostatic force and energy.

Constructor & Destructor Documentation

◆ BaseMaterial()

material::pd::BaseMaterial::BaseMaterial ( const size_t &  dim,
const double &  horizon 
)
inline

Constructor.

Parameters
dimDimension
horizonHorizon

Member Function Documentation

◆ getBondEF()

virtual std::pair<util::Point3,double> material::pd::BaseMaterial::getBondEF ( size_t  i,
size_t  j 
)
inlinevirtual

Returns energy and force between bond.

Parameters
iId of node 1
jLocal id in the neighborlist of node i
Returns
pair Pair of energy and force

Reimplemented in material::pd::RNPBond, and material::pd::ElasticState.

Referenced by model::QuasiStaticModel< T >::computePertubatedForces().

Here is the caller graph for this function:

◆ getBondForceDirection()

virtual util::Point3 material::pd::BaseMaterial::getBondForceDirection ( const util::Point3 dx,
const util::Point3 du 
) const
inlinevirtual

Get direction of bond force.

Parameters
dxRelative bond vector (reference configuration)
duRelative bond displacement vector
Returns
vector Unit vector along the bond force

Reimplemented in material::pd::ElasticState, and material::pd::RNPBond.

◆ getDensity()

double material::pd::BaseMaterial::getDensity ( ) const
inline

Returns the density of the material.

Returns
density Density of the material

◆ getHorizon()

double material::pd::BaseMaterial::getHorizon ( ) const
inline

Returns horizon.

Returns
horizon Horizon

◆ getInfFn()

virtual double material::pd::BaseMaterial::getInfFn ( const double &  r) const
inlinevirtual

Returns the value of influence function.

Parameters
rReference (initial) bond length
Returns
value Influence function at r

Reimplemented in material::pd::RNPBond, and material::pd::ElasticState.

◆ getS() [1/2]

virtual double material::pd::BaseMaterial::getS ( const util::Point3 dx,
const util::Point3 du 
)
inlinevirtual

Returns the bond strain.

Parameters
dxReference bond vector
duDifference of displacement
Returns
strain Bond strain

Reimplemented in material::pd::RNPBond.

◆ getS() [2/2]

virtual double material::pd::BaseMaterial::getS ( size_t  i,
size_t  j 
)
inlinevirtual

Returns the bond strain.

Parameters
iId of node 1
jId of node 2
Returns
strain Bond strain

Reimplemented in material::pd::RNPBond.

◆ getSc() [1/2]

virtual double material::pd::BaseMaterial::getSc ( const double &  r)
inlinevirtual

Returns critical bond strain.

Parameters
rReference length of bond
Returns
strain Critical strain

Reimplemented in material::pd::RNPBond.

◆ getSc() [2/2]

virtual double material::pd::BaseMaterial::getSc ( size_t  i,
size_t  j 
)
inlinevirtual

Returns critical bond strain.

Parameters
iId of node 1
jId of node 2
Returns
strain Critical strain

Reimplemented in material::pd::RNPBond, and material::pd::ElasticState.

◆ getStrain()

virtual util::Matrix33 material::pd::BaseMaterial::getStrain ( size_t  i)
inlinevirtual

Returns strain tensor.

Parameters
iId of node
Returns
strain tensor

Reimplemented in material::pd::ElasticState.

◆ getStress()

virtual util::Matrix33 material::pd::BaseMaterial::getStress ( size_t  i)
inlinevirtual

Returns stress tensor.

Parameters
iId of node
Returns
stress tensor

Reimplemented in material::pd::ElasticState.

◆ isStateActive()

bool material::pd::BaseMaterial::isStateActive ( ) const
inline

Returns true if state-based potential is active.

Returns
bool True/false

◆ name()

std::string material::pd::BaseMaterial::name ( ) const
inline

Returns name of the material.

Returns
string Name

◆ print()

virtual void material::pd::BaseMaterial::print ( int  nt = 0,
int  lvl = 0 
) const
inlinevirtual

Prints the information about the instance of the object.

Parameters
ntNumber of tabs to append before each line of string
lvlLevel of information sought (higher level means more information)
Here is the call graph for this function:

◆ printStr()

virtual std::string material::pd::BaseMaterial::printStr ( int  nt = 0,
int  lvl = 0 
) const
inlinevirtual

Returns the string containing information about the instance of the object.

Parameters
ntNumber of tabs to append before each line of string
lvlLevel of information sought (higher level means more information)
Returns
string String containing information about this object

Referenced by print().

Here is the caller graph for this function:

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