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

J2 plasticity, associative, with hardning. More...

#include <TensorMechanicsPlasticJ2.h>

Inheritance diagram for TensorMechanicsPlasticJ2:
[legend]

Public Member Functions

 TensorMechanicsPlasticJ2 (const InputParameters &parameters)
 
virtual std::string modelName () const override
 
virtual bool useCustomReturnMap () const override
 Returns false. You will want to override this in your derived class if you write a custom returnMap function. More...
 
virtual bool useCustomCTO () const override
 Returns false. You will want to override this in your derived class if you write a custom consistent tangent operator function. More...
 
virtual bool returnMap (const RankTwoTensor &trial_stress, Real intnl_old, const RankFourTensor &E_ijkl, Real ep_plastic_tolerance, RankTwoTensor &returned_stress, Real &returned_intnl, std::vector< Real > &dpm, RankTwoTensor &delta_dp, std::vector< Real > &yf, bool &trial_stress_inadmissible) const override
 Performs a custom return-map. More...
 
virtual RankFourTensor consistentTangentOperator (const RankTwoTensor &trial_stress, Real intnl_old, const RankTwoTensor &stress, Real intnl, const RankFourTensor &E_ijkl, const std::vector< Real > &cumulative_pm) const override
 Calculates a custom consistent tangent operator. More...
 
void initialize ()
 
void execute ()
 
void finalize ()
 
virtual unsigned int numberSurfaces () const
 The number of yield surfaces for this plasticity model. More...
 
virtual void yieldFunctionV (const RankTwoTensor &stress, Real intnl, std::vector< Real > &f) const
 Calculates the yield functions. More...
 
virtual void dyieldFunction_dstressV (const RankTwoTensor &stress, Real intnl, std::vector< RankTwoTensor > &df_dstress) const
 The derivative of yield functions with respect to stress. More...
 
virtual void dyieldFunction_dintnlV (const RankTwoTensor &stress, Real intnl, std::vector< Real > &df_dintnl) const
 The derivative of yield functions with respect to the internal parameter. More...
 
virtual void flowPotentialV (const RankTwoTensor &stress, Real intnl, std::vector< RankTwoTensor > &r) const
 The flow potentials. More...
 
virtual void dflowPotential_dstressV (const RankTwoTensor &stress, Real intnl, std::vector< RankFourTensor > &dr_dstress) const
 The derivative of the flow potential with respect to stress. More...
 
virtual void dflowPotential_dintnlV (const RankTwoTensor &stress, Real intnl, std::vector< RankTwoTensor > &dr_dintnl) const
 The derivative of the flow potential with respect to the internal parameter. More...
 
virtual void hardPotentialV (const RankTwoTensor &stress, Real intnl, std::vector< Real > &h) const
 The hardening potential. More...
 
virtual void dhardPotential_dstressV (const RankTwoTensor &stress, Real intnl, std::vector< RankTwoTensor > &dh_dstress) const
 The derivative of the hardening potential with respect to stress. More...
 
virtual void dhardPotential_dintnlV (const RankTwoTensor &stress, Real intnl, std::vector< Real > &dh_dintnl) const
 The derivative of the hardening potential with respect to the internal parameter. More...
 
virtual void activeConstraints (const std::vector< Real > &f, const RankTwoTensor &stress, Real intnl, const RankFourTensor &Eijkl, std::vector< bool > &act, RankTwoTensor &returned_stress) const
 The active yield surfaces, given a vector of yield functions. More...
 
bool KuhnTuckerSingleSurface (Real yf, Real dpm, Real dpm_tol) const
 Returns true if the Kuhn-Tucker conditions for the single surface are satisfied. More...
 

Public Attributes

const Real _f_tol
 Tolerance on yield function. More...
 
const Real _ic_tol
 Tolerance on internal constraint. More...
 

Protected Member Functions

virtual Real yieldFunction (const RankTwoTensor &stress, Real intnl) const override
 The following functions are what you should override when building single-plasticity models. More...
 
virtual RankTwoTensor dyieldFunction_dstress (const RankTwoTensor &stress, Real intnl) const override
 The derivative of yield function with respect to stress. More...
 
Real dyieldFunction_dintnl (const RankTwoTensor &stress, Real intnl) const override
 The derivative of yield function with respect to the internal parameter. More...
 
virtual RankTwoTensor flowPotential (const RankTwoTensor &stress, Real intnl) const override
 The flow potential. More...
 
virtual RankFourTensor dflowPotential_dstress (const RankTwoTensor &stress, Real intnl) const override
 The derivative of the flow potential with respect to stress. More...
 
RankTwoTensor dflowPotential_dintnl (const RankTwoTensor &stress, Real intnl) const override
 The derivative of the flow potential with respect to the internal parameter. More...
 
