https://mooseframework.inl.gov
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
TotalLagrangianStressDivergenceBase< G > Class Template Reference

Enforce equilibrium with a total Lagrangian formulation. More...

#include <TotalLagrangianStressDivergenceBase.h>

Inheritance diagram for TotalLagrangianStressDivergenceBase< G >:
[legend]

Public Types

enum  FBarMode { FBarMode::Total, FBarMode::Incremental }
 Mirrors ComputeLagrangianStrainBase::FBarMode. More...
 
typedef std::vector< intJvarMap
 

Public Member Functions

 TotalLagrangianStressDivergenceBase (const InputParameters &parameters)
 
virtual void initialSetup () override
 Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee. More...
 
template<>
InputParameters validParams ()
 
template<>
void initialSetup ()
 Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee. More...
 
template<>
InputParameters validParams ()
 
template<>
void initialSetup ()
 Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee. More...
 
template<>
InputParameters validParams ()
 
template<>
void initialSetup ()
 Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee. More...
 
virtual void computeOffDiagJacobian (unsigned int jvar) override
 
unsigned int mapJvarToCvar (unsigned int jvar)
 
int mapJvarToCvar (unsigned int jvar, const JvarMap &jvar_map)
 
bool mapJvarToCvar (unsigned int jvar, unsigned int &cvar)
 
const JvarMapgetJvarMap ()
 
const JvarMapgetParameterJvarMap (std::string parameter_name)
 

Static Public Member Functions

static InputParameters baseParams ()
 
static InputParameters validParams ()
 

Protected Member Functions

virtual RankTwoTensor gradTest (unsigned int component) override
 
virtual RankTwoTensor gradTrial (unsigned int component) override
 
virtual void precalculateJacobianDisplacement (unsigned int component) override
 Prepare the average shape function gradients for stabilization. More...
 
virtual void precalculateResidual () override
 
virtual void precalculateJacobian () override
 
virtual void precalculateOffDiagJacobian (unsigned int jvar) override
 
virtual Real computeQpResidual () override
 
virtual Real computeQpJacobianDisplacement (unsigned int alpha, unsigned int beta) override
 
virtual Real computeQpJacobianTemperature (unsigned int cvar) override
 
virtual Real computeQpJacobianOutOfPlaneStrain () override
 
void computeAverageGradientSpatialTest ()
 Compute element-averaged spatial gradient of test functions for component _alpha, filling _avg_grad_spatial_test. More...
 
void computeAverageGradientSpatialPhi (unsigned int beta)
 Compute element-averaged spatial gradient of trial functions for component beta, filling _avg_grad_spatial_phi[beta]. More...
 
void computeAvgTestPhiCross (unsigned int beta)
 Compute element-averaged cross product (grad_x test_i)_{b1} * (grad_x phi_j)_{b2} for b1, b2 in {_alpha, beta} (4 combinations), filling _avg_test_phi_cross[b1][b2][i][j]. More...
 
Real gradXTestComponent (unsigned int component) const
 (grad_x test_i)_component at the current _qp, where the push-forward uses the unstabilized F (= F_actual at alpha = 1), consistent with the PK1 wrap. More...
 
Real gradXPhiComponent (unsigned int component) const
 (grad_x phi_j)_component at the current _qp, same push-forward as gradXTestComponent. More...
 
virtual RankTwoTensor gradTrialUnstabilized (unsigned int component)
 The unstabilized trial function gradient. More...
 
virtual Real computeQpJacobian () override
 
virtual Real computeQpOffDiagJacobian (unsigned int jvar) override
 
RankTwoTensor deltaPK1NonLocalFBar (const RankTwoTensor &delta_F_avg) const
 Non-local F-bar contribution to deltaPK1 at the current _qp, given the perturbation delta_F_avg of the element-average F. More...
 
bool hasGuaranteedMaterialProperty (const MaterialPropertyName &prop, Guarantee guarantee)
 

Protected Attributes

const MaterialProperty< RankTwoTensor > & _pk1
 The 1st Piola-Kirchhoff stress. More...
 
