ComputeEigenstrainBase Class Referenceabstract

ComputeEigenstrainBase is the base class for eigenstrain tensors. More...

#include <ComputeEigenstrainBase.h>

Inheritance diagram for ComputeEigenstrainBase:
[legend]

Public Member Functions

ComputeEigenstrainBase (const InputParameters &parameters)

Protected Member Functions

virtual void initQpStatefulProperties ()

virtual void computeQpProperties ()

virtual void computeQpEigenstrain ()=0
Compute the eigenstrain and store in _eigenstrain. More...

Real computeVolumetricStrainComponent (const Real volumetric_strain) const
Helper function for models that compute the eigenstrain based on a volumetric strain. More...

Protected Attributes

std::string _base_name
Base name prepended to material property name. More...

std::string _eigenstrain_name
Material property name for the eigenstrain tensor. More...

MaterialProperty< RankTwoTensor > & _eigenstrain
Stores the current total eigenstrain. More...

bool & _step_zero
Restartable data to check for the zeroth and first time steps for thermal calculations. More...

Detailed Description

ComputeEigenstrainBase is the base class for eigenstrain tensors.

Definition at line 27 of file ComputeEigenstrainBase.h.

◆ ComputeEigenstrainBase()

 ComputeEigenstrainBase::ComputeEigenstrainBase ( const InputParameters & parameters )

Definition at line 35 of file ComputeEigenstrainBase.C.

36  : Material(parameters),
37  _base_name(isParamValid("base_name") ? getParam<std::string>("base_name") + "_" : ""),
38  _eigenstrain_name(_base_name + getParam<std::string>("eigenstrain_name")),
39  _eigenstrain(declareProperty<RankTwoTensor>(_eigenstrain_name)),
40  _step_zero(declareRestartableData<bool>("step_zero", true))
41 {
42 }
std::string _eigenstrain_name
Material property name for the eigenstrain tensor.
std::string _base_name
Base name prepended to material property name.
MaterialProperty< RankTwoTensor > & _eigenstrain
Stores the current total eigenstrain.
bool & _step_zero
Restartable data to check for the zeroth and first time steps for thermal calculations.

◆ computeQpEigenstrain()

 virtual void ComputeEigenstrainBase::computeQpEigenstrain ( )
protectedpure virtual

Compute the eigenstrain and store in _eigenstrain.

Referenced by computeQpProperties().

◆ computeQpProperties()

 void ComputeEigenstrainBase::computeQpProperties ( )
protectedvirtual

Definition at line 53 of file ComputeEigenstrainBase.C.

54 {
55  if (_t_step >= 1)
56  _step_zero = false;
57
58  // Skip the eigenstrain calculation in step zero because no solution is computed during
59  // the zeroth step, hence computing the eigenstrain in the zeroth step would result in
60  // an incorrect calculation of mechanical_strain, which is stateful.
61  if (!_step_zero)
63 }
virtual void computeQpEigenstrain()=0
Compute the eigenstrain and store in _eigenstrain.
bool & _step_zero
Restartable data to check for the zeroth and first time steps for thermal calculations.

◆ computeVolumetricStrainComponent()

 Real ComputeEigenstrainBase::computeVolumetricStrainComponent ( const Real volumetric_strain ) const
protected

Helper function for models that compute the eigenstrain based on a volumetric strain.

This function computes the diagonal components of the eigenstrain tensor as logarithmic strains.

Parameters
 volumetric_strain The current volumetric strain to be applied
Returns
Current strain in one direction due to volumetric strain, expressed as a logarithmic strain

Definition at line 66 of file ComputeEigenstrainBase.C.

67 {
68  // The engineering strain in a given direction is:
69  // epsilon_eng = cbrt(volumetric_strain + 1.0) - 1.0
70  //
71  // We need to provide this as a logarithmic strain to be consistent with the strain measure
72  // used for finite strain:
73  // epsilon_log = log(1.0 + epsilon_eng)
74  //
75  // This can be simplified down to a more direct form:
76  // epsilon_log = log(cbrt(volumetric_strain + 1.0))
77  // or:
78  // epsilon_log = (1/3) log(volumetric_strain + 1.0)
79
80  return std::log(volumetric_strain + 1.0) / 3.0;
81 }

◆ initQpStatefulProperties()

 void ComputeEigenstrainBase::initQpStatefulProperties ( )
protectedvirtual

Reimplemented in ComputeReducedOrderEigenstrain.

Definition at line 45 of file ComputeEigenstrainBase.C.

46 {
47  // This property can be promoted to be stateful by other models that use it,
48  // so it needs to be initalized.
49  _eigenstrain[_qp].zero();
50 }
MaterialProperty< RankTwoTensor > & _eigenstrain
Stores the current total eigenstrain.

◆ _base_name

 std::string ComputeEigenstrainBase::_base_name
protected

Base name prepended to material property name.

Definition at line 40 of file ComputeEigenstrainBase.h.

◆ _eigenstrain

 MaterialProperty& ComputeEigenstrainBase::_eigenstrain
protected

Stores the current total eigenstrain.

Definition at line 46 of file ComputeEigenstrainBase.h.

◆ _eigenstrain_name

 std::string ComputeEigenstrainBase::_eigenstrain_name
protected

Material property name for the eigenstrain tensor.

Definition at line 43 of file ComputeEigenstrainBase.h.

◆ _step_zero

 bool& ComputeEigenstrainBase::_step_zero
protected

Restartable data to check for the zeroth and first time steps for thermal calculations.

Definition at line 59 of file ComputeEigenstrainBase.h.

Referenced by computeQpProperties().

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