www.mooseframework.org
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ComputeIsotropicElasticityTensor Class Reference

ComputeIsotropicElasticityTensor defines an elasticity tensor material for isotropic materials. More...

#include <ComputeIsotropicElasticityTensor.h>

Inheritance diagram for ComputeIsotropicElasticityTensor:
[legend]

Public Member Functions

 ComputeIsotropicElasticityTensor (const InputParameters &parameters)
 
bool hasGuarantee (const MaterialPropertyName &prop_name, Guarantee guarantee)
 

Protected Member Functions

virtual void computeQpElasticityTensor () override
 
virtual void computeQpProperties ()
 
void issueGuarantee (const MaterialPropertyName &prop_name, Guarantee guarantee)
 
void revokeGuarantee (const MaterialPropertyName &prop_name, Guarantee guarantee)
 

Protected Attributes

bool _bulk_modulus_set
 Elastic constants. More...
 
bool _lambda_set
 
bool _poissons_ratio_set
 
bool _shear_modulus_set
 
bool _youngs_modulus_set
 
Real _bulk_modulus
 
Real _lambda
 
Real _poissons_ratio
 
Real _shear_modulus
 
Real _youngs_modulus
 
RankFourTensor _Cijkl
 Individual elasticity tensor. More...
 
std::string _base_name
 
std::string _elasticity_tensor_name
 
MaterialProperty< RankFourTensor > & _elasticity_tensor
 
Function *const _prefactor_function
 prefactor function to multiply the elasticity tensor with More...
 

Detailed Description

ComputeIsotropicElasticityTensor defines an elasticity tensor material for isotropic materials.

Definition at line 24 of file ComputeIsotropicElasticityTensor.h.

Constructor & Destructor Documentation

◆ ComputeIsotropicElasticityTensor()

ComputeIsotropicElasticityTensor::ComputeIsotropicElasticityTensor ( const InputParameters &  parameters)

Definition at line 28 of file ComputeIsotropicElasticityTensor.C.

