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

ComputeStressBase is the base class for stress tensors. More...

#include <ComputeStressBase.h>

Inheritance diagram for ComputeStressBase:
[legend]

Public Member Functions

 ComputeStressBase (const InputParameters &parameters)
 

Protected Member Functions

virtual void initQpStatefulProperties () override
 
virtual void computeQpProperties () override
 
virtual void computeQpStress ()=0
 

Protected Attributes

const std::string _base_name
 
const std::string _elasticity_tensor_name
 
const MaterialProperty< RankTwoTensor > & _mechanical_strain
 
MaterialProperty< RankTwoTensor > & _stress
 
MaterialProperty< RankTwoTensor > & _elastic_strain
 
const MaterialProperty< RankFourTensor > & _elasticity_tensor
 
const MaterialProperty< RankTwoTensor > & _extra_stress
 Extra stress tensor. More...
 
std::vector< Function * > _initial_stress_fcn
 initial stress components More...
 
MaterialProperty< RankFourTensor > & _Jacobian_mult
 derivative of stress w.r.t. strain (_dstress_dstrain) More...
 

Detailed Description

ComputeStressBase is the base class for stress tensors.

Definition at line 27 of file ComputeStressBase.h.

Constructor & Destructor Documentation

◆ ComputeStressBase()

ComputeStressBase::ComputeStressBase ( const InputParameters &  parameters)

Definition at line 27 of file ComputeStressBase.C.

28  : DerivativeMaterialInterface<Material>(parameters),
29  _base_name(isParamValid("base_name") ? getParam<std::string>("base_name") + "_" : ""),
30  _elasticity_tensor_name(_base_name + "elasticity_tensor"),
31  _mechanical_strain(getMaterialPropertyByName<RankTwoTensor>(_base_name + "mechanical_strain")),
32  _stress(declareProperty<RankTwoTensor>(_base_name + "stress")),
33  _elastic_strain(declareProperty<RankTwoTensor>(_base_name + "elastic_strain")),
34  _elasticity_tensor(getMaterialPropertyByName<RankFourTensor>(_elasticity_tensor_name)),
35  _extra_stress(getDefaultMaterialProperty<RankTwoTensor>(_base_name + "extra_stress")),
36  _Jacobian_mult(declareProperty<RankFourTensor>(_base_name + "Jacobian_mult"))
37 {
38 
39  if (getParam<bool>("use_displaced_mesh"))
40  mooseError("The stress calculator needs to run on the undisplaced mesh.");
41 }
MaterialProperty< RankFourTensor > & _Jacobian_mult
derivative of stress w.r.t. strain (_dstress_dstrain)
const std::string _elasticity_tensor_name
MaterialProperty< RankTwoTensor > & _stress
const MaterialProperty< RankTwoTensor > & _mechanical_strain
const std::string _base_name
const MaterialProperty< RankFourTensor > & _elasticity_tensor
MaterialProperty< RankTwoTensor > & _elastic_strain
const MaterialProperty< RankTwoTensor > & _extra_stress
Extra stress tensor.

Member Function Documentation

◆ computeQpProperties()

void ComputeStressBase::computeQpProperties ( )
overrideprotectedvirtual

Definition at line 51 of file ComputeStressBase.C.

52 {
54 
55  // Add in extra stress
56  _stress[_qp] += _extra_stress[_qp];
57 }
virtual void computeQpStress()=0
MaterialProperty< RankTwoTensor > & _stress
const MaterialProperty< RankTwoTensor > & _extra_stress
Extra stress tensor.

◆ computeQpStress()

virtual void ComputeStressBase::computeQpStress ( )
protectedpure virtual

◆ initQpStatefulProperties()

void ComputeStressBase::initQpStatefulProperties ( )
overrideprotectedvirtual

Member Data Documentation

◆ _base_name

const std::string ComputeStressBase::_base_name
protected

◆ _elastic_strain

MaterialProperty<RankTwoTensor>& ComputeStressBase::_elastic_strain
protected

◆ _elasticity_tensor

const MaterialProperty<RankFourTensor>& ComputeStressBase::_elasticity_tensor
protected

◆ _elasticity_tensor_name

const std::string ComputeStressBase::_elasticity_tensor_name
protected

◆ _extra_stress

const MaterialProperty<RankTwoTensor>& ComputeStressBase::_extra_stress
protected

Extra stress tensor.

Definition at line 47 of file ComputeStressBase.h.

Referenced by computeQpProperties().

◆ _initial_stress_fcn

std::vector<Function *> ComputeStressBase::_initial_stress_fcn
protected

initial stress components

Definition at line 50 of file ComputeStressBase.h.

◆ _Jacobian_mult

MaterialProperty<RankFourTensor>& ComputeStressBase::_Jacobian_mult
protected

◆ _mechanical_strain

const MaterialProperty<RankTwoTensor>& ComputeStressBase::_mechanical_strain
protected

◆ _stress

MaterialProperty<RankTwoTensor>& ComputeStressBase::_stress
protected

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