PeriDEM 0.2.0
PeriDEM -- Peridynamics-based high-fidelity model for granular media
Loading...
Searching...
No Matches
material::Material Class Referenceabstract

Collection of methods and database related to peridynamic material. More...

#include <material.h>

Inheritance diagram for material::Material:
Collaboration diagram for material::Material:

Public Member Functions

 Material (std::string name="")
 Constructor.
 
virtual ~Material ()
 Destructor.
 
std::string name ()
 Returns name of the material.
 
size_t getDimension ()
 Returns dimension of the problem.
 
bool isPlaneStrain ()
 Returns plane-strain condition.
 
virtual bool isStateActive () const =0
 Returns true if state-based potential is active.
 
virtual std::pair< double, double > getBondEF (const double &r, const double &s, bool &fs, const bool &break_bonds) const =0
 Returns energy and force between bond due to pairwise interaction.
 
virtual std::pair< double, double > getBondEF (const double &r, const double &s, bool &fs, const double &mx, const double &thetax) const =0
 Returns energy and force between bond due to state-based model.
 
virtual util::Point getBondForceDirection (const util::Point &dx, const util::Point &du) const =0
 Returns the unit vector along which bond-force acts.
 
virtual double getS (const util::Point &dx, const util::Point &du) const =0
 Returns the bond strain.
 
virtual double getSc (const double &r) const =0
 Returns critical bond strain.
 
virtual double getDensity () const =0
 Returns the density of the material.
 
virtual double getInfFn (const double &r) const =0
 Returns the value of influence function.
 
virtual double getMoment (const size_t &i) const =0
 Returns the moment of influence function.
 
virtual double getHorizon () const =0
 Returns horizon.
 
virtual inp::MatData computeMaterialProperties (const size_t &dim) const =0
 Computes elastic and fracture material properties and returns the data.
 
virtual std::string printStr (int nt, int lvl) const
 Returns the string containing printable information about the object.
 
virtual void print (int nt, int lvl) const
 Prints the information about the object.
 
virtual void print () const
 Prints the information about the object.
 

Private Attributes

std::string d_name
 Name of the material.
 

Detailed Description

Collection of methods and database related to peridynamic material.

At present we have implemented both bond-based and state-based model. We consider RNP regularized potential proposed and studied in Lipton 2016, Jha and Lipton 2018, Diehl et al 2018, Jha and Lipton 2019. We have also implemented PMB material model (Prototypical micro-elastic brittle material), see Silling 2000.

A class providing methods to compute energy density and force of peridynamic material

Definition at line 76 of file material.h.

Constructor & Destructor Documentation

◆ Material()

material::Material::Material ( std::string  name = "")
inlineexplicit

Constructor.

Parameters
nameName of material model

Definition at line 83 of file material.h.

83: d_name(name) {}
std::string name()
Returns name of the material.
Definition material.h:96
std::string d_name
Name of the material.
Definition material.h:244

◆ ~Material()

virtual material::Material::~Material ( )
inlinevirtual

Destructor.

Make it virtual so that class inheriting from it are destroyed properly.

Definition at line 90 of file material.h.

90{}

Member Function Documentation

◆ computeMaterialProperties()

virtual inp::MatData material::Material::computeMaterialProperties ( const size_t &  dim) const
pure virtual

Computes elastic and fracture material properties and returns the data.

Parameters
dimDimension of the problem
Returns
Data Material data

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getBondEF() [1/2]

virtual std::pair< double, double > material::Material::getBondEF ( const double &  r,
const double &  s,
bool &  fs,
const bool &  break_bonds 
) const
pure virtual

Returns energy and force between bond due to pairwise interaction.

Parameters
rReference (initial) bond length
sBond strain
fsBond fracture state
break_bondsFlag to specify whether bonds are allowed to break or not
Returns
value Pair of energy and force

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getBondEF() [2/2]

virtual std::pair< double, double > material::Material::getBondEF ( const double &  r,
const double &  s,
bool &  fs,
const double &  mx,
const double &  thetax 
) const
pure virtual

Returns energy and force between bond due to state-based model.

Parameters
rReference (initial) bond length
sBond strain
fsBond fracture state
mxWeighted volume at node
thetaxDilation
Returns
value Pair of energy and force

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getBondForceDirection()