virtual Real yieldStrength (Real intnl) const
 YieldStrength. More...
 
virtual Real dyieldStrength (Real intnl) const
 d(yieldStrength)/d(intnl) More...
 
virtual Real hardPotential (const RankTwoTensor &stress, Real intnl) const
 The hardening potential. More...
 
virtual RankTwoTensor dhardPotential_dstress (const RankTwoTensor &stress, Real intnl) const
 The derivative of the hardening potential with respect to stress. More...
 
virtual Real dhardPotential_dintnl (const RankTwoTensor &stress, Real intnl) const
 The derivative of the hardening potential with respect to the internal parameter. More...
 

Private Attributes

const TensorMechanicsHardeningModel_strength
 yield strength, from user input More...
 
const unsigned _max_iters
 max iters for custom return map loop More...
 
const bool _use_custom_returnMap
 Whether to use the custom return-map algorithm. More...
 
const bool _use_custom_cto
 Whether to use the custom consistent tangent operator calculation. More...
 

Detailed Description

J2 plasticity, associative, with hardning.

Yield_function = sqrt(3*J2) - yield_strength

Definition at line 25 of file TensorMechanicsPlasticJ2.h.

Constructor & Destructor Documentation

◆ TensorMechanicsPlasticJ2()

TensorMechanicsPlasticJ2::TensorMechanicsPlasticJ2 ( const InputParameters &  parameters)

Definition at line 40 of file TensorMechanicsPlasticJ2.C.

41  : TensorMechanicsPlasticModel(parameters),
42  _strength(getUserObject<TensorMechanicsHardeningModel>("yield_strength")),
43  _max_iters(getParam<unsigned>("max_iterations")),
44  _use_custom_returnMap(getParam<bool>("use_custom_returnMap")),
45  _use_custom_cto(getParam<bool>("use_custom_cto"))
46 {
47 }
TensorMechanicsPlasticModel(const InputParameters &parameters)
const unsigned _max_iters
max iters for custom return map loop
const bool _use_custom_cto
Whether to use the custom consistent tangent operator calculation.
const bool _use_custom_returnMap
Whether to use the custom return-map algorithm.
const TensorMechanicsHardeningModel & _strength
yield strength, from user input

Member Function Documentation

◆ activeConstraints()

void TensorMechanicsPlasticModel::activeConstraints ( const std::vector< Real > &  f,
const RankTwoTensor &  stress,
Real  intnl,
const RankFourTensor &  Eijkl,
std::vector< bool > &  act,
RankTwoTensor &  returned_stress 
) const
virtualinherited

The active yield surfaces, given a vector of yield functions.

This is used by FiniteStrainMultiPlasticity to determine the initial set of active constraints at the trial (stress, intnl) configuration. It is up to you (the coder) to determine how accurate you want the returned_stress to be. Currently it is only used by FiniteStrainMultiPlasticity to estimate a good starting value for the Newton-Rahson procedure, so currently it may not need to be super perfect.

Parameters
fvalues of the yield functions
stressstress tensor
intnlinternal parameter
Eijklelasticity tensor (stress = Eijkl*strain)
[out]actact[i] = true if the i_th yield function is active
[out]returned_stressApproximate value of the returned stress

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, TensorMechanicsPlasticTensileMulti, TensorMechanicsPlasticMeanCapTC, TensorMechanicsPlasticWeakPlaneShear, and TensorMechanicsPlasticWeakPlaneTensile.

Definition at line 187 of file TensorMechanicsPlasticModel.C.

193 {
194  mooseAssert(f.size() == numberSurfaces(),
195  "f incorrectly sized at " << f.size() << " in activeConstraints");
196  act.resize(numberSurfaces());
197  for (unsigned surface = 0; surface < numberSurfaces(); ++surface)
198  act[surface] = (f[surface] > _f_tol);
199 }
virtual unsigned int numberSurfaces() const
The number of yield surfaces for this plasticity model.
const Real _f_tol
Tolerance on yield function.

◆ consistentTangentOperator()

RankFourTensor TensorMechanicsPlasticJ2::consistentTangentOperator ( const RankTwoTensor &  trial_stress,
Real  intnl_old,
const RankTwoTensor &  stress,
Real  intnl,
const RankFourTensor &  E_ijkl,
const std::vector< Real > &  cumulative_pm 
) const
overridevirtual

Calculates a custom consistent tangent operator.

You may choose to over-ride this in your derived TensorMechanicsPlasticXXXX class.

(Note, if you over-ride returnMap, you will probably want to override consistentTangentOpertor too, otherwise it will default to E_ijkl.)

Parameters
stress_oldtrial stress before returning
intnl_oldinternal parameter before returning
stresscurrent returned stress state
intnlinternal parameter
E_ijklelasticity tensor
cumulative_pmthe cumulative plastic multipliers
Returns
the consistent tangent operator: E_ijkl if not over-ridden

