https://mooseframework.inl.gov
Loading...
Searching...
No Matches
ComputeMultipleCrystalPlasticityStress.h
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
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
10#pragma once
11
13
16
17#include "RankTwoTensor.h"
18#include "RankFourTensor.h"
19
31{
32public:
34
36
37 virtual void initialSetup() override;
38
39protected:
40 virtual void computeQpStress() override;
41
48 virtual void updateStress(RankTwoTensor & cauchy_stress, RankFourTensor & jacobian_mult);
49
55 virtual void initQpStatefulProperties() override;
56
62
67 void preSolveQp();
68
73 void solveQp();
74
78 void postSolveQp(RankTwoTensor & stress_new, RankFourTensor & jacobian_mult);
79
85
89 void solveStress();
90
97 void calculateResidual();
98
104 void calculateJacobian();
105
107 void calcTangentModuli(RankFourTensor & jacobian_mult);
108 void elasticTangentModuli(RankFourTensor & jacobian_mult);
109 void elastoPlasticTangentModuli(RankFourTensor & jacobian_mult);
111
113 bool lineSearchUpdate(const Real & rnorm_prev, const RankTwoTensor & dpk2);
114
119
121 const unsigned _num_models;
122
124 std::vector<CrystalPlasticityStressUpdateBase *> _models;
125
127 const unsigned _num_eigenstrains;
128
130 std::vector<ComputeCrystalPlasticityEigenstrainBase *> _eigenstrains;
131
133 const std::string _base_name;
134
137
139 Real _rtol;
142
147
149 unsigned int _maxiter;
151 unsigned int _maxiterg;
152
155
157 unsigned int _max_substep_iter;
158
161
164
167
170
173
176
181
186
191
196
199
206
211
217
225
228
231
236
239};
ComputeFiniteStrainElasticStress computes the stress following elasticity theory for finite strains.
ComputeMultipleCrystalPlasticityStress (used together with CrystalPlasticityStressUpdateBase) uses th...
void preSolveQp()
Reset the PK2 stress and the inverse deformation gradient to old values and provide an interface for ...
const MaterialProperty< RankTwoTensor > & _crysrot
Crystal rotation in the original, or reference, configuration as defined by Euler angle arguments in ...
void postSolveQp(RankTwoTensor &stress_new, RankFourTensor &jacobian_mult)
Save the final stress and internal variable values after the iterative solve.
const MaterialProperty< RankTwoTensor > & _deformation_gradient
Total deformation gradient RankTwoTensor for the crystal.
void solveStress()
solves for stress, updates plastic deformation gradient.
Real _abs_tol
Stress residual equation absolute tolerance.
void calculateResidual()
Calculate stress residual as the difference between the stored material property PK2 stress and the e...
RankTwoTensor _temporary_deformation_gradient
Helper deformation gradient tensor variables used in iterative solve.
unsigned int _maxiter
Maximum number of iterations for stress update.
void calculateJacobian()
Calculates the jacobian as $\mathbf{J} = \mathbf{I} - \mathbf{C} \frac{d\mathbf{E}^e}{d\mathbf{F}^e} ...
MaterialProperty< RankTwoTensor > & _plastic_deformation_gradient
Plastic deformation gradient RankTwoTensor for the crystal.
void calcTangentModuli(RankFourTensor &jacobian_mult)
Calculates the tangent moduli for use as a preconditioner, using the elastic or elastic-plastic optio...
enum ComputeMultipleCrystalPlasticityStress::TangentModuliType _tan_mod_type
bool _convergence_failed
Flag to check whether convergence is achieved or if substepping is needed.
Real _rtol
Stress residual equation relative tolerance.
bool lineSearchUpdate(const Real &rnorm_prev, const RankTwoTensor &dpk2)
performs the line search update
enum ComputeMultipleCrystalPlasticityStress::LineSearchMethod _line_search_method
const MaterialProperty< RankFourTensor > & _elasticity_tensor
Elasticity tensor as defined by a separate class.
const bool _print_convergence_message
Flag to print to console warning messages on stress, constitutive model convergence.
Real _dfgrd_scale_factor
Scales the substepping increment to obtain deformation gradient at a substep iteration.
MaterialProperty< RankTwoTensor > & _updated_rotation
Tracks the rotation of the crystal during deformation Note: this rotation tensor is not applied to th...
MaterialProperty< RankTwoTensor > & _total_lagrangian_strain
Lagrangian total strain measure for the entire crystal.
std::vector< CrystalPlasticityStressUpdateBase * > _models
The user supplied cyrstal plasticity consititutive models.
virtual void computeQpStress() override
Compute the stress and store it in the _stress material property for the current quadrature point.
virtual void initQpStatefulProperties() override
initializes the stateful properties such as PK2 stress, resolved shear stress, plastic deformation gr...
const std::string _base_name
optional parameter to define several mechanical systems on the same block, e.g. multiple phases
const MaterialProperty< RankTwoTensor > * _eigenstrain_deformation_gradient_old
void solveQp()
Solve the stress and internal state variables (e.g.
MaterialProperty< Real > & _misorientation
Misorientation angle of the crystal during deformation.
unsigned int _line_search_max_iterations
Line search bisection method maximum iteration number.
void solveStateVariables()
Solves the internal variables stress as a function of the slip specified by the constitutive model de...
Real _line_search_tolerance
Line search bisection method tolerance.
void calculateEigenstrainDeformationGrad()
Calculates the deformation gradient due to eigenstrain.
const MaterialProperty< RankTwoTensor > & _updated_rotation_old
unsigned int _maxiterg
Maximum number of iterations for internal variable update.
void calculateResidualAndJacobian()
Calls the residual and jacobian functions used in the stress update algorithm.
MaterialProperty< RankTwoTensor > * _eigenstrain_deformation_gradient
Generalized eigenstrain deformation gradient RankTwoTensor for the crystal.
RankTwoTensor _delta_deformation_gradient
Used for substepping; Uniformly divides the increment in deformation gradient.
const MaterialProperty< RankTwoTensor > & _deformation_gradient_old
MaterialProperty< RankTwoTensor > & _pk2
Second Piola-Kirchoff stress measure.
unsigned int _max_substep_iter
Maximum number of substep iterations.
const MaterialProperty< RankTwoTensor > & _plastic_deformation_gradient_old
virtual void updateStress(RankTwoTensor &cauchy_stress, RankFourTensor &jacobian_mult)
Updates the stress (PK2) at a quadrature point by calling constiutive relationship as defined in a ch...
std::vector< ComputeCrystalPlasticityEigenstrainBase * > _eigenstrains
The user supplied cyrstal plasticity eigenstrains.