www.mooseframework.org
ComputeRSphericalIncrementalStrain.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 #include "Assembly.h"
12 #include "FEProblem.h"
13 #include "MooseMesh.h"
14 
15 #include "libmesh/quadrature.h"
16 
18 
20 
21 InputParameters
23 {
24  InputParameters params = ComputeIncrementalSmallStrain::validParams();
25  params.addClassDescription(
26  "Compute a strain increment for incremental strains in 1D spherical symmetry problems.");
27  return params;
28 }
29 
31  const InputParameters & parameters)
32  : ComputeIncrementalSmallStrain(parameters), _disp_old_0(coupledValueOld("displacements", 0))
33 {
34 }
35 
36 void
38 {
40 
41  const auto & subdomainIDs = _mesh.meshSubdomains();
42  for (auto subdomainID : subdomainIDs)
43  if (_fe_problem.getCoordSystem(subdomainID) != Moose::COORD_RSPHERICAL)
44  mooseError("The coordinate system must be set to RSPHERICAL for 1D R spherical simulations.");
45 }
46 
47 void
49  RankTwoTensor & total_strain_increment)
50 {
51  // Deformation gradient calculation in cylindrical coordinates
52  RankTwoTensor A; // Deformation gradient
53  RankTwoTensor Fbar; // Old Deformation gradient
54 
55  // Step through calculating the current and old deformation gradients
56  // Only diagonal components are nonzero because this is a 1D material
57  // Note: x_disp is the radial displacement
58  A(0, 0) = (*_grad_disp[0])[_qp](0);
59  Fbar(0, 0) = (*_grad_disp_old[0])[_qp](0);
60 
61  // The polar and azimuthal strains are functions of radial displacement
62  if (!MooseUtils::relativeFuzzyEqual(_q_point[_qp](0), 0.0))
63  {
64  A(1, 1) = (*_disp[0])[_qp] / _q_point[_qp](0);
65  Fbar(1, 1) = _disp_old_0[_qp] / _q_point[_qp](0);
66  }
67 
68  // The polar and azimuthal strains are equivalent in this 1D problem
69  A(2, 2) = A(1, 1);
70  Fbar(2, 2) = Fbar(1, 1);
71 
72  // Gauss point deformation gradient
73  _deformation_gradient[_qp] = A;
74  _deformation_gradient[_qp].addIa(1.0);
75 
76  // very nearly A = gradU - gradUold, adapted to cylindrical coords
77  A -= Fbar;
78 
79  total_strain_increment = 0.5 * (A + A.transpose());
80 }
ComputeRSphericalIncrementalStrain.h
ComputeIncrementalSmallStrain
ComputeIncrementalSmallStrain defines a strain increment and rotation increment (=1),...
Definition: ComputeIncrementalSmallStrain.h:23
ComputeRSphericalIncrementalStrain::ComputeRSphericalIncrementalStrain
ComputeRSphericalIncrementalStrain(const InputParameters &parameters)
Definition: ComputeRSphericalIncrementalStrain.C:30
ComputeStrainBase::_disp
std::vector< const VariableValue * > _disp
Definition: ComputeStrainBase.h:41
ComputeRSphericalIncrementalStrain
ComputeRSphericalIncrementalStrain defines a strain increment only for small strains in 1D spherical ...
Definition: ComputeRSphericalIncrementalStrain.h:25
ComputeRSphericalIncrementalStrain::_disp_old_0
const VariableValue & _disp_old_0
the old value of the first component of the displacements vector
Definition: ComputeRSphericalIncrementalStrain.h:40
ComputeIncrementalStrainBase::_grad_disp_old
std::vector< const VariableGradient * > _grad_disp_old
Definition: ComputeIncrementalStrainBase.h:36
ComputeRSphericalIncrementalStrain::computeTotalStrainIncrement
virtual void computeTotalStrainIncrement(RankTwoTensor &total_strain_increment) override
Computes the current and old deformation gradients with the assumptions for 1D spherical symmetry geo...
Definition: ComputeRSphericalIncrementalStrain.C:48
registerMooseObject
registerMooseObject("TensorMechanicsApp", ComputeRSphericalIncrementalStrain)
ComputeIncrementalStrainBase::_deformation_gradient
MaterialProperty< RankTwoTensor > & _deformation_gradient
Definition: ComputeIncrementalStrainBase.h:42
ComputeIncrementalStrainBase::initialSetup
void initialSetup() override
Definition: ComputeIncrementalStrainBase.C:38
ComputeRSphericalIncrementalStrain::initialSetup
virtual void initialSetup() override
Definition: ComputeRSphericalIncrementalStrain.C:37
RankTwoTensorTempl< Real >
ComputeRSphericalIncrementalStrain::validParams
static InputParameters validParams()
Definition: ComputeRSphericalIncrementalStrain.C:22
ComputeIncrementalSmallStrain::validParams
static InputParameters validParams()
Definition: ComputeIncrementalSmallStrain.C:19
ComputeStrainBase::_grad_disp
std::vector< const VariableGradient * > _grad_disp
Definition: ComputeStrainBase.h:42
defineLegacyParams
defineLegacyParams(ComputeRSphericalIncrementalStrain)