Reimplemented from TensorMechanicsPlasticModel.

Definition at line 192 of file TensorMechanicsPlasticJ2.C.

198 {
199  if (!_use_custom_cto)
201  trial_stress, intnl_old, stress, intnl, E_ijkl, cumulative_pm);
202 
203  Real mu = E_ijkl(0, 1, 0, 1);
204 
205  Real h = 3 * mu + dyieldStrength(intnl);
206  RankTwoTensor sij = stress.deviatoric();
207  Real sII = stress.secondInvariant();
208  Real equivalent_stress = std::sqrt(3.0 * sII);
209  Real zeta = cumulative_pm[0] / (1.0 + 3.0 * mu * cumulative_pm[0] / equivalent_stress);
210 
211  return E_ijkl - 3.0 * mu * mu / sII / h * sij.outerProduct(sij) -
212  4.0 * mu * mu * zeta * dflowPotential_dstress(stress, intnl);
213 }
virtual RankFourTensor dflowPotential_dstress(const RankTwoTensor &stress, Real intnl) const override
The derivative of the flow potential with respect to stress.
const bool _use_custom_cto
Whether to use the custom consistent tangent operator calculation.
virtual RankFourTensor consistentTangentOperator(const RankTwoTensor &trial_stress, Real intnl_old, const RankTwoTensor &stress, Real intnl, const RankFourTensor &E_ijkl, const std::vector< Real > &cumulative_pm) const
Calculates a custom consistent tangent operator.
virtual Real dyieldStrength(Real intnl) const
d(yieldStrength)/d(intnl)

◆ dflowPotential_dintnl()

RankTwoTensor TensorMechanicsPlasticJ2::dflowPotential_dintnl ( const RankTwoTensor &  stress,
Real  intnl 
) const
overrideprotectedvirtual

The derivative of the flow potential with respect to the internal parameter.

Parameters
stressthe stress at which to calculate the flow potential
intnlinternal parameter
Returns
dr_dintnl(i, j) = dr(i, j)/dintnl

Reimplemented from TensorMechanicsPlasticModel.

Definition at line 96 of file TensorMechanicsPlasticJ2.C.

98 {
99  return RankTwoTensor();
100 }

◆ dflowPotential_dintnlV()

void TensorMechanicsPlasticModel::dflowPotential_dintnlV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< RankTwoTensor > &  dr_dintnl 
) const
virtualinherited

The derivative of the flow potential with respect to the internal parameter.

Parameters
stressthe stress at which to calculate the flow potential
intnlinternal parameter
[out]dr_dintnldr_dintnl[alpha](i, j) = dr[alpha](i, j)/dintnl

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, and TensorMechanicsPlasticTensileMulti.

Definition at line 138 of file TensorMechanicsPlasticModel.C.

141 {
142  return dr_dintnl.assign(1, dflowPotential_dintnl(stress, intnl));
143 }
virtual RankTwoTensor dflowPotential_dintnl(const RankTwoTensor &stress, Real intnl) const
The derivative of the flow potential with respect to the internal parameter.

◆ dflowPotential_dstress()

RankFourTensor TensorMechanicsPlasticJ2::dflowPotential_dstress ( const RankTwoTensor &  stress,
Real  intnl 
) const
overrideprotectedvirtual

The derivative of the flow potential with respect to stress.

Parameters
stressthe stress at which to calculate the flow potential
intnlinternal parameter
Returns
dr_dstress(i, j, k, l) = dr(i, j)/dstress(k, l)

Reimplemented from TensorMechanicsPlasticModel.

Reimplemented in TensorMechanicsPlasticIsotropicSD, and TensorMechanicsPlasticOrthotropic.

Definition at line 78 of file TensorMechanicsPlasticJ2.C.

Referenced by consistentTangentOperator(), TensorMechanicsPlasticOrthotropic::dflowPotential_dstress(), and TensorMechanicsPlasticIsotropicSD::dflowPotential_dstress().

79 {
80  Real sII = stress.secondInvariant();
81  if (sII == 0)
82  return RankFourTensor();
83 
84  RankFourTensor dfp = 0.5 * std::sqrt(3.0 / sII) * stress.d2secondInvariant();
85  Real pre = -0.25 * std::sqrt(3.0) * std::pow(sII, -1.5);
86  RankTwoTensor dII = stress.dsecondInvariant();
87  for (unsigned i = 0; i < 3; ++i)
88  for (unsigned j = 0; j < 3; ++j)
89  for (unsigned k = 0; k < 3; ++k)
90  for (unsigned l = 0; l < 3; ++l)
91  dfp(i, j, k, l) += pre * dII(i, j) * dII(k, l);
92  return dfp;
93 }
ExpressionBuilder::EBTerm pow(const ExpressionBuilder::EBTerm &left, T exponent)

