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

ComputeInstantaneousThermalExpansionFunctionEigenstrain computes an eigenstrain for thermal expansion according to an instantaneous thermal expansion function. More...

#include <ComputeInstantaneousThermalExpansionFunctionEigenstrain.h>

Inheritance diagram for ComputeInstantaneousThermalExpansionFunctionEigenstrain:
[legend]

Public Member Functions

 ComputeInstantaneousThermalExpansionFunctionEigenstrain (const InputParameters &parameters)
 

Static Public Member Functions

static InputParameters validParams ()
 

Protected Member Functions

virtual void initQpStatefulProperties () override
 
virtual void computeThermalStrain (Real &thermal_strain, Real &instantaneous_cte) override
 
virtual void computeQpEigenstrain () override
 

Protected Attributes

const VariableValue & _temperature_old
 
const Function & _thermal_expansion_function
 
MaterialProperty< Real > & _thermal_strain
 Stores the thermal strain as a scalar for use in computing an incremental update to this. More...
 
const MaterialProperty< Real > & _thermal_strain_old
 
bool & _step_one
 Indicates whether we are on the first step, avoiding false positives when restarting. More...
 
const VariableValue & _temperature
 
MaterialProperty< RankTwoTensor > & _deigenstrain_dT
 
const VariableValue & _stress_free_temperature
 

Detailed Description

ComputeInstantaneousThermalExpansionFunctionEigenstrain computes an eigenstrain for thermal expansion according to an instantaneous thermal expansion function.

Definition at line 24 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.h.

Constructor & Destructor Documentation

◆ ComputeInstantaneousThermalExpansionFunctionEigenstrain()

ComputeInstantaneousThermalExpansionFunctionEigenstrain::ComputeInstantaneousThermalExpansionFunctionEigenstrain ( const InputParameters &  parameters)

Definition at line 32 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.C.

34  _temperature_old(coupledValueOld("temperature")),
35  _thermal_expansion_function(getFunction("thermal_expansion_function")),
36  _thermal_strain(declareProperty<Real>("InstantaneousThermalExpansionFunction_thermal_strain")),
38  getMaterialPropertyOld<Real>("InstantaneousThermalExpansionFunction_thermal_strain")),
39  _step_one(declareRestartableData<bool>("step_one", true))
40 {
41 }

Member Function Documentation

◆ computeQpEigenstrain()

void ComputeThermalExpansionEigenstrainBase::computeQpEigenstrain ( )
overrideprotectedvirtualinherited

Definition at line 38 of file ComputeThermalExpansionEigenstrainBase.C.

39 {
40  Real thermal_strain = 0.0;
41 
42  // instantaneous_cte is just the derivative of thermal_strain with respect to temperature
43  Real instantaneous_cte = 0.0;
44 
45  computeThermalStrain(thermal_strain, instantaneous_cte);
46 
47  _eigenstrain[_qp].zero();
48  _eigenstrain[_qp].addIa(thermal_strain);
49 
50  _deigenstrain_dT[_qp].zero();
51  _deigenstrain_dT[_qp].addIa(instantaneous_cte);
52 }

◆ computeThermalStrain()

void ComputeInstantaneousThermalExpansionFunctionEigenstrain::computeThermalStrain ( Real &  thermal_strain,
Real &  instantaneous_cte 
)
overrideprotectedvirtual

Implements ComputeThermalExpansionEigenstrainBase.

Definition at line 50 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.C.

52 {
53  if (_t_step > 1)
54  _step_one = false;
55 
56  const Real & current_temp = _temperature[_qp];
57 
58  const Real & old_thermal_strain = _thermal_strain_old[_qp];
59 
60  const Real & old_temp = (_step_one ? _stress_free_temperature[_qp] : _temperature_old[_qp]);
61  const Real delta_T = current_temp - old_temp;
62 
63  const Point p;
64  const Real alpha_current_temp = _thermal_expansion_function.value(current_temp, p);
65  const Real alpha_old_temp = _thermal_expansion_function.value(old_temp, p);
66 
67  thermal_strain = old_thermal_strain + delta_T * 0.5 * (alpha_current_temp + alpha_old_temp);
68  _thermal_strain[_qp] = thermal_strain;
69 
70  instantaneous_cte = alpha_current_temp;
71 }

◆ initQpStatefulProperties()

void ComputeInstantaneousThermalExpansionFunctionEigenstrain::initQpStatefulProperties ( )
overrideprotectedvirtual

Definition at line 44 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.C.

45 {
46  _thermal_strain[_qp] = 0;
47 }

◆ validParams()

