- base_nameMaterial property base name
C++ Type:std::string
Controllable:No
Description:Material property base name
 - blockThe list of blocks (ids or names) that this object will be applied
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:The list of blocks (ids or names) that this object will be applied
 - boundaryThe list of boundaries (ids or names) from the mesh where this object applies
C++ Type:std::vector<BoundaryName>
Controllable:No
Description:The list of boundaries (ids or names) from the mesh where this object applies
 - computeTrueWhen false, MOOSE will not call compute methods on this material. The user must call computeProperties() after retrieving the MaterialBase via MaterialBasePropertyInterface::getMaterialBase(). Non-computed MaterialBases are not sorted for dependencies.
Default:True
C++ Type:bool
Controllable:No
Description:When false, MOOSE will not call compute methods on this material. The user must call computeProperties() after retrieving the MaterialBase via MaterialBasePropertyInterface::getMaterialBase(). Non-computed MaterialBases are not sorted for dependencies.
 - constant_onNONEWhen ELEMENT, MOOSE will only call computeQpProperties() for the 0th quadrature point, and then copy that value to the other qps.When SUBDOMAIN, MOOSE will only call computeQpProperties() for the 0th quadrature point, and then copy that value to the other qps. Evaluations on element qps will be skipped
Default:NONE
C++ Type:MooseEnum
Controllable:No
Description:When ELEMENT, MOOSE will only call computeQpProperties() for the 0th quadrature point, and then copy that value to the other qps.When SUBDOMAIN, MOOSE will only call computeQpProperties() for the 0th quadrature point, and then copy that value to the other qps. Evaluations on element qps will be skipped
 - declare_suffixAn optional suffix parameter that can be appended to any declared properties. The suffix will be prepended with a '_' character.
C++ Type:MaterialPropertyName
Unit:(no unit assumed)
Controllable:No
Description:An optional suffix parameter that can be appended to any declared properties. The suffix will be prepended with a '_' character.
 - elasticity_tensorelasticity_tensorThe name of the elasticity tensor.
Default:elasticity_tensor
C++ Type:MaterialPropertyName
Unit:(no unit assumed)
Controllable:No
Description:The name of the elasticity tensor.
 - large_kinematicsFalseUse a large displacement stress update.
Default:False
C++ Type:bool
Controllable:No
Description:Use a large displacement stress update.
 - objective_ratetruesdellWhich type of objective integration to use
Default:truesdell
C++ Type:MooseEnum
Controllable:No
Description:Which type of objective integration to use
 
ComputeLagrangianLinearElasticStress
Stress update based on the small (engineering) stress
Overview
This class implements the simple linear elastic model  which returns the small stress as a linear function of the small strain.    is an elasticity tensor calculated by a ComputeElasticityTensor object, with a name provided in the stress calculator input.
This model inherits from ComputeLagrangianObjectiveStress and so it will integrate an objective stress rate to provide a "hypoelastic" large deformation constitutive response based solely on the small strain model.
Example Input File Syntax
The key parameters are elasticity_tensor giving the name of the elasticity tensor and large_kinematics which controls whether the model uses the simple small stress, linear elastic update or integrates the model through an objective stress rate.  The objective_rate parameters controls which objective rate is used.
The following example sets up a hypoelastic, large deformation model based on the truesdell rate using the default elastic tensor name ("elasticity_tensor").
[Materials<<<{"href": "../../../syntax/Materials/index.html"}>>>]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor<<<{"description": "Compute a constant isotropic elasticity tensor.", "href": "../ComputeIsotropicElasticityTensor.html"}>>>
    youngs_modulus<<<{"description": "Young's modulus of the material."}>>> = 1000.0
    poissons_ratio<<<{"description": "Poisson's ratio for the material."}>>> = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress<<<{"description": "Stress update based on the small (engineering) stress", "href": "ComputeLagrangianLinearElasticStress.html"}>>>
    large_kinematics<<<{"description": "Use a large displacement stress update."}>>> = true
  []
  [compute_strain]
    type = ComputeLagrangianStrain<<<{"description": "Compute strain in Cartesian coordinates.", "href": "ComputeLagrangianStrain.html"}>>>
    displacements<<<{"description": "Displacement variables"}>>> = 'disp_x disp_y disp_z'
    large_kinematics<<<{"description": "Use large displacement kinematics in the kernel."}>>> = true
  []
[](modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/patch/large_patch.i)Input Parameters
- control_tagsAdds user-defined labels for accessing object parameters via control logic.
C++ Type:std::vector<std::string>
Controllable:No
Description:Adds user-defined labels for accessing object parameters via control logic.
 - enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:Yes
Description:Set the enabled status of the MooseObject.
 - implicitTrueDetermines whether this object is calculated using an implicit or explicit form
Default:True
C++ Type:bool
Controllable:No
Description:Determines whether this object is calculated using an implicit or explicit form
 - search_methodnearest_node_connected_sidesChoice of search algorithm. All options begin by finding the nearest node in the primary boundary to a query point in the secondary boundary. In the default nearest_node_connected_sides algorithm, primary boundary elements are searched iff that nearest node is one of their nodes. This is fast to determine via a pregenerated node-to-elem map and is robust on conforming meshes. In the optional all_proximate_sides algorithm, primary boundary elements are searched iff they touch that nearest node, even if they are not topologically connected to it. This is more CPU-intensive but is necessary for robustness on any boundary surfaces which has disconnections (such as Flex IGA meshes) or non-conformity (such as hanging nodes in adaptively h-refined meshes).
Default:nearest_node_connected_sides
C++ Type:MooseEnum
Options:nearest_node_connected_sides, all_proximate_sides
Controllable:No
Description:Choice of search algorithm. All options begin by finding the nearest node in the primary boundary to a query point in the secondary boundary. In the default nearest_node_connected_sides algorithm, primary boundary elements are searched iff that nearest node is one of their nodes. This is fast to determine via a pregenerated node-to-elem map and is robust on conforming meshes. In the optional all_proximate_sides algorithm, primary boundary elements are searched iff they touch that nearest node, even if they are not topologically connected to it. This is more CPU-intensive but is necessary for robustness on any boundary surfaces which has disconnections (such as Flex IGA meshes) or non-conformity (such as hanging nodes in adaptively h-refined meshes).
 - seed0The seed for the master random number generator
Default:0
C++ Type:unsigned int
Controllable:No
Description:The seed for the master random number generator
 - use_displaced_meshFalseWhether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.
 
Advanced Parameters
- output_propertiesList of material properties, from this material, to output (outputs must also be defined to an output type)
C++ Type:std::vector<std::string>
Controllable:No
Description:List of material properties, from this material, to output (outputs must also be defined to an output type)
 - outputsnone Vector of output names where you would like to restrict the output of variables(s) associated with this object
Default:none
C++ Type:std::vector<OutputName>
Controllable:No
Description:Vector of output names where you would like to restrict the output of variables(s) associated with this object
 
Outputs Parameters
- prop_getter_suffixAn optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
C++ Type:MaterialPropertyName
Unit:(no unit assumed)
Controllable:No
Description:An optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
 - use_interpolated_stateFalseFor the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Default:False
C++ Type:bool
Controllable:No
Description:For the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
 
Material Property Retrieval Parameters
Input Files
- (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/thermal_expansion/jactest.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/rates/jacobian.i)
 - (modules/solid_mechanics/test/tests/jacobian_damper/block_restriction.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/3D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/1D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/2d_pbc_symmetry.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/patch.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/thermal_expansion/constrained.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/generalized_plane_strain/pull_2D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/action_2d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/ld-strain.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/3D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/jacobian/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/L/small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/rates/rotation.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/action_L.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/area.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/2D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/no_action_L.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/1D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/3D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/thermal_expansion/constrained.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/noaction_2d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/thermal_expansion/jactest.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/patch/small_patch.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/stabilization/cook_small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/sd-stress.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/thermal_expansion/jactest.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/patch/small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/1D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/action/action.i)
 - (modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/action/action.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/stabilization/cook_small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/no_action_1D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/action/homogenization_block.i)
 - (modules/solid_mechanics/test/tests/lagrangian/materials/convergence/cauchy-elastic.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/noaction_3d.i)
 - (modules/solid_mechanics/test/tests/eigen_decomp_material/pipe_2d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/2D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/patch/large_patch.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/1D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/L/large.i)
 - (modules/solid_mechanics/test/tests/cohesive_zone_model/ad_czm.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/1D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/no_action_1D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/1D/neumann.i)
 - (modules/solid_mechanics/examples/wave_propagation/cantilever_sweep.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/3D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/analytical/small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/patch/large.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/small-tests/3d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/2D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/3D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/3D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/1D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/patch.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/ld-stress.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/action_1D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/2D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/L/large.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/objective_shear.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/rates/shear.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/L/small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/thermal_expansion/free.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/weak_plane_stress/convergence.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/patch/small_patch.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/action_3d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/thermal_expansion/free.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/large-tests/1d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/objective_shear.i)
 - (modules/solid_mechanics/test/tests/lagrangian/action/simple_test.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/2D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/sd-strain.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/weak_plane_stress/pull_2D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/large-tests/3d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/weak_plane_stress/pull_3D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/rotate.i)
 - (modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/jacobian/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/2D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/no_action_L.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/generalized_plane_strain/pull_3D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/patch/large_patch.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/small-tests/1d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/large-tests/2d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/area.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/2D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/small-tests/2d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/2D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/action_1D.i)
 - (modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/jacobian/dirichlet.i)
 - (modules/solid_mechanics/test/tests/jacobian_damper/cube_load_undisplaced.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/3D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/rotate.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/residual_and_jacobian/3d.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/1D/dirichlet.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/3D/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/action_L.i)
 - (modules/solid_mechanics/test/tests/lagrangian/materials/correctness/cauchy-elastic.i)
 - (modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/jacobian/neumann.i)
 - (modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/analytical/small.i)
 - (modules/solid_mechanics/test/tests/lagrangian/cartesian/total/thermal_expansion/jactest.i)
 
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/patch/large_patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
               '
             '   0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    displacements = 'disp_x disp_y disp_z'
    component = 0
    use_displaced_mesh = true
    large_kinematics = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    displacements = 'disp_x disp_y disp_z'
    component = 1
    use_displaced_mesh = true
    large_kinematics = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    displacements = 'disp_x disp_y disp_z'
    component = 2
    use_displaced_mesh = true
    large_kinematics = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    displacements = 'disp_x disp_y disp_z'
    large_kinematics = true
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/thermal_expansion/jactest.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 2
  ny = 2
  nz = 2
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [temperature]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
    use_displaced_mesh = false
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
    use_displaced_mesh = false
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
    use_displaced_mesh = false
  []
  [temperature]
    type = Diffusion
    variable = temperature
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    eigenstrain_names = "thermal_contribution"
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
    petsc_options_iname = '-snes_type'
    petsc_options_value = 'test'
  []
[]
[Executioner]
  solve_type = NEWTON
  end_time = 1
  dt = 1
  type = Transient
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/rates/jacobian.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.02
    max = 0.02
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.02
    max = 0.02
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.02
    max = 0.02
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '4000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-2000 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '3000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_z
    function = pullz
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
(modules/solid_mechanics/test/tests/jacobian_damper/block_restriction.i)
[Problem]
  kernel_coverage_check = false
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
  [lower_d]
    type = LowerDBlockFromSidesetGenerator
    input = gmg
    sidesets = left
    new_block_id = 10
  []
[]
[Functions]
  [top_pull]
    type = PiecewiseLinear
    x = '0 1     2'
    y = '0 0.025 0.05'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = TOTAL
        block = 0
      []
    []
  []
[]
[BCs]
  [y_pull_function]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 3
    function = top_pull
    preset = true
  []
  [x_bot]
    type = DirichletBC
    variable = disp_x
    boundary = 4
    value = 0.0
  []
  [y_bot]
    type = DirichletBC
    variable = disp_y
    boundary = 1
    value = 0.0
  []
  [z_bot]
    type = DirichletBC
    variable = disp_z
    boundary = 0
    value = 0.0
  []
[]
[Materials]
  [elasticity_tensor]
    type = ComputeIsotropicElasticityTensor
    poissons_ratio = 0.3
    youngs_modulus = 2e5
    block = 0
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
    block = 0
  []
  [dummy]
    type = GenericConstantMaterial
    prop_names = dummy
    prop_values = 0
    block = 10
  []
[]
[Dampers]
  [ejd]
    type = ReferenceElementJacobianDamper
    max_increment = 0.002
    displacements = 'disp_x disp_y disp_z'
    block = 0
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  line_search = 'none'
  nl_rel_tol = 1e-12
  nl_abs_tol = 1e-10
  start_time = 0.0
  end_time = 2
  dt = 1
[]
[Outputs]
  exodus = true
  print_linear_residuals = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/3D/dirichlet.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.4 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.2 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
  [pull_z]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_z
    function = pullz
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/1D/neumann.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '200 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionNeumannBC
    boundary = left
    variable = disp_x
    function = pull
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [stress_base]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/2d_pbc_symmetry.i)
# 2D thermomechanical coupling
# strain periodicity in +-x
# symmetry about the -y plane (i.e. bottom)
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 3
    ny = 3
  []
  [pins]
    type = ExtraNodesetGenerator
    input = 'gmg'
    new_boundary = 'pin'
    coord = '0 0 0'
  []
[]
[Variables]
  [T]
    initial_condition = 300
  []
[]
[Kernels]
  [htime]
    type = CoefTimeDerivative
    variable = 'T'
    Coefficient = 1
  []
  [hcond]
    type = MatDiffusion
    variable = 'T'
    diffusivity = 1e-4
  []
  [hsource]
    type = MatBodyForce
    variable = 'T'
    material_property = source
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
        temperature = T
        eigenstrain_names = 'thermal_egs'
        constraint_types = 'strain none none none none none none none none'
        targets = '0'
        generate_output = 'strain_xx strain_xy strain_yy'
      []
    []
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = 'disp_x'
      auto_direction = 'x'
    []
    [y]
      variable = 'disp_y'
      auto_direction = 'x'
    []
    [T]
      variable = 'T'
      auto_direction = 'x'
    []
  []
  # remove rigid body modes
  [fix_x]
    type = DirichletBC
    boundary = 'pin'
    variable = 'disp_x'
    value = 0
  []
  # symmetry
  [symmetry]
    type = DirichletBC
    boundary = 'bottom'
    variable = 'disp_y'
    value = 0
  []
[]
[Functions]
  [source]
    type = ParsedFunction
    expression = '3*sin(2*pi*x)-y^2'
  []
[]
[Materials]
  [source]
    type = GenericFunctionMaterial
    prop_names = 'source'
    prop_values = 'source'
  []
  [thermal_egs]
    type = ComputeThermalExpansionEigenstrain
    eigenstrain_name = 'thermal_egs'
    stress_free_temperature = 300
    thermal_expansion_coeff = 5e-3
    temperature = 'T'
  []
  [C]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1e5
    poissons_ratio = 0.3
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
    objective_rate = jaumann
  []
[]
[Executioner]
  type = Transient
  solve_type = 'NEWTON'
  line_search = none
  automatic_scaling = true
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  dt = 1
  end_time = 2
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
                  0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  base_name = 'whatever'
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    elasticity_tensor = elasticity_tensor
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/thermal_expansion/constrained.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 2
  ny = 2
  nz = 2
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  eigenstrain_names = "thermal_contribution"
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[AuxVariables]
  [temperature]
  []