◆ dflowPotential_dstressV()

void TensorMechanicsPlasticModel::dflowPotential_dstressV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< RankFourTensor > &  dr_dstress 
) const
virtualinherited

The derivative of the flow potential with respect to stress.

Parameters
stressthe stress at which to calculate the flow potential
intnlinternal parameter
[out]dr_dstressdr_dstress[alpha](i, j, k, l) = dr[alpha](i, j)/dstress(k, l)

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, and TensorMechanicsPlasticTensileMulti.

Definition at line 124 of file TensorMechanicsPlasticModel.C.

127 {
128  return dr_dstress.assign(1, dflowPotential_dstress(stress, intnl));
129 }
virtual RankFourTensor dflowPotential_dstress(const RankTwoTensor &stress, Real intnl) const
The derivative of the flow potential with respect to stress.

◆ dhardPotential_dintnl()

Real TensorMechanicsPlasticModel::dhardPotential_dintnl ( const RankTwoTensor &  stress,
Real  intnl 
) const
protectedvirtualinherited

The derivative of the hardening potential with respect to the internal parameter.

Parameters
stressthe stress at which to calculate the hardening potentials
intnlinternal parameter
Returns
the derivative

Reimplemented in TensorMechanicsPlasticMeanCapTC.

Definition at line 173 of file TensorMechanicsPlasticModel.C.

Referenced by TensorMechanicsPlasticModel::dhardPotential_dintnlV().

175 {
176  return 0.0;
177 }

◆ dhardPotential_dintnlV()

void TensorMechanicsPlasticModel::dhardPotential_dintnlV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< Real > &  dh_dintnl 
) const
virtualinherited

The derivative of the hardening potential with respect to the internal parameter.

Parameters
stressthe stress at which to calculate the hardening potentials
intnlinternal parameter
[out]dh_dintnldh_dintnl[alpha] = dh[alpha]/dintnl

Definition at line 179 of file TensorMechanicsPlasticModel.C.

182 {
183  dh_dintnl.resize(numberSurfaces(), dhardPotential_dintnl(stress, intnl));
184 }
virtual unsigned int numberSurfaces() const
The number of yield surfaces for this plasticity model.
virtual Real dhardPotential_dintnl(const RankTwoTensor &stress, Real intnl) const
The derivative of the hardening potential with respect to the internal parameter. ...

◆ dhardPotential_dstress()

RankTwoTensor TensorMechanicsPlasticModel::dhardPotential_dstress ( const RankTwoTensor &  stress,
Real  intnl 
) const
protectedvirtualinherited

The derivative of the hardening potential with respect to stress.

Parameters
stressthe stress at which to calculate the hardening potentials
intnlinternal parameter
Returns
dh_dstress(i, j) = dh/dstress(i, j)

Reimplemented in TensorMechanicsPlasticMeanCapTC.

Definition at line 159 of file TensorMechanicsPlasticModel.C.

Referenced by TensorMechanicsPlasticModel::dhardPotential_dstressV().

161 {
162  return RankTwoTensor();
163 }

◆ dhardPotential_dstressV()

void TensorMechanicsPlasticModel::dhardPotential_dstressV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< RankTwoTensor > &  dh_dstress 
) const
virtualinherited

The derivative of the hardening potential with respect to stress.

Parameters
stressthe stress at which to calculate the hardening potentials
intnlinternal parameter
[out]dh_dstressdh_dstress[alpha](i, j) = dh[alpha]/dstress(i, j)

Definition at line 165 of file TensorMechanicsPlasticModel.C.

168 {
169  dh_dstress.assign(numberSurfaces(), dhardPotential_dstress(stress, intnl));
170 }
virtual unsigned int numberSurfaces() const
The number of yield surfaces for this plasticity model.
virtual RankTwoTensor dhardPotential_dstress(const RankTwoTensor &stress, Real intnl) const
The derivative of the hardening potential with respect to stress.

◆ dyieldFunction_dintnl()

Real TensorMechanicsPlasticJ2::dyieldFunction_dintnl ( const RankTwoTensor &  stress,
Real  intnl 
) const
overrideprotectedvirtual

The derivative of yield function with respect to the internal parameter.

Parameters
stressthe stress at which to calculate the yield function
intnlinternal parameter
Returns
the derivative

Reimplemented from TensorMechanicsPlasticModel.

Definition at line 66 of file TensorMechanicsPlasticJ2.C.

67 {
68  return -dyieldStrength(intnl);
69 }
virtual Real dyieldStrength(Real intnl) const
d(yieldStrength)/d(intnl)

◆ dyieldFunction_dintnlV()

void TensorMechanicsPlasticModel::dyieldFunction_dintnlV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< Real > &  df_dintnl 
) const
virtualinherited