virtual util::Point material::Material::getBondForceDirection ( const util::Point dx,
const util::Point du 
) const
pure virtual

Returns the unit vector along which bond-force acts.

Parameters
dxReference bond vector
duDifference of displacement
Returns
vector Unit vector

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getDensity()

virtual double material::Material::getDensity ( ) const
pure virtual

Returns the density of the material.

Returns
density Density of the material

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getDimension()

size_t material::Material::getDimension ( )
inline

Returns dimension of the problem.

Returns
dim Dimension

Definition at line 102 of file material.h.

102{ return dimension; }
size_t dimension
Dimension of the domain.
Definition material.h:26

◆ getHorizon()

virtual double material::Material::getHorizon ( ) const
pure virtual

Returns horizon.

Returns
horizon Horizon

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getInfFn()

virtual double material::Material::getInfFn ( const double &  r) const
pure virtual

Returns the value of influence function.

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

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getMoment()

virtual double material::Material::getMoment ( const size_t &  i) const
pure virtual

Returns the moment of influence function.

If \( J(r) \) is the influence function for \( r\in [0,1)\) then \( i^{th}\) moment is given by

\[ M_i = \int_0^1 J(r) r^i dr. \]

Parameters
iith moment
Returns
value Moment

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getS()

virtual double material::Material::getS ( const util::Point dx,
const util::Point du 
) const
pure virtual

Returns the bond strain.

Parameters
dxReference bond vector
duDifference of displacement
Returns
strain Bond strain \( S = \frac{du \cdot dx}{|dx|^2} \)

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ getSc()

virtual double material::Material::getSc ( const double &  r) const
pure virtual

Returns critical bond strain.

Parameters
rReference length of bond
Returns
strain Critical strain

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ isPlaneStrain()

bool material::Material::isPlaneStrain ( )
inline

Returns plane-strain condition.

Returns
bool True if plane-strain active

Definition at line 108 of file material.h.

108{ return is_plane_strain; }
bool is_plane_strain
Is plane-stress condition active.
Definition material.h:29

◆ isStateActive()

virtual bool material::Material::isStateActive ( ) const
pure virtual

Returns true if state-based potential is active.

Returns
bool True/false

Implemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

◆ name()

std::string material::Material::name ( )
inline

Returns name of the material.

Returns
string Name

Definition at line 96 of file material.h.

96{ return d_name; }

References d_name.

◆ print() [1/2]

virtual void material::Material::print ( ) const
inlinevirtual

Prints the information about the object.

Reimplemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

Definition at line 240 of file material.h.

240{ print(0, 0); }
virtual void print() const
Prints the information about the object.
Definition material.h:240

References print().

Referenced by print().

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

◆ print() [2/2]

virtual void material::Material::print ( int  nt,
int  lvl 
) const
inlinevirtual

Prints the information about the object.

Parameters
ntNumber of tabs to append before printing
lvlInformation level (higher means more information)

Reimplemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

Definition at line 237 of file material.h.

237{ std::cout << printStr(nt, lvl); }
virtual std::string printStr(int nt, int lvl) const
Returns the string containing printable information about the object.
Definition material.h:217

References printStr().

Here is the call graph for this function:

◆ printStr()

virtual std::string material::Material::printStr ( int  nt,
int  lvl 
) const
inlinevirtual

Returns the string containing printable information about the object.

Parameters
ntNumber of tabs to append before printing
lvlInformation level (higher means more information)
Returns
string String containing printable information about the object

Reimplemented in material::RnpMaterial, material::PmbMaterial, material::PdElastic, and material::PdState.

Definition at line 217 of file material.h.

217 {
218
219 auto tabS = util::io::getTabS(nt);
220 std::ostringstream oss;
221 oss << tabS << "------- particle::Material --------" << std::endl
222 << std::endl;
223 oss << tabS << "Abstract class of peridynamic materials" << std::endl;
224 oss << tabS << "See RnpMaterial and PmbMaterial for implementation"
225 << std::endl;
226 oss << tabS << std::endl;
227
228 return oss.str();
229 }
std::string getTabS(int nt)
Returns tab spaces of given size.
Definition io.h:40

References util::io::getTabS().

Referenced by print().

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

Field Documentation

◆ d_name

std::string material::Material::d_name
private

Name of the material.

Definition at line 244 of file material.h.

Referenced by name().


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