www.mooseframework.org
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Compute1DSmallStrain Class Referenceabstract

Compute1DSmallStrain defines a strain tensor, assuming small strains, in 1D problems, handling strains in other two directions. More...

#include <Compute1DSmallStrain.h>

Inheritance diagram for Compute1DSmallStrain:
[legend]

Public Member Functions

 Compute1DSmallStrain (const InputParameters &parameters)
 
void computeProperties () override
 
void initialSetup () override
 

Protected Member Functions

virtual Real computeStrainYY ()=0
 Computes the strain_yy; as a virtual function, this function is overwritten for the specific geometries defined by inheriting classes. More...
 
virtual Real computeStrainZZ ()=0
 Computes the strain_zz; as a virtual function, this function is overwritten for the specific geometries defined by inheriting classes. More...
 
virtual void initQpStatefulProperties () override
 
virtual void displacementIntegrityCheck ()
 

Protected Attributes

unsigned int _ndisp
 Coupled displacement variables. More...
 
std::vector< const VariableValue * > _disp
 
std::vector< const VariableGradient * > _grad_disp
 
std::string _base_name
 
MaterialProperty< RankTwoTensor > & _mechanical_strain
 
MaterialProperty< RankTwoTensor > & _total_strain
 
std::vector< MaterialPropertyName > _eigenstrain_names
 
std::vector< const MaterialProperty< RankTwoTensor > * > _eigenstrains
 
const MaterialProperty< RankTwoTensor > * _global_strain
 
bool _volumetric_locking_correction
 
const Real & _current_elem_volume
 

Detailed Description

Compute1DSmallStrain defines a strain tensor, assuming small strains, in 1D problems, handling strains in other two directions.

Compute1DSmallStrain contains virtual methods to define the strain_yy and strain_zz as a general nonzero value.

Definition at line 26 of file Compute1DSmallStrain.h.

Constructor & Destructor Documentation

◆ Compute1DSmallStrain()

Compute1DSmallStrain::Compute1DSmallStrain ( const InputParameters &  parameters)

Definition at line 23 of file Compute1DSmallStrain.C.

24  : ComputeSmallStrain(parameters)
25 {
26 }
ComputeSmallStrain(const InputParameters &parameters)

Member Function Documentation

◆ computeProperties()

void Compute1DSmallStrain::computeProperties ( )
overridevirtual

Reimplemented from ComputeSmallStrain.

Definition at line 29 of file Compute1DSmallStrain.C.

30 {
31  for (_qp = 0; _qp < _qrule->n_points(); ++_qp)
32  {
33  _total_strain[_qp](0, 0) = (*_grad_disp[0])[_qp](0);
34  _total_strain[_qp](1, 1) = computeStrainYY();
35  _total_strain[_qp](2, 2) = computeStrainZZ();
36 
38 
39  // Remove the eigenstrain
40  for (auto es : _eigenstrains)
41  _mechanical_strain[_qp] -= (*es)[_qp];
42  }
43 }
virtual Real computeStrainYY()=0
Computes the strain_yy; as a virtual function, this function is overwritten for the specific geometri...
virtual Real computeStrainZZ()=0
Computes the strain_zz; as a virtual function, this function is overwritten for the specific geometri...
MaterialProperty< RankTwoTensor > & _mechanical_strain
MaterialProperty< RankTwoTensor > & _total_strain
std::vector< const MaterialProperty< RankTwoTensor > * > _eigenstrains
std::vector< const VariableGradient * > _grad_disp

◆ computeStrainYY()

virtual Real Compute1DSmallStrain::computeStrainYY ( )
protectedpure virtual

Computes the strain_yy; as a virtual function, this function is overwritten for the specific geometries defined by inheriting classes.

Implemented in ComputeAxisymmetric1DSmallStrain.

Referenced by computeProperties().

◆ computeStrainZZ()

virtual Real Compute1DSmallStrain::computeStrainZZ ( )
protectedpure virtual