30  : ComputeElasticityTensorBase(parameters),
31  _bulk_modulus_set(parameters.isParamValid("bulk_modulus")),
32  _lambda_set(parameters.isParamValid("lambda")),
33  _poissons_ratio_set(parameters.isParamValid("poissons_ratio")),
34  _shear_modulus_set(parameters.isParamValid("shear_modulus")),
35  _youngs_modulus_set(parameters.isParamValid("youngs_modulus")),
36  _bulk_modulus(_bulk_modulus_set ? getParam<Real>("bulk_modulus") : -1),
37  _lambda(_lambda_set ? getParam<Real>("lambda") : -1),
38  _poissons_ratio(_poissons_ratio_set ? getParam<Real>("poissons_ratio") : -1),
39  _shear_modulus(_shear_modulus_set ? getParam<Real>("shear_modulus") : -1),
40  _youngs_modulus(_youngs_modulus_set ? getParam<Real>("youngs_modulus") : -1)
41 {
42  unsigned int num_elastic_constants = _bulk_modulus_set + _lambda_set + _poissons_ratio_set +
44  if (num_elastic_constants != 2)
45  mooseError("Exactly two elastic constants must be defined for material '" + name() + "'.");
46 
47  // all tensors created by this class are always isotropic
49  if (!isParamValid("elasticity_tensor_prefactor"))
51 
52  if (_bulk_modulus_set && _bulk_modulus <= 0.0)
53  mooseError("Bulk modulus must be positive in material '" + name() + "'.");
54 
55  if (_poissons_ratio_set && (_poissons_ratio <= -1.0 || _poissons_ratio >= 0.5))
56  mooseError("Poissons ratio must be greater than -1 and less than 0.5 in "
57  "material '" +
58  name() + "'.");
59 
61  mooseError("Shear modulus must not be negative in material '" + name() + "'.");
62 
64  mooseError("Youngs modulus must be positive in material '" + name() + "'.");
65 
67  {
68  _Cijkl.fillSymmetricIsotropicEandNu(_youngs_modulus, _poissons_ratio);
69  return;
70  }
71 
72  std::vector<Real> iso_const(2);
73 
75  {
76  iso_const[0] = _lambda;
77  iso_const[1] = _shear_modulus;
78  }
80  {
81  iso_const[0] = _bulk_modulus - 2.0 / 3.0 * _shear_modulus;
82  iso_const[1] = _shear_modulus;
83  }
85  {
86  iso_const[0] = 3.0 * _bulk_modulus * _poissons_ratio / (1.0 + _poissons_ratio);
87  iso_const[1] =
88  3.0 * _bulk_modulus * (1.0 - 2.0 * _poissons_ratio) / (2.0 * (1.0 + _poissons_ratio));
89  }
90  else if (_lambda_set && _bulk_modulus_set)
91  {
92  iso_const[0] = _lambda;
93  iso_const[1] = 3.0 * (_bulk_modulus - _lambda) / 2.0;
94  }
96  {
97  iso_const[0] = _shear_modulus * (_youngs_modulus - 2.0 * _shear_modulus) /
99  iso_const[1] = _shear_modulus;
100  }
102  {
103  iso_const[0] = 2.0 * _shear_modulus * _poissons_ratio / (1.0 - 2.0 * _poissons_ratio);
104  iso_const[1] = _shear_modulus;
105  }
107  {
108  iso_const[0] = 3.0 * _bulk_modulus * (3.0 * _bulk_modulus - _youngs_modulus) /
109  (9.0 * _bulk_modulus - _youngs_modulus);
110  iso_const[1] = 3.0 * _bulk_modulus * _youngs_modulus / (9.0 * _bulk_modulus - _youngs_modulus);
111  }
112  else if (_lambda_set && _poissons_ratio_set)
113  {
114  iso_const[0] = _lambda;
115  iso_const[1] = _lambda * (1.0 - 2.0 * _poissons_ratio) / (2.0 * _poissons_ratio);
116  }
117  else if (_lambda_set && _youngs_modulus_set)
118  {
119  iso_const[0] = _lambda;
120  iso_const[1] = (_youngs_modulus - 3.0 * _lambda +
121  std::sqrt(_youngs_modulus * _youngs_modulus + 9.0 * _lambda * _lambda +
122  2.0 * _youngs_modulus * _lambda)) /
123  4.0;
124  }
125  else
126  mooseError("Incorrect combination of elastic properties in ComputeIsotropicElasticityTensor.");
127 
128  // Fill elasticity tensor
129  _Cijkl.fillFromInputVector(iso_const, RankFourTensor::symmetric_isotropic);
130 }
void issueGuarantee(const MaterialPropertyName &prop_name, Guarantee guarantee)
const std::string name
Definition: Setup.h:22
RankFourTensor _Cijkl
Individual elasticity tensor.
ComputeElasticityTensorBase(const InputParameters &parameters)

Member Function Documentation

◆ computeQpElasticityTensor()

void ComputeIsotropicElasticityTensor::computeQpElasticityTensor ( )
overrideprotectedvirtual

Implements ComputeElasticityTensorBase.

Definition at line 133 of file ComputeIsotropicElasticityTensor.C.

134 {
135  // Assign elasticity tensor at a given quad point
136  _elasticity_tensor[_qp] = _Cijkl;
137 }
RankFourTensor _Cijkl
Individual elasticity tensor.
MaterialProperty< RankFourTensor > & _elasticity_tensor

◆ computeQpProperties()

void ComputeElasticityTensorBase::computeQpProperties ( )
protectedvirtualinherited

Definition at line 41 of file ComputeElasticityTensorBase.C.