[]
[AuxKernels]
  [control_temperature]
    type = FunctionAux
    variable = temperature
    function = temperature_control
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [rightx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
[]
[Functions]
  [temperature_control]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz strain_xx strain_yy strain_zz strain_xy '
                          'strain_xz strain_yz'
      []
    []
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  solve_type = NEWTON
  end_time = 1
  dt = 1
  type = Transient
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/generalized_plane_strain/pull_2D.i)
constraint_types = 'none none none none none none none none strain'
targets = '0'
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 5
    ny = 5
  []
  use_displaced_mesh = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [hvar]
    family = SCALAR
    order = FIRST
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
[]
[BCs]
  [fix_x]
    type = DirichletBC
    variable = disp_x
    boundary = 'top bottom'
    value = 0
  []
  [fix_y]
    type = DirichletBC
    variable = disp_y
    boundary = 'bottom'
    value = 0
  []
  [disp_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'top'
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [stress_zz]
    type = RankTwoCartesianComponent
    rank_two_tensor = cauchy_stress
    index_i = 2
    index_j = 2
    property_name = stress_zz
  []
  [strain_zz]
    type = RankTwoCartesianComponent
    rank_two_tensor = mechanical_strain
    index_i = 2
    index_j = 2
    property_name = strain_zz
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  end_time = 0.1
  solve_type = 'newton'
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
[]
[Postprocessors]
  [strain_zz]
    type = ElementAverageMaterialProperty
    mat_prop = strain_zz
  []
  [stress_zz]
    type = ElementAverageMaterialProperty
    mat_prop = stress_zz
  []
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/action_2d.i)
# 2D with mixed conditions on stress/strain
[GlobalParams]
  displacements = 'disp_x disp_y'
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '2d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0'
    fixed_normal = true
    new_boundary = 'left right bottom top'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
        constraint_types = 'stress none none stress strain none none none none'
        targets = 'stress11 stress12 strain22'
        generate_output = 'pk1_stress_xx pk1_stress_xy pk1_stress_xz pk1_stress_yx pk1_stress_yy '
                          'pk1_stress_yz pk1_stress_zx pk1_stress_zy pk1_stress_zz '
                          'deformation_gradient_xx deformation_gradient_xy deformation_gradient_xz '
                          'deformation_gradient_yx deformation_gradient_yy deformation_gradient_yz '
                          'deformation_gradient_zx deformation_gradient_zy deformation_gradient_zz'
      []
    []
  []
[]
[Functions]
  [stress11]
    type = ParsedFunction
    expression = '400*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-2.0e-2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_y
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix2"
    variable = disp_y
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 30
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  [out]
    type = Exodus
    file_base = '2d'
  []
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/ld-strain.i)
# 2D test with just strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  constraint_types = 'strain strain strain strain strain strain strain strain strain'
  targets = 'strain11 strain21 strain31 strain12 strain22 strain32 strain13 strain23 strain33'
  macro_gradient = hvar
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = NINTH
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.1
    max = 0.1
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.1
    max = 0.1
  []
  [hvar]
    type = ScalarConstantIC
    variable = hvar
    value = 0.1
  []
[]
[AuxVariables]
  [s11]
    family = MONOMIAL
    order = CONSTANT
  []
  [s21]
    family = MONOMIAL
    order = CONSTANT
  []
  [s31]
    family = MONOMIAL
    order = CONSTANT
  []
  [s12]
    family = MONOMIAL
    order = CONSTANT
  []
  [s22]
    family = MONOMIAL
    order = CONSTANT
  []
  [s32]
    family = MONOMIAL
    order = CONSTANT
  []
  [s13]
    family = MONOMIAL
    order = CONSTANT
  []
  [s23]
    family = MONOMIAL
    order = CONSTANT
  []
  [s33]
    family = MONOMIAL
    order = CONSTANT
  []
  [F11]
    family = MONOMIAL
    order = CONSTANT
  []
  [F21]
    family = MONOMIAL
    order = CONSTANT
  []
  [F31]
    family = MONOMIAL
    order = CONSTANT
  []
  [F12]
    family = MONOMIAL
    order = CONSTANT
  []
  [F22]
    family = MONOMIAL
    order = CONSTANT
  []
  [F32]
    family = MONOMIAL
    order = CONSTANT
  []
  [F13]
    family = MONOMIAL
    order = CONSTANT
  []
  [F23]
    family = MONOMIAL
    order = CONSTANT
  []
  [F33]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [s11]
    type = RankTwoAux
    variable = s11
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [s21]
    type = RankTwoAux
    variable = s21
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [s31]
    type = RankTwoAux
    variable = s31
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [s12]
    type = RankTwoAux
    variable = s12
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [s22]
    type = RankTwoAux
    variable = s22
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [s32]
    type = RankTwoAux
    variable = s32
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [s13]
    type = RankTwoAux
    variable = s13
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [s23]
    type = RankTwoAux
    variable = s23
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [s33]
    type = RankTwoAux
    variable = s33
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [F11]
    type = RankTwoAux
    variable = F11
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [F21]
    type = RankTwoAux
    variable = F21
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [F31]
    type = RankTwoAux
    variable = F31
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [F12]
    type = RankTwoAux
    variable = F12
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [F22]
    type = RankTwoAux
    variable = F22
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [F32]
    type = RankTwoAux
    variable = F32
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [F13]
    type = RankTwoAux
    variable = F13
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [F23]
    type = RankTwoAux
    variable = F23
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [F33]
    type = RankTwoAux
    variable = F33
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-4.0e-2*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain32]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain31]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain21]
    type = ParsedFunction
    expression = '-1.5e-2*t'
  []
  [zero]
    type = ConstantFunction
    value = 0
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [s11]
    type = ElementAverageValue
    variable = s11
    execute_on = 'initial timestep_end'
  []
  [s21]
    type = ElementAverageValue
    variable = s21
    execute_on = 'initial timestep_end'
  []
  [s31]
    type = ElementAverageValue
    variable = s31
    execute_on = 'initial timestep_end'
  []
  [s12]
    type = ElementAverageValue
    variable = s12
    execute_on = 'initial timestep_end'
  []
  [s22]
    type = ElementAverageValue
    variable = s22
    execute_on = 'initial timestep_end'
  []
  [s32]
    type = ElementAverageValue
    variable = s32
    execute_on = 'initial timestep_end'
  []
  [s13]
    type = ElementAverageValue
    variable = s13
    execute_on = 'initial timestep_end'
  []
  [s23]
    type = ElementAverageValue
    variable = s23
    execute_on = 'initial timestep_end'
  []
  [s33]
    type = ElementAverageValue
    variable = s33
    execute_on = 'initial timestep_end'
  []
  [F11]
    type = ElementAverageValue
    variable = F11
    execute_on = 'initial timestep_end'
  []
  [F21]
    type = ElementAverageValue
    variable = F21
    execute_on = 'initial timestep_end'
  []
  [F31]
    type = ElementAverageValue
    variable = F31
    execute_on = 'initial timestep_end'
  []
  [F12]
    type = ElementAverageValue
    variable = F12
    execute_on = 'initial timestep_end'
  []
  [F22]
    type = ElementAverageValue
    variable = F22
    execute_on = 'initial timestep_end'
  []
  [F32]
    type = ElementAverageValue
    variable = F32
    execute_on = 'initial timestep_end'
  []
  [F13]
    type = ElementAverageValue
    variable = F13
    execute_on = 'initial timestep_end'
  []
  [F23]
    type = ElementAverageValue
    variable = F23
    execute_on = 'initial timestep_end'
  []
  [F33]
    type = ElementAverageValue
    variable = F33
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 20
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
[Outputs]
  exodus = false
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/3D/neumann.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '4000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-2000 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '3000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_z
    function = pullz
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/jacobian/neumann.i)
[GlobalParams]
  displacements = 'disp_r disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 2
    ny = 2
  []
  coord_type = RZ
[]
[Variables]
  [disp_r]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_r
    component = 0
  []
  [sdz]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_z
    component = 1
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    preset = false
    variable = disp_z
    boundary = bottom
    value = 0.0
  []
  [top]
    type = FunctionNeumannBC
    variable = disp_z
    boundary = top
    function = 't*1e3'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrainAxisymmetricCylindrical
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 5
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/L/small.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/rates/rotation.i)
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 1
    ny = 1
  []
  [bottom_left]
    type = ExtraNodesetGenerator
    input = msh
    new_boundary = 'bottom_left'
    coord = '0 0 0'
  []
  [top_left]
    type = ExtraNodesetGenerator
    input = bottom_left
    new_boundary = 'top_left'
    coord = '0 1 0'
  []
  [top_right]
    type = ExtraNodesetGenerator
    input = top_left
    new_boundary = 'top_right'
    coord = '1 1 0'
  []
  [bottom_right]
    type = ExtraNodesetGenerator
    input = top_right
    new_boundary = 'bottom_right'
    coord = '1 0 0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[AuxVariables]
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
    [AuxKernel]
      type = RankTwoAux
      rank_two_tensor = cauchy_stress
      index_i = 0
      index_j = 0
      execute_on = TIMESTEP_END
    []
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
    [AuxKernel]
      type = RankTwoAux
      rank_two_tensor = cauchy_stress
      index_i = 1
      index_j = 1
      execute_on = TIMESTEP_END
    []
  []
[]
[BCs]
  [fix_y]
    type = DirichletBC
    variable = disp_y
    boundary = 'bottom_left'
    value = 0
  []
  [fix_x]
    type = DirichletBC
    variable = disp_x
    boundary = 'bottom_left'
    value = 0
  []
  [top_left_x]
    type = FunctionDirichletBC
    variable = disp_x
    boundary = 'top_left'
    function = 'theta:=if(t<1,0,t-1); -sin(theta)'
  []
  [top_left_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'top_left'
    function = 'theta:=if(t<1,0,t-1); cos(theta)-1'
  []
  [bottom_right_x]
    type = FunctionDirichletBC
    variable = disp_x
    boundary = 'bottom_right'
    function = 'theta:=if(t<1,0,t-1); if(t<1,t,2*cos(theta)-1)'
  []
  [bottom_right_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'bottom_right'
    function = 'theta:=if(t<1,0,t-1); if(t<1,0,2*sin(theta))'
  []
  [top_right_x]
    type = FunctionDirichletBC
    variable = disp_x
    boundary = 'top_right'
    function = 'theta:=if(t<1,0,t-1); phi:=theta+atan(0.5); if(t<1,t,sqrt(5)*cos(phi)-1)'
  []
  [top_right_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'top_right'
    function = 'theta:=if(t<1,0,t-1); phi:=theta+atan(0.5); if(t<1,0,sqrt(5)*sin(phi)-1)'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1e5
    poissons_ratio = 0
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [strain]
    type = ComputeLagrangianStrain
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = stress_xx
    execute_on = 'INITIAL TIMESTEP_END'
  []
  [syy]
    type = ElementAverageValue
    variable = stress_yy
    execute_on = 'INITIAL TIMESTEP_END'
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  end_time = '${fparse pi/2+1}'
  solve_type = NEWTON
  line_search = none
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/action_L.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = true
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz strain_xx strain_yy strain_zz strain_xy '
                          'strain_xz strain_yz'
      []
    []
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Outputs]
  [out]
    type = Exodus
    file_base = 'blah'
  []
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/area.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[Functions]
  [zstress]
    type = PiecewiseLinear
    x = '0 1'
    y = '0 500'
  []
  [constant]
    type = ConstantFunction
    value = 1.0
  []
  [ratio]
    type = ParsedFunction
    symbol_names = 'sd su'
    symbol_values = 's_def s_undef'
    expression = 'sd / su'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [boty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [backz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = front
    variable = disp_z
    function = zstress
  []
[]
[AuxKernels]
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [s_undef]
    type = SideIntegralVariablePostprocessor
    variable = stress_zz
    boundary = front
  []
  [s_def]
    type = SideIntegralVariablePostprocessor
    variable = stress_zz
    boundary = front
    use_displaced_mesh = true
  []
  [area_calc]
    type = FunctionValuePostprocessor
    function = ratio
  []
  [area]
    type = AreaPostprocessor
    boundary = front
    use_displaced_mesh = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/2D/dirichlet.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.01
    max = 0.01
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.01
    max = 0.01
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.5 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/no_action_L.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [cauchy_stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [cauchy_stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [cauchy_stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [cauchy_stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [cauchy_stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [cauchy_stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Outputs]
  exodus = true
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/1D/dirichlet.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [stress_base]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/3D/neumann.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.02
    max = 0.02
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.02
    max = 0.02
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.02
    max = 0.02
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '4000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-2000 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '3000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_z
    function = pullz
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/thermal_expansion/constrained.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 2
  ny = 2
  nz = 2
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  eigenstrain_names = "thermal_contribution"
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[AuxVariables]
  [temperature]
  []
[]
[AuxKernels]
  [control_temperature]
    type = FunctionAux
    variable = temperature
    function = temperature_control
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [rightx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
[]
[Functions]
  [temperature_control]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        new_system = true
        formulation = UPDATED
        volumetric_locking_correction = false
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz strain_xx strain_yy strain_zz strain_xy '
                          'strain_xz strain_yz'
      []
    []
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  solve_type = NEWTON
  end_time = 1
  dt = 1
  type = Transient
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/noaction_2d.i)
# 2D with mixed conditions on stress/strain
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = false
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '2d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0'
    fixed_normal = true
    new_boundary = 'left right bottom top'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [hvar]
    family = SCALAR
    order = THIRD
  []
[]
[AuxVariables]
  [pk1_stress_xx]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_yx]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_zx]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_xy]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_yy]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_zy]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_xz]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_yz]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_zz]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_xx]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_yx]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_zx]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_xy]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_yy]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_zy]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_xz]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_yz]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_zz]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [pk1_stress_xx]
    type = RankTwoAux
    variable = pk1_stress_xx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [pk1_stress_yx]
    type = RankTwoAux
    variable = pk1_stress_yx
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [pk1_stress_zx]
    type = RankTwoAux
    variable = pk1_stress_zx
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [pk1_stress_xy]
    type = RankTwoAux
    variable = pk1_stress_xy
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [pk1_stress_yy]
    type = RankTwoAux
    variable = pk1_stress_yy
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [pk1_stress_zy]
    type = RankTwoAux
    variable = pk1_stress_zy
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [pk1_stress_xz]
    type = RankTwoAux
    variable = pk1_stress_xz
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [pk1_stress_yz]
    type = RankTwoAux
    variable = pk1_stress_yz
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [pk1_stress_zz]
    type = RankTwoAux
    variable = pk1_stress_zz
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [deformation_gradient_xx]
    type = RankTwoAux
    variable = deformation_gradient_xx
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [deformation_gradient_yx]
    type = RankTwoAux
    variable = deformation_gradient_yx
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [deformation_gradient_zx]
    type = RankTwoAux
    variable = deformation_gradient_zx
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [deformation_gradient_xy]
    type = RankTwoAux
    variable = deformation_gradient_xy
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [deformation_gradient_yy]
    type = RankTwoAux
    variable = deformation_gradient_yy
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [deformation_gradient_zy]
    type = RankTwoAux
    variable = deformation_gradient_zy
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [deformation_gradient_xz]
    type = RankTwoAux
    variable = deformation_gradient_xz
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [deformation_gradient_yz]
    type = RankTwoAux
    variable = deformation_gradient_yz
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [deformation_gradient_zz]
    type = RankTwoAux
    variable = deformation_gradient_zz
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
    constraint_types = 'stress none none stress strain none none none none'
    targets = 'stress11 stress12 strain22'
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
    constraint_types = 'stress none none stress strain none none none none'
    targets = 'stress11 stress12 strain22'
  []
[]
[Functions]
  [stress11]
    type = ParsedFunction
    expression = '400*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-2.0e-2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_y
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix2"
    variable = disp_y
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
    constraint_types = 'stress none none stress strain none none none none'
    targets = 'stress11 stress12 strain22'
    macro_gradient = hvar
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 30
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  file_base = 2d
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/thermal_expansion/jactest.i)
[GlobalParams]
  displacements = 'disp_r'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  type = GeneratedMesh
  dim = 1
  nx = 2
  coord_type = RSPHERICAL
[]
[Variables]
  [disp_r]
    [InitialCondition]
      type = RandomIC
      min = 0
      max = 0.02
    []
  []
  [temperature]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceCentrosymmetricSpherical
    variable = disp_r
    component = 0
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
  []
  [temperature]
    type = Diffusion
    variable = temperature
  []
[]
[BCs]
  [T_left]
    type = DirichletBC
    variable = temperature
    boundary = left
    value = 0
    preset = false
  []
  [T_right]
    type = DirichletBC
    variable = temperature
    boundary = right
    value = 1
    preset = false
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrainCentrosymmetricSpherical
    eigenstrain_names = 'thermal_contribution'
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  end_time = 1
  dt = 1
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/patch/small_patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
               '
             '   0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/stabilization/cook_small.i)
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = false
  stabilize_strain = true
[]
[Mesh]
  type = FileMesh
  file = cook_mesh.exo
  dim = 2
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [fixed_x]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = canti
    value = 0.0
  []
  [fixed_y]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = canti
    value = 0.0
  []
  [pull]
    type = NeumannBC
    variable = disp_y
    boundary = loading
    value = 10.0
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 250.0
    poissons_ratio = 0.4999999
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Steady
  solve_type = 'newton'
  line_search = 'none'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-6
  l_tol = 1e-10
