LCOV - code coverage report
Current view: top level - src/materials/lagrangian - ComputeLagrangianWPSStrain.C (source / functions) Hit Total Coverage
Test: idaholab/moose solid_mechanics: #33390 (250e9c) with base 846a5c Lines: 13 14 92.9 %
Date: 2026-07-31 18:20:40 Functions: 3 3 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       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             : #include "ComputeLagrangianWPSStrain.h"
      11             : 
      12             : registerMooseObject("SolidMechanicsApp", ComputeLagrangianWPSStrain);
      13             : 
      14             : InputParameters
      15          64 : ComputeLagrangianWPSStrain::validParams()
      16             : {
      17          64 :   InputParameters params = ComputeLagrangianStrain::validParams();
      18         128 :   params.addRequiredCoupledVar("out_of_plane_strain", "The out-of-plane strain");
      19          64 :   return params;
      20           0 : }
      21             : 
      22          48 : ComputeLagrangianWPSStrain::ComputeLagrangianWPSStrain(const InputParameters & params)
      23          48 :   : ComputeLagrangianStrain(params), _out_of_plane_strain(coupledValue("out_of_plane_strain"))
      24             : {
      25          48 : }
      26             : 
      27             : void
      28       20253 : ComputeLagrangianWPSStrain::computeDeformationGradient()
      29             : {
      30       20253 :   ComputeLagrangianStrain::computeDeformationGradient();
      31             : 
      32             :   // Add the out-of-plane strain to BOTH the stabilized `_F` and the unstabilized
      33             :   // `_F_ust` AFTER F-bar has run. F-bar's partials (`_d_F_stab_d_F_*`) therefore do
      34             :   // NOT see this contribution -- strain_zz bypasses F-bar's non-local chain. The WPS
      35             :   // kernel and the TL kernel's `computeQpJacobianOutOfPlaneStrain` use the
      36             :   // "no-F-bar" pk1_jacobian variant to handle strain_zz perturbations correctly.
      37      101265 :   for (_qp = 0; _qp < _qrule->n_points(); ++_qp)
      38             :   {
      39       81012 :     _F[_qp](2, 2) += _out_of_plane_strain[_qp];
      40       81012 :     _F_ust[_qp](2, 2) += _out_of_plane_strain[_qp];
      41             :   }
      42       20253 : }

Generated by: LCOV version 1.14