23 params.
addClassDescription(
"Computes eigenstrain due to thermal expansion using a function that "
24 "describes the instantaneous thermal expansion as a function of "
27 "Function describing the instantaneous thermal expansion "
28 "coefficient as a function of temperature");
37 _thermal_expansion_function(this->getFunction(
"thermal_expansion_function")),
38 _thermal_strain(this->template declareGenericProperty<Real, is_ad>(
39 this->_base_name +
"InstantaneousThermalExpansionFunction_thermal_strain")),
40 _thermal_strain_old(this->template getMaterialPropertyOld<Real>(
41 this->_base_name +
"InstantaneousThermalExpansionFunction_thermal_strain")),
42 _step_one(this->template declareRestartableData<bool>(
"step_one", true))
45 this->paramError(
"use_old_temperature",
46 "The old temperature value cannot be used in this incremental update model.");
53 _thermal_strain[_qp] = 0;
60 if (this->_t_step > 1)
63 const auto & old_temp =
64 (_step_one ? this->_stress_free_temperature[_qp] : this->_temperature_old[_qp]);
65 const auto delta_T = this->_temperature[_qp] - old_temp;
67 const auto alpha_current_temp = _thermal_expansion_function.value(this->_temperature[_qp]);
68 const auto alpha_old_temp = _thermal_expansion_function.value(old_temp);
70 const auto thermal_strain =
71 _thermal_strain_old[_qp] + delta_T * 0.5 * (alpha_current_temp + alpha_old_temp);
75 _thermal_strain[_qp] = dual_number_cast<GenericReal<is_ad>>(thermal_strain);
77 return thermal_strain;
registerMooseObject("SolidMechanicsApp", ComputeInstantaneousThermalExpansionFunctionEigenstrain)
typename std::conditional< is_ad, ADReal, ChainedReal >::type ValueAndDerivative
Return type with a single derivative.
ComputeInstantaneousThermalExpansionFunctionEigenstrain computes an eigenstrain for thermal expansion...
virtual void initQpStatefulProperties() override
static InputParameters validParams()
virtual ValueAndDerivative< is_ad > computeThermalStrain() override
computeThermalStrain must be overridden in derived classes.
ComputeInstantaneousThermalExpansionFunctionEigenstrainTempl(const InputParameters ¶meters)
ComputeThermalExpansionEigenstrainBase is a base class for all models that compute eigenstrains due t...
static InputParameters validParams()
const bool _use_old_temperature
lag temperature variable