[]
[Postprocessors]
  [value]
    type = PointValue
    variable = disp_y
    point = '48 60 0'
    use_displaced_mesh = false
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/sd-stress.i)
# 3D test with stress control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  constraint_types = 'stress none none stress stress none stress stress stress'
  targets = 'stress11 stress12 stress22 stress13 stress23 stress33'
  macro_gradient = hvar
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = SIXTH
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.1
    max = 0.1
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.1
    max = 0.1
  []
  [hvar]
    type = ScalarConstantIC
    variable = hvar
    value = 0.1
  []
[]
[AuxVariables]
  [sxx]
    family = MONOMIAL
    order = CONSTANT
  []
  [syy]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxy]
    family = MONOMIAL
    order = CONSTANT
  []
  [szz]
    family = MONOMIAL
    order = CONSTANT
  []
  [syz]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exx]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyy]
    family = MONOMIAL
    order = CONSTANT
  []
  [exy]
    family = MONOMIAL
    order = CONSTANT
  []
  [ezz]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exz]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [sxx]
    type = RankTwoAux
    variable = sxx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [syy]
    type = RankTwoAux
    variable = syy
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [sxy]
    type = RankTwoAux
    variable = sxy
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [zz]
    type = RankTwoAux
    variable = szz
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [syz]
    type = RankTwoAux
    variable = syz
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [sxz]
    type = RankTwoAux
    variable = sxz
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [exx]
    type = RankTwoAux
    variable = exx
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 0
  []
  [eyy]
    type = RankTwoAux
    variable = eyy
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 1
  []
  [exy]
    type = RankTwoAux
    variable = exy
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 1
  []
  [ezz]
    type = RankTwoAux
    variable = ezz
    rank_two_tensor = mechanical_strain
    index_i = 2
    index_j = 2
  []
  [eyz]
    type = RankTwoAux
    variable = eyz
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 2
  []
  [exz]
    type = RankTwoAux
    variable = exz
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [stress11]
    type = ParsedFunction
    expression = '4.0e2*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-2.0e2*t'
  []
  [stress33]
    type = ParsedFunction
    expression = '8.0e2*t'
  []
  [stress23]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress13]
    type = ParsedFunction
    expression = '-7.0e2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = sxx
    execute_on = 'initial timestep_end'
  []
  [syy]
    type = ElementAverageValue
    variable = syy
    execute_on = 'initial timestep_end'
  []
  [sxy]
    type = ElementAverageValue
    variable = sxy
    execute_on = 'initial timestep_end'
  []
  [szz]
    type = ElementAverageValue
    variable = szz
    execute_on = 'initial timestep_end'
  []
  [syz]
    type = ElementAverageValue
    variable = syz
    execute_on = 'initial timestep_end'
  []
  [sxz]
    type = ElementAverageValue
    variable = sxz
    execute_on = 'initial timestep_end'
  []
  [exx]
    type = ElementAverageValue
    variable = exx
    execute_on = 'initial timestep_end'
  []
  [eyy]
    type = ElementAverageValue
    variable = eyy
    execute_on = 'initial timestep_end'
  []
  [exy]
    type = ElementAverageValue
    variable = exy
    execute_on = 'initial timestep_end'
  []
  [ezz]
    type = ElementAverageValue
    variable = ezz
    execute_on = 'initial timestep_end'
  []
  [eyz]
    type = ElementAverageValue
    variable = eyz
    execute_on = 'initial timestep_end'
  []
  [exz]
    type = ElementAverageValue
    variable = exz
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
[Outputs]
  exodus = false
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/thermal_expansion/jactest.i)
[GlobalParams]
  displacements = 'disp_r disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  type = GeneratedMesh
  dim = 2
  nx = 2
  ny = 2
  coord_type = RZ
[]
[Variables]
  [disp_r]
    [InitialCondition]
      type = RandomIC
      min = 0
      max = 0.02
    []
  []
  [disp_z]
    [InitialCondition]
      type = RandomIC
      min = -0.02
      max = 0.02
    []
  []
  [temperature]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_r
    component = 0
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
  []
  [sdz]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_z
    component = 1
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
  []
  [temperature]
    type = Diffusion
    variable = temperature
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    variable = disp_z
    boundary = bottom
    value = 0.0
    preset = false
  []
  [top]
    type = DirichletBC
    variable = disp_z
    boundary = top
    value = 0.1
    preset = false
  []
  [T_left]
    type = DirichletBC
    variable = temperature
    boundary = left
    value = 0
    preset = false
  []
  [T_right]
    type = DirichletBC
    variable = temperature
    boundary = right
    value = 1
    preset = false
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrainAxisymmetricCylindrical
    eigenstrain_names = 'thermal_contribution'
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  end_time = 1
  dt = 1
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/patch/small.i)
[GlobalParams]
  displacements = 'disp_r disp_z'
  large_kinematics = false
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 2
    ny = 2
  []
  coord_type = RZ
[]
[Variables]
  [disp_r]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_r
    component = 0
  []
  [sdz]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_z
    component = 1
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    preset = false
    variable = disp_z
    boundary = bottom
    value = 0.0
  []
  [top]
    type = FunctionDirichletBC
    preset = false
    variable = disp_z
    boundary = top
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    output_properties = 'pk1_stress'
    outputs = 'exodus'
  []
  [compute_strain]
    type = ComputeLagrangianStrainAxisymmetricCylindrical
    output_properties = 'mechanical_strain'
    outputs = 'exodus'
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/1D/neumann.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '200 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionNeumannBC
    boundary = left
    variable = disp_x
    function = pull
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 5.0
  dtmin = 5.0
  end_time = 5.0
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/action/action.i)
[GlobalParams]
  displacements = 'disp_r disp_z'
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 2
    ny = 2
  []
  coord_type = RZ
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        formulation = TOTAL
        strain = FINITE
        add_variables = true
        new_system = true
        volumetric_locking_correction = true
      []
    []
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    preset = false
    variable = disp_z
    boundary = bottom
    value = 0.0
  []
  [top]
    type = FunctionDirichletBC
    preset = false
    variable = disp_z
    boundary = top
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/action/action.i)
[GlobalParams]
  displacements = 'disp_r'
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 2
  []
  coord_type = RSPHERICAL
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        formulation = TOTAL
        strain = FINITE
        add_variables = true
        new_system = true
        volumetric_locking_correction = true
      []
    []
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    preset = false
    variable = disp_r
    boundary = left
    value = 0.0
  []
  [top]
    type = FunctionDirichletBC
    preset = false
    variable = disp_r
    boundary = right
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/stabilization/cook_small.i)
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = false
  stabilize_strain = true
[]
[Mesh]
  type = FileMesh
  file = cook_mesh.exo
  dim = 2
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [fixed_x]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = canti
    value = 0.0
  []
  [fixed_y]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = canti
    value = 0.0
  []
  [pull]
    type = NeumannBC
    variable = disp_y
    boundary = loading
    value = 10.0
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 250.0
    poissons_ratio = 0.4999999
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Steady
  solve_type = 'newton'
  line_search = 'none'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-6
  l_tol = 1e-10
[]
[Postprocessors]
  [value]
    type = PointValue
    variable = disp_y
    point = '48 60 0'
    use_displaced_mesh = false
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/no_action_1D.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [stress_base]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/action/homogenization_block.i)
[Mesh]
  use_displaced_mesh = false
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
  [A]
    type = SubdomainBoundingBoxGenerator
    input = msh
    bottom_left = '0 0 0'
    top_right = '1 1 1'
    block_id = 0
    block_name = A
  []
  [B]
    type = SubdomainBoundingBoxGenerator
    input = A
    bottom_left = '0 0 0'
    top_right = '0.25 0.25 0.5'
    block_id = 1
    block_name = B
  []
[]
[Variables]
  [x]
    block = 'B'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      displacements = 'disp_x disp_y disp_z'
      [all]
        displacements = 'disp_x disp_y disp_z'
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = true
        block = 'A'
        constraint_types = 'stress strain strain stress stress strain stress stress strain'
        targets = '0 0 0 0 0 0 0 0 0'
      []
    []
  []
[]
[Materials]
  [stress]
    type = ComputeLagrangianLinearElasticStress
    block = 'A'
  []
  [C1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 2e5
    poissons_ratio = 0.3
    block = 'A'
  []
[]
[Kernels]
  [blah]
    type = NullKernel
    variable = x
  []
[]
[Executioner]
  type = Steady
[]
(modules/solid_mechanics/test/tests/lagrangian/materials/convergence/cauchy-elastic.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.01
    max = 0.01
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.01
    max = 0.01
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.01
    max = 0.01
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '4000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-2000 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '3000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_z
    function = pullz
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  l_max_its = 2
  l_tol = 1e-14
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 2.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/noaction_3d.i)
# 3D test with just mixed stress strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = NINTH
  []
[]
[AuxVariables]
  [pk1_stress_xx]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_yx]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_zx]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_xy]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_yy]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_zy]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_xz]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_yz]
    family = MONOMIAL
    order = CONSTANT
  []
  [pk1_stress_zz]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_xx]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_yx]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_zx]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_xy]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_yy]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_zy]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_xz]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_yz]
    family = MONOMIAL
    order = CONSTANT
  []
  [deformation_gradient_zz]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [pk1_stress_xx]
    type = RankTwoAux
    variable = pk1_stress_xx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [pk1_stress_yx]
    type = RankTwoAux
    variable = pk1_stress_yx
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [pk1_stress_zx]
    type = RankTwoAux
    variable = pk1_stress_zx
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [pk1_stress_xy]
    type = RankTwoAux
    variable = pk1_stress_xy
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [pk1_stress_yy]
    type = RankTwoAux
    variable = pk1_stress_yy
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [pk1_stress_zy]
    type = RankTwoAux
    variable = pk1_stress_zy
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [pk1_stress_xz]
    type = RankTwoAux
    variable = pk1_stress_xz
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [pk1_stress_yz]
    type = RankTwoAux
    variable = pk1_stress_yz
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [pk1_stress_zz]
    type = RankTwoAux
    variable = pk1_stress_zz
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [deformation_gradient_xx]
    type = RankTwoAux
    variable = deformation_gradient_xx
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [deformation_gradient_yx]
    type = RankTwoAux
    variable = deformation_gradient_yx
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [deformation_gradient_zx]
    type = RankTwoAux
    variable = deformation_gradient_zx
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [deformation_gradient_xy]
    type = RankTwoAux
    variable = deformation_gradient_xy
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [deformation_gradient_yy]
    type = RankTwoAux
    variable = deformation_gradient_yy
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [deformation_gradient_zy]
    type = RankTwoAux
    variable = deformation_gradient_zy
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [deformation_gradient_xz]
    type = RankTwoAux
    variable = deformation_gradient_xz
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [deformation_gradient_yz]
    type = RankTwoAux
    variable = deformation_gradient_yz
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [deformation_gradient_zz]
    type = RankTwoAux
    variable = deformation_gradient_zz
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    constraint_types = 'stress strain strain strain stress strain strain strain strain'
    targets = 'stress11 strain21 strain31 strain12 stress22 strain32 strain13 strain23 strain33'
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    constraint_types = 'stress strain strain strain stress strain strain strain strain'
    targets = 'stress11 strain21 strain31 strain12 stress22 strain32 strain13 strain23 strain33'
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    constraint_types = 'stress strain strain strain stress strain strain strain strain'
    targets = 'stress11 strain21 strain31 strain12 stress22 strain32 strain13 strain23 strain33'
    scalar_variable = hvar
  []
[]
[Functions]
  [stress11]
    type = ParsedFunction
    expression = '120.0*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '65*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain32]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain31]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain21]
    type = ParsedFunction
    expression = '-1.5e-2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
    macro_gradient = hvar
    constraint_types = 'stress strain strain strain stress strain strain strain strain'
    targets = 'stress11 strain21 strain31 strain12 stress22 strain32 strain13 strain23 strain33'
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 20
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  file_base = 3d
  exodus = true
[]
(modules/solid_mechanics/test/tests/eigen_decomp_material/pipe_2d.i)
# pipe with outer diameter = 24", wall thickness 0.979"
# units in MPa, meters
[GlobalParams]
  order = SECOND
  family = LAGRANGE
  displacements = 'disp_x disp_y'
[]
[Mesh]
  coord_type = RZ
  [pipe]
    type = GeneratedMeshGenerator
    dim = 2
    xmin = 0.2799334 #12"-0.979"
    xmax = .3048 #12"
    ymin = 0
    ymax = 0.00497 #0.979"/5
    nx = 5
    ny = 1
    elem_type = quad9
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
      []
    []
  []
[]
[Functions]
  [inner_pressure]
    type = ConstantFunction
    value = 3
  []
  [big_pipe]
    type = ParsedFunction
    expression = -(p*11.021*11.021)/(12*12-11.021*11.021)
    symbol_names = 'p'
    symbol_values = 3
  []
[]
[BCs]
  [fixBottom]
    type = DirichletBC
    variable = disp_y
    boundary = bottom
    value = 0.0
    preset = true
  []
  [Pressure]
    [inside]
      boundary = left
      function = inner_pressure
    []
    [axial]
      boundary = top
      function = big_pipe
    []
  []
[]
[Constraints]
  [top]
    type = EqualValueBoundaryConstraint
    variable = disp_y
    secondary = top
    penalty = 1e+14
    formulation = penalty
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 168000
    poissons_ratio = 0.31
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [nonADeig_decomp]
    type = EigenDecompositionMaterial
    rank_two_tensor = cauchy_stress
    outputs = exodus
    output_properties = "max_eigen_vector mid_eigen_vector min_eigen_vector "
                        "max_eigen_valuemid_eigen_value min_eigen_value"
  []
[]
[Executioner]
  type = Steady
  solve_type = 'NEWTON'
  petsc_options_iname = '-pc_type -pc_factor_mat_solver_package'
  petsc_options_value = 'lu       superlu_dist'
  nl_rel_tol = 5e-8
  line_search = NONE
[]
[Postprocessors]
  [eigval_max]
    type = ElementAverageMaterialProperty
    mat_prop = max_eigen_value
  []
[]
[Outputs]
  exodus = on
  console = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/2D/neumann.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.01
    max = 0.01
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.01
    max = 0.01
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '50000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-30000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/patch/large_patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
               '
             '   0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    large_kinematics = true
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    large_kinematics = true
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    large_kinematics = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    large_kinematics = true
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/1D/dirichlet.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 5.0
  dtmin = 5.0
  end_time = 5.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/L/large.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/cohesive_zone_model/ad_czm.i)
[Mesh]
  [msh]
    type = FileMeshGenerator
    file = patch_mesh.e
  []
  [split]
    type = BreakMeshByBlockGenerator
    input = msh
  []
  [add_surfaces]
    type = SideSetsFromNormalsGenerator
    input = split
    normals = '0  0  1
               0  1  0
               1  0  0
               0  0 -1
               0 -1  0
              -1  0  0'
    fixed_normal = true
    new_boundary = 'z1 y1 x1 z0 y0 x0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        add_variables = true
        new_system = true
      []
    []
    [CohesiveZone]
      [interface]
        boundary = 'interface'
        strain = SMALL
        use_automatic_differentiation = true
      []
    []
  []
[]
[Functions]
  [stretch]
    type = PiecewiseLinear
    x = '0 0.05'
    y = '0 0.1'
  []
[]
[Constraints]
  [x1]
    type = EqualValueBoundaryConstraint
    variable = disp_x
    secondary = 'x1' # boundary
    penalty = 1e6
  []
  [y1]
    type = EqualValueBoundaryConstraint
    variable = disp_y
    secondary = 'y1' # boundary
    penalty = 1e6
  []