Computes the strain_zz; as a virtual function, this function is overwritten for the specific geometries defined by inheriting classes.

Implemented in ComputeAxisymmetric1DSmallStrain.

Referenced by computeProperties().

◆ displacementIntegrityCheck()

void ComputeStrainBase::displacementIntegrityCheck ( )
protectedvirtualinherited

Reimplemented in Compute2DFiniteStrain, Compute2DIncrementalStrain, and Compute2DSmallStrain.

Definition at line 92 of file ComputeStrainBase.C.

Referenced by ComputeStrainBase::initialSetup().

93 {
94  // Checking for consistency between mesh size and length of the provided displacements vector
95  if (_ndisp != _mesh.dimension())
96  paramError(
97  "displacements",
98  "The number of variables supplied in 'displacements' must match the mesh dimension.");
99 }
unsigned int _ndisp
Coupled displacement variables.

◆ initialSetup()

void ComputeStrainBase::initialSetup ( )
overrideinherited

Definition at line 73 of file ComputeStrainBase.C.

Referenced by ComputeIncrementalStrainBase::initialSetup(), and ComputeAxisymmetric1DSmallStrain::initialSetup().

74 {
76  // fetch coupled variables and gradients (as stateful properties if necessary)
77  for (unsigned int i = 0; i < _ndisp; ++i)
78  {
79  _disp[i] = &coupledValue("displacements", i);
80  _grad_disp[i] = &coupledGradient("displacements", i);
81  }
82 
83  // set unused dimensions to zero
84  for (unsigned i = _ndisp; i < 3; ++i)
85  {
86  _disp[i] = &_zero;
87  _grad_disp[i] = &_grad_zero;
88  }
89 }
virtual void displacementIntegrityCheck()
std::vector< const VariableValue * > _disp
unsigned int _ndisp
Coupled displacement variables.
std::vector< const VariableGradient * > _grad_disp

◆ initQpStatefulProperties()

void ComputeStrainBase::initQpStatefulProperties ( )
overrideprotectedvirtualinherited

Reimplemented in ComputeCosseratIncrementalSmallStrain, and ComputeIncrementalStrainBase.

Definition at line 102 of file ComputeStrainBase.C.

103 {
104  _mechanical_strain[_qp].zero();
105  _total_strain[_qp].zero();
106 }
MaterialProperty< RankTwoTensor > & _mechanical_strain
MaterialProperty< RankTwoTensor > & _total_strain

Member Data Documentation

◆ _base_name

std::string ComputeStrainBase::_base_name
protectedinherited

Definition at line 43 of file ComputeStrainBase.h.

Referenced by ComputeStrainBase::ComputeStrainBase().

◆ _current_elem_volume

const Real& ComputeStrainBase::_current_elem_volume
protectedinherited

◆ _disp

std::vector<const VariableValue *> ComputeStrainBase::_disp
protectedinherited

◆ _eigenstrain_names

std::vector<MaterialPropertyName> ComputeStrainBase::_eigenstrain_names
protectedinherited

◆ _eigenstrains

std::vector<const MaterialProperty<RankTwoTensor> *> ComputeStrainBase::_eigenstrains
protectedinherited

◆ _global_strain

const MaterialProperty<RankTwoTensor>* ComputeStrainBase::_global_strain
protectedinherited

◆ _grad_disp

std::vector<const VariableGradient *> ComputeStrainBase::_grad_disp
protectedinherited

◆ _mechanical_strain

MaterialProperty<RankTwoTensor>& ComputeStrainBase::_mechanical_strain
protectedinherited

◆ _ndisp

unsigned int ComputeStrainBase::_ndisp
protectedinherited

◆ _total_strain

MaterialProperty<RankTwoTensor>& ComputeStrainBase::_total_strain
protectedinherited

◆ _volumetric_locking_correction

bool ComputeStrainBase::_volumetric_locking_correction
protectedinherited

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