The derivative of yield functions with respect to the internal parameter.

Parameters
stressthe stress at which to calculate the yield function
intnlinternal parameter
[out]df_dintnldf_dintnl[alpha] = df[alpha]/dintnl

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, and TensorMechanicsPlasticTensileMulti.

Definition at line 97 of file TensorMechanicsPlasticModel.C.

100 {
101  return df_dintnl.assign(1, dyieldFunction_dintnl(stress, intnl));
102 }
virtual Real dyieldFunction_dintnl(const RankTwoTensor &stress, Real intnl) const
The derivative of yield function with respect to the internal parameter.

◆ dyieldFunction_dstress()

RankTwoTensor TensorMechanicsPlasticJ2::dyieldFunction_dstress ( const RankTwoTensor &  stress,
Real  intnl 
) const
overrideprotectedvirtual

The derivative of yield function with respect to stress.

Parameters
stressthe stress at which to calculate the yield function
intnlinternal parameter
Returns
df_dstress(i, j) = dyieldFunction/dstress(i, j)

Reimplemented from TensorMechanicsPlasticModel.

Reimplemented in TensorMechanicsPlasticIsotropicSD, and TensorMechanicsPlasticOrthotropic.

Definition at line 56 of file TensorMechanicsPlasticJ2.C.

Referenced by TensorMechanicsPlasticOrthotropic::flowPotential(), flowPotential(), and TensorMechanicsPlasticIsotropicSD::flowPotential().

57 {
58  Real sII = stress.secondInvariant();
59  if (sII == 0.0)
60  return RankTwoTensor();
61  else
62  return 0.5 * std::sqrt(3.0 / sII) * stress.dsecondInvariant();
63 }

◆ dyieldFunction_dstressV()

void TensorMechanicsPlasticModel::dyieldFunction_dstressV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< RankTwoTensor > &  df_dstress 
) const
virtualinherited

The derivative of yield functions with respect to stress.

Parameters
stressthe stress at which to calculate the yield function
intnlinternal parameter
[out]df_dstressdf_dstress[alpha](i, j) = dyieldFunction[alpha]/dstress(i, j)

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, and TensorMechanicsPlasticTensileMulti.

Definition at line 83 of file TensorMechanicsPlasticModel.C.

86 {
87  df_dstress.assign(1, dyieldFunction_dstress(stress, intnl));
88 }
virtual RankTwoTensor dyieldFunction_dstress(const RankTwoTensor &stress, Real intnl) const
The derivative of yield function with respect to stress.

◆ dyieldStrength()

Real TensorMechanicsPlasticJ2::dyieldStrength ( Real  intnl) const
protectedvirtual

d(yieldStrength)/d(intnl)

Definition at line 109 of file TensorMechanicsPlasticJ2.C.

Referenced by consistentTangentOperator(), dyieldFunction_dintnl(), and returnMap().

110 {
111  return _strength.derivative(intnl);
112 }
virtual Real derivative(Real intnl) const
const TensorMechanicsHardeningModel & _strength
yield strength, from user input

◆ execute()

void TensorMechanicsPlasticModel::execute ( )
inherited

Definition at line 46 of file TensorMechanicsPlasticModel.C.

47 {
48 }

◆ finalize()

void TensorMechanicsPlasticModel::finalize ( )
inherited

Definition at line 51 of file TensorMechanicsPlasticModel.C.

52 {
53 }

◆ flowPotential()

RankTwoTensor TensorMechanicsPlasticJ2::flowPotential ( const RankTwoTensor &  stress,
Real  intnl 
) const
overrideprotectedvirtual

The flow potential.

Parameters
stressthe stress at which to calculate the flow potential
intnlinternal parameter
Returns
the flow potential

Reimplemented from TensorMechanicsPlasticModel.

Reimplemented in TensorMechanicsPlasticIsotropicSD, and TensorMechanicsPlasticOrthotropic.

Definition at line 72 of file TensorMechanicsPlasticJ2.C.

73 {
74  return dyieldFunction_dstress(stress, intnl);
75 }
virtual RankTwoTensor dyieldFunction_dstress(const RankTwoTensor &stress, Real intnl) const override
The derivative of yield function with respect to stress.

◆ flowPotentialV()

void TensorMechanicsPlasticModel::flowPotentialV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< RankTwoTensor > &  r 
) const
virtualinherited

The flow potentials.

Parameters
stressthe stress at which to calculate the flow potential
intnlinternal parameter
[out]rr[alpha] is the flow potential for the "alpha" yield function

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, and TensorMechanicsPlasticTensileMulti.

Definition at line 110 of file TensorMechanicsPlasticModel.C.