[]
[BCs]
  [fix_x]
    type = DirichletBC
    value = 0.0
    boundary = 'x0'
    variable = disp_x
  []
  [fix_y]
    type = DirichletBC
    value = 0.0
    boundary = 'y0'
    variable = disp_y
  []
  [fix_z]
    type = DirichletBC
    value = 0.0
    boundary = 'z0'
    variable = disp_z
  []
  [back_z]
    type = FunctionDirichletBC
    boundary = 'z1'
    variable = disp_z
    use_displaced_mesh = true
    function = stretch
    preset = false
  []
  [rotate_x]
    type = DisplacementAboutAxis
    boundary = 'x0 y0 z0 x1 y1 z1'
    function = '90.'
    angle_units = degrees
    axis_origin = '0. 0. 0.'
    axis_direction = '0. 1. 0.'
    component = 0
    variable = disp_x
    angular_velocity = true
    preset = false
  []
  [rotate_y]
    type = DisplacementAboutAxis
    boundary = 'x0 y0 z0 x1 y1 z1'
    function = '90.'
    angle_units = degrees
    axis_origin = '0. 0. 0.'
    axis_direction = '0. 1. 0.'
    component = 1
    variable = disp_y
    angular_velocity = true
    preset = false
  []
  [rotate_z]
    type = DisplacementAboutAxis
    boundary = 'x0 y0 z0 x1 y1 z1'
    function = '90.'
    angle_units = degrees
    axis_origin = '0. 0. 0.'
    axis_direction = '0. 1. 0.'
    component = 2
    variable = disp_z
    angular_velocity = true
    preset = false
  []
[]
[Controls]
  [c1]
    type = TimePeriod
    enable_objects = 'BCs::fix_x BCs::fix_y BCs::fix_z BCs::back_z Constraints::x1 Constraints::y1'
    disable_objects = 'BCs::rotate_x BCs::rotate_y BCs::rotate_z'
    start_time = '0'
    end_time = '0.051'
    execute_on = 'initial timestep_begin'
  []
[]
[Materials]
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [elasticity_tensor]
    type = ComputeElasticityTensor
    fill_method = symmetric9
    C_ijkl = '1.684e5 0.176e5 0.176e5 1.684e5 0.176e5 1.684e5 0.754e5 0.754e5 0.754e5'
  []
  [czm_mat]
    type = ADPureElasticTractionSeparation
    normal_stiffness = 1e4
    tangent_stiffness = 7e3
    boundary = 'interface'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  automatic_scaling = true
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_rel_tol = 1e-15
  nl_abs_tol = 1e-15
  start_time = 0.0
  dt = 0.025
  end_time = 0.075
[]
[Outputs]
  exodus = true
  print_linear_residuals = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/1D/neumann.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '200 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionNeumannBC
    boundary = left
    variable = disp_x
    function = pull
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/no_action_1D.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [stress_base]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/1D/neumann.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '200 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionNeumannBC
    boundary = left
    variable = disp_x
    function = pull
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 5.0
  dtmin = 5.0
  end_time = 5.0
[]
(modules/solid_mechanics/examples/wave_propagation/cantilever_sweep.i)
# Frequency Response function for cantilever beam:
# Analytic results: 509Hz and 763Hz
# Simulation results with coarse mesh: 600Hz and 800Hz
[Mesh]
   type = GeneratedMesh
   elem_type = HEX8
   dim = 3
   xmin=0
   xmax=1
   nx=10
   ymin=0
   ymax=0.1
   ny = 1
   zmin=0
   zmax=0.15
   nz = 2
[]
[GlobalParams]
  order = FIRST
  family = LAGRANGE
  displacements = 'disp_x disp_y disp_z'
[]
[Problem]
 type = ReferenceResidualProblem
 reference_vector = 'ref'
 extra_tag_vectors = 'ref'
 group_variables = 'disp_x disp_y disp_z'
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        add_variables = true
        new_system = true
        formulation = TOTAL
      []
    []
  []
[]
[Kernels]
    #reaction terms
    [reaction_realx]
        type = Reaction
        variable = disp_x
        rate = 0# filled by controller
        extra_vector_tags = 'ref'
    []
    [reaction_realy]
        type = Reaction
        variable = disp_y
        rate = 0# filled by controller
        extra_vector_tags = 'ref'
    []
    [reaction_realz]
        type = Reaction
        variable = disp_z
        rate = 0# filled by controller
        extra_vector_tags = 'ref'
    []
[]
[AuxVariables]
  [disp_mag]
  []
[]
[AuxKernels]
  [disp_mag]
    type = ParsedAux
    variable = disp_mag
    coupled_variables = 'disp_x disp_y disp_z'
    expression = 'sqrt(disp_x^2+disp_y^2+disp_z^2)'
  []
[]
[BCs]
#Left
[disp_x_left]
  type = DirichletBC
  variable = disp_x
  boundary = 'left'
  value = 0.0
[]
[disp_y_left]
  type = DirichletBC
  variable = disp_y
  boundary = 'left'
  value = 0.0
[]
[disp_z_left]
  type = DirichletBC
  variable = disp_z
  boundary = 'left'
  value = 0.0
[]
#Right
[BC_right_yreal]
    type = NeumannBC
    variable = disp_y
    boundary = 'right'
    value = 1000
[]
[BC_right_zreal]
    type = NeumannBC
    variable = disp_z
    boundary = 'right'
    value = 1000
[]
[]
[Materials]
  [elastic_tensor_Al]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 68e9
    poissons_ratio = 0.36
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Postprocessors]
  [dispMag]
    type = NodalExtremeValue
    value_type = max
    variable = disp_mag
  []
[]
[Functions]
  [./freq2]
    type = ParsedFunction
    symbol_names = density
    symbol_values = 2.7e3 #Al kg/m3
    expression = '-t*t*density'
  [../]
[]
[Controls]
  [./func_control]
    type = RealFunctionControl
    parameter = 'Kernels/*/rate'
    function = 'freq2'
    execute_on = 'initial timestep_begin'
  [../]
[]
[Executioner]
  type = Transient
  solve_type=LINEAR
  petsc_options_iname = ' -pc_type'
  petsc_options_value = 'lu'
  start_time = 300  #starting frequency
  end_time =  1200  #ending frequency
  nl_abs_tol = 1e-6
  [TimeStepper]
    type = ConstantDT
    dt = 50  #frequency stepsize
  []
[]
[Outputs]
  csv=true
  exodus=false
  console = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/3D/dirichlet.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.02
    max = 0.02
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.02
    max = 0.02
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.02
    max = 0.02
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.4 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.2 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
  [pull_z]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_z
    function = pullz
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/analytical/small.i)
# This test aims to verify the implementation by comparing the numerical solution
# to the analytical solution. The Lame solution for a hollow cylinder is used in
# this test. Given inner pressure p = 100, outer pressure q = 200, inner radius
# a = 2, outer radius b = 4, the stress and displacements at the middle of the cylinder
# (r = 3, z = 0) should be
# sigma_rr = -174.074
# sigma_tt = -292.593
# u_r = -0.65972
# The numerical approximation yields
# sigma_rr = -172.051
# sigma_tt = -294.613
# u_r = -0.65964
[GlobalParams]
  displacements = 'disp_r disp_z'
  large_kinematics = false
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    xmin = 2
    xmax = 4
    ymin = 0
    ymax = 10
    nx = 20
    ny = 100
  []
  coord_type = RZ
[]
[Variables]
  [disp_r]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_r
    component = 0
  []
  [sdz]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_z
    component = 1
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    variable = disp_z
    boundary = 'top bottom'
    value = 0.0
    preset = false
  []
  [inner]
    type = NeumannBC
    variable = disp_r
    boundary = left
    value = 100
  []
  [outer]
    type = NeumannBC
    variable = disp_r
    boundary = right
    value = -200
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    output_properties = 'cauchy_stress'
    outputs = 'exodus'
  []
  [compute_strain]
    type = ComputeLagrangianStrainAxisymmetricCylindrical
  []
[]
[Postprocessors]
  [u_r]
    type = PointValue
    variable = disp_r
    point = '3 0 0'
  []
  [sigma_rr]
    type = PointValue
    variable = cauchy_stress_00
    point = '3 0 0'
  []
  [sigma_tt]
    type = PointValue
    variable = cauchy_stress_22
    point = '3 0 0'
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  num_steps = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/patch/large.i)
[GlobalParams]
  displacements = 'disp_r disp_z'
  large_kinematics = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 2
    ny = 2
  []
  coord_type = RZ
[]
[Variables]
  [disp_r]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_r
    component = 0
  []
  [sdz]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_z
    component = 1
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    preset = false
    variable = disp_z
    boundary = bottom
    value = 0.0
  []
  [top]
    type = FunctionDirichletBC
    preset = false
    variable = disp_z
    boundary = top
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    output_properties = 'pk1_stress'
    outputs = 'exodus'
  []
  [compute_strain]
    type = ComputeLagrangianStrainAxisymmetricCylindrical
    output_properties = 'mechanical_strain'
    outputs = 'exodus'
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 10
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/small-tests/3d.i)
# 2D test with just strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = SIXTH
  []
[]
[AuxVariables]
  [sxx]
    family = MONOMIAL
    order = CONSTANT
  []
  [syy]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxy]
    family = MONOMIAL
    order = CONSTANT
  []
  [szz]
    family = MONOMIAL
    order = CONSTANT
  []
  [syz]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exx]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyy]
    family = MONOMIAL
    order = CONSTANT
  []
  [exy]
    family = MONOMIAL
    order = CONSTANT
  []
  [ezz]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exz]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [sxx]
    type = RankTwoAux
    variable = sxx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [syy]
    type = RankTwoAux
    variable = syy
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [sxy]
    type = RankTwoAux
    variable = sxy
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [zz]
    type = RankTwoAux
    variable = szz
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [syz]
    type = RankTwoAux
    variable = syz
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [sxz]
    type = RankTwoAux
    variable = sxz
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [exx]
    type = RankTwoAux
    variable = exx
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 0
  []
  [eyy]
    type = RankTwoAux
    variable = eyy
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 1
  []
  [exy]
    type = RankTwoAux
    variable = exy
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 1
  []
  [ezz]
    type = RankTwoAux
    variable = ezz
    rank_two_tensor = mechanical_strain
    index_i = 2
    index_j = 2
  []
  [eyz]
    type = RankTwoAux
    variable = eyz
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 2
  []
  [exz]
    type = RankTwoAux
    variable = exz
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '4.0e-2*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-2.0e-2*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [stress11]
    type = ParsedFunction
    expression = '4.0e2*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-2.0e2*t'
  []
  [stress33]
    type = ParsedFunction
    expression = '8.0e2*t'
  []
  [stress23]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress13]
    type = ParsedFunction
    expression = '-7.0e2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = sxx
    execute_on = 'initial timestep_end'
  []
  [syy]
    type = ElementAverageValue
    variable = syy
    execute_on = 'initial timestep_end'
  []
  [sxy]
    type = ElementAverageValue
    variable = sxy
    execute_on = 'initial timestep_end'
  []
  [szz]
    type = ElementAverageValue
    variable = szz
    execute_on = 'initial timestep_end'
  []
  [syz]
    type = ElementAverageValue
    variable = syz
    execute_on = 'initial timestep_end'
  []
  [sxz]
    type = ElementAverageValue
    variable = sxz
    execute_on = 'initial timestep_end'
  []
  [exx]
    type = ElementAverageValue
    variable = exx
    execute_on = 'initial timestep_end'
  []
  [eyy]
    type = ElementAverageValue
    variable = eyy
    execute_on = 'initial timestep_end'
  []
  [exy]
    type = ElementAverageValue
    variable = exy
    execute_on = 'initial timestep_end'
  []
  [ezz]
    type = ElementAverageValue
    variable = ezz
    execute_on = 'initial timestep_end'
  []
  [eyz]
    type = ElementAverageValue
    variable = eyz
    execute_on = 'initial timestep_end'
  []
  [exz]
    type = ElementAverageValue
    variable = exz
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/2D/dirichlet.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.5 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/3D/dirichlet.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.4 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.2 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
  [pull_z]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_z
    function = pullz
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence-auto/3D/dirichlet.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.02
    max = 0.02
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.02
    max = 0.02
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.02
    max = 0.02
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.4 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.2 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
  [pull_z]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_z
    function = pullz
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/1D/dirichlet.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
                  0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  base_name = 'whatever'
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = whatever_cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = whatever_mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    elasticity_tensor = elasticity_tensor
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/ld-stress.i)
# 2D test with just strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  constraint_types = 'stress strain strain stress stress strain stress stress stress'
  macro_gradient = hvar
  targets = 'stress11 zero zero stress12 stress22 zero stress13 stress23 stress33'
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = NINTH
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.1
    max = 0.1
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.1
    max = 0.1
  []
  [hvar]
    type = ScalarConstantIC
    variable = hvar
    value = 0.1
  []
[]
[AuxVariables]
  [s11]
    family = MONOMIAL
    order = CONSTANT
  []
  [s21]
    family = MONOMIAL
    order = CONSTANT
  []
  [s31]
    family = MONOMIAL
    order = CONSTANT
  []
  [s12]
    family = MONOMIAL
    order = CONSTANT
  []
  [s22]
    family = MONOMIAL
    order = CONSTANT
  []
  [s32]
    family = MONOMIAL
    order = CONSTANT
  []
  [s13]
    family = MONOMIAL
    order = CONSTANT
  []
  [s23]
    family = MONOMIAL
    order = CONSTANT
  []
  [s33]
    family = MONOMIAL
    order = CONSTANT
  []
  [F11]
    family = MONOMIAL
    order = CONSTANT
  []
  [F21]
    family = MONOMIAL
    order = CONSTANT
  []
  [F31]
    family = MONOMIAL
    order = CONSTANT
  []
  [F12]
    family = MONOMIAL
    order = CONSTANT
  []
  [F22]
    family = MONOMIAL
    order = CONSTANT
  []
  [F32]
    family = MONOMIAL
    order = CONSTANT
  []
  [F13]
    family = MONOMIAL
    order = CONSTANT
  []
  [F23]
    family = MONOMIAL
    order = CONSTANT
  []
  [F33]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [s11]
    type = RankTwoAux
    variable = s11
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [s21]
    type = RankTwoAux
    variable = s21
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [s31]
    type = RankTwoAux
    variable = s31
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [s12]
    type = RankTwoAux
    variable = s12
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [s22]
    type = RankTwoAux
    variable = s22
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [s32]
    type = RankTwoAux
    variable = s32
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [s13]
    type = RankTwoAux
    variable = s13
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [s23]
    type = RankTwoAux
    variable = s23
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [s33]
    type = RankTwoAux
    variable = s33
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [F11]
    type = RankTwoAux
    variable = F11
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [F21]
    type = RankTwoAux
    variable = F21
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [F31]
    type = RankTwoAux
    variable = F31
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [F12]
    type = RankTwoAux
    variable = F12
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [F22]
    type = RankTwoAux
    variable = F22
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [F32]
    type = RankTwoAux
    variable = F32
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [F13]
    type = RankTwoAux
    variable = F13
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [F23]
    type = RankTwoAux
    variable = F23
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [F33]
    type = RankTwoAux
    variable = F33
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [stress11]
    type = ParsedFunction
    expression = '4.0e2*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-2.0e2*t'
  []
  [stress33]
    type = ParsedFunction
    expression = '8.0e2*t'
  []
  [stress23]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress13]
    type = ParsedFunction
    expression = '-7.0e2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress32]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress31]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress21]
    type = ParsedFunction
    expression = '-1.5e2*t'
  []
  [zero]
    type = ConstantFunction
    value = 0
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [s11]
    type = ElementAverageValue
    variable = s11
    execute_on = 'initial timestep_end'
  []
  [s21]
    type = ElementAverageValue
    variable = s21
    execute_on = 'initial timestep_end'
  []
  [s31]
    type = ElementAverageValue
    variable = s31
    execute_on = 'initial timestep_end'
  []
  [s12]
    type = ElementAverageValue
    variable = s12
    execute_on = 'initial timestep_end'
  []
  [s22]
    type = ElementAverageValue
    variable = s22
    execute_on = 'initial timestep_end'
  []
  [s32]
    type = ElementAverageValue
    variable = s32
    execute_on = 'initial timestep_end'
  []
  [s13]
    type = ElementAverageValue
    variable = s13
    execute_on = 'initial timestep_end'
  []
  [s23]
    type = ElementAverageValue
    variable = s23
    execute_on = 'initial timestep_end'
  []
  [s33]
    type = ElementAverageValue
    variable = s33
    execute_on = 'initial timestep_end'
  []
  [F11]
    type = ElementAverageValue
    variable = F11
    execute_on = 'initial timestep_end'
  []
  [F21]
    type = ElementAverageValue
    variable = F21
    execute_on = 'initial timestep_end'
  []
  [F31]
    type = ElementAverageValue
    variable = F31
    execute_on = 'initial timestep_end'
  []
  [F12]
    type = ElementAverageValue
    variable = F12
    execute_on = 'initial timestep_end'
  []
  [F22]
    type = ElementAverageValue
    variable = F22
    execute_on = 'initial timestep_end'
  []
  [F32]
    type = ElementAverageValue
    variable = F32
    execute_on = 'initial timestep_end'
  []
  [F13]
    type = ElementAverageValue
    variable = F13
    execute_on = 'initial timestep_end'
  []
  [F23]
    type = ElementAverageValue
    variable = F23
    execute_on = 'initial timestep_end'
  []
  [F33]
    type = ElementAverageValue
    variable = F33
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
[Outputs]
  exodus = false
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/action_1D.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = UPDATED
        volumetric_locking_correction = false
      []
    []
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [stress_base]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/2D/dirichlet.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.5 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/L/large.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/objective_shear.i)
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[Functions]
  [shearme]
    type = PiecewiseLinear
    x = '0 1'
    y = '0 2'
  []