42 {
44 
45  // Multiply by prefactor
47  _elasticity_tensor[_qp] *= _prefactor_function->value(_t, _q_point[_qp]);
48 }
Function *const _prefactor_function
prefactor function to multiply the elasticity tensor with
virtual void computeQpElasticityTensor()=0
MaterialProperty< RankFourTensor > & _elasticity_tensor

◆ hasGuarantee()

bool GuaranteeProvider::hasGuarantee ( const MaterialPropertyName &  prop_name,
Guarantee  guarantee 
)
inherited

Definition at line 16 of file GuaranteeProvider.C.

17 {
18  auto it = _guarantees.find(prop_name);
19  if (it == _guarantees.end())
20  return false;
21 
22  auto it2 = it->second.find(guarantee);
23  return it2 != it->second.end();
24 }
std::map< MaterialPropertyName, std::set< Guarantee > > _guarantees

◆ issueGuarantee()

void GuaranteeProvider::issueGuarantee ( const MaterialPropertyName &  prop_name,
Guarantee  guarantee 
)
protectedinherited

◆ revokeGuarantee()

void GuaranteeProvider::revokeGuarantee ( const MaterialPropertyName &  prop_name,
Guarantee  guarantee 
)
protectedinherited

Definition at line 34 of file GuaranteeProvider.C.

Referenced by ComputeElasticityTensorCP::ComputeElasticityTensorCP().

35 {
36  auto it = _guarantees.find(prop_name);
37  if (it != _guarantees.end())
38  it->second.erase(guarantee);
39 }
std::map< MaterialPropertyName, std::set< Guarantee > > _guarantees

Member Data Documentation

◆ _base_name

std::string ComputeElasticityTensorBase::_base_name
protectedinherited

◆ _bulk_modulus

Real ComputeIsotropicElasticityTensor::_bulk_modulus
protected

Definition at line 39 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _bulk_modulus_set

bool ComputeIsotropicElasticityTensor::_bulk_modulus_set
protected

Elastic constants.

Definition at line 33 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _Cijkl

RankFourTensor ComputeIsotropicElasticityTensor::_Cijkl
protected

Individual elasticity tensor.

Definition at line 46 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor(), and computeQpElasticityTensor().

◆ _elasticity_tensor

MaterialProperty<RankFourTensor>& ComputeElasticityTensorBase::_elasticity_tensor
protectedinherited

◆ _elasticity_tensor_name

std::string ComputeElasticityTensorBase::_elasticity_tensor_name
protectedinherited

◆ _lambda

Real ComputeIsotropicElasticityTensor::_lambda
protected

Definition at line 40 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _lambda_set

bool ComputeIsotropicElasticityTensor::_lambda_set
protected

Definition at line 34 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _poissons_ratio

Real ComputeIsotropicElasticityTensor::_poissons_ratio
protected

Definition at line 41 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _poissons_ratio_set

bool ComputeIsotropicElasticityTensor::_poissons_ratio_set
protected

Definition at line 35 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _prefactor_function

Function* const ComputeElasticityTensorBase::_prefactor_function
protectedinherited

prefactor function to multiply the elasticity tensor with

Definition at line 42 of file ComputeElasticityTensorBase.h.

Referenced by ComputeLayeredCosseratElasticityTensor::computeQpElasticityTensor(), and ComputeElasticityTensorBase::computeQpProperties().

◆ _shear_modulus

Real ComputeIsotropicElasticityTensor::_shear_modulus
protected

Definition at line 42 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _shear_modulus_set

bool ComputeIsotropicElasticityTensor::_shear_modulus_set
protected

Definition at line 36 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _youngs_modulus

Real ComputeIsotropicElasticityTensor::_youngs_modulus
protected

Definition at line 43 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().

◆ _youngs_modulus_set

bool ComputeIsotropicElasticityTensor::_youngs_modulus_set
protected

Definition at line 37 of file ComputeIsotropicElasticityTensor.h.

Referenced by ComputeIsotropicElasticityTensor().


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