113 {
114  return r.assign(1, flowPotential(stress, intnl));
115 }
virtual RankTwoTensor flowPotential(const RankTwoTensor &stress, Real intnl) const
The flow potential.

◆ hardPotential()

Real TensorMechanicsPlasticModel::hardPotential ( const RankTwoTensor &  stress,
Real  intnl 
) const
protectedvirtualinherited

The hardening potential.

Parameters
stressthe stress at which to calculate the hardening potential
intnlinternal parameter
Returns
the hardening potential

Reimplemented in TensorMechanicsPlasticMeanCapTC.

Definition at line 146 of file TensorMechanicsPlasticModel.C.

Referenced by TensorMechanicsPlasticModel::hardPotentialV().

147 {
148  return -1.0;
149 }

◆ hardPotentialV()

void TensorMechanicsPlasticModel::hardPotentialV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< Real > &  h 
) const
virtualinherited

The hardening potential.

Parameters
stressthe stress at which to calculate the hardening potential
intnlinternal parameter
[out]hh[alpha] is the hardening potential for the "alpha" yield function

Definition at line 151 of file TensorMechanicsPlasticModel.C.

154 {
155  h.assign(numberSurfaces(), hardPotential(stress, intnl));
156 }
virtual Real hardPotential(const RankTwoTensor &stress, Real intnl) const
The hardening potential.
virtual unsigned int numberSurfaces() const
The number of yield surfaces for this plasticity model.

◆ initialize()

void TensorMechanicsPlasticModel::initialize ( )
inherited

Definition at line 41 of file TensorMechanicsPlasticModel.C.

42 {
43 }

◆ KuhnTuckerSingleSurface()

bool TensorMechanicsPlasticModel::KuhnTuckerSingleSurface ( Real  yf,
Real  dpm,
Real  dpm_tol 
) const
inherited

Returns true if the Kuhn-Tucker conditions for the single surface are satisfied.

Parameters
yfYield function value
dpmplastic multiplier
dpm_toltolerance on plastic multiplier: viz dpm>-dpm_tol means "dpm is non-negative"

Definition at line 247 of file TensorMechanicsPlasticModel.C.

Referenced by TensorMechanicsPlasticMohrCoulombMulti::KuhnTuckerOK(), TensorMechanicsPlasticTensileMulti::KuhnTuckerOK(), and TensorMechanicsPlasticModel::returnMap().

248 {
249  return (dpm == 0 && yf <= _f_tol) || (dpm > -dpm_tol && yf <= _f_tol && yf >= -_f_tol);
250 }
const Real _f_tol
Tolerance on yield function.

◆ modelName()

std::string TensorMechanicsPlasticJ2::modelName ( ) const
overridevirtual

Implements TensorMechanicsPlasticModel.

Definition at line 115 of file TensorMechanicsPlasticJ2.C.

116 {
117  return "J2";
118 }

◆ numberSurfaces()

unsigned TensorMechanicsPlasticModel::numberSurfaces ( ) const
virtualinherited

◆ returnMap()

bool TensorMechanicsPlasticJ2::returnMap ( const RankTwoTensor &  trial_stress,
Real  intnl_old,
const RankFourTensor &  E_ijkl,
Real  ep_plastic_tolerance,
RankTwoTensor &  returned_stress,
Real &  returned_intnl,
std::vector< Real > &  dpm,
RankTwoTensor &  delta_dp,
std::vector< Real > &  yf,
bool &  trial_stress_inadmissible 
) const
overridevirtual

Performs a custom return-map.

You may choose to over-ride this in your derived TensorMechanicsPlasticXXXX class, and you may implement the return-map algorithm in any way that suits you. Eg, using a Newton-Raphson approach, or a radial-return, etc. This may also be used as a quick way of ascertaining whether (trial_stress, intnl_old) is in fact admissible.

For over-riding this function, please note the following.

(1) Denoting the return value of the function by "successful_return", the only possible output values should be: (A) trial_stress_inadmissible=false, successful_return=true. That is, (trial_stress, intnl_old) is in fact admissible (in the elastic domain). (B) trial_stress_inadmissible=true, successful_return=false. That is (trial_stress, intnl_old) is inadmissible (outside the yield surface), and you didn't return to the yield surface. (C) trial_stress_inadmissible=true, successful_return=true. That is (trial_stress, intnl_old) is inadmissible (outside the yield surface), but you did return to the yield surface. The default implementation only handles case (A) and (B): it does not attempt to do a return-map algorithm.

(2) you must correctly signal "successful_return" using the return value of this function. Don't assume the calling function will do Kuhn-Tucker checking and so forth!

(3) In cases (A) and (B) you needn't set returned_stress, returned_intnl, delta_dp, or dpm. This is for computational efficiency.