[]
[BCs]
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [bottom_y]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [bottom_x]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = bottom
    value = 0.0
  []
  [shear]
    type = FunctionDirichletBC
    variable = disp_x
    boundary = top
    function = shearme
    preset = true
  []
  [hmm]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = top
    value = 0.0
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/rates/shear.i)
# shear modulus
G = 5000
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
    [AuxKernel]
      type = RankTwoAux
      rank_two_tensor = cauchy_stress
      index_i = 0
      index_j = 0
      execute_on = 'INITIAL TIMESTEP_END'
    []
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
    [AuxKernel]
      type = RankTwoAux
      rank_two_tensor = cauchy_stress
      index_i = 1
      index_j = 1
      execute_on = 'INITIAL TIMESTEP_END'
    []
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
    [AuxKernel]
      type = RankTwoAux
      rank_two_tensor = cauchy_stress
      index_i = 0
      index_j = 1
      execute_on = 'INITIAL TIMESTEP_END'
    []
  []
[]
[BCs]
  [x]
    type = FunctionDirichletBC
    variable = disp_x
    boundary = 'top bottom' # This contains all 8 nodes in the patch
    function = 't*y'
  []
  [y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'top bottom' # This contains all 8 nodes in the patch
    function = '0'
  []
  [z]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = 'top bottom' # This contains all 8 nodes in the patch
    function = '0'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    lambda = ${G}
    shear_modulus = ${G}
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = stress_xx
    execute_on = 'INITIAL TIMESTEP_BEGIN'
    outputs = none
  []
  [sxx0]
    type = ParsedPostprocessor
    pp_names = 'sxx'
    expression = 'sxx/${G}'
    execute_on = 'INITIAL TIMESTEP_BEGIN'
  []
  [syy]
    type = ElementAverageValue
    variable = stress_yy
    execute_on = 'INITIAL TIMESTEP_BEGIN'
    outputs = none
  []
  [syy0]
    type = ParsedPostprocessor
    pp_names = 'syy'
    expression = 'syy/${G}'
    execute_on = 'INITIAL TIMESTEP_BEGIN'
  []
  [sxy]
    type = ElementAverageValue
    variable = stress_xy
    execute_on = 'INITIAL TIMESTEP_BEGIN'
    outputs = none
  []
  [sxy0]
    type = ParsedPostprocessor
    pp_names = 'sxy'
    expression = 'sxy/${G}'
    execute_on = 'INITIAL TIMESTEP_BEGIN'
  []
[]
[Executioner]
  type = Transient
  dt = 0.05
  solve_type = NEWTON
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 20
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/L/small.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/thermal_expansion/free.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 2
  ny = 2
  nz = 2
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  eigenstrain_names = "thermal_contribution"
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[AuxVariables]
  [temperature]
  []
[]
[AuxKernels]
  [control_temperature]
    type = FunctionAux
    variable = temperature
    function = temperature_control
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
[]
[Functions]
  [temperature_control]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        new_system = true
        formulation = UPDATED
        volumetric_locking_correction = false
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz strain_xx strain_yy strain_zz strain_xy '
                          'strain_xz strain_yz'
      []
    []
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  solve_type = NEWTON
  end_time = 1
  dt = 1
  type = Transient
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/weak_plane_stress/convergence.i)
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 2
    ny = 2
  []
  use_displaced_mesh = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [strain_zz]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    out_of_plane_strain = strain_zz
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    out_of_plane_strain = strain_zz
    component = 1
  []
  [wps]
    type = TotalLagrangianWeakPlaneStress
    variable = strain_zz
  []
[]
[BCs]
  [fix_x]
    type = DirichletBC
    variable = disp_x
    boundary = 'top bottom'
    value = 0
  []
  [fix_y]
    type = DirichletBC
    variable = disp_y
    boundary = 'bottom'
    value = 0
  []
  [disp_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'top'
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [strain]
    type = ComputeLagrangianWPSStrain
    out_of_plane_strain = strain_zz
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  end_time = 0.1
  solve_type = 'newton'
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/patch/small_patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
               '
             '   0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = pk1_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/action/action_3d.i)
# 3D mixed test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
        constraint_types = 'stress strain strain strain stress strain strain strain strain'
        targets = 'stress11 strain21 strain31 strain12 stress22 strain32 strain13 strain23 strain33'
        generate_output = 'pk1_stress_xx pk1_stress_xy pk1_stress_xz pk1_stress_yx pk1_stress_yy '
                          'pk1_stress_yz pk1_stress_zx pk1_stress_zy pk1_stress_zz '
                          'deformation_gradient_xx deformation_gradient_xy deformation_gradient_xz '
                          'deformation_gradient_yx deformation_gradient_yy deformation_gradient_yz '
                          'deformation_gradient_zx deformation_gradient_zy deformation_gradient_zz'
      []
    []
  []
[]
[Functions]
  [stress11]
    type = ParsedFunction
    expression = '120.0*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '65*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain32]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain31]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain21]
    type = ParsedFunction
    expression = '-1.5e-2*t'
  []
  [zero]
    type = ConstantFunction
    value = 0
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 20
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  [out]
    type = Exodus
    file_base = '3d'
  []
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/thermal_expansion/free.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 2
  ny = 2
  nz = 2
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  eigenstrain_names = "thermal_contribution"
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[AuxVariables]
  [temperature]
  []
[]
[AuxKernels]
  [control_temperature]
    type = FunctionAux
    variable = temperature
    function = temperature_control
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
[]
[Functions]
  [temperature_control]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz strain_xx strain_yy strain_zz strain_xy '
                          'strain_xz strain_yz'
      []
    []
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  solve_type = NEWTON
  end_time = 1
  dt = 1
  type = Transient
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/large-tests/1d.i)
# 1D strain controlled test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '1d.exo'
  []
  [ss]
    type = SideSetsFromPointsGenerator
    input = base
    points = '-1 0 0
               7 0 0'
    new_boundary = 'left right'
  []
[]
[Variables]
  [disp_x]
  []
  [hvar]
    family = SCALAR
    order = FIRST
  []
[]
[AuxVariables]
  [s11]
    family = MONOMIAL
    order = CONSTANT
  []
  [s21]
    family = MONOMIAL
    order = CONSTANT
  []
  [s31]
    family = MONOMIAL
    order = CONSTANT
  []
  [s12]
    family = MONOMIAL
    order = CONSTANT
  []
  [s22]
    family = MONOMIAL
    order = CONSTANT
  []
  [s32]
    family = MONOMIAL
    order = CONSTANT
  []
  [s13]
    family = MONOMIAL
    order = CONSTANT
  []
  [s23]
    family = MONOMIAL
    order = CONSTANT
  []
  [s33]
    family = MONOMIAL
    order = CONSTANT
  []
  [F11]
    family = MONOMIAL
    order = CONSTANT
  []
  [F21]
    family = MONOMIAL
    order = CONSTANT
  []
  [F31]
    family = MONOMIAL
    order = CONSTANT
  []
  [F12]
    family = MONOMIAL
    order = CONSTANT
  []
  [F22]
    family = MONOMIAL
    order = CONSTANT
  []
  [F32]
    family = MONOMIAL
    order = CONSTANT
  []
  [F13]
    family = MONOMIAL
    order = CONSTANT
  []
  [F23]
    family = MONOMIAL
    order = CONSTANT
  []
  [F33]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [s11]
    type = RankTwoAux
    variable = s11
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [s21]
    type = RankTwoAux
    variable = s21
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [s31]
    type = RankTwoAux
    variable = s31
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [s12]
    type = RankTwoAux
    variable = s12
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [s22]
    type = RankTwoAux
    variable = s22
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [s32]
    type = RankTwoAux
    variable = s32
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [s13]
    type = RankTwoAux
    variable = s13
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [s23]
    type = RankTwoAux
    variable = s23
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [s33]
    type = RankTwoAux
    variable = s33
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [F11]
    type = RankTwoAux
    variable = F11
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [F21]
    type = RankTwoAux
    variable = F21
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [F31]
    type = RankTwoAux
    variable = F31
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [F12]
    type = RankTwoAux
    variable = F12
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [F22]
    type = RankTwoAux
    variable = F22
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [F32]
    type = RankTwoAux
    variable = F32
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [F13]
    type = RankTwoAux
    variable = F13
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [F23]
    type = RankTwoAux
    variable = F23
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [F33]
    type = RankTwoAux
    variable = F33
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
[]
[Functions]
  [func_stress]
    type = ParsedFunction
    expression = '400*t'
  []
  [func_strain]
    type = ParsedFunction
    expression = '4.0e-1*t'
  []
[]
[BCs]
  [Periodic]
    [all]
      variable = disp_x
      auto_direction = 'x'
    []
  []
  [centerfix_x]
    type = DirichletBC
    boundary = "fixme"
    variable = disp_x
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [s11]
    type = ElementAverageValue
    variable = s11
    execute_on = 'initial timestep_end'
  []
  [s21]
    type = ElementAverageValue
    variable = s21
    execute_on = 'initial timestep_end'
  []
  [s31]
    type = ElementAverageValue
    variable = s31
    execute_on = 'initial timestep_end'
  []
  [s12]
    type = ElementAverageValue
    variable = s12
    execute_on = 'initial timestep_end'
  []
  [s22]
    type = ElementAverageValue
    variable = s22
    execute_on = 'initial timestep_end'
  []
  [s32]
    type = ElementAverageValue
    variable = s32
    execute_on = 'initial timestep_end'
  []
  [s13]
    type = ElementAverageValue
    variable = s13
    execute_on = 'initial timestep_end'
  []
  [s23]
    type = ElementAverageValue
    variable = s23
    execute_on = 'initial timestep_end'
  []
  [s33]
    type = ElementAverageValue
    variable = s33
    execute_on = 'initial timestep_end'
  []
  [F11]
    type = ElementAverageValue
    variable = F11
    execute_on = 'initial timestep_end'
  []
  [F21]
    type = ElementAverageValue
    variable = F21
    execute_on = 'initial timestep_end'
  []
  [F31]
    type = ElementAverageValue
    variable = F31
    execute_on = 'initial timestep_end'
  []
  [F12]
    type = ElementAverageValue
    variable = F12
    execute_on = 'initial timestep_end'
  []
  [F22]
    type = ElementAverageValue
    variable = F22
    execute_on = 'initial timestep_end'
  []
  [F32]
    type = ElementAverageValue
    variable = F32
    execute_on = 'initial timestep_end'
  []
  [F13]
    type = ElementAverageValue
    variable = F13
    execute_on = 'initial timestep_end'
  []
  [F23]
    type = ElementAverageValue
    variable = F23
    execute_on = 'initial timestep_end'
  []
  [F33]
    type = ElementAverageValue
    variable = F33
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = default
  automatic_scaling = true
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-6
  nl_abs_tol = 1e-8
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/objective_shear.i)
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[Functions]
  [shearme]
    type = PiecewiseLinear
    x = '0 1'
    y = '0 2'
  []
[]
[BCs]
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [bottom_y]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [bottom_x]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = bottom
    value = 0.0
  []
  [shear]
    type = FunctionDirichletBC
    variable = disp_x
    boundary = top
    function = shearme
    preset = true
  []
  [hmm]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = top
    value = 0.0
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/action/simple_test.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
      order = second
  []
  [disp_y]
      order = second
  []
  [disp_z]
      order = second
  []
[]
[Mesh]
  type = FileMesh
  file = 'second.exo'
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz mechanical_strain_xx mechanical_strain_yy mechanical_strain_zz mechanical_strain_xy '
                          'mechanical_strain_xz mechanical_strain_yz'
      []
    []
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1
  end_time = 1
[]
[Outputs]
  exodus = false
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/2D/neumann.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.01
    max = 0.01
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.01
    max = 0.01
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '50000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-30000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/convergence/sd-strain.i)
# 2D test with just strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
  constraint_types = 'strain none none strain strain none strain strain strain'
  targets = 'strain11 strain12 strain22 strain13 strain23 strain33'
  macro_gradient = hvar
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = SIXTH
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.1
    max = 0.1
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.1
    max = 0.1
  []
  [hvar]
    type = ScalarConstantIC
    variable = hvar
    value = 0.1
  []
[]
[AuxVariables]
  [sxx]
    family = MONOMIAL
    order = CONSTANT
  []
  [syy]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxy]
    family = MONOMIAL
    order = CONSTANT
  []
  [szz]
    family = MONOMIAL
    order = CONSTANT
  []
  [syz]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exx]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyy]
    family = MONOMIAL
    order = CONSTANT
  []
  [exy]
    family = MONOMIAL
    order = CONSTANT
  []
  [ezz]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exz]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [sxx]
    type = RankTwoAux
    variable = sxx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [syy]
    type = RankTwoAux
    variable = syy
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [sxy]
    type = RankTwoAux
    variable = sxy
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [zz]
    type = RankTwoAux
    variable = szz
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [syz]
    type = RankTwoAux
    variable = syz
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [sxz]
    type = RankTwoAux
    variable = sxz
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [exx]
    type = RankTwoAux
    variable = exx
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 0
  []
  [eyy]
    type = RankTwoAux
    variable = eyy
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 1
  []
  [exy]
    type = RankTwoAux
    variable = exy
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 1
  []
  [ezz]
    type = RankTwoAux
    variable = ezz
    rank_two_tensor = mechanical_strain
    index_i = 2
    index_j = 2
  []
  [eyz]
    type = RankTwoAux
    variable = eyz
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 2
  []
  [exz]
    type = RankTwoAux
    variable = exz
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '4.0e-2*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-2.0e-2*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = sxx
    execute_on = 'initial timestep_end'
  []
  [syy]
    type = ElementAverageValue
    variable = syy
    execute_on = 'initial timestep_end'
  []
  [sxy]
    type = ElementAverageValue
    variable = sxy
    execute_on = 'initial timestep_end'
  []
  [szz]
    type = ElementAverageValue
    variable = szz
    execute_on = 'initial timestep_end'
  []
  [syz]
    type = ElementAverageValue
    variable = syz
    execute_on = 'initial timestep_end'
  []
  [sxz]
    type = ElementAverageValue
    variable = sxz
    execute_on = 'initial timestep_end'
  []
  [exx]
    type = ElementAverageValue
    variable = exx
    execute_on = 'initial timestep_end'
  []
  [eyy]
    type = ElementAverageValue
    variable = eyy
    execute_on = 'initial timestep_end'
  []
  [exy]
    type = ElementAverageValue
    variable = exy
    execute_on = 'initial timestep_end'
  []
  [ezz]
    type = ElementAverageValue
    variable = ezz
    execute_on = 'initial timestep_end'
  []
  [eyz]
    type = ElementAverageValue
    variable = eyz
    execute_on = 'initial timestep_end'
  []
  [exz]
    type = ElementAverageValue
    variable = exz
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  #automatic_scaling = true
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
[Outputs]
  exodus = false
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/weak_plane_stress/pull_2D.i)
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 1
    ny = 1
  []
  use_displaced_mesh = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [strain_zz]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    out_of_plane_strain = strain_zz
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    out_of_plane_strain = strain_zz
    component = 1
    save_in = 'ry'
  []
  [wps]
    type = TotalLagrangianWeakPlaneStress
    variable = strain_zz
  []
[]
[AuxVariables]
  [ry]
  []
