www.mooseframework.org
HyperbolicViscoplasticityStressUpdate.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
3 //*
4 //* All rights reserved, see COPYRIGHT for full restrictions
5 //* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6 //*
7 //* Licensed under LGPL 2.1, please see LICENSE for details
8 //* https://www.gnu.org/licenses/lgpl-2.1.html
9 
11 
12 #include "Function.h"
13 #include "ElasticityTensorTools.h"
14 
15 registerMooseObject("TensorMechanicsApp", HyperbolicViscoplasticityStressUpdate);
16 
17 defineLegacyParams(HyperbolicViscoplasticityStressUpdate);
18 
19 InputParameters
21 {
22  InputParameters params = RadialReturnStressUpdate::validParams();
23  params.addClassDescription("This class uses the discrete material for a hyperbolic sine "
24  "viscoplasticity model in which the effective plastic strain is "
25  "solved for using a creep approach.");
26 
27  // Linear strain hardening parameters
28  params.addRequiredParam<Real>("yield_stress",
29  "The point at which plastic strain begins accumulating");
30  params.addRequiredParam<Real>("hardening_constant", "Hardening slope");
31 
32  // Viscoplasticity constitutive equation parameters
33  params.addRequiredParam<Real>("c_alpha",
34  "Viscoplasticity coefficient, scales the hyperbolic function");
35  params.addRequiredParam<Real>("c_beta",
36  "Viscoplasticity coefficient inside the hyperbolic sin function");
37  params.addDeprecatedParam<std::string>(
38  "plastic_prepend",
39  "",
40  "String that is prepended to the plastic_strain Material Property",
41  "This has been replaced by the 'base_name' parameter");
42  params.set<std::string>("effective_inelastic_strain_name") = "effective_plastic_strain";
43 
44  return params;
45 }
46 
47 HyperbolicViscoplasticityStressUpdate::HyperbolicViscoplasticityStressUpdate(
48  const InputParameters & parameters)
49  : RadialReturnStressUpdate(parameters),
50  _plastic_prepend(getParam<std::string>("plastic_prepend")),
51  _yield_stress(parameters.get<Real>("yield_stress")),
52  _hardening_constant(parameters.get<Real>("hardening_constant")),
53  _c_alpha(parameters.get<Real>("c_alpha")),
54  _c_beta(parameters.get<Real>("c_beta")),
55  _yield_condition(-1.0), // set to a non-physical value to catch uninitalized yield condition
56  _hardening_variable(declareProperty<Real>("hardening_variable")),
57  _hardening_variable_old(getMaterialPropertyOld<Real>("hardening_variable")),
58 
59  _plastic_strain(
60  declareProperty<RankTwoTensor>(_base_name + _plastic_prepend + "plastic_strain")),
61  _plastic_strain_old(
62  getMaterialPropertyOld<RankTwoTensor>(_base_name + _plastic_prepend + "plastic_strain"))
63 {
64 }
65 
66 void
67 HyperbolicViscoplasticityStressUpdate::initQpStatefulProperties()
68 {
69  _hardening_variable[_qp] = 0.0;
70  _plastic_strain[_qp].zero();
71 }
72 
73 void
74 HyperbolicViscoplasticityStressUpdate::propagateQpStatefulProperties()
75 {
76  _hardening_variable[_qp] = _hardening_variable_old[_qp];
77  _plastic_strain[_qp] = _plastic_strain_old[_qp];
78 
79  propagateQpStatefulPropertiesRadialReturn();
80 }
81 
82 void
83 HyperbolicViscoplasticityStressUpdate::computeStressInitialize(
84  const Real effective_trial_stress, const RankFourTensor & /*elasticity_tensor*/)
85 {
86  _yield_condition = effective_trial_stress - _hardening_variable_old[_qp] - _yield_stress;
87 
88  _hardening_variable[_qp] = _hardening_variable_old[_qp];
89  _plastic_strain[_qp] = _plastic_strain_old[_qp];
90 }
91 
92 Real
93 HyperbolicViscoplasticityStressUpdate::computeResidual(const Real effective_trial_stress,
94  const Real scalar)
95 {
96  Real residual = 0.0;
97 
98  mooseAssert(_yield_condition != -1.0,
99  "the yield stress was not updated by computeStressInitialize");
100 
101  if (_yield_condition > 0.0)
102  {
103  const Real xflow = _c_beta * (effective_trial_stress - (_three_shear_modulus * scalar) -
104  computeHardeningValue(scalar) - _yield_stress);
105  const Real xphi = _c_alpha * std::sinh(xflow);
106 
107  _xphidp = -_three_shear_modulus * _c_alpha * _c_beta * std::cosh(xflow);
108  _xphir = -_c_alpha * _c_beta * std::cosh(xflow);
109  residual = xphi * _dt - scalar;
110  }
111  return residual;
112 }
113 
114 Real
115 HyperbolicViscoplasticityStressUpdate::computeDerivative(const Real /*effective_trial_stress*/,
116  const Real /*scalar*/)
117 {
118  Real derivative = 1.0;
119  if (_yield_condition > 0.0)
120  derivative = _xphidp * _dt + _hardening_constant * _xphir * _dt - 1.0;
121 
122  return derivative;
123 }
124 
125 void
126 HyperbolicViscoplasticityStressUpdate::iterationFinalize(Real scalar)
127 {
128  if (_yield_condition > 0.0)
129  _hardening_variable[_qp] = computeHardeningValue(scalar);
130 }
131 
132 Real
133 HyperbolicViscoplasticityStressUpdate::computeHardeningValue(Real scalar)
134 {
135  return _hardening_variable_old[_qp] + (_hardening_constant * scalar);
136 }
137 
138 void
139 HyperbolicViscoplasticityStressUpdate::computeStressFinalize(
140  const RankTwoTensor & plasticStrainIncrement)
141 {
142  _plastic_strain[_qp] += plasticStrainIncrement;
143 }
RadialReturnStressUpdate
RadialReturnStressUpdate computes the radial return stress increment for an isotropic elastic-viscopl...
Definition: RadialReturnStressUpdate.h:34
defineLegacyParams
defineLegacyParams(HyperbolicViscoplasticityStressUpdate)
ElasticityTensorTools.h
validParams
InputParameters validParams()
RadialReturnStressUpdate::validParams
static InputParameters validParams()
Definition: RadialReturnStressUpdate.C:18
registerMooseObject
registerMooseObject("TensorMechanicsApp", HyperbolicViscoplasticityStressUpdate)
RankFourTensorTempl
Definition: ACGrGrElasticDrivingForce.h:20
HyperbolicViscoplasticityStressUpdate.h
RankTwoTensorTempl< Real >