(4) In cases (A) and (B), you MUST place the yield function values at (trial_stress, intnl_old) into yf so the calling function can use this information optimally. You will have already calculated these yield function values, which can be quite expensive, and it's not very optimal for the calling function to have to re-calculate them.

(5) In case (C), you need to set: returned_stress (the returned value of stress) returned_intnl (the returned value of the internal variable) delta_dp (the change in plastic strain) dpm (the plastic multipliers needed to bring about the return) yf (yield function values at the returned configuration)

(Note, if you over-ride returnMap, you will probably want to override consistentTangentOpertor too, otherwise it will default to E_ijkl.)

Parameters
trial_stressThe trial stress
intnl_oldValue of the internal parameter
E_ijklElasticity tensor
ep_plastic_toleranceTolerance defined by the user for the plastic strain
[out]returned_stressIn case (C): lies on the yield surface after returning and produces the correct plastic strain (normality condition). Otherwise: not defined
[out]returned_intnlIn case (C): the value of the internal parameter after returning. Otherwise: not defined
[out]dpmIn case (C): the plastic multipliers needed to bring about the return. Otherwise: not defined
[out]delta_dpIn case (C): The change in plastic strain induced by the return process. Otherwise: not defined
[out]yfIn case (C): the yield function at (returned_stress, returned_intnl). Otherwise: the yield function at (trial_stress, intnl_old)
[out]trial_stress_inadmissibleShould be set to false if the trial_stress is admissible, and true if the trial_stress is inadmissible. This can be used by the calling prorgram
Returns
true if a successful return (or a return-map not needed), false if the trial_stress is inadmissible but the return process failed

Reimplemented from TensorMechanicsPlasticModel.

Definition at line 121 of file TensorMechanicsPlasticJ2.C.

131 {
132  if (!(_use_custom_returnMap))
133  return TensorMechanicsPlasticModel::returnMap(trial_stress,
134  intnl_old,
135  E_ijkl,
136  ep_plastic_tolerance,
137  returned_stress,
138  returned_intnl,
139  dpm,
140  delta_dp,
141  yf,
142  trial_stress_inadmissible);
143 
144  yf.resize(1);
145 
146  Real yf_orig = yieldFunction(trial_stress, intnl_old);
147 
148  yf[0] = yf_orig;
149 
150  if (yf_orig < _f_tol)
151  {
152  // the trial_stress is admissible
153  trial_stress_inadmissible = false;
154  return true;
155  }
156 
157  trial_stress_inadmissible = true;
158  Real mu = E_ijkl(0, 1, 0, 1);
159 
160  // Perform a Newton-Raphson to find dpm when
161  // residual = 3*mu*dpm - trial_equivalent_stress + yieldStrength(intnl_old + dpm) = 0
162  Real trial_equivalent_stress = yf_orig + yieldStrength(intnl_old);
163  Real residual;
164  Real jac;
165  dpm[0] = 0;
166  unsigned int iter = 0;
167  do
168  {
169  residual = 3.0 * mu * dpm[0] - trial_equivalent_stress + yieldStrength(intnl_old + dpm[0]);
170  jac = 3.0 * mu + dyieldStrength(intnl_old + dpm[0]);
171  dpm[0] += -residual / jac;
172  if (iter > _max_iters) // not converging
173  return false;
174  iter++;
175  } while (residual * residual > _f_tol * _f_tol);
176 
177  // set the returned values
178  yf[0] = 0;
179  returned_intnl = intnl_old + dpm[0];
180  RankTwoTensor nn = 1.5 * trial_stress.deviatoric() /
181  trial_equivalent_stress; // = dyieldFunction_dstress(trial_stress, intnl_old) =
182  // the normal to the yield surface, at the trial
183  // stress
184  returned_stress = 2.0 / 3.0 * nn * yieldStrength(returned_intnl);
185  returned_stress.addIa(1.0 / 3.0 * trial_stress.trace());
186  delta_dp = nn * dpm[0];
187 
188  return true;
189 }
virtual Real yieldStrength(Real intnl) const
YieldStrength.
const unsigned _max_iters
max iters for custom return map loop
virtual Real dyieldStrength(Real intnl) const
d(yieldStrength)/d(intnl)
const bool _use_custom_returnMap
Whether to use the custom return-map algorithm.
const Real _f_tol
Tolerance on yield function.
virtual Real yieldFunction(const RankTwoTensor &stress, Real intnl) const override
The following functions are what you should override when building single-plasticity models...
virtual bool returnMap(const RankTwoTensor &trial_stress, Real intnl_old, const RankFourTensor &E_ijkl, Real ep_plastic_tolerance, RankTwoTensor &returned_stress, Real &returned_intnl, std::vector< Real > &dpm, RankTwoTensor &delta_dp, std::vector< Real > &yf, bool &trial_stress_inadmissible) const
Performs a custom return-map.

◆ useCustomCTO()