[]
[BCs]
  [left_x]
    type = DirichletBC
    variable = disp_x
    boundary = left
    value = 0
  []
  [bottom_y]
    type = DirichletBC
    variable = disp_y
    boundary = bottom
    value = 0
  []
  [disp_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = top
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [strain]
    type = ComputeLagrangianWPSStrain
    out_of_plane_strain = strain_zz
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  end_time = 0.1
  solve_type = 'newton'
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
[]
[Postprocessors]
  [Ry]
    type = NodalSum
    variable = ry
    boundary = top
    execute_on = 'INITIAL TIMESTEP_END'
  []
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/large-tests/3d.i)
# 2D test with just strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = NINTH
  []
[]
[AuxVariables]
  [s11]
    family = MONOMIAL
    order = CONSTANT
  []
  [s21]
    family = MONOMIAL
    order = CONSTANT
  []
  [s31]
    family = MONOMIAL
    order = CONSTANT
  []
  [s12]
    family = MONOMIAL
    order = CONSTANT
  []
  [s22]
    family = MONOMIAL
    order = CONSTANT
  []
  [s32]
    family = MONOMIAL
    order = CONSTANT
  []
  [s13]
    family = MONOMIAL
    order = CONSTANT
  []
  [s23]
    family = MONOMIAL
    order = CONSTANT
  []
  [s33]
    family = MONOMIAL
    order = CONSTANT
  []
  [F11]
    family = MONOMIAL
    order = CONSTANT
  []
  [F21]
    family = MONOMIAL
    order = CONSTANT
  []
  [F31]
    family = MONOMIAL
    order = CONSTANT
  []
  [F12]
    family = MONOMIAL
    order = CONSTANT
  []
  [F22]
    family = MONOMIAL
    order = CONSTANT
  []
  [F32]
    family = MONOMIAL
    order = CONSTANT
  []
  [F13]
    family = MONOMIAL
    order = CONSTANT
  []
  [F23]
    family = MONOMIAL
    order = CONSTANT
  []
  [F33]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [s11]
    type = RankTwoAux
    variable = s11
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [s21]
    type = RankTwoAux
    variable = s21
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [s31]
    type = RankTwoAux
    variable = s31
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [s12]
    type = RankTwoAux
    variable = s12
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [s22]
    type = RankTwoAux
    variable = s22
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [s32]
    type = RankTwoAux
    variable = s32
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [s13]
    type = RankTwoAux
    variable = s13
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [s23]
    type = RankTwoAux
    variable = s23
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [s33]
    type = RankTwoAux
    variable = s33
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [F11]
    type = RankTwoAux
    variable = F11
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [F21]
    type = RankTwoAux
    variable = F21
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [F31]
    type = RankTwoAux
    variable = F31
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [F12]
    type = RankTwoAux
    variable = F12
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [F22]
    type = RankTwoAux
    variable = F22
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [F32]
    type = RankTwoAux
    variable = F32
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [F13]
    type = RankTwoAux
    variable = F13
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [F23]
    type = RankTwoAux
    variable = F23
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [F33]
    type = RankTwoAux
    variable = F33
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-4.0e-2*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain32]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain31]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain21]
    type = ParsedFunction
    expression = '-1.5e-2*t'
  []
  [stress11]
    type = ParsedFunction
    expression = '4.0e2*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-2.0e2*t'
  []
  [stress33]
    type = ParsedFunction
    expression = '8.0e2*t'
  []
  [stress23]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress13]
    type = ParsedFunction
    expression = '-7.0e2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress32]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress31]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress21]
    type = ParsedFunction
    expression = '-1.5e2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [s11]
    type = ElementAverageValue
    variable = s11
    execute_on = 'initial timestep_end'
  []
  [s21]
    type = ElementAverageValue
    variable = s21
    execute_on = 'initial timestep_end'
  []
  [s31]
    type = ElementAverageValue
    variable = s31
    execute_on = 'initial timestep_end'
  []
  [s12]
    type = ElementAverageValue
    variable = s12
    execute_on = 'initial timestep_end'
  []
  [s22]
    type = ElementAverageValue
    variable = s22
    execute_on = 'initial timestep_end'
  []
  [s32]
    type = ElementAverageValue
    variable = s32
    execute_on = 'initial timestep_end'
  []
  [s13]
    type = ElementAverageValue
    variable = s13
    execute_on = 'initial timestep_end'
  []
  [s23]
    type = ElementAverageValue
    variable = s23
    execute_on = 'initial timestep_end'
  []
  [s33]
    type = ElementAverageValue
    variable = s33
    execute_on = 'initial timestep_end'
  []
  [F11]
    type = ElementAverageValue
    variable = F11
    execute_on = 'initial timestep_end'
  []
  [F21]
    type = ElementAverageValue
    variable = F21
    execute_on = 'initial timestep_end'
  []
  [F31]
    type = ElementAverageValue
    variable = F31
    execute_on = 'initial timestep_end'
  []
  [F12]
    type = ElementAverageValue
    variable = F12
    execute_on = 'initial timestep_end'
  []
  [F22]
    type = ElementAverageValue
    variable = F22
    execute_on = 'initial timestep_end'
  []
  [F32]
    type = ElementAverageValue
    variable = F32
    execute_on = 'initial timestep_end'
  []
  [F13]
    type = ElementAverageValue
    variable = F13
    execute_on = 'initial timestep_end'
  []
  [F23]
    type = ElementAverageValue
    variable = F23
    execute_on = 'initial timestep_end'
  []
  [F33]
    type = ElementAverageValue
    variable = F33
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/weak_plane_stress/pull_3D.i)
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
  use_displaced_mesh = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    save_in = 'ry'
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [ry]
  []
[]
[BCs]
  [left_x]
    type = DirichletBC
    boundary = left
    variable = disp_x
    value = 0
  []
  [bottom_y]
    type = DirichletBC
    boundary = bottom
    variable = disp_y
    value = 0
  []
  [back_z]
    type = DirichletBC
    boundary = back
    variable = disp_z
    value = 0
  []
  [disp_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = top
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [strain]
    type = ComputeLagrangianStrain
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  end_time = 0.1
  solve_type = 'newton'
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
[]
[Postprocessors]
  [Ry]
    type = NodalSum
    variable = ry
    boundary = top
    execute_on = 'INITIAL TIMESTEP_END'
  []
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/special/rotate.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
    xmin = -0.5
    xmax = 0.5
    ymin = -0.5
    ymax = 0.5
    zmin = -0.5
    zmax = 0.5
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[AuxVariables]
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[Functions]
  [angles]
    type = PiecewiseLinear
    x = '0 1 2'
    y = '0 0 1.5707963'
  []
  [stretch]
    type = PiecewiseLinear
    x = '0 1 2'
    y = '0 0.1 0.1'
  []
  [move_y]
    type = ParsedFunction
    expression = 'y*cos(theta) - z * (1 + a)*sin(theta) - y'
    symbol_names = 'a theta'
    symbol_values = 'stretch angles'
  []
  [move_z]
    type = ParsedFunction
    expression = 'y*sin(theta) + z*(1+a)*cos(theta) - z'
    symbol_names = 'a theta'
    symbol_values = 'stretch angles'
  []
  [dts]
    type = PiecewiseConstant
    x = '0 1 2'
    y = '0.1 0.001 0.001'
    direction = 'LEFT_INCLUSIVE'
  []
[]
[BCs]
  [fix]
    type = DirichletBC
    preset = true
    value = 0.0
    boundary = left
    variable = disp_x
  []
  [front_y]
    type = FunctionDirichletBC
    boundary = front
    variable = disp_y
    function = move_y
    preset = true
  []
  [back_y]
    type = FunctionDirichletBC
    boundary = back
    variable = disp_y
    function = move_y
    preset = true
  []
  [front_z]
    type = FunctionDirichletBC
    boundary = front
    variable = disp_z
    function = move_z
    preset = true
  []
  [back_z]
    type = FunctionDirichletBC
    boundary = back
    variable = disp_z
    function = move_z
    preset = true
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = stress_xx
  []
  [syy]
    type = ElementAverageValue
    variable = stress_yy
  []
  [szz]
    type = ElementAverageValue
    variable = stress_zz
  []
  [syz]
    type = ElementAverageValue
    variable = stress_yz
  []
  [sxz]
    type = ElementAverageValue
    variable = stress_xz
  []
  [sxy]
    type = ElementAverageValue
    variable = stress_xy
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-4
  nl_abs_tol = 1e-6
  start_time = 0.0
  end_time = 2.0
  [TimeStepper]
    type = FunctionDT
    function = dts
    interpolate = False
  []
[]
[Outputs]
  exodus = true
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/axisymmetric_cylindrical/total/jacobian/dirichlet.i)
[GlobalParams]
  displacements = 'disp_r disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 2
    ny = 2
  []
  coord_type = RZ
[]
[Variables]
  [disp_r]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_r
    component = 0
  []
  [sdz]
    type = TotalLagrangianStressDivergenceAxisymmetricCylindrical
    variable = disp_z
    component = 1
  []
