https://mooseframework.inl.gov
Loading...
Searching...
No Matches
ADComputeIncrementalStrain.C
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
11#include "RankTwoTensor.h"
12#include "RankFourTensor.h"
15
16#include "libmesh/quadrature.h"
17
19registerMooseObjectRenamed("SolidMechanicsApp",
20 ADComputeIncrementalSmallStrain,
21 "06/30/2025 24:00",
23
24template <typename R2>
27{
30 "Compute a strain increment and rotation increment for small strains.");
31 return params;
32}
33
34template <typename R2>
40
41template <typename R2>
42void
44{
45 ADReal volumetric_strain = 0.0;
46 for (_qp = 0; _qp < _qrule->n_points(); ++_qp)
47 {
48 ADR2 total_strain_increment;
49 computeTotalStrainIncrement(total_strain_increment);
50
51 _strain_increment[_qp] = total_strain_increment;
52
53 if (_volumetric_locking_correction)
54 volumetric_strain += total_strain_increment.trace() * _JxW[_qp] * _coord[_qp];
55 }
56
57 if (_volumetric_locking_correction)
58 volumetric_strain /= _current_elem_volume;
59
60 for (_qp = 0; _qp < _qrule->n_points(); ++_qp)
61 {
62 if (_volumetric_locking_correction)
63 {
64 const auto correction = (volumetric_strain - _strain_increment[_qp].trace()) / 3.0;
65 _strain_increment[_qp].addIa(correction);
66 }
67
68 _total_strain[_qp] = _strain_increment[_qp] + _total_strain_old[_qp];
69
70 // Remove the Eigen strain increment
71 this->subtractEigenstrainIncrementFromStrain(_strain_increment[_qp]);
72
73 // strain rate
74 if (_dt > 0)
75 _strain_rate[_qp] = _strain_increment[_qp] / _dt;
76 else
77 _strain_rate[_qp].zero();
78
79 // Update strain in intermediate configuration: rotations are not needed
80 _mechanical_strain[_qp] = _strain_increment[_qp] + _mechanical_strain_old[_qp];
81
82 // incremental small strain does not include rotation
83 _rotation_increment[_qp].setToIdentity();
84 }
85}
86
87template <typename R2>
88void
90{
91 // Deformation gradient (symmetrized)
92 const auto A = ADR2::initializeSymmetric(
93 (*_grad_disp[0])[_qp], (*_grad_disp[1])[_qp], (*_grad_disp[2])[_qp]);
94 // Old Deformation gradient (symmetrized)
95 const auto Fbar = ADR2::initializeSymmetric(
96 (*_grad_disp_old[0])[_qp], (*_grad_disp_old[1])[_qp], (*_grad_disp_old[2])[_qp]);
97
98 total_strain_increment = A - Fbar;
99}
100
registerMooseObjectRenamed("SolidMechanicsApp", ADComputeIncrementalSmallStrain, "06/30/2025 24:00", ADComputeIncrementalStrain)
registerMooseObject("SolidMechanicsApp", ADComputeIncrementalStrain)
DualNumber< Real, DNDerivativeType, true > ADReal
ADComputeIncrementalStrainBase is the base class for strain tensors using incremental formulations.
ADComputeIncrementalStrainTempl defines a strain increment and rotation increment (=1),...
Moose::GenericType< R2, true > ADR2
ADComputeIncrementalStrainTempl(const InputParameters &parameters)
virtual void computeTotalStrainIncrement(ADR2 &total_strain_increment)
Computes the current and old deformation gradients and passes back the total strain increment tensor.
void addClassDescription(const std::string &doc_string)