diff --git a/modules/solid_mechanics/test/tests/pressure/gold/pressure_control_test_out.e b/modules/solid_mechanics/test/tests/pressure/gold/pressure_control_test_out.e new file mode 100644 index 000000000000..79e6018dcfa6 Binary files /dev/null and b/modules/solid_mechanics/test/tests/pressure/gold/pressure_control_test_out.e differ diff --git a/modules/solid_mechanics/test/tests/pressure/pressure_control_test.i b/modules/solid_mechanics/test/tests/pressure/pressure_control_test.i new file mode 100644 index 000000000000..e9206a6081fe --- /dev/null +++ b/modules/solid_mechanics/test/tests/pressure/pressure_control_test.i @@ -0,0 +1,142 @@ +[Mesh] + type = FileMesh + file = pressure_test.e + displacements = 'disp_x disp_y disp_z' +[] + +[Functions] + [rampConstant] + type = PiecewiseLinear + x = '0. 1. 2.' + y = '0. 1. 1.' + scale_factor = 1.0 + [] + [zeroRamp] + type = PiecewiseLinear + x = '0. 1. 2.' + y = '0. 0. 1.' + scale_factor = 1.0 + [] + [rampUnramp] + type = PiecewiseLinear + x = '0. 1. 2.' + y = '0. 1. 0.' + scale_factor = 10.0 + [] +[] + +[Variables] + [disp_x] + order = FIRST + family = LAGRANGE + [] + [disp_y] + order = FIRST + family = LAGRANGE + [] + [disp_z] + order = FIRST + family = LAGRANGE + [] +[] + +[Kernels] + [SolidMechanics] + displacements = 'disp_x disp_y disp_z' + [] +[] + +[BCs] + [no_x] + type = DirichletBC + variable = disp_x + boundary = 4 + value = 0.0 + [] + [no_y] + type = DirichletBC + variable = disp_y + boundary = 5 + value = 0.0 + [] + [no_z] + type = DirichletBC + variable = disp_z + boundary = 6 + value = 0.0 + [] + [Pressure] + [Side1] + boundary = 1 + function = rampConstant + displacements = 'disp_x disp_y disp_z' + control_tags = 'tag_pressure' + [] + [Side2] + boundary = 2 + function = zeroRamp + displacements = 'disp_x disp_y disp_z' + factor = 2.0 + control_tags = 'tag_pressure' + [] + [Side3] + boundary = 3 + function = rampUnramp + displacements = 'disp_x disp_y disp_z' + control_tags = 'tag_pressure' + [] + [] +[] + +[Materials] + [Elasticity_tensor] + type = ComputeElasticityTensor + block = 1 + fill_method = symmetric_isotropic + C_ijkl = '0 0.5e6' + [] + [strain] + type = ComputeSmallStrain + displacements = 'disp_x disp_y disp_z' + block = 1 + [] + [stress] + type = ComputeLinearElasticStress + block = 1 + [] +[] + +[Controls] + # Turn Pressure on some boundaries for step 2, off at step 3 + [pressure_crank] + type = TimePeriod + enable_objects = 'BCs/Pressure/Side1' + disable_objects = 'BCs/Pressure/Side2 BCs/Pressure/Side3' + start_time = 1 + end_time = 2 + # All Pressure are controlled outside of the period as well + reverse_on_false = true + [] +[] + +[Executioner] + type = Transient + solve_type = PJFNK + nl_abs_tol = 1e-10 + l_max_its = 20 + start_time = 0.0 + dt = 1.0 + num_steps = 3 + end_time = 2.0 +[] + +[Outputs] + [out] + type = Exodus + elemental_as_nodal = true + [] + [controls] + type = ControlOutput + show_active_objects = false + [] +[]