[]
[BCs]
  [bottom]
    type = DirichletBC
    preset = false
    variable = disp_z
    boundary = bottom
    value = 0.0
  []
  [top]
    type = FunctionDirichletBC
    preset = false
    variable = disp_z
    boundary = top
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrainAxisymmetricCylindrical
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 5
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/2D/dirichlet.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.01
    max = 0.01
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.01
    max = 0.01
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '0.5 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-0.3 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = pullx
    preset = true
  []
  [pull_y]
    type = FunctionDirichletBC
    boundary = top
    variable = disp_y
    function = pully
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 0.2
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/no_action_L.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  stabilize_strain = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [cauchy_stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [cauchy_stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [cauchy_stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [cauchy_stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [cauchy_stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [cauchy_stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [cauchy_stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = cauchy_stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = total_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Outputs]
  exodus = true
  csv = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/planar/generalized_plane_strain/pull_3D.i)
nz = 1
z = '${fparse nz*0.2}'
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 5
    ny = 5
    nz = ${nz}
    zmax = ${z}
  []
  use_displaced_mesh = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[BCs]
  [fix_x]
    type = DirichletBC
    boundary = 'top bottom'
    variable = disp_x
    value = 0
  []
  [fix_y]
    type = DirichletBC
    boundary = 'bottom'
    variable = disp_y
    value = 0
  []
  [fix_z]
    type = DirichletBC
    boundary = 'top bottom'
    variable = disp_z
    value = 0
  []
  [disp_y]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 'top'
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [strain]
    type = ComputeLagrangianStrain
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [stress_zz]
    type = RankTwoCartesianComponent
    rank_two_tensor = cauchy_stress
    index_i = 2
    index_j = 2
    property_name = stress_zz
  []
  [strain_zz]
    type = RankTwoCartesianComponent
    rank_two_tensor = mechanical_strain
    index_i = 2
    index_j = 2
    property_name = strain_zz
  []
[]
[Executioner]
  type = Transient
  dt = 0.01
  end_time = 0.1
  solve_type = 'newton'
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  nl_abs_tol = 1e-8
  nl_rel_tol = 1e-6
[]
[Postprocessors]
  [strain_zz]
    type = ElementAverageMaterialProperty
    mat_prop = strain_zz
  []
  [stress_zz]
    type = ElementAverageMaterialProperty
    mat_prop = stress_zz
  []
[]
[Outputs]
  csv = true
  file_base = 'pull_3D_nz_${nz}'
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/patch/large_patch.i)
[Mesh]
  [base]
    type = FileMeshGenerator
    file = 'patch.xda'
  []
  [sets]
    input = base
    type = SideSetsFromPointsGenerator
    new_boundary = 'left right bottom top back front'
    points = '    0 0.5 0.5
                  1 0.5 0.5
                  0.5 0.0 0.5
               '
             '   0.5 1.0 0.5
                  0.5 0.5 0.0
                  0.5 0.5 1.0'
  []
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    displacements = 'disp_x disp_y disp_z'
    component = 0
    use_displaced_mesh = true
    large_kinematics = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    displacements = 'disp_x disp_y disp_z'
    component = 1
    use_displaced_mesh = true
    large_kinematics = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    displacements = 'disp_x disp_y disp_z'
    component = 2
    use_displaced_mesh = true
    large_kinematics = true
  []
[]
[AuxVariables]
  [strain_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_xz]
    order = CONSTANT
    family = MONOMIAL
  []
  [strain_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xx]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [strain_yy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [strain_zz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [strain_xy]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [strain_xz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [strain_yz]
    type = RankTwoAux
    rank_two_tensor = mechanical_strain
    variable = strain_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = left
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = bottom
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = back
    value = 0.0
  []
  [front]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = front
    value = 0.1
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    displacements = 'disp_x disp_y disp_z'
    large_kinematics = true
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  dt = 1
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  end_time = 1
  dtmin = 1.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/small-tests/1d.i)
# 1D strain controlled test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = false
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '1d.exo'
  []
  [ss]
    type = SideSetsFromPointsGenerator
    input = base
    points = '-1 0 0
               7 0 0'
    new_boundary = 'left right'
  []
[]
[Variables]
  [disp_x]
  []
  [hvar]
    family = SCALAR
    order = FIRST
  []
[]
[AuxVariables]
  [sxx]
    family = MONOMIAL
    order = CONSTANT
  []
  [exx]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [sxx]
    type = RankTwoAux
    variable = sxx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [exx]
    type = RankTwoAux
    variable = exx
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 0
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
[]
[Functions]
  [func_stress]
    type = ParsedFunction
    expression = '1800*t'
  []
  [func_strain]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
[]
[BCs]
  [Periodic]
    [all]
      variable = disp_x
      auto_direction = 'x'
    []
  []
  [centerfix_x]
    type = DirichletBC
    boundary = "fixme"
    variable = disp_x
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = sxx
    execute_on = 'initial timestep_end'
  []
  [exx]
    type = ElementAverageValue
    variable = exx
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = default
  automatic_scaling = true
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-6
  nl_abs_tol = 1e-8
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/large-tests/2d.i)
# 2D with mixed conditions on stress/strain
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '2d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0'
    fixed_normal = true
    new_boundary = 'left right bottom top'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [hvar]
    family = SCALAR
    order = FOURTH
  []
[]
[AuxVariables]
  [s11]
    family = MONOMIAL
    order = CONSTANT
  []
  [s21]
    family = MONOMIAL
    order = CONSTANT
  []
  [s31]
    family = MONOMIAL
    order = CONSTANT
  []
  [s12]
    family = MONOMIAL
    order = CONSTANT
  []
  [s22]
    family = MONOMIAL
    order = CONSTANT
  []
  [s32]
    family = MONOMIAL
    order = CONSTANT
  []
  [s13]
    family = MONOMIAL
    order = CONSTANT
  []
  [s23]
    family = MONOMIAL
    order = CONSTANT
  []
  [s33]
    family = MONOMIAL
    order = CONSTANT
  []
  [F11]
    family = MONOMIAL
    order = CONSTANT
  []
  [F21]
    family = MONOMIAL
    order = CONSTANT
  []
  [F31]
    family = MONOMIAL
    order = CONSTANT
  []
  [F12]
    family = MONOMIAL
    order = CONSTANT
  []
  [F22]
    family = MONOMIAL
    order = CONSTANT
  []
  [F32]
    family = MONOMIAL
    order = CONSTANT
  []
  [F13]
    family = MONOMIAL
    order = CONSTANT
  []
  [F23]
    family = MONOMIAL
    order = CONSTANT
  []
  [F33]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [s11]
    type = RankTwoAux
    variable = s11
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [s21]
    type = RankTwoAux
    variable = s21
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [s31]
    type = RankTwoAux
    variable = s31
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [s12]
    type = RankTwoAux
    variable = s12
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [s22]
    type = RankTwoAux
    variable = s22
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [s32]
    type = RankTwoAux
    variable = s32
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [s13]
    type = RankTwoAux
    variable = s13
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [s23]
    type = RankTwoAux
    variable = s23
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [s33]
    type = RankTwoAux
    variable = s33
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [F11]
    type = RankTwoAux
    variable = F11
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [F21]
    type = RankTwoAux
    variable = F21
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [F31]
    type = RankTwoAux
    variable = F31
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [F12]
    type = RankTwoAux
    variable = F12
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [F22]
    type = RankTwoAux
    variable = F22
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [F32]
    type = RankTwoAux
    variable = F32
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [F13]
    type = RankTwoAux
    variable = F13
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [F23]
    type = RankTwoAux
    variable = F23
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [F33]
    type = RankTwoAux
    variable = F33
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '4.0e-1*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-2.0e-1*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-1*t'
  []
  [strain21]
    type = ParsedFunction
    expression = '-1.5e-1*t'
  []
  [stress11]
    type = ParsedFunction
    expression = '4.0e2*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-2.0e2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress21]
    type = ParsedFunction
    expression = '-1.5e2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_y
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix2"
    variable = disp_y
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [s11]
    type = ElementAverageValue
    variable = s11
    execute_on = 'initial timestep_end'
  []
  [s21]
    type = ElementAverageValue
    variable = s21
    execute_on = 'initial timestep_end'
  []
  [s31]
    type = ElementAverageValue
    variable = s31
    execute_on = 'initial timestep_end'
  []
  [s12]
    type = ElementAverageValue
    variable = s12
    execute_on = 'initial timestep_end'
  []
  [s22]
    type = ElementAverageValue
    variable = s22
    execute_on = 'initial timestep_end'
  []
  [s32]
    type = ElementAverageValue
    variable = s32
    execute_on = 'initial timestep_end'
  []
  [s13]
    type = ElementAverageValue
    variable = s13
    execute_on = 'initial timestep_end'
  []
  [s23]
    type = ElementAverageValue
    variable = s23
    execute_on = 'initial timestep_end'
  []
  [s33]
    type = ElementAverageValue
    variable = s33
    execute_on = 'initial timestep_end'
  []
  [F11]
    type = ElementAverageValue
    variable = F11
    execute_on = 'initial timestep_end'
  []
  [F21]
    type = ElementAverageValue
    variable = F21
    execute_on = 'initial timestep_end'
  []
  [F31]
    type = ElementAverageValue
    variable = F31
    execute_on = 'initial timestep_end'
  []
  [F12]
    type = ElementAverageValue
    variable = F12
    execute_on = 'initial timestep_end'
  []
  [F22]
    type = ElementAverageValue
    variable = F22
    execute_on = 'initial timestep_end'
  []
  [F32]
    type = ElementAverageValue
    variable = F32
    execute_on = 'initial timestep_end'
  []
  [F13]
    type = ElementAverageValue
    variable = F13
    execute_on = 'initial timestep_end'
  []
  [F23]
    type = ElementAverageValue
    variable = F23
    execute_on = 'initial timestep_end'
  []
  [F33]
    type = ElementAverageValue
    variable = F33
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 30
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/area.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[AuxVariables]
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[Functions]
  [zstress]
    type = PiecewiseLinear
    x = '0 1'
    y = '0 500'
  []
  [constant]
    type = ConstantFunction
    value = 1.0
  []
  [ratio]
    type = ParsedFunction
    symbol_names = 'sd su'
    symbol_values = 's_def s_undef'
    expression = 'sd / su'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [boty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [backz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = front
    variable = disp_z
    function = zstress
  []
[]
[AuxKernels]
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [s_undef]
    type = SideIntegralVariablePostprocessor
    variable = stress_zz
    boundary = front
  []
  [s_def]
    type = SideIntegralVariablePostprocessor
    variable = stress_zz
    boundary = front
    use_displaced_mesh = true
  []
  [area_calc]
    type = FunctionValuePostprocessor
    function = ratio
  []
  [area]
    type = AreaPostprocessor
    boundary = front
    use_displaced_mesh = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/convergence/2D/neumann.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '50000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-30000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/small-tests/2d.i)
# 2D with mixed conditions on stress/strain
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = false
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '2d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0'
    fixed_normal = true
    new_boundary = 'left right bottom top'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [hvar]
    family = SCALAR
    order = THIRD
  []
[]
[AuxVariables]
  [sxx]
    family = MONOMIAL
    order = CONSTANT
  []
  [syy]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxy]
    family = MONOMIAL
    order = CONSTANT
  []
  [exx]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyy]
    family = MONOMIAL
    order = CONSTANT
  []
  [exy]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [sxx]
    type = RankTwoAux
    variable = sxx
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [syy]
    type = RankTwoAux
    variable = syy
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [sxy]
    type = RankTwoAux
    variable = sxy
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [exx]
    type = RankTwoAux
    variable = exx
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 0
  []
  [eyy]
    type = RankTwoAux
    variable = eyy
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 1
  []
  [exy]
    type = RankTwoAux
    variable = exy
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 1
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '4.0e-2*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-2.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [stress11]
    type = ParsedFunction
    expression = '400*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-200*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '100*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix1"
    variable = disp_y
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix2"
    variable = disp_y
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = sxx
    execute_on = 'initial timestep_end'
  []
  [syy]
    type = ElementAverageValue
    variable = syy
    execute_on = 'initial timestep_end'
  []
  [sxy]
    type = ElementAverageValue
    variable = sxy
    execute_on = 'initial timestep_end'
  []
  [exx]
    type = ElementAverageValue
    variable = exx
    execute_on = 'initial timestep_end'
  []
  [eyy]
    type = ElementAverageValue
    variable = eyy
    execute_on = 'initial timestep_end'
  []
  [exy]
    type = ElementAverageValue
    variable = exy
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 30
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/2D/neumann.i)
# Simple 2D plane strain test
[GlobalParams]
  displacements = 'disp_x disp_y'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 2
    nx = 4
    ny = 4
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '50000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-30000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-10
  nl_abs_tol = 1e-12
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/action/action_1D.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = TOTAL
        volumetric_locking_correction = false
      []
    []
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [stress_base]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 5.0
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/jacobian/dirichlet.i)
[GlobalParams]
  displacements = 'disp_r'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 5
  []
  coord_type = RSPHERICAL
[]
[Variables]
  [disp_r]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceCentrosymmetricSpherical
    variable = disp_r
    component = 0
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = false
    variable = disp_r
    boundary = left
    value = 0.0
  []
  [right]
    type = FunctionDirichletBC
    preset = false
    variable = disp_r
    boundary = right
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrainCentrosymmetricSpherical
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 5
[]
(modules/solid_mechanics/test/tests/jacobian_damper/cube_load_undisplaced.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 1
  ny = 1
  nz = 1
[]
[Functions]
  [top_pull]
    type = PiecewiseLinear
    x = '0 1     2'
    y = '0 0.025 0.05'
  []
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      displacements = 'disp_x disp_y disp_z'
      [all]
        displacements = 'disp_x disp_y disp_z'
        strain = FINITE
        add_variables = true
        new_system = true
        formulation = TOTAL
      []
    []
  []
[]
[BCs]
  [y_pull_function]
    type = FunctionDirichletBC
    variable = disp_y
    boundary = 3
    function = top_pull
    preset = true
  []
  [x_bot]
    type = DirichletBC
    variable = disp_x
    boundary = 4
    value = 0.0
  []
  [y_bot]
    type = DirichletBC
    variable = disp_y
    boundary = 1
    value = 0.0
  []
  [z_bot]
    type = DirichletBC
    variable = disp_z
    boundary = 0
    value = 0.0
  []
[]
[Materials]
  [elasticity_tensor]
    type = ComputeIsotropicElasticityTensor
    poissons_ratio = 0.3
    youngs_modulus = 2e5
  []
  [stress]
    type = ComputeLagrangianLinearElasticStress
    large_kinematics = true
  []
[]
[Dampers]
  [ejd]
    type = ReferenceElementJacobianDamper
    max_increment = 0.002
    displacements = 'disp_x disp_y disp_z'
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  line_search = 'none'
  nl_rel_tol = 1e-12
  nl_abs_tol = 1e-10
  start_time = 0.0
  end_time = 2
  dt = 1
[]
[Outputs]
  exodus = true
  print_linear_residuals = false
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/3D/neumann.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.02
    max = 0.02
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.02
    max = 0.02
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.02
    max = 0.02
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '4000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-2000 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '3000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_z
    function = pullz
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 1.0
  dtmin = 1.0
  end_time = 1.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/special/rotate.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
    xmin = -0.5
    xmax = 0.5
    ymin = -0.5
    ymax = 0.5
    zmin = -0.5
    zmax = 0.5
  []
[]
[Kernels]
  [sdx]
    type = UpdatedLagrangianStressDivergence
    variable = disp_x
    component = 0
    use_displaced_mesh = true
  []
  [sdy]
    type = UpdatedLagrangianStressDivergence
    variable = disp_y
    component = 1
    use_displaced_mesh = true
  []
  [sdz]
    type = UpdatedLagrangianStressDivergence
    variable = disp_z
    component = 2
    use_displaced_mesh = true
  []
[]
[AuxVariables]
  [stress_xx]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_zz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xy]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_yz]
    order = CONSTANT
    family = MONOMIAL
  []
  [stress_xz]
    order = CONSTANT
    family = MONOMIAL
  []
[]
[Functions]
  [angles]
    type = PiecewiseLinear
    x = '0 1 2'
    y = '0 0 1.5707963'
  []
  [stretch]
    type = PiecewiseLinear
    x = '0 1 2'
    y = '0 0.1 0.1'
  []
  [move_y]
    type = ParsedFunction
    expression = 'y*cos(theta) - z * (1 + a)*sin(theta) - y'
    symbol_names = 'a theta'
    symbol_values = 'stretch angles'
  []
  [move_z]
    type = ParsedFunction
    expression = 'y*sin(theta) + z*(1+a)*cos(theta) - z'
    symbol_names = 'a theta'
    symbol_values = 'stretch angles'
  []
  [dts]
    type = PiecewiseConstant
    x = '0 1 2'
    y = '0.1 0.001 0.001'
    direction = 'LEFT_INCLUSIVE'
  []
[]
[BCs]
  [fix]
    type = DirichletBC
    preset = true
    value = 0.0
    boundary = left
    variable = disp_x
  []
  [front_y]
    type = FunctionDirichletBC
    boundary = front
    variable = disp_y
    function = move_y
    preset = true
  []
  [back_y]
    type = FunctionDirichletBC
    boundary = back
    variable = disp_y
    function = move_y
    preset = true
  []
  [front_z]
    type = FunctionDirichletBC
    boundary = front
    variable = disp_z
    function = move_z
    preset = true
  []
  [back_z]
    type = FunctionDirichletBC
    boundary = back
    variable = disp_z
    function = move_z
    preset = true
  []
[]
[AuxKernels]
  [stress_xx]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xx
    index_i = 0
    index_j = 0
    execute_on = timestep_end
  []
  [stress_yy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yy
    index_i = 1
    index_j = 1
    execute_on = timestep_end
  []
  [stress_zz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_zz
    index_i = 2
    index_j = 2
    execute_on = timestep_end
  []
  [stress_xy]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xy
    index_i = 0
    index_j = 1
    execute_on = timestep_end
  []
  [stress_xz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_xz
    index_i = 0
    index_j = 2
    execute_on = timestep_end
  []
  [stress_yz]
    type = RankTwoAux
    rank_two_tensor = cauchy_stress
    variable = stress_yz
    index_i = 1
    index_j = 2
    execute_on = timestep_end
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = stress_xx
  []
  [syy]
    type = ElementAverageValue
    variable = stress_yy
  []
  [szz]
    type = ElementAverageValue
    variable = stress_zz
  []
  [syz]
    type = ElementAverageValue
    variable = stress_yz
  []
  [sxz]
    type = ElementAverageValue
    variable = stress_xz
  []
  [sxy]
    type = ElementAverageValue
    variable = stress_xy
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-4
  nl_abs_tol = 1e-6
  start_time = 0.0
  end_time = 2.0
  [TimeStepper]
    type = FunctionDT
    function = dts
    interpolate = False
  []
[]
[Outputs]
  exodus = true
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/homogenization/residual_and_jacobian/3d.i)
# 2D test with just strain control
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
  macro_gradient = hvar
  constraint_types = ${constraint_types}
  targets = ${targets}
[]
[Mesh]
  [base]
    type = FileMeshGenerator
    file = '3d.exo'
  []
  [sidesets]
    type = SideSetsFromNormalsGenerator
    input = base
    normals = '-1 0 0
                1 0 0
                0 -1 0
                0 1 0
            '
              '    0 0 -1
                0 0 1'
    fixed_normal = true
    new_boundary = 'left right bottom top back front'
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [hvar]
    family = SCALAR
    order = NINTH
  []
[]
[AuxVariables]
  [s11]
    family = MONOMIAL
    order = CONSTANT
  []
  [s21]
    family = MONOMIAL
    order = CONSTANT
  []
  [s31]
    family = MONOMIAL
    order = CONSTANT
  []
  [s12]
    family = MONOMIAL
    order = CONSTANT
  []
  [s22]
    family = MONOMIAL
    order = CONSTANT
  []
  [s32]
    family = MONOMIAL
    order = CONSTANT
  []
  [s13]
    family = MONOMIAL
    order = CONSTANT
  []
  [s23]
    family = MONOMIAL
    order = CONSTANT
  []
  [s33]
    family = MONOMIAL
    order = CONSTANT
  []
  [F11]
    family = MONOMIAL
    order = CONSTANT
  []
  [F21]
    family = MONOMIAL
    order = CONSTANT
  []
  [F31]
    family = MONOMIAL
    order = CONSTANT
  []
  [F12]
    family = MONOMIAL
    order = CONSTANT
  []
  [F22]
    family = MONOMIAL
    order = CONSTANT
  []
  [F32]
    family = MONOMIAL
    order = CONSTANT
  []
  [F13]
    family = MONOMIAL
    order = CONSTANT
  []
  [F23]
    family = MONOMIAL
    order = CONSTANT
  []
  [F33]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [s11]
    type = RankTwoAux
    variable = s11
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 0
  []
  [s21]
    type = RankTwoAux
    variable = s21
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 0
  []
  [s31]
    type = RankTwoAux
    variable = s31
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 0
  []
  [s12]
    type = RankTwoAux
    variable = s12
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 1
  []
  [s22]
    type = RankTwoAux
    variable = s22
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 1
  []
  [s32]
    type = RankTwoAux
    variable = s32
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 1
  []
  [s13]
    type = RankTwoAux
    variable = s13
    rank_two_tensor = pk1_stress
    index_i = 0
    index_j = 2
  []
  [s23]
    type = RankTwoAux
    variable = s23
    rank_two_tensor = pk1_stress
    index_i = 1
    index_j = 2
  []
  [s33]
    type = RankTwoAux
    variable = s33
    rank_two_tensor = pk1_stress
    index_i = 2
    index_j = 2
  []
  [F11]
    type = RankTwoAux
    variable = F11
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 0
  []
  [F21]
    type = RankTwoAux
    variable = F21
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 0
  []
  [F31]
    type = RankTwoAux
    variable = F31
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 0
  []
  [F12]
    type = RankTwoAux
    variable = F12
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 1
  []
  [F22]
    type = RankTwoAux
    variable = F22
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 1
  []
  [F32]
    type = RankTwoAux
    variable = F32
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 1
  []
  [F13]
    type = RankTwoAux
    variable = F13
    rank_two_tensor = deformation_gradient
    index_i = 0
    index_j = 2
  []
  [F23]
    type = RankTwoAux
    variable = F23
    rank_two_tensor = deformation_gradient
    index_i = 1
    index_j = 2
  []
  [F33]
    type = RankTwoAux
    variable = F33
    rank_two_tensor = deformation_gradient
    index_i = 2
    index_j = 2
  []
[]
[Kernels]
  [sdx]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    scalar_variable = hvar
  []
  [sdy]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    scalar_variable = hvar
  []
  [sdz]
    type = HomogenizedTotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    scalar_variable = hvar
  []
[]
[Functions]
  [strain11]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain22]
    type = ParsedFunction
    expression = '-4.0e-2*t'
  []
  [strain33]
    type = ParsedFunction
    expression = '8.0e-2*t'
  []
  [strain23]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain13]
    type = ParsedFunction
    expression = '-7.0e-2*t'
  []
  [strain12]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain32]
    type = ParsedFunction
    expression = '1.0e-2*t'
  []
  [strain31]
    type = ParsedFunction
    expression = '2.0e-2*t'
  []
  [strain21]
    type = ParsedFunction
    expression = '-1.5e-2*t'
  []
  [stress11]
    type = ParsedFunction
    expression = '4.0e2*t'
  []
  [stress22]
    type = ParsedFunction
    expression = '-2.0e2*t'
  []
  [stress33]
    type = ParsedFunction
    expression = '8.0e2*t'
  []
  [stress23]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress13]
    type = ParsedFunction
    expression = '-7.0e2*t'
  []
  [stress12]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress32]
    type = ParsedFunction
    expression = '1.0e2*t'
  []
  [stress31]
    type = ParsedFunction
    expression = '2.0e2*t'
  []
  [stress21]
    type = ParsedFunction
    expression = '-1.5e2*t'
  []