const MaterialProperty< RankFourTensor > & _dpk1
 The derivative of the PK1 stress with respect to the deformation gradient (F that the stress material consumed, i.e. More...
 
const MaterialProperty< RankFourTensor > & _dpk1_d_grad_u
 The derivative of the PK1 stress with respect to the displacement gradient (grad u_{n+1}). More...
 
const MaterialProperty< RankFourTensor > & _dpk1_bypass_fbar
 Variant of _dpk1 (= pk1_jacobian) computed WITHOUT the F-bar chain factor _d_F_stab_d_F_ust in the sigma-via-dL contribution. More...
 
bool _large_kinematics
 If true use large deformation kinematics. More...
 
const bool _stabilize_strain
 If true calculate the deformation gradient derivatives for F_bar. More...
 
const FBarMode _F_bar_mode
 What F gets F-bar volumetric correction (Total vs. More...
 
const std::string _base_name
 Prepend to the material properties. More...
 
const unsigned int _alpha
 Which component of the vector residual this kernel is responsible for. More...
 
const unsigned int _ndisp
 Total number of displacements/size of residual vector. More...
 
std::vector< unsigned int_disp_nums
 The displacement numbers. More...
 
std::vector< std::vector< RankTwoTensor > > _avg_grad_trial
 
std::vector< Real_avg_grad_spatial_test
 Element-averaged spatial (deformed-frame) gradient of test functions for the kernel's component _alpha: _avg_grad_spatial_test[i] = (1/V_x) int_e (grad_x test_i)_alpha dV_x Used for OLD-compat B-bar volumetric correction in F_bar_mode = incremental. More...
 
std::vector< std::vector< Real > > _avg_grad_spatial_phi
 Element-averaged spatial gradient of trial functions per component: _avg_grad_spatial_phi[component][j] = (1/V_x) int_e (grad_x phi_j)_component dV_x Populated alongside _avg_grad_spatial_test for the Jacobian's B-bar contribution. More...
 
std::vector< std::vector< std::vector< std::vector< Real > > > > _avg_test_phi_cross
 Element-averaged cross product (on displaced mesh) of spatial test/trial gradients: avg_test_phi_cross[b1][b2][i][j] = (1/V_x) int_e (grad_x test_i){b1} * (grad_x phi_j)_{b2} dV_x Indexed by [b1][b2] in {0,1,2}^2. More...
 
const MaterialProperty< RankTwoTensor > & _F_ust
 The unmodified deformation gradient. More...
 
const MaterialProperty< RankTwoTensor > & _F_ust_old
 Old unstabilized deformation gradient. More...
 
const MaterialProperty< RankTwoTensor > & _F_avg
 The element-average deformation gradient. More...
 
const MaterialProperty< RankTwoTensor > & _f_inv
 The inverse increment deformation gradient. More...
 
const MaterialProperty< RankTwoTensor > & _F_inv
 The inverse deformation gradient. More...
 
const MaterialProperty< RankTwoTensor > * _F_ust_inv = nullptr
 F_ust^{-1} and det(F_ust) from the strain calculator, consumed by the F-bar spatial push-forward (grad_x = F_ust^{-T} grad_X, J_ust = det F_ust) on both the residual and Jacobian sweeps. More...
 
const MaterialProperty< Real > * _F_ust_det = nullptr
 
const MaterialProperty< RankTwoTensor > & _F
 The actual (stabilized) deformation gradient. More...
 
const MaterialProperty< RankTwoTensor > & _F_actual
 The literal deformation gradient at n+1 (I + grad u_{n+1}), independent of alpha and F-bar. More...
 
const MaterialProperty< RankFourTensor > & _d_deformation_gradient_increment_d_F
 Derivative of the spatial velocity gradient increment w.r.t. F_{n+1}. More...
 
const MaterialProperty< RankFourTensor > & _d_F_d_grad_u
 Derivative of F_{n+1} w.r.t. the displacement gradient. More...
 
const MaterialProperty< RankFourTensor > & _d_F_stab_d_F_ust
 Partials of the F-bar-stabilized deformation gradient. More...
 
const MaterialProperty< RankFourTensor > & _d_F_stab_d_F_avg
 
const MooseVariable_temperature
 Temperature, if provided. This is used only to get the trial functions. More...
 
const MooseVariable_out_of_plane_strain
 Out-of-plane strain, if provided. More...
 
std::vector< std::vector< const MaterialProperty< RankTwoTensor > * > > _deigenstrain_dargs
 Eigenstrain derivatives wrt generate coupleds. More...
 
const MaterialProperty< RankFourTensor > * _dcauchy_stress_d_eigenstrain = nullptr
 Derivative of the Cauchy stress with respect to the eigenstrain (published by ComputeLagrangianObjectiveStress; can be overridden by other Cauchy-providing materials). More...
 
const MaterialProperty< RankFourTensor > * _d_nl_fbar = nullptr
 Composed non-local F-bar operator D_nl = cauchy_jac : d(dL)/dF : d(F_stab)/d(F_avg), published per qp by the stress material (once per element, shared by all displacement kernels). More...
 
const unsigned int _n_args
 

Private Member Functions

void populateLocalPK1Cache (unsigned int beta)
 Populate the per-(qp, j) caches consumed by computeQpJacobianDisplacement. More...
 
void cachePK1ContractionFUst ()
 Cache pk1 : F_ust per qp (the J * tr(sigma) factor of the B-bar volumetric correction). More...
 

Private Attributes

std::vector< std::vector< RankTwoTensor > > _dpk1_grad_trial_cache
 _dpk1_d_grad_u[qp] * gradTrial(beta) per (qp, j) for the current Jacobian column's beta. More...
 
std::vector< std::vector< RankTwoTensor > > _grad_trial_cache
 Cached gradTrialUnstabilized(beta) per (qp, j) for the current column. More...
 
std::vector< std::vector< RankTwoTensor > > _delta_PK1_NL_cache
 Fully wrapped non-local F-bar contribution to deltaPK1 per (qp, j) for the current column: _d_nl_fbar[qp] * (_d_F_d_grad_u[qp] * _avg_grad_trial[beta][j]) then PK1-wrapped via the strain calc's det(F_ust) / F_ust^{-1} properties in large kinematics. More...
 
std::vector< std::vector< RankTwoTensor > > _dpk1_total_cache
 Local + non-local PK1 derivative per (qp, j): _dpk1_grad_trial_cache + _delta_PK1_NL_cache. More...
 
std::vector< Real_pk1_ddot_F_ust
 pk1 : F_ust per qp for the B-bar volumetric correction (see cachePK1ContractionFUst). More...
 
std::vector< std::vector< Real > > _dA_dU_cache
 d(pk1 : F_ust)/dU per (qp, j) for the current column – the B-bar Jacobian's dA/dU term. More...
 

Detailed Description

template<class G>
class TotalLagrangianStressDivergenceBase< G >

Enforce equilibrium with a total Lagrangian formulation.

This class enforces equilibrium when used in conjunction with the corresponding strain calculator (CalculateStrainLagrangianKernel) and with either a stress calculator that provides the 1st PK stress ("pk1_stress") and the derivative of the 1st PK stress with respect to the deformation gradient ("pk1_jacobian")

This kernel should be used with the new "ComputeLagrangianStressBase" stress update system and the "ComputeLagrangianStrain" system for strains.

Definition at line 27 of file TotalLagrangianStressDivergenceBase.h.

Member Enumeration Documentation

◆ FBarMode

Mirrors ComputeLagrangianStrainBase::FBarMode.

Replicated here (rather than included) so this header doesn't need to pull in the templated strain header.

Enumerator
Total 
Incremental 

Definition at line 39 of file LagrangianStressDivergenceBase.h.

40  {
41  Total,
42  Incremental
43  };

Constructor & Destructor Documentation

◆ TotalLagrangianStressDivergenceBase()

Definition at line 23 of file TotalLagrangianStressDivergenceBase.C.

25  : LagrangianStressDivergenceBase(parameters),
26  _pk1(getMaterialPropertyByName<RankTwoTensor>(_base_name + "pk1_stress")),
27  _dpk1(getMaterialPropertyByName<RankFourTensor>(_base_name + "pk1_jacobian")),
28  _dpk1_d_grad_u(getMaterialPropertyByName<RankFourTensor>(_base_name + "dpk1_d_grad_u")),
30  getMaterialPropertyByName<RankFourTensor>(_base_name + "pk1_jacobian_bypass_fbar"))
31 {
32 }
const MaterialProperty< RankTwoTensor > & _pk1
The 1st Piola-Kirchhoff stress.
LagrangianStressDivergenceBase(const InputParameters &parameters)
const MaterialProperty< RankFourTensor > & _dpk1_bypass_fbar
Variant of _dpk1 (= pk1_jacobian) computed WITHOUT the F-bar chain factor _d_F_stab_d_F_ust in the si...
const MaterialProperty< RankFourTensor > & _dpk1_d_grad_u
The derivative of the PK1 stress with respect to the displacement gradient (grad u_{n+1}).
const MaterialProperty< RankFourTensor > & _dpk1
The derivative of the PK1 stress with respect to the deformation gradient (F that the stress material...
const std::string _base_name
Prepend to the material properties.

Member Function Documentation

◆ baseParams()

template<class G >
InputParameters TotalLagrangianStressDivergenceBase< G >::baseParams ( )
static

Definition at line 14 of file TotalLagrangianStressDivergenceBase.C.

Referenced by TotalLagrangianStressDivergenceBase< G >::validParams().

15 {
17  // This kernel requires use_displaced_mesh to be off
18  params.suppressParameter<bool>("use_displaced_mesh");
19  return params;
20 }
void suppressParameter(const std::string &name)

◆ cachePK1ContractionFUst()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::cachePK1ContractionFUst ( )
private

Cache pk1 : F_ust per qp (the J * tr(sigma) factor of the B-bar volumetric correction).

Column-independent, so it is hoisted out of the per-(_i) residual loop and the per-(_i, _j, component) Jacobian loop. Gated on F_bar_mode = incremental.

Definition at line 108 of file TotalLagrangianStressDivergenceBase.C.

109 {
110  const unsigned int n_qp = _qrule->n_points();
111  _pk1_ddot_F_ust.assign(n_qp, 0.0);
112  for (const auto qp : make_range(n_qp))
113  _pk1_ddot_F_ust[qp] = _pk1[qp].doubleContraction(_F_ust[qp]);
114 }
const MaterialProperty< RankTwoTensor > & _pk1
The 1st Piola-Kirchhoff stress.
std::vector< Real > _pk1_ddot_F_ust
pk1 : F_ust per qp for the B-bar volumetric correction (see cachePK1ContractionFUst).
const MaterialProperty< RankTwoTensor > & _F_ust
The unmodified deformation gradient.
IntRange< T > make_range(T beg, T end)

◆ computeAverageGradientSpatialPhi()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::computeAverageGradientSpatialPhi ( unsigned int  beta)
protected

Compute element-averaged spatial gradient of trial functions for component beta, filling _avg_grad_spatial_phi[beta].

Used for the B-bar Jacobian contribution.

Definition at line 273 of file TotalLagrangianStressDivergenceBase.C.

274 {
275  // Same structure as computeAverageGradientSpatialTest, but for trial functions and component
276  // beta.
277  _avg_grad_spatial_phi[beta].assign(_phi.size(), 0.0);
278  Real V_x = 0.0;
279  for (unsigned int qp = 0; qp < _qrule->n_points(); ++qp)
280  {
281  const Real J = _large_kinematics ? (*_F_ust_det)[qp] : 1.0;
282  const Real w = J * _JxW[qp] * _coord[qp];
283  V_x += w;
284  const RankTwoTensor F_inv = _large_kinematics ? (*_F_ust_inv)[qp] : RankTwoTensor::Identity();
285  for (unsigned int j = 0; j < _phi.size(); ++j)
286  {
287  Real g_x = 0.0;
288  for (unsigned int k = 0; k < 3; ++k)
289  g_x += _grad_phi[j][qp](k) * F_inv(k, beta);
290  _avg_grad_spatial_phi[beta][j] += g_x * w;
291  }
292  }
293  for (unsigned int j = 0; j < _phi.size(); ++j)
294  _avg_grad_spatial_phi[beta][j] /= V_x;
295 }
std::vector< std::vector< Real > > _avg_grad_spatial_phi
Element-averaged spatial gradient of trial functions per component: _avg_grad_spatial_phi[component][...
static RankTwoTensorTempl Identity()
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
bool _large_kinematics
If true use large deformation kinematics.
static const std::string k
Definition: NS.h:134

◆ computeAverageGradientSpatialTest()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::computeAverageGradientSpatialTest ( )
protected

Compute element-averaged spatial gradient of test functions for component _alpha, filling _avg_grad_spatial_test.

Used for the OLD-compat B-bar volumetric correction.

Definition at line 245 of file TotalLagrangianStressDivergenceBase.C.

246 {
247  // _avg_grad_spatial_test[i] = (1/V_x) int (grad_x test_i)_alpha dV_x
248  // = (sum_qp (grad_X test_i)_j (F_ust^{-1})_{j, _alpha} * J_ust * w)
249  // / (sum_qp J_ust * w), w = JxW * coord
250  // For small kinematics, F_ust = I, J_ust = 1, reducing to OLD's element-averaged grad_test.
251  _avg_grad_spatial_test.assign(_test.size(), 0.0);
252  Real V_x = 0.0;
253  for (unsigned int qp = 0; qp < _qrule->n_points(); ++qp)
254  {
255  const Real J = _large_kinematics ? (*_F_ust_det)[qp] : 1.0;
256  const Real w = J * _JxW[qp] * _coord[qp];
257  V_x += w;
258  const RankTwoTensor F_inv = _large_kinematics ? (*_F_ust_inv)[qp] : RankTwoTensor::Identity();
259  for (unsigned int i = 0; i < _test.size(); ++i)
260  {
261  Real g_x = 0.0;
262  for (unsigned int j = 0; j < 3; ++j)
263  g_x += _grad_test[i][qp](j) * F_inv(j, _alpha);
264  _avg_grad_spatial_test[i] += g_x * w;
265  }
266  }
267  for (unsigned int i = 0; i < _test.size(); ++i)
268  _avg_grad_spatial_test[i] /= V_x;
269 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
std::vector< Real > _avg_grad_spatial_test
Element-averaged spatial (deformed-frame) gradient of test functions for the kernel&#39;s component _alph...
static RankTwoTensorTempl Identity()
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
bool _large_kinematics
If true use large deformation kinematics.

◆ computeAvgTestPhiCross()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::computeAvgTestPhiCross ( unsigned int  beta)
protected

Compute element-averaged cross product (grad_x test_i)_{b1} * (grad_x phi_j)_{b2} for b1, b2 in {_alpha, beta} (4 combinations), filling _avg_test_phi_cross[b1][b2][i][j].

Used by the non-local B-bar Jacobian contribution from d(avg_grad_spatial_test)/dU. beta is the displacement component of the trial-side variable in this Jacobian column; only the four (_alpha, _alpha), (_alpha, beta), (beta, _alpha), (beta, beta) entries are populated (others are left untouched / unread).

Definition at line 299 of file TotalLagrangianStressDivergenceBase.C.

300 {
301  // Populate the cross-products
302  // _avg_test_phi_cross[b1][b2][i][j] = (1/V_x) int (grad_x test_i)_{b1} * (grad_x phi_j)_{b2}
303  // dV_x
304  // for the 4 combinations of (b1, b2) in {_alpha, beta}. The d(avg_grad_spatial_test)/dU
305  // term in the B-bar Jacobian needs both (alpha, beta) and (beta, alpha) entries; the
306  // diagonal (alpha == beta) collapses to a single combination.
307  const unsigned int n_test = _test.size();
308  const unsigned int n_phi = _phi.size();
309  std::vector<unsigned int> bs = {_alpha};
310  if (beta != _alpha)
311  bs.push_back(beta);
312  // Zero out and resize the affected slots
313  for (auto b1 : bs)
314  for (auto b2 : bs)
315  {
316  _avg_test_phi_cross[b1][b2].assign(n_test, std::vector<Real>(n_phi, 0.0));
317  }
318  Real V_x = 0.0;
319  // Cache (grad_x test_i)_{b1} and (grad_x phi_j)_{b2} per qp to avoid recomputing for
320  // each (i, j) pair.
321  std::vector<std::vector<Real>> gx_test(bs.size(), std::vector<Real>(n_test, 0.0));
322  std::vector<std::vector<Real>> gx_phi(bs.size(), std::vector<Real>(n_phi, 0.0));
323  for (unsigned int qp = 0; qp < _qrule->n_points(); ++qp)
324  {
325  const Real J = _large_kinematics ? (*_F_ust_det)[qp] : 1.0;
326  const Real w = J * _JxW[qp] * _coord[qp];
327  V_x += w;
328  const RankTwoTensor F_inv = _large_kinematics ? (*_F_ust_inv)[qp] : RankTwoTensor::Identity();
329  for (unsigned int bi = 0; bi < bs.size(); ++bi)
330  {
331  const unsigned int b = bs[bi];
332  for (unsigned int i = 0; i < n_test; ++i)
333  {
334  Real g = 0.0;
335  for (unsigned int k = 0; k < 3; ++k)
336  g += _grad_test[i][qp](k) * F_inv(k, b);
337  gx_test[bi][i] = g;
338  }
339  for (unsigned int j = 0; j < n_phi; ++j)
340  {
341  Real g = 0.0;
342  for (unsigned int k = 0; k < 3; ++k)
343  g += _grad_phi[j][qp](k) * F_inv(k, b);
344  gx_phi[bi][j] = g;
345  }
346  }
347  for (unsigned int b1i = 0; b1i < bs.size(); ++b1i)
348  for (unsigned int b2i = 0; b2i < bs.size(); ++b2i)
349  {
350  const unsigned int b1 = bs[b1i];
351  const unsigned int b2 = bs[b2i];
352  auto & dest = _avg_test_phi_cross[b1][b2];
353  for (unsigned int i = 0; i < n_test; ++i)
354  for (unsigned int j = 0; j < n_phi; ++j)
355  dest[i][j] += gx_test[b1i][i] * gx_phi[b2i][j] * w;
356  }
357  }
358  for (auto b1 : bs)
359  for (auto b2 : bs)
360  {
361  auto & dest = _avg_test_phi_cross[b1][b2];
362  for (unsigned int i = 0; i < n_test; ++i)
363  for (unsigned int j = 0; j < n_phi; ++j)
364  dest[i][j] /= V_x;
365  }
366 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
static RankTwoTensorTempl Identity()
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
bool _large_kinematics
If true use large deformation kinematics.
static const std::string k
Definition: NS.h:134
std::vector< std::vector< std::vector< std::vector< Real > > > > _avg_test_phi_cross
Element-averaged cross product (on displaced mesh) of spatial test/trial gradients: avg_test_phi_cros...

◆ computeQpJacobian()

Real LagrangianStressDivergenceBase::computeQpJacobian ( )
overrideprotectedvirtualinherited

Reimplemented in TotalLagrangianWeakPlaneStress.

Definition at line 191 of file LagrangianStressDivergenceBase.C.

192 {
194 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
virtual Real computeQpJacobianDisplacement(unsigned int alpha, unsigned int beta)=0

◆ computeQpJacobianDisplacement()

template<class G >
Real TotalLagrangianStressDivergenceBase< G >::computeQpJacobianDisplacement ( unsigned int  alpha,
unsigned int  beta 
)
overrideprotectedvirtual

Implements LagrangianStressDivergenceBase.

Definition at line 398 of file TotalLagrangianStressDivergenceBase.C.

400 {
401  // gradTest(alpha) feeds the local Jacobian contraction below.
402  const RankTwoTensor grad_test = gradTest(alpha);
403 
404  // Local (+ non-local F-bar) Jacobian: J_{alpha beta} = gradTest_alpha : dPK1_total, where
405  // dPK1_total = dPK1/d(grad u) * grad_phi_beta (local) plus the wrapped non-local F-bar
406  // perturbation. Both pieces depend only on (qp, j) and are precomputed and pre-summed into
407  // `_dpk1_total_cache` by `populateLocalPK1Cache(beta)`, so a single contraction covers both.
408  // Without stabilization there is no non-local piece, so the local cache is contracted directly.
410  : _dpk1_grad_trial_cache[_qp][_j]);
411 
412  // OLD-compat B-bar volumetric correction Jacobian (only in `F_bar_mode = incremental`).
413  // The residual added the term R_extra = (PK1:F_ust)/3 * (avg_T - T_alpha) summed over qps.
414  // Linearizing per (i, j, alpha, beta):
415  // J_extra_qp = (1/3) * d(PK1:F_ust)/dU * (avg_T - T_alpha)
416  // + (1/3) * (PK1:F_ust) * (d(avg_T)/dU - dT_alpha/dU)
417  // with derivatives in U (the trial-DOF for component beta at node j):
418  // d(PK1:F_ust)/dU|qp = (dPK1_local + dPK1_NL) : F_ust + PK1 : dF_ust_local
419  // dPK1_local = _dpk1_grad_trial_cache[_qp][_j] (cached above)
420  // dPK1_NL = d_PK1_NL (cached above)
421  // dF_ust = _grad_trial_cache[_qp][_j] (cached unstabilized trial)
422  // dT_alpha/dU|qp = -(grad_x test_i)_beta * (grad_x phi_j)_alpha (local cross)
423  // d(avg_T)/dU = avgCross(alpha, beta) - avgCross(beta, alpha) - avg_T(i) *
424  // avg_grad_spatial_phi[beta][j]
425  // avgCross(b1, b2) = _avg_test_phi_cross[b1][b2][i][j] (precomputed)
427  {
428  // A_qp (= pk1:F_ust/3, per qp) and dA_dU (per qp, j) are precomputed in
429  // `cachePK1ContractionFUst` / `populateLocalPK1Cache` -- no double contractions here.
430  const Real A_qp = _pk1_ddot_F_ust[_qp] / 3.0;
431  const Real avg_T = _avg_grad_spatial_test[_i];
432  const Real T_alpha = gradXTestComponent(alpha);
433  const Real B = avg_T - T_alpha;
434 
435  const Real dA_dU = _dA_dU_cache[_qp][_j];
436 
437  // dB/dU: -dT_alpha/dU + d(avg_T)/dU
438  // dT_alpha/dU = -(grad_x test_i)_beta * (grad_x phi_j)_alpha (local cross at _qp)
439  const Real T_beta_i = gradXTestComponent(beta);
440  const Real phi_alpha_j = gradXPhiComponent(alpha);
441  const Real dT_alpha_dU = -T_beta_i * phi_alpha_j;
442 
443  const Real avg_cross_ab = _avg_test_phi_cross[alpha][beta][_i][_j];
444  const Real avg_cross_ba = _avg_test_phi_cross[beta][alpha][_i][_j];
445  const Real d_avg_T_dU = avg_cross_ab - avg_cross_ba - avg_T * _avg_grad_spatial_phi[beta][_j];
446 
447  const Real dB_dU = d_avg_T_dU - dT_alpha_dU;
448  J += dA_dU * B + A_qp * dB_dU;
449  }
450 
451  return J;
452 }
std::vector< std::vector< RankTwoTensor > > _dpk1_grad_trial_cache
_dpk1_d_grad_u[qp] * gradTrial(beta) per (qp, j) for the current Jacobian column&#39;s beta...
Real gradXPhiComponent(unsigned int component) const
(grad_x phi_j)_component at the current _qp, same push-forward as gradXTestComponent.
std::vector< std::vector< Real > > _avg_grad_spatial_phi
Element-averaged spatial gradient of trial functions per component: _avg_grad_spatial_phi[component][...
std::vector< Real > _avg_grad_spatial_test
Element-averaged spatial (deformed-frame) gradient of test functions for the kernel&#39;s component _alph...
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
std::vector< Real > _pk1_ddot_F_ust
pk1 : F_ust per qp for the B-bar volumetric correction (see cachePK1ContractionFUst).
virtual RankTwoTensor gradTest(unsigned int component) override
std::vector< std::vector< RankTwoTensor > > _dpk1_total_cache
Local + non-local PK1 derivative per (qp, j): _dpk1_grad_trial_cache + _delta_PK1_NL_cache.
Real doubleContraction(const RankTwoTensorTempl< Real > &a) const
std::vector< std::vector< Real > > _dA_dU_cache
d(pk1 : F_ust)/dU per (qp, j) for the current column – the B-bar Jacobian&#39;s dA/dU term...
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string alpha
Definition: NS.h:138
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.
Real gradXTestComponent(unsigned int component) const
(grad_x test_i)_component at the current _qp, where the push-forward uses the unstabilized F (= F_act...
std::vector< std::vector< std::vector< std::vector< Real > > > > _avg_test_phi_cross
Element-averaged cross product (on displaced mesh) of spatial test/trial gradients: avg_test_phi_cros...

◆ computeQpJacobianOutOfPlaneStrain()

template<class G >
Real TotalLagrangianStressDivergenceBase< G >::computeQpJacobianOutOfPlaneStrain ( )
overrideprotectedvirtual

Implements LagrangianStressDivergenceBase.

Definition at line 487 of file TotalLagrangianStressDivergenceBase.C.

488 {
489  // d(R_disp_alpha)/d(strain_zz_j) at qp = gradTest_alpha : d(PK1)/d(strain_zz_j).
490  // strain_zz feeds `_F[(2,2)]` AFTER F-bar runs in `ComputeLagrangianWPSStrain`, so
491  // strain_zz perturbations bypass F-bar's chain. Use `_dpk1_bypass_fbar` (= the
492  // pk1_jacobian variant computed with the F-bar `_d_F_stab_d_F_ust` factor REPLACED
493  // by identity in the sigma chain) for a consistent Jacobian.
494  return _dpk1_bypass_fbar[_qp].contractionKl(2, 2, gradTest(_alpha)) *
495  _out_of_plane_strain->phi()[_j][_qp];
496 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
const MaterialProperty< RankFourTensor > & _dpk1_bypass_fbar
Variant of _dpk1 (= pk1_jacobian) computed WITHOUT the F-bar chain factor _d_F_stab_d_F_ust in the si...
const MooseVariable * _out_of_plane_strain
Out-of-plane strain, if provided.
virtual RankTwoTensor gradTest(unsigned int component) override
const FieldVariablePhiValue & phi() const override

◆ computeQpJacobianTemperature()

template<class G >
Real TotalLagrangianStressDivergenceBase< G >::computeQpJacobianTemperature ( unsigned int  cvar)
overrideprotectedvirtual

Implements LagrangianStressDivergenceBase.

Definition at line 456 of file TotalLagrangianStressDivergenceBase.C.

457 {
458  // Multiple eigenstrains may depend on the same coupled var
459  RankTwoTensor total_deigen;
460  for (const auto deigen_darg : _deigenstrain_dargs[cvar])
461  total_deigen += (*deigen_darg)[_qp];
462 
463  // No eigenstrain -> no temperature coupling. Short-circuit before dereferencing the
464  // d_sigma/d_eigenstrain property (only fetched when eigenstrains are coupled; see
465  // LagrangianStressDivergenceBase ctor).
466  if (total_deigen.L2norm() == 0.0)
467  return 0.0;
468 
469  // Direct chain through the constitutive update. The stress material publishes
470  // d_sigma/d_eigenstrain (= -Jinv * small_jacobian for the objective-rate path,
471  // with the sign convention that an eigenstrain increase
472  // reduces the mechanical strain).
473  // We then wrap to PK1 the same way the residual does:
474  // dP/dT = det(F) * dsigma/dT * F^{-T} (large kinematics)
475  // dP/dT = dsigma/dT (small kinematics, P == sigma by convention)
476  const RankTwoTensor dsigma_dT = (*_dcauchy_stress_d_eigenstrain)[_qp] * total_deigen;
477  RankTwoTensor dP_dT;
478  if (_large_kinematics)
479  dP_dT = _F[_qp].det() * dsigma_dT * _F_inv[_qp].transpose();
480  else
481  dP_dT = dsigma_dT;
482  return dP_dT.doubleContraction(gradTest(_alpha)) * _temperature->phi()[_j][_qp];
483 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
const MaterialProperty< RankTwoTensor > & _F_inv
The inverse deformation gradient.
const MaterialProperty< RankTwoTensor > & _F
The actual (stabilized) deformation gradient.
virtual RankTwoTensor gradTest(unsigned int component) override
const FieldVariablePhiValue & phi() const override
Real doubleContraction(const RankTwoTensorTempl< Real > &a) const
const MooseVariable * _temperature
Temperature, if provided. This is used only to get the trial functions.
bool _large_kinematics
If true use large deformation kinematics.
std::vector< std::vector< const MaterialProperty< RankTwoTensor > * > > _deigenstrain_dargs
Eigenstrain derivatives wrt generate coupleds.

◆ computeQpOffDiagJacobian()

Real LagrangianStressDivergenceBase::computeQpOffDiagJacobian ( unsigned int  jvar)
overrideprotectedvirtualinherited

Reimplemented in TotalLagrangianWeakPlaneStress.

Definition at line 210 of file LagrangianStressDivergenceBase.C.

211 {
212  // Bail if jvar not coupled
213  if (getJvarMap()[jvar] < 0)
214  return 0.0;
215 
216  // Off diagonal terms for other displacements
217  for (auto beta : make_range(_ndisp))
218  if (jvar == _disp_nums[beta])
220 
221  // Off diagonal temperature term due to eigenstrain
222  if (_temperature && jvar == _temperature->number())
224 
225  // Off diagonal term due to weak plane stress
228 
229  return 0;
230 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
virtual Real computeQpJacobianDisplacement(unsigned int alpha, unsigned int beta)=0
unsigned int number() const
virtual Real computeQpJacobianOutOfPlaneStrain()=0
const MooseVariable * _out_of_plane_strain
Out-of-plane strain, if provided.
std::vector< unsigned int > _disp_nums
The displacement numbers.
const unsigned int _ndisp
Total number of displacements/size of residual vector.
const MooseVariable * _temperature
Temperature, if provided. This is used only to get the trial functions.
IntRange< T > make_range(T beg, T end)
virtual Real computeQpJacobianTemperature(unsigned int cvar)=0

◆ computeQpResidual()

template<class G >
Real TotalLagrangianStressDivergenceBase< G >::computeQpResidual ( )
overrideprotectedvirtual

Reimplemented in TotalLagrangianWeakPlaneStress.

Definition at line 370 of file TotalLagrangianStressDivergenceBase.C.

371 {
372  Real result = gradTest(_alpha).doubleContraction(_pk1[_qp]);
373 
374  // OLD-compat B-bar volumetric correction (only in `F_bar_mode = incremental`, the explicit
375  // OLD-compat mode). This adds
376  // int (tr sigma / 3) * (avg_grad_x test - grad_x test)_alpha dV_x
377  // expressed in reference-frame integration as
378  // sum_qp ((PK1 : F_ust) / 3) * (avg_grad_spatial_test[_i] - grad_x_test_alpha) * JxW * coord
379  // (the J = det(F_ust) factor is already absorbed into `PK1 : F_ust = J * tr sigma`).
380  // Without this term, PK1 = det(F_ust) sigma F_ust^{-T} reproduces OLD's `sigma : grad_x test`
381  // term but not OLD's vol-locking correction; for uniform sigma that's harmless (the integral
382  // vanishes per element) but for non-uniform sigma -- e.g. mixed-component Dirichlet BCs producing
383  // non-affine equilibrium with plasticity + a kinematic decomposition that gives spatially varying
384  // sigma -- it drives the converged displacement away from OLD's. Scoped to incremental mode
385  // because (a) that's the documented OLD-compat F-bar mode and (b) the existing `total` mode tests
386  // are calibrated to the F-bar-in-sigma-only formulation (adding the B-bar term there would be
387  // a separate behavior change).
389  {
390  const Real PK1_F_over_3 = _pk1_ddot_F_ust[_qp] / 3.0;
391  result += PK1_F_over_3 * (_avg_grad_spatial_test[_i] - gradXTestComponent(_alpha));
392  }
393  return result;
394 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
const MaterialProperty< RankTwoTensor > & _pk1
The 1st Piola-Kirchhoff stress.
std::vector< Real > _avg_grad_spatial_test
Element-averaged spatial (deformed-frame) gradient of test functions for the kernel&#39;s component _alph...
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
std::vector< Real > _pk1_ddot_F_ust
pk1 : F_ust per qp for the B-bar volumetric correction (see cachePK1ContractionFUst).
virtual RankTwoTensor gradTest(unsigned int component) override
Real doubleContraction(const RankTwoTensorTempl< Real > &a) const
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.
Real gradXTestComponent(unsigned int component) const
(grad_x test_i)_component at the current _qp, where the push-forward uses the unstabilized F (= F_act...

◆ deltaPK1NonLocalFBar()

RankTwoTensor LagrangianStressDivergenceBase::deltaPK1NonLocalFBar ( const RankTwoTensor delta_F_avg) const
protectedinherited

Non-local F-bar contribution to deltaPK1 at the current _qp, given the perturbation delta_F_avg of the element-average F.

Implements the shared chain deltaF_stab_NL = _d_F_stab_d_F_avg * deltaF_avg deltadL_NL = _d_deformation_gradient_increment_d_F * deltaF_stab_NL deltasigma_NL = _cauchy_jacobian * deltadL_NL deltaPK1_NL = det(F_ust) * deltasigma_NL * F_ust^{-T} (large kinematics) = deltasigma_NL (small kinematics, PK1 == sigma) Returns zero when F-bar is off (!_stabilize_strain). Used by the TL displacement Jacobian, the WPS off-diag Jacobian, and the homogenization scalar<->disp Jacobian – anywhere the disp perturbation chains through F-bar's non-local route.

Consumes the strain/stress material's per-qp _d_nl_fbar operator so the inner (test, trial) loop pays only one R4*R2 (and, in the large-kinematics branch, one R2*R2*R2 PK1 wrap) per call instead of three R4*R2 chains plus a per-call 3x3 inverse.

Definition at line 197 of file LagrangianStressDivergenceBase.C.

Referenced by TotalLagrangianWeakPlaneStress::computeQpOffDiagJacobian(), and HomogenizedTotalLagrangianStressDivergence::computeScalarQpOffDiagJacobian().

198 {
199  if (!_stabilize_strain)
200  return RankTwoTensor();
201  // `_d_nl_fbar` (the composed non-local operator) and F_ust^{-1}/det come from the stress and
202  // strain materials as per-qp properties -- no kernel-side cache to refresh.
203  const RankTwoTensor delta_sigma_nl = (*_d_nl_fbar)[_qp] * delta_F_avg;
204  if (_large_kinematics)
205  return (*_F_ust_det)[_qp] * delta_sigma_nl * (*_F_ust_inv)[_qp].transpose();
206  return delta_sigma_nl;
207 }
const MaterialProperty< Real > * _F_ust_det
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
RankTwoTensorTempl< Real > transpose() const
bool _large_kinematics
If true use large deformation kinematics.

◆ gradTest()

template<class G >
RankTwoTensor TotalLagrangianStressDivergenceBase< G >::gradTest ( unsigned int  component)
overrideprotectedvirtual

Implements LagrangianStressDivergenceBase.

Definition at line 36 of file TotalLagrangianStressDivergenceBase.C.

Referenced by HomogenizedTotalLagrangianStressDivergence::computeQpOffDiagJacobianScalar().

37 {
38  // F-bar doesn't modify the test function
39  return G::gradOp(component, _grad_test[_i][_qp], _test[_i][_qp], _q_point[_qp]);
40 }
static const std::string component
Definition: NS.h:157

◆ gradTrial()

template<class G >
RankTwoTensor TotalLagrangianStressDivergenceBase< G >::gradTrial ( unsigned int  component)
overrideprotectedvirtual

Implements LagrangianStressDivergenceBase.

Definition at line 44 of file TotalLagrangianStressDivergenceBase.C.

Referenced by TotalLagrangianWeakPlaneStress::computeQpOffDiagJacobian(), and HomogenizedTotalLagrangianStressDivergence::computeScalarQpOffDiagJacobian().

45 {
46  // After the F_ust-wrap architectural change, pk1_jacobian = dPK1/d(F_ust) already
47  // contains the local F-bar contribution (via the sigma-chain through
48  // `_d_F_stab_d_F_ust`). The trial gradient is always unstabilized; the non-local F-bar
49  // Jacobian contribution is added explicitly in `computeQpJacobianDisplacement`.
51 }
virtual RankTwoTensor gradTrialUnstabilized(unsigned int component)
The unstabilized trial function gradient.
static const std::string component
Definition: NS.h:157

◆ gradTrialUnstabilized()

template<class G >
RankTwoTensor TotalLagrangianStressDivergenceBase< G >::gradTrialUnstabilized ( unsigned int  component)
protectedvirtual

The unstabilized trial function gradient.

Exposed (protected, not private) so subclasses like HomogenizedTotalLagrangianStressDivergence can use it directly for the macro-var <-> disp off-diagonal Jacobian chain.

Definition at line 55 of file TotalLagrangianStressDivergenceBase.C.

Referenced by HomogenizedTotalLagrangianStressDivergence::computeScalarQpOffDiagJacobian().

56 {
57  // Without F-bar stabilization, simply return the gradient of the trial functions
58  return G::gradOp(component, _grad_phi[_j][_qp], _phi[_j][_qp], _q_point[_qp]);
59 }
static const std::string component
Definition: NS.h:157

◆ gradXPhiComponent()

template<class G >
Real TotalLagrangianStressDivergenceBase< G >::gradXPhiComponent ( unsigned int  component) const
protected

(grad_x phi_j)_component at the current _qp, same push-forward as gradXTestComponent.

Definition at line 232 of file TotalLagrangianStressDivergenceBase.C.

233 {
234  if (!_large_kinematics)
235  return _grad_phi[_j][_qp](component);
236  const RankTwoTensor & F_inv = (*_F_ust_inv)[_qp];
237  Real out = 0.0;
238  for (unsigned int j = 0; j < 3; ++j)
239  out += _grad_phi[_j][_qp](j) * F_inv(j, component);
240  return out;
241 }
static const std::string component
Definition: NS.h:157
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
OStreamProxy out
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
bool _large_kinematics
If true use large deformation kinematics.

◆ gradXTestComponent()

template<class G >
Real TotalLagrangianStressDivergenceBase< G >::gradXTestComponent ( unsigned int  component) const
protected

(grad_x test_i)_component at the current _qp, where the push-forward uses the unstabilized F (= F_actual at alpha = 1), consistent with the PK1 wrap.

Definition at line 216 of file TotalLagrangianStressDivergenceBase.C.

217 {
218  // (grad_x test_i)_component = (grad_X test_i)_j (F_ust^{-1})_{j, component}
219  // Push-forward via F_ust (= F_actual at alpha=1) matches the PK1 wrap. F_ust^{-1} is a
220  // material property (computed once per qp by the strain calc), not recomputed here.
221  if (!_large_kinematics)
222  return _grad_test[_i][_qp](component);
223  const RankTwoTensor & F_inv = (*_F_ust_inv)[_qp];
224  Real out = 0.0;
225  for (unsigned int j = 0; j < 3; ++j)
226  out += _grad_test[_i][_qp](j) * F_inv(j, component);
227  return out;
228 }
static const std::string component
Definition: NS.h:157
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
OStreamProxy out
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
bool _large_kinematics
If true use large deformation kinematics.

◆ hasGuaranteedMaterialProperty()

bool GuaranteeConsumer::hasGuaranteedMaterialProperty ( const MaterialPropertyName &  prop,
Guarantee  guarantee 
)
protectedinherited

Definition at line 28 of file GuaranteeConsumer.C.

Referenced by ComputeFiniteStrainElasticStress::computeQpStress(), ADComputeSmearedCrackingStress::initialSetup(), ComputeSmearedCrackingStress::initialSetup(), ComputeLinearElasticPFFractureStress::initialSetup(), CriticalTimeStep::initialSetup(), ComputeStVenantKirchhoffStress::initialSetup(), ComputeMultipleInelasticStressBase::initialSetup(), ADComputeMultipleInelasticStress::initialSetup(), LagrangianStressDivergenceBase::initialSetup(), and ComputeLagrangianStressBase::initialSetup().

30 {
32  mooseError("hasGuaranteedMaterialProperty() needs to be called in initialSetup()");
33 
34  // Reference to MaterialWarehouse for testing and retrieving block ids
35  const auto & warehouse = _gc_feproblem->getMaterialWarehouse();
36 
37  // Complete set of ids that this object is active
38  const auto & ids = (_gc_block_restrict && _gc_block_restrict->blockRestricted())
41 
42  // Loop over each id for this object
43  for (const auto & id : ids)
44  {
45  // If block materials exist, look if any issue the required guarantee
46  if (warehouse.hasActiveBlockObjects(id))
47  {
48  const std::vector<std::shared_ptr<MaterialBase>> & mats = warehouse.getActiveBlockObjects(id);
49  for (const auto & mat : mats)
50  {
51  const auto & mat_props = mat->getSuppliedItems();
52  if (mat_props.count(prop_name))
53  {
54  auto guarantee_mat = dynamic_cast<GuaranteeProvider *>(mat.get());
55  if (guarantee_mat && !guarantee_mat->hasGuarantee(prop_name, guarantee))
56  {
57  // we found at least one material on the set of block we operate on
58  // that does _not_ provide the requested guarantee
59  return false;
60  }
61  }
62  }
63  }
64  }
65 
66  return true;
67 }
void mooseError(Args &&... args)
Add-on class that provides the functionality to issue guarantees for declared material properties...
BlockRestrictable *const _gc_block_restrict
Access block restrictions of the object with this interface.
virtual const std::set< SubdomainID > & blockIDs() const
virtual bool blockRestricted() const
const MaterialWarehouse & getMaterialWarehouse() const
FEProblemBase *const _gc_feproblem
Reference to the FEProblemBase class.
virtual MooseMesh & mesh() override
virtual bool startedInitialSetup()
const std::set< SubdomainID > & meshSubdomains() const

◆ initialSetup() [1/4]

template<>
void TotalLagrangianStressDivergenceBase< GradientOperatorCartesian >::initialSetup ( )
inlinevirtual

Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.

Reimplemented from LagrangianStressDivergenceBase.

Definition at line 26 of file TotalLagrangianStressDivergence.h.

27 {
28  // Derives _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.
30 
31  if (getBlockCoordSystem() != Moose::COORD_XYZ)
32  mooseError("This kernel should only act in Cartesian coordinates.");
33 }
void mooseError(Args &&... args)
virtual void initialSetup() override
Derive _large_kinematics from the strain calculator&#39;s LARGE_KINEMATICS guarantee. ...

◆ initialSetup() [2/4]

Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.

Reimplemented from LagrangianStressDivergenceBase.

Definition at line 26 of file TotalLagrangianStressDivergenceAxisymmetricCylindrical.h.

27 {
28  // Derives _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.
30 
31  if (getBlockCoordSystem() != Moose::COORD_RZ)
32  mooseError("This kernel should only act in axisymmetric cylindrical coordinates.");
33 }
void mooseError(Args &&... args)
virtual void initialSetup() override
Derive _large_kinematics from the strain calculator&#39;s LARGE_KINEMATICS guarantee. ...

◆ initialSetup() [3/4]

Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.

Reimplemented from LagrangianStressDivergenceBase.

Definition at line 26 of file TotalLagrangianStressDivergenceCentrosymmetricSpherical.h.

27 {
28  // Derives _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.
30 
31  if (getBlockCoordSystem() != Moose::COORD_RSPHERICAL)
32  mooseError("This kernel should only act in centrosymmetric spherical coordinates.");
33 }
void mooseError(Args &&... args)
COORD_RSPHERICAL
virtual void initialSetup() override
Derive _large_kinematics from the strain calculator&#39;s LARGE_KINEMATICS guarantee. ...

◆ initialSetup() [4/4]

template<class G >
virtual void TotalLagrangianStressDivergenceBase< G >::initialSetup ( )
overridevirtual

Derive _large_kinematics from the strain calculator's LARGE_KINEMATICS guarantee.

Reimplemented from LagrangianStressDivergenceBase.

◆ populateLocalPK1Cache()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::populateLocalPK1Cache ( unsigned int  beta)
private

Populate the per-(qp, j) caches consumed by computeQpJacobianDisplacement.

beta is fixed across a single Jacobian column, so the R4*R2 chain _dpk1_d_grad_u[qp] * gradTrial(beta), the cached unstabilized trial gradient, and (when _stabilize_strain == true) the fully wrapped non-local F-bar PK1 perturbation can all be computed once per (qp, j) instead of once per (qp, _i, _j). Called from precalculateJacobian (with beta = _alpha) and precalculateOffDiagJacobian(jvar) (with the matched beta).

Definition at line 155 of file TotalLagrangianStressDivergenceBase.C.

156 {
157  const unsigned int n_qp = _qrule->n_points();
158  const unsigned int n_phi = _phi.size();
159  _dpk1_grad_trial_cache.assign(n_qp, std::vector<RankTwoTensor>(n_phi));
160  _grad_trial_cache.assign(n_qp, std::vector<RankTwoTensor>(n_phi));
161  if (_stabilize_strain)
162  {
163  _delta_PK1_NL_cache.assign(n_qp, std::vector<RankTwoTensor>(n_phi));
164  _dpk1_total_cache.assign(n_qp, std::vector<RankTwoTensor>(n_phi));
165  }
166 
167  // B-bar volumetric correction (incremental mode only): cache the column-independent
168  // `pk1 : F_ust` per qp and the per-(qp, j) `dA/dU` term so the Jacobian inner loop reads
169  // scalars instead of recomputing three double contractions per (_i, _j, component).
170  const bool bbar = _stabilize_strain && _F_bar_mode == FBarMode::Incremental;
171  if (bbar)
172  {
174  _dA_dU_cache.assign(n_qp, std::vector<Real>(n_phi));
175  }
176 
177  for (unsigned int qp = 0; qp < n_qp; ++qp)
178  {
179  const RankFourTensor & dpk1 = _dpk1_d_grad_u[qp];
180  const RankFourTensor & dFdGU = _d_F_d_grad_u[qp];
181  for (unsigned int j = 0; j < n_phi; ++j)
182  {
183  // gradTrial == gradTrialUnstabilized in TL (line ~50); single cache feeds both consumers.
184  const RankTwoTensor grad_trial = G::gradOp(beta, _grad_phi[j][qp], _phi[j][qp], _q_point[qp]);
185  _grad_trial_cache[qp][j] = grad_trial;
186  _dpk1_grad_trial_cache[qp][j] = dpk1 * grad_trial;
187  if (_stabilize_strain)
188  {
189  // Compose the full non-local F-bar PK1 perturbation:
190  // deltasigma_NL = D_nl[qp] * (_d_F_d_grad_u[qp] * _avg_grad_trial[beta][j])
191  // deltaPK1_NL = det(F_ust) * deltasigma_NL * F_ust^{-T} (large kinematics)
192  // = deltasigma_NL (small kinematics)
193  // D_nl (`_d_nl_fbar`), det(F_ust), and F_ust^{-1} are all per-qp material properties
194  // from the stress/strain materials -- no kernel-side cache.
195  const RankTwoTensor delta_F_avg = dFdGU * _avg_grad_trial[beta][j];
196  const RankTwoTensor delta_sigma_nl = (*_d_nl_fbar)[qp] * delta_F_avg;
197  if (_large_kinematics)
198  _delta_PK1_NL_cache[qp][j] =
199  (*_F_ust_det)[qp] * delta_sigma_nl * (*_F_ust_inv)[qp].transpose();
200  else
201  _delta_PK1_NL_cache[qp][j] = delta_sigma_nl;
202  // Local + non-local PK1 derivative: the single tensor the disp Jacobian contracts against.
204  }
205  // dA/dU = [ (dPK1_local + dPK1_NL) : F_ust + pk1 : dF_ust ] / 3, all per (qp, j).
206  if (bbar)
207  _dA_dU_cache[qp][j] = (_dpk1_total_cache[qp][j].doubleContraction(_F_ust[qp]) +
208  _pk1[qp].doubleContraction(_grad_trial_cache[qp][j])) /
209  3.0;
210  }
211  }
212 }
const MaterialProperty< RankTwoTensor > & _pk1
The 1st Piola-Kirchhoff stress.
std::vector< std::vector< RankTwoTensor > > _dpk1_grad_trial_cache
_dpk1_d_grad_u[qp] * gradTrial(beta) per (qp, j) for the current Jacobian column&#39;s beta...
std::vector< std::vector< RankTwoTensor > > _avg_grad_trial
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
std::vector< std::vector< RankTwoTensor > > _delta_PK1_NL_cache
Fully wrapped non-local F-bar contribution to deltaPK1 per (qp, j) for the current column: _d_nl_fbar...
const MaterialProperty< RankTwoTensor > & _F_ust
The unmodified deformation gradient.
std::vector< std::vector< RankTwoTensor > > _dpk1_total_cache
Local + non-local PK1 derivative per (qp, j): _dpk1_grad_trial_cache + _delta_PK1_NL_cache.
const MaterialProperty< RankFourTensor > & _dpk1_d_grad_u
The derivative of the PK1 stress with respect to the displacement gradient (grad u_{n+1}).
std::vector< std::vector< Real > > _dA_dU_cache
d(pk1 : F_ust)/dU per (qp, j) for the current column – the B-bar Jacobian&#39;s dA/dU term...
const MaterialProperty< RankFourTensor > & _d_F_d_grad_u
Derivative of F_{n+1} w.r.t. the displacement gradient.
RankTwoTensorTempl< Real > transpose() const
void cachePK1ContractionFUst()
Cache pk1 : F_ust per qp (the J * tr(sigma) factor of the B-bar volumetric correction).
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.
std::vector< std::vector< RankTwoTensor > > _grad_trial_cache
Cached gradTrialUnstabilized(beta) per (qp, j) for the current column.
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")
bool _large_kinematics
If true use large deformation kinematics.

◆ precalculateJacobian()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::precalculateJacobian ( )
overrideprotectedvirtual

Reimplemented from LagrangianStressDivergenceBase.

Reimplemented in TotalLagrangianWeakPlaneStress.

Definition at line 118 of file TotalLagrangianStressDivergenceBase.C.

119 {
121  // Populate the per-(qp, j) local PK1 chain cache for the diagonal column (beta = _alpha).
122  // Runs regardless of `_stabilize_strain` because the local chain is always needed; the
123  // helper itself only touches `_avg_grad_trial` when stab is on.
126  {
130  }
131 }
const unsigned int _alpha
Which component of the vector residual this kernel is responsible for.
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
void computeAverageGradientSpatialTest()
Compute element-averaged spatial gradient of test functions for component _alpha, filling _avg_grad_s...
void computeAverageGradientSpatialPhi(unsigned int beta)
Compute element-averaged spatial gradient of trial functions for component beta, filling _avg_grad_sp...
void populateLocalPK1Cache(unsigned int beta)
Populate the per-(qp, j) caches consumed by computeQpJacobianDisplacement.
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.
void computeAvgTestPhiCross(unsigned int beta)
Compute element-averaged cross product (grad_x test_i)_{b1} * (grad_x phi_j)_{b2} for b1...

◆ precalculateJacobianDisplacement()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::precalculateJacobianDisplacement ( unsigned int  component)
overrideprotectedvirtual

Prepare the average shape function gradients for stabilization.

Implements LagrangianStressDivergenceBase.

Definition at line 63 of file TotalLagrangianStressDivergenceBase.C.

Referenced by HomogenizedTotalLagrangianStressDivergence::computeScalarOffDiagJacobian().

64 {
65  // For total Lagrangian, the averaging is taken on the reference frame regardless of geometric
66  // nonlinearity. The stored quantity is what the strain calc's `_d_F_stab_d_F_avg` contracts
67  // with: deltaF_avg in `F_bar_mode = total`, deltaf_avg in `F_bar_mode = incremental`.
68  // total: avg_q(grad_phi[j][q]) -> deltaF_avg per DOF
69  // incremental: avg_q(grad_phi[j][q] * F_ust_old[q]^{-1})
70  // -> deltaf_avg per DOF
71  // (since f_ust = F_ust * F_ust_old^{-1} and F_ust_old is fixed w.r.t. the
72  // current Newton iterate's disp, so deltaf_ust = deltaF_ust * F_ust_old^{-1}).
73  const bool incremental = (_F_bar_mode == FBarMode::Incremental);
74  // F_ust_old[qp]^{-1} depends only on qp, but the average below runs once per trial DOF j.
75  // Precompute the per-qp inverse once instead of re-inverting the 3x3 for every (qp, j).
76  std::vector<RankTwoTensor> f_ust_old_inv;
77  if (incremental)
78  {
79  f_ust_old_inv.resize(_qrule->n_points());
80  for (const auto qp : make_range(_qrule->n_points()))
81  f_ust_old_inv[qp] = _F_ust_old[qp].inverse();
82  }
83  for (auto j : make_range(_phi.size()))
85  [this, component, j, incremental, &f_ust_old_inv](unsigned int qp)
86  {
87  const RankTwoTensor g = G::gradOp(component, _grad_phi[j][qp], _phi[j][qp], _q_point[qp]);
88  return incremental ? g * f_ust_old_inv[qp] : g;
89  },
90  _JxW,
91  _coord);
92 }
std::vector< std::vector< RankTwoTensor > > _avg_grad_trial
static const std::string component
Definition: NS.h:157
const MaterialProperty< RankTwoTensor > & _F_ust_old
Old unstabilized deformation gradient.
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.
IntRange< T > make_range(T beg, T end)
auto elementAverage(const Functor &f, const MooseArray< Real > &JxW, const MooseArray< Real > &coord)
static const std::complex< double > j(0, 1)
Complex number "j" (also known as "i")

◆ precalculateOffDiagJacobian()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::precalculateOffDiagJacobian ( unsigned int  jvar)
overrideprotectedvirtual

Reimplemented from LagrangianStressDivergenceBase.

Definition at line 135 of file TotalLagrangianStressDivergenceBase.C.

136 {
138  // Populate the per-(qp, j) local PK1 chain cache for the matched off-diagonal beta.
139  for (auto beta : make_range(_ndisp))
140  if (jvar == _disp_nums[beta])
141  {
142  populateLocalPK1Cache(beta);
144  {
148  }
149  break;
150  }
151 }
virtual void precalculateOffDiagJacobian(unsigned int jvar) override
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
void computeAverageGradientSpatialTest()
Compute element-averaged spatial gradient of test functions for component _alpha, filling _avg_grad_s...
void computeAverageGradientSpatialPhi(unsigned int beta)
Compute element-averaged spatial gradient of trial functions for component beta, filling _avg_grad_sp...
void populateLocalPK1Cache(unsigned int beta)
Populate the per-(qp, j) caches consumed by computeQpJacobianDisplacement.
std::vector< unsigned int > _disp_nums
The displacement numbers.
const unsigned int _ndisp
Total number of displacements/size of residual vector.
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.
IntRange< T > make_range(T beg, T end)
void computeAvgTestPhiCross(unsigned int beta)
Compute element-averaged cross product (grad_x test_i)_{b1} * (grad_x phi_j)_{b2} for b1...

◆ precalculateResidual()

template<class G >
void TotalLagrangianStressDivergenceBase< G >::precalculateResidual ( )
overrideprotectedvirtual

Definition at line 96 of file TotalLagrangianStressDivergenceBase.C.

97 {
98  LagrangianStressDivergenceBase::precalculateResidual();
100  {
103  }
104 }
const bool _stabilize_strain
If true calculate the deformation gradient derivatives for F_bar.
void computeAverageGradientSpatialTest()
Compute element-averaged spatial gradient of test functions for component _alpha, filling _avg_grad_s...
void cachePK1ContractionFUst()
Cache pk1 : F_ust per qp (the J * tr(sigma) factor of the B-bar volumetric correction).
const FBarMode _F_bar_mode
What F gets F-bar volumetric correction (Total vs.

◆ validParams() [1/4]

Definition at line 16 of file TotalLagrangianStressDivergence.h.

17 {
19  params.addClassDescription(
20  "Enforce equilibrium with a total Lagrangian formulation in Cartesian coordinates.");
21  return params;
22 }
void addClassDescription(const std::string &doc_string)

◆ validParams() [2/4]

Definition at line 16 of file TotalLagrangianStressDivergenceAxisymmetricCylindrical.h.

17 {
19  params.addClassDescription("Enforce equilibrium with a total Lagrangian formulation in "
20  "axisymmetric cylindrical coordinates.");
21  return params;
22 }
void addClassDescription(const std::string &doc_string)

◆ validParams() [3/4]

Definition at line 16 of file TotalLagrangianStressDivergenceCentrosymmetricSpherical.h.

17 {
19  params.addClassDescription("Enforce equilibrium with a total Lagrangian formulation in "
20  "centrosymmetric spherical coordinates.");
21  return params;
22 }
void addClassDescription(const std::string &doc_string)

◆ validParams() [4/4]

template<class G >
static InputParameters TotalLagrangianStressDivergenceBase< G >::validParams ( )
static

Member Data Documentation

◆ _alpha

const unsigned int LagrangianStressDivergenceBase::_alpha
protectedinherited

◆ _avg_grad_spatial_phi

std::vector<std::vector<Real> > LagrangianStressDivergenceBase::_avg_grad_spatial_phi
protectedinherited

Element-averaged spatial gradient of trial functions per component: _avg_grad_spatial_phi[component][j] = (1/V_x) int_e (grad_x phi_j)_component dV_x Populated alongside _avg_grad_spatial_test for the Jacobian's B-bar contribution.

Definition at line 134 of file LagrangianStressDivergenceBase.h.

◆ _avg_grad_spatial_test

std::vector<Real> LagrangianStressDivergenceBase::_avg_grad_spatial_test
protectedinherited

Element-averaged spatial (deformed-frame) gradient of test functions for the kernel's component _alpha: _avg_grad_spatial_test[i] = (1/V_x) int_e (grad_x test_i)_alpha dV_x Used for OLD-compat B-bar volumetric correction in F_bar_mode = incremental.

Populated by the TL kernel's precalculateResidual / precalculateJacobian overrides when _stabilize_strain == true. The trial-function analog is published per (component, j) in _avg_grad_spatial_phi and used by the Jacobian.

Definition at line 129 of file LagrangianStressDivergenceBase.h.

◆ _avg_grad_trial

std::vector<std::vector<RankTwoTensor> > LagrangianStressDivergenceBase::_avg_grad_trial
protectedinherited

◆ _avg_test_phi_cross

std::vector<std::vector<std::vector<std::vector<Real> > > > LagrangianStressDivergenceBase::_avg_test_phi_cross
protectedinherited

Element-averaged cross product (on displaced mesh) of spatial test/trial gradients: avg_test_phi_cross[b1][b2][i][j] = (1/V_x) int_e (grad_x test_i){b1} * (grad_x phi_j)_{b2} dV_x Indexed by [b1][b2] in {0,1,2}^2.

Only the (b1, b2) entries needed for the current Jacobian call are populated by the TL kernel's computeAvgTestPhiCross(beta) helper. Used for the B-bar Jacobian's non-local term (d(avg_grad_spatial_test)/dU).

Definition at line 141 of file LagrangianStressDivergenceBase.h.

◆ _base_name

const std::string LagrangianStressDivergenceBase::_base_name
protectedinherited

◆ _d_deformation_gradient_increment_d_F

const MaterialProperty<RankFourTensor>& LagrangianStressDivergenceBase::_d_deformation_gradient_increment_d_F
protectedinherited

Derivative of the spatial velocity gradient increment w.r.t. F_{n+1}.

Definition at line 177 of file LagrangianStressDivergenceBase.h.

◆ _d_F_d_grad_u

const MaterialProperty<RankFourTensor>& LagrangianStressDivergenceBase::_d_F_d_grad_u
protectedinherited

◆ _d_F_stab_d_F_avg

const MaterialProperty<RankFourTensor>& LagrangianStressDivergenceBase::_d_F_stab_d_F_avg
protectedinherited

◆ _d_F_stab_d_F_ust

const MaterialProperty<RankFourTensor>& LagrangianStressDivergenceBase::_d_F_stab_d_F_ust
protectedinherited

Partials of the F-bar-stabilized deformation gradient.

Used by the UL kernel to assemble the F-bar Jacobian contribution. For F-bar off, _d_F_stab_d_F_ust = I^(4) and _d_F_stab_d_F_avg = 0, so the kernel chain reduces to the unstabilized case. TL also uses _d_F_stab_d_F_avg directly for the non-local F-bar Jacobian contribution to PK1 (since after the F_ust-wrap architectural change PK1 = det(F_ust) sigma F_ust^{-T} no longer contains the non-local F-bar effect – it has to enter through the sigma-via-dL chain explicitly).

Definition at line 189 of file LagrangianStressDivergenceBase.h.

Referenced by HomogenizedTotalLagrangianStressDivergence::computeScalarQpOffDiagJacobian().

◆ _d_nl_fbar

const MaterialProperty<RankFourTensor>* LagrangianStressDivergenceBase::_d_nl_fbar = nullptr
protectedinherited

Composed non-local F-bar operator D_nl = cauchy_jac : d(dL)/dF : d(F_stab)/d(F_avg), published per qp by the stress material (once per element, shared by all displacement kernels).

deltaPK1NonLocalFBar(deltaF_avg) collapses to one R4*R2 contraction against it. Fetched only when _stabilize_strain (nullptr otherwise).

Definition at line 212 of file LagrangianStressDivergenceBase.h.

Referenced by LagrangianStressDivergenceBase::LagrangianStressDivergenceBase().

◆ _dA_dU_cache

template<class G >
std::vector<std::vector<Real> > TotalLagrangianStressDivergenceBase< G >::_dA_dU_cache
private

d(pk1 : F_ust)/dU per (qp, j) for the current column – the B-bar Jacobian's dA/dU term.

Depends on (qp, j) and the column beta, so it is hoisted out of the per-(_i, _j) loop into populateLocalPK1Cache. Populated only when F_bar_mode = incremental.

Definition at line 142 of file TotalLagrangianStressDivergenceBase.h.

◆ _dcauchy_stress_d_eigenstrain

const MaterialProperty<RankFourTensor>* LagrangianStressDivergenceBase::_dcauchy_stress_d_eigenstrain = nullptr
protectedinherited

Derivative of the Cauchy stress with respect to the eigenstrain (published by ComputeLagrangianObjectiveStress; can be overridden by other Cauchy-providing materials).

Only fetched when eigenstrains are coupled, since only the temperature off-diagonal Jacobian needs it. Will be nullptr otherwise; subclasses that consume it must guard accordingly.

Definition at line 206 of file LagrangianStressDivergenceBase.h.

Referenced by LagrangianStressDivergenceBase::LagrangianStressDivergenceBase().

◆ _deigenstrain_dargs

std::vector<std::vector<const MaterialProperty<RankTwoTensor> *> > LagrangianStressDivergenceBase::_deigenstrain_dargs
protectedinherited

Eigenstrain derivatives wrt generate coupleds.

Definition at line 199 of file LagrangianStressDivergenceBase.h.

Referenced by LagrangianStressDivergenceBase::LagrangianStressDivergenceBase().

◆ _delta_PK1_NL_cache

template<class G >
std::vector<std::vector<RankTwoTensor> > TotalLagrangianStressDivergenceBase< G >::_delta_PK1_NL_cache
private

Fully wrapped non-local F-bar contribution to deltaPK1 per (qp, j) for the current column: _d_nl_fbar[qp] * (_d_F_d_grad_u[qp] * _avg_grad_trial[beta][j]) then PK1-wrapped via the strain calc's det(F_ust) / F_ust^{-1} properties in large kinematics.

Populated only when _stabilize_strain == true; replaces the per-call deltaPK1NonLocalFBar(...) invocation in TL's displacement Jacobian.

Definition at line 127 of file TotalLagrangianStressDivergenceBase.h.

◆ _disp_nums

std::vector<unsigned int> LagrangianStressDivergenceBase::_disp_nums
protectedinherited

◆ _dpk1

template<class G >
const MaterialProperty<RankFourTensor>& TotalLagrangianStressDivergenceBase< G >::_dpk1
protected

The derivative of the PK1 stress with respect to the deformation gradient (F that the stress material consumed, i.e.

the alpha-weighted F under the generalized midpoint rule). Used by the homogenization macro-var Jacobian path, which couples to F directly.

Definition at line 76 of file TotalLagrangianStressDivergenceBase.h.

Referenced by TotalLagrangianWeakPlaneStress::computeQpOffDiagJacobian(), and HomogenizedTotalLagrangianStressDivergence::computeScalarQpOffDiagJacobian().

◆ _dpk1_bypass_fbar

template<class G >
const MaterialProperty<RankFourTensor>& TotalLagrangianStressDivergenceBase< G >::_dpk1_bypass_fbar
protected

Variant of _dpk1 (= pk1_jacobian) computed WITHOUT the F-bar chain factor _d_F_stab_d_F_ust in the sigma-via-dL contribution.

Used for coupled variables that add to _F AFTER F-bar runs (out-of-plane strain in WPS, homogenization macro_grad) – those perturbations bypass F-bar's chain, so the sigma side of dPK1/d(F_ust) must NOT include the F-bar local correction.

Definition at line 89 of file TotalLagrangianStressDivergenceBase.h.

Referenced by TotalLagrangianWeakPlaneStress::computeQpJacobian(), HomogenizedTotalLagrangianStressDivergence::computeQpOffDiagJacobianScalar(), and HomogenizedTotalLagrangianStressDivergence::computeScalarJacobian().

◆ _dpk1_d_grad_u

template<class G >
const MaterialProperty<RankFourTensor>& TotalLagrangianStressDivergenceBase< G >::_dpk1_d_grad_u
protected

The derivative of the PK1 stress with respect to the displacement gradient (grad u_{n+1}).

Equals _dpk1 * _d_F_d_grad_u, populated in ComputeLagrangianStressBase::computeQpProperties. Used by the TL displacement Jacobian so the kernel does not need to know about the generalized-alpha kinematic policy.

Definition at line 82 of file TotalLagrangianStressDivergenceBase.h.

◆ _dpk1_grad_trial_cache

template<class G >
std::vector<std::vector<RankTwoTensor> > TotalLagrangianStressDivergenceBase< G >::_dpk1_grad_trial_cache
private

_dpk1_d_grad_u[qp] * gradTrial(beta) per (qp, j) for the current Jacobian column's beta.

Used by the main local PK1 chain and (in F_bar_mode = incremental) the B-bar Jacobian's local PK1 derivative – gradTrial == gradTrialUnstabilized in TL so a single cache covers both consumers.

Definition at line 115 of file TotalLagrangianStressDivergenceBase.h.

◆ _dpk1_total_cache

template<class G >
std::vector<std::vector<RankTwoTensor> > TotalLagrangianStressDivergenceBase< G >::_dpk1_total_cache
private

Local + non-local PK1 derivative per (qp, j): _dpk1_grad_trial_cache + _delta_PK1_NL_cache.

The displacement Jacobian contracts gradTest against this single tensor instead of the local and non-local pieces separately, halving the per-(_i, _j) double contractions. Populated only when _stabilize_strain == true (otherwise the Jacobian uses the local cache).

Definition at line 133 of file TotalLagrangianStressDivergenceBase.h.

◆ _F

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_F
protectedinherited

The actual (stabilized) deformation gradient.

With the generalized midpoint rule this is the alpha-weighted F, NOT the literal F at n+1.

Definition at line 170 of file LagrangianStressDivergenceBase.h.

Referenced by HomogenizedTotalLagrangianStressDivergence::computeScalarResidual().

◆ _F_actual

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_F_actual
protectedinherited

The literal deformation gradient at n+1 (I + grad u_{n+1}), independent of alpha and F-bar.

Used by the UL kernel to convert spatial gradients to reference-frame gradients.

Definition at line 174 of file LagrangianStressDivergenceBase.h.

◆ _F_avg

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_F_avg
protectedinherited

The element-average deformation gradient.

Definition at line 152 of file LagrangianStressDivergenceBase.h.

◆ _F_bar_mode

const FBarMode LagrangianStressDivergenceBase::_F_bar_mode
protectedinherited

What F gets F-bar volumetric correction (Total vs.

Incremental). Must match the strain calc's F_bar_mode. Incremental mode changes how _avg_grad_trial is computed so the non-local F-bar chain captures deltaf_avg (= avg of deltaF_ust * F_ust_old^{-1}) instead of deltaF_avg.

Definition at line 103 of file LagrangianStressDivergenceBase.h.

Referenced by UpdatedLagrangianStressDivergenceBase< G >::UpdatedLagrangianStressDivergenceBase().

◆ _f_inv

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_f_inv
protectedinherited

The inverse increment deformation gradient.

Definition at line 155 of file LagrangianStressDivergenceBase.h.

◆ _F_inv

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_F_inv
protectedinherited

The inverse deformation gradient.

Definition at line 158 of file LagrangianStressDivergenceBase.h.

◆ _F_ust

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_F_ust
protectedinherited

The unmodified deformation gradient.

Definition at line 144 of file LagrangianStressDivergenceBase.h.

◆ _F_ust_det

const MaterialProperty<Real>* LagrangianStressDivergenceBase::_F_ust_det = nullptr
protectedinherited

◆ _F_ust_inv

const MaterialProperty<RankTwoTensor>* LagrangianStressDivergenceBase::_F_ust_inv = nullptr
protectedinherited

F_ust^{-1} and det(F_ust) from the strain calculator, consumed by the F-bar spatial push-forward (grad_x = F_ust^{-T} grad_X, J_ust = det F_ust) on both the residual and Jacobian sweeps.

Fetched only when _stabilize_strain (nullptr otherwise). The strain material computes them once per qp (shared by all displacement kernels), replacing the former per-kernel F_ust-inverse/det cache and the per-test/trial recomputation.

Definition at line 165 of file LagrangianStressDivergenceBase.h.

Referenced by LagrangianStressDivergenceBase::LagrangianStressDivergenceBase().

◆ _F_ust_old

const MaterialProperty<RankTwoTensor>& LagrangianStressDivergenceBase::_F_ust_old
protectedinherited

Old unstabilized deformation gradient.

Only consulted in F_bar_mode = incremental for the kernel's element-average of grad_phi * F_ust_old^{-1}. Always fetched (cheap) so the kernel doesn't need conditional property bookkeeping.

Definition at line 149 of file LagrangianStressDivergenceBase.h.

◆ _grad_trial_cache

template<class G >
std::vector<std::vector<RankTwoTensor> > TotalLagrangianStressDivergenceBase< G >::_grad_trial_cache
private

Cached gradTrialUnstabilized(beta) per (qp, j) for the current column.

Used by the B-bar Jacobian branch (F_bar_mode = incremental). Cheap to store and avoids the per-(_i, _j) G::gradOp call.

Definition at line 120 of file TotalLagrangianStressDivergenceBase.h.

◆ _large_kinematics

bool LagrangianStressDivergenceBase::_large_kinematics
protectedinherited

If true use large deformation kinematics.

Derived in initialSetup() from the strain calculator's LARGE_KINEMATICS guarantee (single source of truth); the kernel's own large_kinematics parameter is deprecated.

Definition at line 95 of file LagrangianStressDivergenceBase.h.

Referenced by HomogenizedTotalLagrangianStressDivergence::computeScalarJacobian(), HomogenizedTotalLagrangianStressDivergence::computeScalarQpOffDiagJacobian(), HomogenizedTotalLagrangianStressDivergence::computeScalarResidual(), LagrangianStressDivergenceBase::deltaPK1NonLocalFBar(), and LagrangianStressDivergenceBase::initialSetup().

◆ _ndisp

const unsigned int LagrangianStressDivergenceBase::_ndisp
protectedinherited

◆ _out_of_plane_strain

const MooseVariable* LagrangianStressDivergenceBase::_out_of_plane_strain
protectedinherited

◆ _pk1

template<class G >
const MaterialProperty<RankTwoTensor>& TotalLagrangianStressDivergenceBase< G >::_pk1
protected

◆ _pk1_ddot_F_ust

template<class G >
std::vector<Real> TotalLagrangianStressDivergenceBase< G >::_pk1_ddot_F_ust
private

pk1 : F_ust per qp for the B-bar volumetric correction (see cachePK1ContractionFUst).

Populated only when F_bar_mode = incremental.

Definition at line 137 of file TotalLagrangianStressDivergenceBase.h.

◆ _stabilize_strain

const bool LagrangianStressDivergenceBase::_stabilize_strain
protectedinherited

◆ _temperature

const MooseVariable* LagrangianStressDivergenceBase::_temperature
protectedinherited

Temperature, if provided. This is used only to get the trial functions.

Definition at line 193 of file LagrangianStressDivergenceBase.h.

Referenced by LagrangianStressDivergenceBase::computeQpOffDiagJacobian().


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