bool TensorMechanicsPlasticJ2::useCustomCTO ( ) const
overridevirtual

Returns false. You will want to override this in your derived class if you write a custom consistent tangent operator function.

Reimplemented from TensorMechanicsPlasticModel.

Definition at line 222 of file TensorMechanicsPlasticJ2.C.

223 {
224  return _use_custom_cto;
225 }
const bool _use_custom_cto
Whether to use the custom consistent tangent operator calculation.

◆ useCustomReturnMap()

bool TensorMechanicsPlasticJ2::useCustomReturnMap ( ) const
overridevirtual

Returns false. You will want to override this in your derived class if you write a custom returnMap function.

Reimplemented from TensorMechanicsPlasticModel.

Definition at line 216 of file TensorMechanicsPlasticJ2.C.

217 {
218  return _use_custom_returnMap;
219 }
const bool _use_custom_returnMap
Whether to use the custom return-map algorithm.

◆ yieldFunction()

Real TensorMechanicsPlasticJ2::yieldFunction ( const RankTwoTensor &  stress,
Real  intnl 
) const
overrideprotectedvirtual

The following functions are what you should override when building single-plasticity models.

The yield function

Parameters
stressthe stress at which to calculate the yield function
intnlinternal parameter
Returns
the yield function

Reimplemented from TensorMechanicsPlasticModel.

Reimplemented in TensorMechanicsPlasticIsotropicSD, and TensorMechanicsPlasticOrthotropic.

Definition at line 50 of file TensorMechanicsPlasticJ2.C.

Referenced by returnMap().

51 {
52  return std::sqrt(3.0 * stress.secondInvariant()) - yieldStrength(intnl);
53 }
virtual Real yieldStrength(Real intnl) const
YieldStrength.

◆ yieldFunctionV()

void TensorMechanicsPlasticModel::yieldFunctionV ( const RankTwoTensor &  stress,
Real  intnl,
std::vector< Real > &  f 
) const
virtualinherited

Calculates the yield functions.

Note that for single-surface plasticity you don't want to override this - override the private yieldFunction below

Parameters
stressthe stress at which to calculate the yield function
intnlinternal parameter
[out]fthe yield functions

Reimplemented in TensorMechanicsPlasticMohrCoulombMulti, and TensorMechanicsPlasticTensileMulti.

Definition at line 68 of file TensorMechanicsPlasticModel.C.

Referenced by TensorMechanicsPlasticModel::returnMap().

71 {
72  f.assign(1, yieldFunction(stress, intnl));
73 }
virtual Real yieldFunction(const RankTwoTensor &stress, Real intnl) const
The following functions are what you should override when building single-plasticity models...

◆ yieldStrength()

Real TensorMechanicsPlasticJ2::yieldStrength ( Real  intnl) const
protectedvirtual

YieldStrength.

The yield function is sqrt(3*J2) - yieldStrength. In this class yieldStrength = 1, but this may be over-ridden by derived classes with nontrivial hardning

Definition at line 103 of file TensorMechanicsPlasticJ2.C.

Referenced by returnMap(), TensorMechanicsPlasticOrthotropic::yieldFunction(), yieldFunction(), and TensorMechanicsPlasticIsotropicSD::yieldFunction().

104 {
105  return _strength.value(intnl);
106 }
virtual Real value(Real intnl) const
const TensorMechanicsHardeningModel & _strength
yield strength, from user input

Member Data Documentation

◆ _f_tol

const Real TensorMechanicsPlasticModel::_f_tol
inherited

◆ _ic_tol

const Real TensorMechanicsPlasticModel::_ic_tol
inherited

Tolerance on internal constraint.

Definition at line 177 of file TensorMechanicsPlasticModel.h.

◆ _max_iters

const unsigned TensorMechanicsPlasticJ2::_max_iters
private

max iters for custom return map loop

Definition at line 85 of file TensorMechanicsPlasticJ2.h.

Referenced by returnMap().

◆ _strength

const TensorMechanicsHardeningModel& TensorMechanicsPlasticJ2::_strength
private

yield strength, from user input

Definition at line 82 of file TensorMechanicsPlasticJ2.h.

Referenced by dyieldStrength(), and yieldStrength().

◆ _use_custom_cto

const bool TensorMechanicsPlasticJ2::_use_custom_cto
private

Whether to use the custom consistent tangent operator calculation.

Definition at line 91 of file TensorMechanicsPlasticJ2.h.

Referenced by consistentTangentOperator(), and useCustomCTO().

◆ _use_custom_returnMap

const bool TensorMechanicsPlasticJ2::_use_custom_returnMap
private

Whether to use the custom return-map algorithm.

Definition at line 88 of file TensorMechanicsPlasticJ2.h.

Referenced by returnMap(), and useCustomReturnMap().


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