InputParameters ComputeInstantaneousThermalExpansionFunctionEigenstrain::validParams ( )
static

Definition at line 19 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.C.

20 {
21  InputParameters params = ComputeThermalExpansionEigenstrainBase::validParams();
22  params.addClassDescription("Computes eigenstrain due to thermal expansion using a function that "
23  "describes the instantaneous thermal expansion as a function of "
24  "temperature");
25  params.addRequiredParam<FunctionName>("thermal_expansion_function",
26  "Function describing the instantaneous thermal expansion "
27  "coefficient as a function of temperature");
28  return params;
29 }

Member Data Documentation

◆ _deigenstrain_dT

MaterialProperty<RankTwoTensor>& ComputeThermalExpansionEigenstrainBase::_deigenstrain_dT
protectedinherited

◆ _step_one

bool& ComputeInstantaneousThermalExpansionFunctionEigenstrain::_step_one
protected

Indicates whether we are on the first step, avoiding false positives when restarting.

Definition at line 46 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.h.

Referenced by computeThermalStrain().

◆ _stress_free_temperature

const VariableValue& ComputeThermalExpansionEigenstrainBase::_stress_free_temperature
protectedinherited

◆ _temperature

const VariableValue& ComputeThermalExpansionEigenstrainBase::_temperature
protectedinherited

◆ _temperature_old

const VariableValue& ComputeInstantaneousThermalExpansionFunctionEigenstrain::_temperature_old
protected

◆ _thermal_expansion_function

const Function& ComputeInstantaneousThermalExpansionFunctionEigenstrain::_thermal_expansion_function
protected

◆ _thermal_strain

MaterialProperty<Real>& ComputeInstantaneousThermalExpansionFunctionEigenstrain::_thermal_strain
protected

Stores the thermal strain as a scalar for use in computing an incremental update to this.

Definition at line 41 of file ComputeInstantaneousThermalExpansionFunctionEigenstrain.h.

Referenced by computeThermalStrain(), and initQpStatefulProperties().

◆ _thermal_strain_old

const MaterialProperty<Real>& ComputeInstantaneousThermalExpansionFunctionEigenstrain::_thermal_strain_old
protected

The documentation for this class was generated from the following files:
ComputeInstantaneousThermalExpansionFunctionEigenstrain::_thermal_strain_old
const MaterialProperty< Real > & _thermal_strain_old
Definition: ComputeInstantaneousThermalExpansionFunctionEigenstrain.h:42
ComputeThermalExpansionEigenstrainBase::_temperature
const VariableValue & _temperature
Definition: ComputeThermalExpansionEigenstrainBase.h:49
ComputeInstantaneousThermalExpansionFunctionEigenstrain::_thermal_expansion_function
const Function & _thermal_expansion_function
Definition: ComputeInstantaneousThermalExpansionFunctionEigenstrain.h:37
ComputeThermalExpansionEigenstrainBase::computeThermalStrain
virtual void computeThermalStrain(Real &thermal_strain, Real &instantaneous_cte)=0
ComputeThermalExpansionEigenstrainBase::_stress_free_temperature
const VariableValue & _stress_free_temperature
Definition: ComputeThermalExpansionEigenstrainBase.h:51
ComputeInstantaneousThermalExpansionFunctionEigenstrain::_step_one
bool & _step_one
Indicates whether we are on the first step, avoiding false positives when restarting.
Definition: ComputeInstantaneousThermalExpansionFunctionEigenstrain.h:46
ComputeThermalExpansionEigenstrainBase::_deigenstrain_dT
MaterialProperty< RankTwoTensor > & _deigenstrain_dT
Definition: ComputeThermalExpansionEigenstrainBase.h:50
ComputeInstantaneousThermalExpansionFunctionEigenstrain::_temperature_old
const VariableValue & _temperature_old
Definition: ComputeInstantaneousThermalExpansionFunctionEigenstrain.h:36
ComputeThermalExpansionEigenstrainBase::validParams
static InputParameters validParams()
Definition: ComputeThermalExpansionEigenstrainBase.C:16
ComputeThermalExpansionEigenstrainBase::ComputeThermalExpansionEigenstrainBase
ComputeThermalExpansionEigenstrainBase(const InputParameters &parameters)
Definition: ComputeThermalExpansionEigenstrainBase.C:27
ComputeInstantaneousThermalExpansionFunctionEigenstrain::_thermal_strain
MaterialProperty< Real > & _thermal_strain
Stores the thermal strain as a scalar for use in computing an incremental update to this.
Definition: ComputeInstantaneousThermalExpansionFunctionEigenstrain.h:41