micromechanical (C++)
Loading...
Searching...
No Matches
micromechanical::core::ElastoplasticContactLaw< T > Struct Template Referenceabstract

Base class for elastoplastic contact laws. More...

#include <contactlaw.hpp>

Inheritance diagram for micromechanical::core::ElastoplasticContactLaw< T >:
Collaboration diagram for micromechanical::core::ElastoplasticContactLaw< T >:

Public Member Functions

void setPlasticMethod (const std::string &method)
 set the plastic method
 
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > yieldSurfaces (int idx, const Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > &fn, const Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > &fr, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Calculate yield function for multiple times.
 
- Public Member Functions inherited from micromechanical::core::ContactLawBase< T >
 ContactLawBase (const std::map< std::string, T > &props={})
 constructor
 
virtual ~ContactLawBase ()=default
 destructor
 
virtual std::vector< std::string > symmetricContactScalars ()
 Symmetric contact scalar variables.
 
virtual std::vector< std::string > symmetricContactVectors ()
 Symmetric contact vector variables.
 
virtual void initialize (StateVariable< T > &sv)
 initialize the contact law
 
ContactLawBaseoperator= (const ContactLawBase &other)
 move operator
 
frictionCoefficient (int idx, const StateVariable< T > &sv0, const StateVariable< T > &sv)
 calculate the friction coefficient combined with different criteria
 
Eigen::Matrix< T, 3, 3 > forceDisplacement (int idx, Eigen::Matrix< T, 3, 1 > &ddisp, Eigen::Matrix< T, 3, 3 > &Ke, const StateVariable< T > &sv0, StateVariable< T > &sv)
 integrate the force-displacement relation
 
virtual Eigen::Matrix< T, 3, 3 > elasticStiffness (int idx, T fn, const StateVariable< T > &sv0, const StateVariable< T > &sv)=0
 Calculate the elastic stiffness matrix.
 

Public Attributes

std::string plasticMethod = "CPA"
 Plastic method.
 
std::string type = "Elastoplastic"
 Type of the contact law.
 
- Public Attributes inherited from micromechanical::core::ContactLawBase< T >
std::shared_ptr< Material< T > > material
 Material properties.
 
std::string name = "Undefined"
 Name of the contact law.
 
std::string type = "Undefined"
 Type of the contact law.
 
int nstatev_custom = 0
 Number of custom state variables.
 
bool plastic_displacement = false
 Flag to save the plastic displacement in the state variables.
 
std::shared_ptr< Options< T > > options = std::shared_ptr<Options<T>>(new Options<T>())
 options for the micromechanical model
 
std::shared_ptr< DebugVariable< T > > debugVariable = std::shared_ptr<DebugVariable<T>>(new DebugVariable<T>())
 debug variable
 
int _phase = 0
 index of the phase
 
int _step = 0
 current step
 
int _mixedLoad = 0
 number of mixed load steps
 
int _integration = 0
 number of integration steps
 
int _increment = 0
 number of contact increments
 
int _plasticCorrection = 0
 number of contact plastic corrections
 

Protected Member Functions

bool isExplicit () const
 check if the plastic method is explicit
 
bool isCPA () const
 check if the plastic method is CPA
 
bool isCPPM () const
 check if the plastic method is CPPM
 
Eigen::Matrix< T, 3, 3 > integrate (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const Eigen::Matrix< T, 3, 3 > &Ke, const StateVariable< T > &sv0, StateVariable< T > &sv) override
 integrate the force-displacement contact law, with a number of increments.
 
Eigen::Matrix< T, 3, 3 > stiffness (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv) override
 calculate the elastoplastic stiffness matrix
 
virtual bool isConverged (int idx, T f, bool trial, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Determine whether the contact force state is converged to the yield surface or the force state is in the elastic region.
 
virtual T plasticModulus (int idx, const Eigen::Matrix< T, 3, 3 > &Ke, const Eigen::Matrix< T, 3, 1 > &dfdforce, const Eigen::Matrix< T, 3, 1 > &dgdforce, T hardening, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Calculate the plastic modulus.
 
virtual T plasticMultiplier (int idx, T f, const Eigen::Matrix< T, 3, 3 > &Ke, const Eigen::Matrix< T, 3, 1 > &ddisp, const Eigen::Matrix< T, 3, 1 > &dfdforce, T Kp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Calculate the plastic multiplier.
 
Eigen::Matrix< T, 3, 3 > ExplicitCPA (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Explicit method for elastoplastic contact laws.
 
Eigen::Matrix< T, 3, 3 > CPPM (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 CPPM method for elastoplastic contact laws.
 
virtual T yieldSurface (int idx, T fn, T fr, const StateVariable< T > &sv0, StateVariable< T > &sv)=0
 Yield function for elastoplastic contact laws.
 
virtual Eigen::Matrix< T, 3, 1 > dfdforce (int idx, const StateVariable< T > &sv0, StateVariable< T > &sv)=0
 Derivative of the yield function with respect to the force.
 
virtual Eigen::Matrix< T, 3, 1 > dgdforce (int idx, const StateVariable< T > &sv0, StateVariable< T > &sv)=0
 Derivative of the potential function with respect to the force.
 
virtual T hardening (int idx, const Eigen::Matrix< T, 3, 1 > &dgdforce, const StateVariable< T > &sv0, StateVariable< T > &sv)=0
 Hardening items for elastoplastic contact laws.
 
virtual void updateHardeningVariables (int idx, T dlambda, const Eigen::Matrix< T, 3, 1 > &ddispp, const StateVariable< T > &sv0, StateVariable< T > &sv)=0
 Update the hardening variables.
 
virtual void revertHardeningVariables (int idx, T dlambda, const Eigen::Matrix< T, 3, 1 > &ddispp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Revert the hardening variables.
 
virtual void YieldSurfaceCorrection (int idx, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Yield surface correction to keep the force state on the yield surface.
 
virtual void maintainYieldSurface (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const Eigen::Matrix< T, 3, 1 > &dforce, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Revert state variables from elastic state to maintain the force state on the yield surface.
 
- Protected Member Functions inherited from micromechanical::core::ContactLawBase< T >
Eigen::Matrix< T, 3, 3 > increment (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const Eigen::Matrix< T, 3, 3 > &Ke, const StateVariable< T > &sv0, StateVariable< T > &sv)
 Calculate one increment.
 
virtual void check (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 check the convergence of the contact law
 
virtual void preIntegration (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 pre-processing before the integration
 
virtual void postIntegration (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 post-processing after the integration
 
virtual void preIncrement (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 pre-processing before the increment
 
virtual void postIncrement (int idx, const Eigen::Matrix< T, 3, 1 > &ddisp, const StateVariable< T > &sv0, StateVariable< T > &sv)
 post-processing after the increment
 
virtual T CSL (int idx, const StateVariable< T > &sv0, StateVariable< T > &sv)
 calculate the critical state line
 

Detailed Description

template<typename T>
struct micromechanical::core::ElastoplasticContactLaw< T >

Base class for elastoplastic contact laws.

Member Function Documentation

◆ CPPM()

template<typename T>
Eigen::Matrix< T, 3, 3 > micromechanical::core::ElastoplasticContactLaw< T >::CPPM ( int idx,
const Eigen::Matrix< T, 3, 1 > & ddisp,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotected

CPPM method for elastoplastic contact laws.

Parameters
idxindex of the integration point
ddispdisplacement increment
sv0initial state variable
svstate variable
Returns
the elastoplastic stiffness matrix
Todo
the CPPM method is not implemented yet, fall back to the CPA method

References ExplicitCPA().

Referenced by stiffness().

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

◆ dfdforce()

template<typename T>
virtual Eigen::Matrix< T, 3, 1 > micromechanical::core::ElastoplasticContactLaw< T >::dfdforce ( int idx,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
protectedpure virtual

Derivative of the yield function with respect to the force.

Parameters
idxindex of the integration point
sv0initial state variable
svstate variable
Returns
the derivative of the yield function with respect to the force

Implemented in micromechanical::contacts::MCCContactLaw< T >, micromechanical::contacts::OSIMSANDContactLaw< T >, micromechanical::contacts::SANISANDContactLaw< T >, and micromechanical::contacts::SIMSANDContactLaw< T >.

Referenced by ExplicitCPA(), plasticModulus(), and plasticMultiplier().

Here is the caller graph for this function:

◆ dgdforce()

template<typename T>
virtual Eigen::Matrix< T, 3, 1 > micromechanical::core::ElastoplasticContactLaw< T >::dgdforce ( int idx,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
protectedpure virtual

Derivative of the potential function with respect to the force.

Parameters
idxindex of the integration point
sv0initial state variable
svstate variable
Returns
the derivative of the potential function with respect to the force

Implemented in micromechanical::contacts::MCCContactLaw< T >, micromechanical::contacts::OSIMSANDContactLaw< T >, micromechanical::contacts::SANISANDContactLaw< T >, and micromechanical::contacts::SIMSANDContactLaw< T >.

Referenced by ExplicitCPA(), hardening(), and plasticModulus().

Here is the caller graph for this function:

◆ ExplicitCPA()

template<typename T>
Eigen::Matrix< T, 3, 3 > micromechanical::core::ElastoplasticContactLaw< T >::ExplicitCPA ( int idx,
const Eigen::Matrix< T, 3, 1 > & ddisp,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotected

Explicit method for elastoplastic contact laws.

Parameters
idxindex of the integration point
ddispdisplacement increment
sv0initial state variable
svstate variable
Returns
the elastoplastic stiffness matrix

References micromechanical::core::ContactLawBase< T >::_increment, micromechanical::core::ContactLawBase< T >::_integration, micromechanical::core::ContactLawBase< T >::_mixedLoad, micromechanical::core::ContactLawBase< T >::_phase, micromechanical::core::ContactLawBase< T >::_plasticCorrection, micromechanical::core::ContactLawBase< T >::_step, micromechanical::core::StateVariable< T >::cscalars, micromechanical::core::ContactLawBase< T >::debugVariable, dfdforce(), dgdforce(), micromechanical::core::StateVariable< T >::disp, micromechanical::core::StateVariable< T >::dispp, micromechanical::core::StateVariable< T >::elasticStiffnessMatrix(), micromechanical::core::StateVariable< T >::fn(), micromechanical::core::StateVariable< T >::fnc(), micromechanical::core::StateVariable< T >::force, micromechanical::core::StateVariable< T >::fr(), hardening(), isConverged(), isExplicit(), maintainYieldSurface(), micromechanical::core::ContactLawBase< T >::material, micromechanical::core::ContactLawBase< T >::options, plasticModulus(), plasticMultiplier(), revertHardeningVariables(), updateHardeningVariables(), micromechanical::core::StateVariable< T >::vectors, micromechanical::core::StateVariable< T >::w, yieldSurface(), and YieldSurfaceCorrection().

Referenced by CPPM(), and stiffness().

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

◆ hardening()

template<typename T>
virtual T micromechanical::core::ElastoplasticContactLaw< T >::hardening ( int idx,
const Eigen::Matrix< T, 3, 1 > & dgdforce,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
protectedpure virtual

Hardening items for elastoplastic contact laws.

Parameters
idxindex of the integration point
dgdforcederivative of the potential function with respect to the force
sv0initial state variable
svstate variable
Returns
the hardening items

Implemented in micromechanical::contacts::MCCContactLaw< T >, micromechanical::contacts::OSIMSANDContactLaw< T >, micromechanical::contacts::SANISANDContactLaw< T >, and micromechanical::contacts::SIMSANDContactLaw< T >.

References dgdforce().

Referenced by ExplicitCPA(), and plasticModulus().

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

◆ integrate()

template<typename T>
Eigen::Matrix< T, 3, 3 > micromechanical::core::ElastoplasticContactLaw< T >::integrate ( int idx,
const Eigen::Matrix< T, 3, 1 > & ddisp,
const Eigen::Matrix< T, 3, 3 > & Ke,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineoverrideprotectedvirtual

integrate the force-displacement contact law, with a number of increments.

Parameters
idxindex of the integration point
ddispdisplacement increment
Keelastic stiffness matrix
sv0initial state variable
svstate variable
Returns
the elastoplastic stiffness matrix

Implements micromechanical::core::ContactLawBase< T >.

References micromechanical::core::ContactLawBase< T >::_increment, and micromechanical::core::ContactLawBase< T >::increment().

Here is the call graph for this function:

◆ isConverged()

template<typename T>
virtual bool micromechanical::core::ElastoplasticContactLaw< T >::isConverged ( int idx,
T f,
bool trial,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotectedvirtual

Determine whether the contact force state is converged to the yield surface or the force state is in the elastic region.

Parameters
idxindex of the integration point
fyield function value
trialwhether it is for elastic trial
sv0initial state variable
svstate variable
Returns
whether the contact force state is converged to the yield surface or the force state is in the elastic region

References micromechanical::core::ContactLawBase< T >::options.

Referenced by ExplicitCPA().

Here is the caller graph for this function:

◆ isCPA()

template<typename T>
bool micromechanical::core::ElastoplasticContactLaw< T >::isCPA ( ) const
inlineprotected

check if the plastic method is CPA

Returns
true if the plastic method is CPA, false otherwise

Referenced by stiffness().

Here is the caller graph for this function:

◆ isCPPM()

template<typename T>
bool micromechanical::core::ElastoplasticContactLaw< T >::isCPPM ( ) const
inlineprotected

check if the plastic method is CPPM

Returns
true if the plastic method is CPPM, false otherwise

Referenced by stiffness().

Here is the caller graph for this function:

◆ isExplicit()

template<typename T>
bool micromechanical::core::ElastoplasticContactLaw< T >::isExplicit ( ) const
inlineprotected

check if the plastic method is explicit

Returns
true if the plastic method is explicit, false otherwise

Referenced by ExplicitCPA(), plasticMultiplier(), and stiffness().

Here is the caller graph for this function:

◆ maintainYieldSurface()

template<typename T>
virtual void micromechanical::core::ElastoplasticContactLaw< T >::maintainYieldSurface ( int idx,
const Eigen::Matrix< T, 3, 1 > & ddisp,
const Eigen::Matrix< T, 3, 1 > & dforce,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotectedvirtual

Revert state variables from elastic state to maintain the force state on the yield surface.

Parameters
idxindex of the integration point
ddispdisplacement increment
dforceforce increment
sv0initial state variable
svstate variable

Reimplemented in micromechanical::contacts::SANISANDContactLaw< T >.

Referenced by ExplicitCPA().

Here is the caller graph for this function:

◆ plasticModulus()

template<typename T>
virtual T micromechanical::core::ElastoplasticContactLaw< T >::plasticModulus ( int idx,
const Eigen::Matrix< T, 3, 3 > & Ke,
const Eigen::Matrix< T, 3, 1 > & dfdforce,
const Eigen::Matrix< T, 3, 1 > & dgdforce,
T hardening,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotectedvirtual

Calculate the plastic modulus.

Parameters
idxindex of the integration point
Keelastic stiffness matrix
dfdforcederivative of the yield function with respect to the force
dgdforcederivative of the hardening variable with respect to the force
hardeninghardening item
sv0initial state variable
svcurrent state variable
Returns
the plastic modulus

References dfdforce(), dgdforce(), and hardening().

Referenced by ExplicitCPA().

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

◆ plasticMultiplier()

template<typename T>
virtual T micromechanical::core::ElastoplasticContactLaw< T >::plasticMultiplier ( int idx,
T f,
const Eigen::Matrix< T, 3, 3 > & Ke,
const Eigen::Matrix< T, 3, 1 > & ddisp,
const Eigen::Matrix< T, 3, 1 > & dfdforce,
T Kp,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotectedvirtual

Calculate the plastic multiplier.

Parameters
idxIndex of the integration point
fYield function value
KeElastic stiffness matrix
ddispDisplacement increment
dfdforceDerivative of the yield function with respect to the force
KpPlastic modulus
sv0Initial state variables
svCurrent state variables
Returns
Plastic multiplier

References dfdforce(), and isExplicit().

Referenced by ExplicitCPA().

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

◆ revertHardeningVariables()

template<typename T>
virtual void micromechanical::core::ElastoplasticContactLaw< T >::revertHardeningVariables ( int idx,
T dlambda,
const Eigen::Matrix< T, 3, 1 > & ddispp,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotectedvirtual

Revert the hardening variables.

Parameters
idxindex of the integration point
dlambdaplastic multiplier
ddisppplastic displacement increment
sv0initial state variable
svstate variable

Referenced by ExplicitCPA().

Here is the caller graph for this function:

◆ setPlasticMethod()

template<typename T>
void micromechanical::core::ElastoplasticContactLaw< T >::setPlasticMethod ( const std::string & method)
inline

set the plastic method

Parameters
methodplastic method, "Explicit", "CPA", or "CPPM"

◆ stiffness()

template<typename T>
Eigen::Matrix< T, 3, 3 > micromechanical::core::ElastoplasticContactLaw< T >::stiffness ( int idx,
const Eigen::Matrix< T, 3, 1 > & ddisp,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineoverrideprotectedvirtual

calculate the elastoplastic stiffness matrix

Parameters
idxindex of the integration point
ddispdisplacement increment
sv0initial state variable
svstate variable
Returns
the elastoplastic stiffness matrix

Implements micromechanical::core::ContactLawBase< T >.

References CPPM(), micromechanical::core::ContactLawBase< T >::CSL(), micromechanical::core::StateVariable< T >::ec, micromechanical::core::StateVariable< T >::elasticStiffnessMatrix(), ExplicitCPA(), micromechanical::core::StateVariable< T >::force, isCPA(), isCPPM(), isExplicit(), and micromechanical::core::StateVariable< T >::vectors.

Here is the call graph for this function:

◆ updateHardeningVariables()

template<typename T>
virtual void micromechanical::core::ElastoplasticContactLaw< T >::updateHardeningVariables ( int idx,
T dlambda,
const Eigen::Matrix< T, 3, 1 > & ddispp,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
protectedpure virtual

Update the hardening variables.

Parameters
idxindex of the integration point
dlambdaplastic multiplier
ddisppplastic displacement increment
sv0initial state variable
svstate variable

Implemented in micromechanical::contacts::MCCContactLaw< T >, micromechanical::contacts::OSIMSANDContactLaw< T >, micromechanical::contacts::SANISANDContactLaw< T >, and micromechanical::contacts::SIMSANDContactLaw< T >.

Referenced by ExplicitCPA().

Here is the caller graph for this function:

◆ yieldSurface()

template<typename T>
virtual T micromechanical::core::ElastoplasticContactLaw< T >::yieldSurface ( int idx,
T fn,
T fr,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
protectedpure virtual

Yield function for elastoplastic contact laws.

Parameters
idxindex of the integration point
fnnormal force
frshear force
sv0initial state variable
svstate variable
Returns
the yield function

Implemented in micromechanical::contacts::MCCContactLaw< T >, micromechanical::contacts::OSIMSANDContactLaw< T >, micromechanical::contacts::SANISANDContactLaw< T >, and micromechanical::contacts::SIMSANDContactLaw< T >.

Referenced by ExplicitCPA(), and yieldSurfaces().

Here is the caller graph for this function:

◆ YieldSurfaceCorrection()

template<typename T>
virtual void micromechanical::core::ElastoplasticContactLaw< T >::YieldSurfaceCorrection ( int idx,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inlineprotectedvirtual

Yield surface correction to keep the force state on the yield surface.

Parameters
idxindex of the integration point
sv0initial state variable
svstate variable

Referenced by ExplicitCPA().

Here is the caller graph for this function:

◆ yieldSurfaces()

template<typename T>
Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > micromechanical::core::ElastoplasticContactLaw< T >::yieldSurfaces ( int idx,
const Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > & fn,
const Eigen::Matrix< T, Eigen::Dynamic, Eigen::Dynamic > & fr,
const StateVariable< T > & sv0,
StateVariable< T > & sv )
inline

Calculate yield function for multiple times.

Parameters
idxindex of the integration point
fnnormal force
frshear force
sv0initial state variable
svstate variable
Returns
the yield function

References yieldSurface().

Here is the call graph for this function:

Member Data Documentation

◆ plasticMethod

template<typename T>
std::string micromechanical::core::ElastoplasticContactLaw< T >::plasticMethod = "CPA"

Plastic method.

◆ type

template<typename T>
std::string micromechanical::core::ElastoplasticContactLaw< T >::type = "Elastoplastic"

Type of the contact law.


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