[]
[BCs]
  [Periodic]
    [x]
      variable = disp_x
      auto_direction = 'x y z'
    []
    [y]
      variable = disp_y
      auto_direction = 'x y z'
    []
    [z]
      variable = disp_z
      auto_direction = 'x y z'
    []
  []
  [fix1_x]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_x
    value = 0
  []
  [fix1_y]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_y
    value = 0
  []
  [fix1_z]
    type = DirichletBC
    boundary = "fix_all"
    variable = disp_z
    value = 0
  []
  [fix2_x]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_x
    value = 0
  []
  [fix2_y]
    type = DirichletBC
    boundary = "fix_xy"
    variable = disp_y
    value = 0
  []
  [fix3_z]
    type = DirichletBC
    boundary = "fix_z"
    variable = disp_z
    value = 0
  []
[]
[Materials]
  [elastic_tensor_1]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
    block = '1'
  []
  [elastic_tensor_2]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 120000.0
    poissons_ratio = 0.21
    block = '2'
  []
  [elastic_tensor_3]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 80000.0
    poissons_ratio = 0.4
    block = '3'
  []
  [elastic_tensor_4]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 76000.0
    poissons_ratio = 0.11
    block = '4'
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    homogenization_gradient_names = 'homogenization_gradient'
  []
  [compute_homogenization_gradient]
    type = ComputeHomogenizedLagrangianStrain
  []
[]
[Postprocessors]
  [s11]
    type = ElementAverageValue
    variable = s11
    execute_on = 'initial timestep_end'
  []
  [s21]
    type = ElementAverageValue
    variable = s21
    execute_on = 'initial timestep_end'
  []
  [s31]
    type = ElementAverageValue
    variable = s31
    execute_on = 'initial timestep_end'
  []
  [s12]
    type = ElementAverageValue
    variable = s12
    execute_on = 'initial timestep_end'
  []
  [s22]
    type = ElementAverageValue
    variable = s22
    execute_on = 'initial timestep_end'
  []
  [s32]
    type = ElementAverageValue
    variable = s32
    execute_on = 'initial timestep_end'
  []
  [s13]
    type = ElementAverageValue
    variable = s13
    execute_on = 'initial timestep_end'
  []
  [s23]
    type = ElementAverageValue
    variable = s23
    execute_on = 'initial timestep_end'
  []
  [s33]
    type = ElementAverageValue
    variable = s33
    execute_on = 'initial timestep_end'
  []
  [F11]
    type = ElementAverageValue
    variable = F11
    execute_on = 'initial timestep_end'
  []
  [F21]
    type = ElementAverageValue
    variable = F21
    execute_on = 'initial timestep_end'
  []
  [F31]
    type = ElementAverageValue
    variable = F31
    execute_on = 'initial timestep_end'
  []
  [F12]
    type = ElementAverageValue
    variable = F12
    execute_on = 'initial timestep_end'
  []
  [F22]
    type = ElementAverageValue
    variable = F22
    execute_on = 'initial timestep_end'
  []
  [F32]
    type = ElementAverageValue
    variable = F32
    execute_on = 'initial timestep_end'
  []
  [F13]
    type = ElementAverageValue
    variable = F13
    execute_on = 'initial timestep_end'
  []
  [F23]
    type = ElementAverageValue
    variable = F23
    execute_on = 'initial timestep_end'
  []
  [F33]
    type = ElementAverageValue
    variable = F33
    execute_on = 'initial timestep_end'
  []
[]
[Executioner]
  type = Transient
  residual_and_jacobian_together = true
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 10
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Outputs]
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence-auto/1D/dirichlet.i)
# Simple 1D plane strain test
[GlobalParams]
  displacements = 'disp_x'
  large_kinematics = true
  stabilize_strain = true
[]
[Variables]
  [disp_x]
  []
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.1
    max = 0.1
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 10
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
[]
[Functions]
  [pull]
    type = ParsedFunction
    expression = '0.06 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = right
    variable = disp_x
    value = 0.0
  []
  [pull]
    type = FunctionDirichletBC
    boundary = left
    variable = disp_x
    function = pull
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 5.0
  dtmin = 5.0
  end_time = 5.0
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/convergence/3D/neumann.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = true
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 4
    ny = 4
    nz = 4
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [pullx]
    type = ParsedFunction
    expression = '4000 * t'
  []
  [pully]
    type = ParsedFunction
    expression = '-2000 * t'
  []
  [pullz]
    type = ParsedFunction
    expression = '3000 * t'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [lefty]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_y
    value = 0.0
  []
  [leftz]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_x
    function = pullx
  []
  [pull_y]
    type = FunctionNeumannBC
    boundary = top
    variable = disp_y
    function = pully
  []
  [pull_z]
    type = FunctionNeumannBC
    boundary = right
    variable = disp_z
    function = pullz
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 15
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.2
  dtmin = 0.2
  end_time = 1.0
[]
[Postprocessors]
  [nonlin]
    type = NumNonlinearIterations
  []
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/updated/action/action_L.i)
[Mesh]
  type = FileMesh
  file = 'L.exo'
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
[]
[Physics]
  [SolidMechanics]
    [QuasiStatic]
      [all]
        strain = SMALL
        add_variables = true
        new_system = true
        formulation = UPDATED
        volumetric_locking_correction = true
        generate_output = 'cauchy_stress_xx cauchy_stress_yy cauchy_stress_zz cauchy_stress_xy '
                          'cauchy_stress_xz cauchy_stress_yz strain_xx strain_yy strain_zz strain_xy '
                          'strain_xz strain_yz'
      []
    []
  []
[]
[Functions]
  [pfn]
    type = PiecewiseLinear
    x = '0    1    2'
    y = '0.00 0.3 0.5'
  []
[]
[BCs]
  [left]
    type = DirichletBC
    preset = true
    variable = disp_x
    boundary = fix
    value = 0.0
  []
  [bottom]
    type = DirichletBC
    preset = true
    variable = disp_y
    boundary = fix
    value = 0.0
  []
  [back]
    type = DirichletBC
    preset = true
    variable = disp_z
    boundary = fix
    value = 0.0
  []
  [front]
    type = FunctionDirichletBC
    variable = disp_z
    boundary = pull
    function = pfn
    preset = true
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  petsc_options_iname = -pc_type
  petsc_options_value = lu
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-8
  end_time = 1.0
  dtmin = 0.5
  dt = 0.5
[]
[Outputs]
  [out]
    type = Exodus
    file_base = 'blah'
  []
[]
(modules/solid_mechanics/test/tests/lagrangian/materials/correctness/cauchy-elastic.i)
# Simple 3D test
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
[]
[Mesh]
  [msh]
    type = GeneratedMeshGenerator
    dim = 3
    nx = 1
    ny = 1
    nz = 1
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
  []
[]
[Functions]
  [strain]
    type = ParsedFunction
    expression = 't'
  []
[]
[BCs]
  [leftx]
    type = DirichletBC
    preset = true
    boundary = left
    variable = disp_x
    value = 0.0
  []
  [boty]
    type = DirichletBC
    preset = true
    boundary = bottom
    variable = disp_y
    value = 0.0
  []
  [backz]
    type = DirichletBC
    preset = true
    boundary = back
    variable = disp_z
    value = 0.0
  []
  [pull_x]
    type = FunctionDirichletBC
    boundary = right
    variable = disp_x
    function = strain
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
  []
[]
[Postprocessors]
  [sxx]
    type = ElementAverageValue
    variable = sxx
    execute_on = 'initial timestep_end'
  []
  [syy]
    type = ElementAverageValue
    variable = syy
    execute_on = 'initial timestep_end'
  []
  [sxy]
    type = ElementAverageValue
    variable = sxy
    execute_on = 'initial timestep_end'
  []
  [szz]
    type = ElementAverageValue
    variable = szz
    execute_on = 'initial timestep_end'
  []
  [syz]
    type = ElementAverageValue
    variable = syz
    execute_on = 'initial timestep_end'
  []
  [sxz]
    type = ElementAverageValue
    variable = sxz
    execute_on = 'initial timestep_end'
  []
  [exx]
    type = ElementAverageValue
    variable = exx
    execute_on = 'initial timestep_end'
  []
  [eyy]
    type = ElementAverageValue
    variable = eyy
    execute_on = 'initial timestep_end'
  []
  [exy]
    type = ElementAverageValue
    variable = exy
    execute_on = 'initial timestep_end'
  []
  [ezz]
    type = ElementAverageValue
    variable = ezz
    execute_on = 'initial timestep_end'
  []
  [eyz]
    type = ElementAverageValue
    variable = eyz
    execute_on = 'initial timestep_end'
  []
  [exz]
    type = ElementAverageValue
    variable = exz
    execute_on = 'initial timestep_end'
  []
[]
[AuxVariables]
  [sxx]
    family = MONOMIAL
    order = CONSTANT
  []
  [syy]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxy]
    family = MONOMIAL
    order = CONSTANT
  []
  [szz]
    family = MONOMIAL
    order = CONSTANT
  []
  [syz]
    family = MONOMIAL
    order = CONSTANT
  []
  [sxz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exx]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyy]
    family = MONOMIAL
    order = CONSTANT
  []
  [exy]
    family = MONOMIAL
    order = CONSTANT
  []
  [ezz]
    family = MONOMIAL
    order = CONSTANT
  []
  [eyz]
    family = MONOMIAL
    order = CONSTANT
  []
  [exz]
    family = MONOMIAL
    order = CONSTANT
  []
[]
[AuxKernels]
  [sxx]
    type = RankTwoAux
    variable = sxx
    rank_two_tensor = cauchy_stress
    index_i = 0
    index_j = 0
  []
  [syy]
    type = RankTwoAux
    variable = syy
    rank_two_tensor = cauchy_stress
    index_i = 1
    index_j = 1
  []
  [sxy]
    type = RankTwoAux
    variable = sxy
    rank_two_tensor = cauchy_stress
    index_i = 0
    index_j = 1
  []
  [zz]
    type = RankTwoAux
    variable = szz
    rank_two_tensor = cauchy_stress
    index_i = 2
    index_j = 2
  []
  [syz]
    type = RankTwoAux
    variable = syz
    rank_two_tensor = cauchy_stress
    index_i = 1
    index_j = 2
  []
  [sxz]
    type = RankTwoAux
    variable = sxz
    rank_two_tensor = cauchy_stress
    index_i = 0
    index_j = 2
  []
  [exx]
    type = RankTwoAux
    variable = exx
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 0
  []
  [eyy]
    type = RankTwoAux
    variable = eyy
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 1
  []
  [exy]
    type = RankTwoAux
    variable = exy
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 1
  []
  [ezz]
    type = RankTwoAux
    variable = ezz
    rank_two_tensor = mechanical_strain
    index_i = 2
    index_j = 2
  []
  [eyz]
    type = RankTwoAux
    variable = eyz
    rank_two_tensor = mechanical_strain
    index_i = 1
    index_j = 2
  []
  [exz]
    type = RankTwoAux
    variable = exz
    rank_two_tensor = mechanical_strain
    index_i = 0
    index_j = 2
  []
[]
[Executioner]
  type = Transient
  solve_type = 'newton'
  line_search = none
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  l_max_its = 2
  l_tol = 1e-14
  nl_max_its = 5
  nl_rel_tol = 1e-8
  nl_abs_tol = 1e-10
  start_time = 0.0
  dt = 0.1
  dtmin = 0.1
  end_time = 0.1
[]
[Outputs]
  exodus = false
  csv = true
[]
(modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/jacobian/neumann.i)
[GlobalParams]
  displacements = 'disp_r'
  large_kinematics = true
  stabilize_strain = true
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 1
    nx = 5
  []
  coord_type = RSPHERICAL
[]
[Variables]
  [disp_r]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceCentrosymmetricSpherical
    variable = disp_r
    component = 0
  []
[]
[BCs]
  [top]
    type = FunctionDirichletBC
    preset = false
    variable = disp_r
    boundary = right
    function = 't'
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrainCentrosymmetricSpherical
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  dt = 0.1
  num_steps = 5
[]
(modules/solid_mechanics/test/tests/lagrangian/centrosymmetric_spherical/total/analytical/small.i)
# This test aims to verify the implementation by comparing the numerical solution
# to the analytical solution. The analytical solution for a hollow sphere is used in
# this test. Given inner pressure p = 100, inner radius a = 2, outer radius b = 4,
# the stress and displacements at the middle of the cylinder
# (r = 3) should be
# sigma_rr = -19.57
# sigma_tt = sigma_pp = 31.22
# u_r = 0.08492
# The numerical approximation yields
# sigma_rr = -19.92
# sigma_tt = sigma_pp = 31.39
# u_r = 0.08492
[GlobalParams]
  displacements = 'disp_r'
  large_kinematics = false
[]
[Mesh]
  [gmg]
    type = GeneratedMeshGenerator
    dim = 1
    xmin = 2
    xmax = 4
    nx = 100
  []
  coord_type = RSPHERICAL
[]
[Variables]
  [disp_r]
  []
[]
[Kernels]
  [sdr]
    type = TotalLagrangianStressDivergenceCentrosymmetricSpherical
    variable = disp_r
    component = 0
  []
[]
[BCs]
  [inner]
    type = NeumannBC
    variable = disp_r
    boundary = left
    value = 100
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 1000.0
    poissons_ratio = 0.25
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
    output_properties = 'cauchy_stress'
    outputs = 'exodus'
  []
  [compute_strain]
    type = ComputeLagrangianStrainCentrosymmetricSpherical
  []
[]
[Postprocessors]
  [u_r]
    type = PointValue
    variable = disp_r
    point = '3 0 0'
  []
  [sigma_rr]
    type = PointValue
    variable = cauchy_stress_00
    point = '3 0 0'
  []
  [sigma_tt]
    type = PointValue
    variable = cauchy_stress_11
    point = '3 0 0'
  []
[]
[Executioner]
  type = Transient
  solve_type = NEWTON
  petsc_options_iname = '-pc_type'
  petsc_options_value = 'lu'
  automatic_scaling = true
  nl_abs_tol = 1e-10
  nl_rel_tol = 1e-10
  num_steps = 1
[]
[Outputs]
  exodus = true
[]
(modules/solid_mechanics/test/tests/lagrangian/cartesian/total/thermal_expansion/jactest.i)
[Mesh]
  type = GeneratedMesh
  dim = 3
  nx = 2
  ny = 2
  nz = 2
[]
[GlobalParams]
  displacements = 'disp_x disp_y disp_z'
  large_kinematics = false
[]
[ICs]
  [disp_x]
    type = RandomIC
    variable = disp_x
    min = -0.02
    max = 0.02
  []
  [disp_y]
    type = RandomIC
    variable = disp_y
    min = -0.02
    max = 0.02
  []
  [disp_z]
    type = RandomIC
    variable = disp_z
    min = -0.02
    max = 0.02
  []
[]
[Variables]
  [disp_x]
  []
  [disp_y]
  []
  [disp_z]
  []
  [temperature]
  []
[]
[Kernels]
  [sdx]
    type = TotalLagrangianStressDivergence
    variable = disp_x
    component = 0
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
  []
  [sdy]
    type = TotalLagrangianStressDivergence
    variable = disp_y
    component = 1
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
  []
  [sdz]
    type = TotalLagrangianStressDivergence
    variable = disp_z
    component = 2
    temperature = temperature
    eigenstrain_names = "thermal_contribution"
  []
  [temperature]
    type = Diffusion
    variable = temperature
  []
[]
[Materials]
  [elastic_tensor]
    type = ComputeIsotropicElasticityTensor
    youngs_modulus = 100000.0
    poissons_ratio = 0.3
  []
  [compute_stress]
    type = ComputeLagrangianLinearElasticStress
  []
  [compute_strain]
    type = ComputeLagrangianStrain
    eigenstrain_names = "thermal_contribution"
  []
  [thermal_expansion]
    type = ComputeThermalExpansionEigenstrain
    temperature = temperature
    thermal_expansion_coeff = 1.0e-3
    eigenstrain_name = thermal_contribution
    stress_free_temperature = 0.0
  []
[]
[Preconditioning]
  [smp]
    type = SMP
    full = true
    petsc_options_iname = '-snes_type'
    petsc_options_value = 'test'
  []
[]
[Executioner]
  solve_type = NEWTON
  end_time = 1
  dt = 1
  type = Transient
[]
[Outputs]
  exodus = true
[]