- inputsThe input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given.
C++ Type:std::vector<MeshGeneratorName>
Controllable:No
Description:The input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given.
CombinerGenerator
Combine multiple meshes (or copies of one mesh) together into one (disjoint) mesh. Can optionally translate those meshes before combining them.
Overview
The CombinerGenerator allows the user to combine the outputs of multiple MeshGenerators into a single mesh. This is somewhat similar to the StitchMeshGenerator with the difference being that CombinerGenerator makes no attempt to "heal" / "join" the mesh like StitchMeshGenerator does. There CombinerGenerator is more suited to creation of disjoint meshes (where the individual pieces are not directly tied together).
CombinerGenerator preserves subdomain names and boundary names (node sets, side sets, and edge sets). If the corresponding IDs exist in multiple meshes, then the meshes/copies listed later in "inputs"/"positions" take precedence.
Usage
There are three main ways to use the CombinerGenerator:
1. Combine Multiple MeshGenerators
The most straightforward thing to do is simply to combine the output of multiple MeshGenerators together into a single mesh. For example:
[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
[gen1]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 10
ny<<<{"description": "Number of elements in the Y direction"}>>> = 10
xmin<<<{"description": "Lower X Coordinate of the generated mesh"}>>> = 0
xmax<<<{"description": "Upper X Coordinate of the generated mesh"}>>> = 1
ymin<<<{"description": "Lower Y Coordinate of the generated mesh"}>>> = 0
ymax<<<{"description": "Upper Y Coordinate of the generated mesh"}>>> = 1
[]
[gen2]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 12
ny<<<{"description": "Number of elements in the Y direction"}>>> = 12
xmin<<<{"description": "Lower X Coordinate of the generated mesh"}>>> = 2
xmax<<<{"description": "Upper X Coordinate of the generated mesh"}>>> = 3
ymin<<<{"description": "Lower Y Coordinate of the generated mesh"}>>> = 2
ymax<<<{"description": "Upper Y Coordinate of the generated mesh"}>>> = 3
[]
[gen3]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 14
ny<<<{"description": "Number of elements in the Y direction"}>>> = 14
xmin<<<{"description": "Lower X Coordinate of the generated mesh"}>>> = 3.5
xmax<<<{"description": "Upper X Coordinate of the generated mesh"}>>> = 5
ymin<<<{"description": "Lower Y Coordinate of the generated mesh"}>>> = 3
ymax<<<{"description": "Upper Y Coordinate of the generated mesh"}>>> = 4
[]
[cmbn]
type = CombinerGenerator<<<{"description": "Combine multiple meshes (or copies of one mesh) together into one (disjoint) mesh. Can optionally translate those meshes before combining them.", "href": "CombinerGenerator.html"}>>>
inputs<<<{"description": "The input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given."}>>> = 'gen1 gen2 gen3'
[]
[](test/tests/meshgenerators/combiner_generator/combiner_multi_input.i)Will generate a mesh that looks like:

2. Combine Multiple MeshGenerators AND Translate Them
It is also possible to translate (move) the input MeshGenerators as they are combined. This is done using the positions option which takes triplets of floating point numbers that are interpreted as displacement vectors for moving each of the input meshes.
If you specify positions then the number of positions must match the number of inputs, unless only one input is specified (more on that in a moment).
[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
[gen1]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 10
ny<<<{"description": "Number of elements in the Y direction"}>>> = 10
[]
[gen2]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 12
ny<<<{"description": "Number of elements in the Y direction"}>>> = 12
[]
[gen3]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 14
ny<<<{"description": "Number of elements in the Y direction"}>>> = 14
[]
[cmbn]
type = CombinerGenerator<<<{"description": "Combine multiple meshes (or copies of one mesh) together into one (disjoint) mesh. Can optionally translate those meshes before combining them.", "href": "CombinerGenerator.html"}>>>
inputs<<<{"description": "The input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given."}>>> = 'gen1 gen2 gen3'
positions<<<{"description": "The (optional) position of each given mesh. If N 'inputs' were given then this must either be left blank or N positions must be given. If 1 input was given then this MUST be provided."}>>> = '1 0 0 2 2 2 3 0 0'
[]
[](test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate.i)Will generate a mesh that looks like:

Alternatively, the same displacement vectors can be supplied in a file with the positions_file option. The above mesh can equivalently be generated with the following.
[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
[gen1]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 10
ny<<<{"description": "Number of elements in the Y direction"}>>> = 10
[]
[gen2]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 12
ny<<<{"description": "Number of elements in the Y direction"}>>> = 12
[]
[gen3]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 14
ny<<<{"description": "Number of elements in the Y direction"}>>> = 14
[]
[cmbn]
type = CombinerGenerator<<<{"description": "Combine multiple meshes (or copies of one mesh) together into one (disjoint) mesh. Can optionally translate those meshes before combining them.", "href": "CombinerGenerator.html"}>>>
inputs<<<{"description": "The input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given."}>>> = 'gen1 gen2 gen3'
positions_file<<<{"description": "Alternative way to provide the position of each given mesh."}>>> = 'positions.txt'
[]
[](test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate_from_file.i)where the positions.txt file contains the floating point triplets.
1 0 0
2 2 2
3 0 0
(test/tests/meshgenerators/combiner_generator/positions.txt)The same restrictions on positions also apply to the number of entries in position_file.
3. Copy a Single Input Multiple Times With Translations
The final option is to provide exactly one inputs but specify multiple positions. This will cause the single input to be copied multiple times with the position of each copy specified by the positions parameter. For example
[Mesh<<<{"href": "../../syntax/Mesh/index.html"}>>>]
[gen]
type = GeneratedMeshGenerator<<<{"description": "Create a line, square, or cube mesh with uniformly spaced or biased elements.", "href": "GeneratedMeshGenerator.html"}>>>
dim<<<{"description": "The dimension of the mesh to be generated"}>>> = 2
nx<<<{"description": "Number of elements in the X direction"}>>> = 10
ny<<<{"description": "Number of elements in the Y direction"}>>> = 10
[]
[cmbn]
type = CombinerGenerator<<<{"description": "Combine multiple meshes (or copies of one mesh) together into one (disjoint) mesh. Can optionally translate those meshes before combining them.", "href": "CombinerGenerator.html"}>>>
inputs<<<{"description": "The input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given."}>>> = 'gen'
positions<<<{"description": "The (optional) position of each given mesh. If N 'inputs' were given then this must either be left blank or N positions must be given. If 1 input was given then this MUST be provided."}>>> = '1 0 0 2 2 2 3 0 0'
[]
[](test/tests/meshgenerators/combiner_generator/combiner_generator.i)Will generate a mesh that looks like:

Again, the same capability can be achieved with the positions_file option.
Input Parameters
- avoid_merging_boundariesFalseWhether to prevent merging sidesets by offsetting ids. The first mesh in the input will keep the same boundary ids, the others will have offsets. All boundary names will remain valid
Default:False
C++ Type:bool
Controllable:No
Description:Whether to prevent merging sidesets by offsetting ids. The first mesh in the input will keep the same boundary ids, the others will have offsets. All boundary names will remain valid
- avoid_merging_subdomainsFalseWhether to prevent merging subdomains by offsetting ids. The first mesh in the input will keep the same subdomains ids, the others will have offsets. All subdomain names will remain valid
Default:False
C++ Type:bool
Controllable:No
Description:Whether to prevent merging subdomains by offsetting ids. The first mesh in the input will keep the same subdomains ids, the others will have offsets. All subdomain names will remain valid
- positionsThe (optional) position of each given mesh. If N 'inputs' were given then this must either be left blank or N positions must be given. If 1 input was given then this MUST be provided.
C++ Type:std::vector<libMesh::Point>
Controllable:No
Description:The (optional) position of each given mesh. If N 'inputs' were given then this must either be left blank or N positions must be given. If 1 input was given then this MUST be provided.
- positions_fileAlternative way to provide the position of each given mesh.
C++ Type:std::vector<FileName>
Controllable:No
Description:Alternative way to provide the position of each given mesh.
Optional Parameters
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:No
Description:Set the enabled status of the MooseObject.
- save_with_nameKeep the mesh from this mesh generator in memory with the name specified
C++ Type:std::string
Controllable:No
Description:Keep the mesh from this mesh generator in memory with the name specified
Advanced Parameters
- nemesisFalseWhether or not to output the mesh file in the nemesisformat (only if output = true)
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not to output the mesh file in the nemesisformat (only if output = true)
- outputFalseWhether or not to output the mesh file after generating the mesh
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not to output the mesh file after generating the mesh
- show_infoFalseWhether or not to show mesh info after generating the mesh (bounding box, element types, sidesets, nodesets, subdomains, etc)
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not to show mesh info after generating the mesh (bounding box, element types, sidesets, nodesets, subdomains, etc)
Debugging Parameters
Input Files
- (test/tests/mesh/blocks_max_dimension/blocks_max_dimension.i)
- (test/tests/meshgenerators/combiner_generator/combiner_merge_names.i)
- (test/tests/meshgenerators/elements_to_tetrahedrons_convertor/pyramid_elems.i)
- (modules/contact/test/tests/verification/patch_tests/automatic_patch_update/iteration_adaptivity_parallel_node_face.i)
- (test/tests/meshgenerators/elements_to_tetrahedrons_convertor/prism_elems.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/double_vector_cp.i)
- (modules/contact/test/tests/avoid-aligned-node-exception/test.i)
- (test/tests/meshgenerators/xy_delaunay_generator/xydelaunay_from_1d_sbdids.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/real_vector_value_mixed.i)
- (test/tests/meshgenerators/mesh_repair_generator/overlapping_fix_test.i)
- (test/tests/meshgenerators/elements_to_tetrahedrons_convertor/hex_elems.i)
- (test/tests/meshgenerators/combiner_generator/combiner_multi_input.i)
- (test/tests/meshgenerators/combiner_generator/combiner_generator.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/real_vector_value.i)
- (modules/heat_transfer/test/tests/gap_heat_transfer_radiation/sphere.i)
- (modules/heat_transfer/test/tests/thermal_materials/2d.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/double_vector_corr.i)
- (test/tests/meshgenerators/mesh_repair_generator/flip_element.i)
- (test/tests/meshgenerators/coarsen_block_generator/coarsen_quad.i)
- (test/tests/convergence/default_steady_state_convergence/base.i)
- (test/tests/meshgenerators/parsed_element_deletion_generator/cut_the_small.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/mg_sd_name.i)
- (test/tests/meshgenerators/mesh_repair_generator/mixed_elements.i)
- (modules/reactor/test/tests/meshgenerators/azimuthal_block_split_generator/err_mixed_order.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/scalar_vector_corr.i)
- (modules/heat_transfer/test/tests/directional_flux_bc/2d.i)
- (test/tests/meshgenerators/xy_delaunay_generator/xydelaunay_from_2d_bcids.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/double_scalar_cp.i)
- (test/tests/meshgenerators/combiner_generator/combiner_generator_from_file.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/scalar_enum_test.i)
- (test/tests/coord_type/coord_type_rz_general.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/single_vector.i)
- (modules/heat_transfer/test/tests/gap_perfect_transfer/perfect_transfer_gap.i)
- (modules/solid_mechanics/test/tests/umat/multiple_blocks/multiple_blocks_two_materials.i)
- (modules/heat_transfer/test/tests/gap_heat_transfer_htonly/1D.i)
- (test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/double_scalar_corr.i)
- (modules/solid_mechanics/test/tests/umat/multiple_blocks/multiple_blocks_two_materials_parallel.i)
- (test/tests/meshgenerators/mesh_diagnostics_generator/node_based_test.i)
- (modules/heat_transfer/test/tests/directional_flux_bc/3d_elem.i)
- (test/tests/meshgenerators/mesh_diagnostics_generator/elem_types_test.i)
- (test/tests/meshgenerators/coarsen_block_generator/coarsen_hex.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/scalar_vector_cp.i)
- (modules/heat_transfer/test/tests/gap_heat_transfer_radiation/cylinder.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/mg_bdry_name.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/single_scalar.i)
- (test/tests/meshgenerators/mesh_diagnostics_generator/detect_amr_hex.i)
- (modules/optimization/test/tests/simp/2d_twoconstraints.i)
- (modules/optimization/test/tests/simp/2d.i)
- (modules/heat_transfer/test/tests/directional_flux_bc/3d.i)
- (test/tests/meshgenerators/elem_order_conversion_generator/order_conversion.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/vector_point.i)
- (modules/solid_mechanics/test/tests/umat/multiple_blocks/multiple_blocks.i)
- (modules/contact/test/tests/verification/patch_tests/automatic_patch_update/iteration_adaptivity_parallel.i)
- (modules/heat_transfer/test/tests/directional_flux_bc/2d_elem.i)
- (test/tests/meshgenerators/mesh_diagnostics_generator/detect_amr_quad.i)
- (test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate_from_file.i)
- (test/tests/mortar/coincident-nodes/test.i)
- (test/tests/meshgenerators/batch_mesh_generation_action/mfname.i)
- (test/tests/postprocessors/nearest_node_number/nearest_node_number_2.i)
inputs
C++ Type:std::vector<MeshGeneratorName>
Controllable:No
Description:The input MeshGenerators. This can either be N generators or 1 generator. If only 1 is given then 'positions' must also be given.
positions
C++ Type:std::vector<libMesh::Point>
Controllable:No
Description:The (optional) position of each given mesh. If N 'inputs' were given then this must either be left blank or N positions must be given. If 1 input was given then this MUST be provided.
(test/tests/meshgenerators/combiner_generator/combiner_multi_input.i)
[Mesh]
[gen1]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
xmin=0
xmax=1
ymin=0
ymax=1
[]
[gen2]
type = GeneratedMeshGenerator
dim = 2
nx = 12
ny = 12
xmin=2
xmax=3
ymin=2
ymax=3
[]
[gen3]
type = GeneratedMeshGenerator
dim = 2
nx = 14
ny = 14
xmin=3.5
xmax=5
ymin=3
ymax=4
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen1 gen2 gen3'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate.i)
[Mesh]
[gen1]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[gen2]
type = GeneratedMeshGenerator
dim = 2
nx = 12
ny = 12
[]
[gen3]
type = GeneratedMeshGenerator
dim = 2
nx = 14
ny = 14
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen1 gen2 gen3'
positions = '1 0 0 2 2 2 3 0 0'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate_from_file.i)
[Mesh]
[gen1]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[gen2]
type = GeneratedMeshGenerator
dim = 2
nx = 12
ny = 12
[]
[gen3]
type = GeneratedMeshGenerator
dim = 2
nx = 14
ny = 14
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen1 gen2 gen3'
positions_file = 'positions.txt'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/combiner_generator/positions.txt)
1 0 0
2 2 2
3 0 0
(test/tests/meshgenerators/combiner_generator/combiner_generator.i)
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen'
positions = '1 0 0 2 2 2 3 0 0'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/mesh/blocks_max_dimension/blocks_max_dimension.i)
# This input file tests MooseMesh::getBlocksMaxDimension(), which gets the MESH
# dimension of a list of subdomain names.
#
# Note the differences between the MESH dimension and the SPATIAL dimension.
# The SPATIAL dimension just looks at the maximum coordinate dimension used:
# - Equals 3 if there is a nonzero z coordinate
# - Equals 2 if there is no nonzero z coordinate, but there is a nonzero y coordinate
# - Equals 1 if there is no nonzero y or z coordinate
# In contrast, the MESH dimension looks at the dimensionality of the elements.
# Therefore, the MESH dimension differs from the SPATIAL dimension when:
# - a 1D element has a nonzero y or z coordinate
# - a 2D element has a nonzero z coordinate
# This test will include subdomains with these cases and test different
# lists of subdomains.
#
[Mesh]
# 1D block
[block1d_mg]
type = GeneratedMeshGenerator
dim = 1
xmin = 0.0
xmax = 1.0
[]
[block1d_renumber_mg]
type = RenameBlockGenerator
input = block1d_mg
old_block = 0
new_block = 1
[]
[block1d_rename_mg]
type = RenameBlockGenerator
input = block1d_renumber_mg
old_block = 1
new_block = 'block1d'
[]
[block1d_translate_mg]
type = TransformGenerator
input = block1d_rename_mg
transform = TRANSLATE
vector_value = '0 0 1.0'
[]
# 2D block
[block2d_mg]
type = GeneratedMeshGenerator
dim = 2
xmin = 2.0
xmax = 3.0
ymin = 0.0
ymax = 1.0
boundary_id_offset = 10
[]
[block2d_renumber_mg]
type = RenameBlockGenerator
input = block2d_mg
old_block = 0
new_block = 2
[]
[block2d_rename_mg]
type = RenameBlockGenerator
input = block2d_renumber_mg
old_block = 2
new_block = 'block2d'
[]
[boundary2d_rename_mg]
type = RenameBoundaryGenerator
input = block2d_rename_mg
old_boundary = 'left right bottom top'
new_boundary = 'left2d right2d bottom2d top2d'
[]
[block2d_translate_mg]
type = TransformGenerator
input = boundary2d_rename_mg
transform = TRANSLATE
vector_value = '0 0 1.0'
[]
# 3D block
[block3d_mg]
type = GeneratedMeshGenerator
dim = 3
xmin = 4.0
xmax = 5.0
ymin = 0.0
ymax = 1.0
zmin = 0.0
zmax = 1.0
boundary_id_offset = 20
[]
[block3d_renumber_mg]
type = RenameBlockGenerator
input = block3d_mg
old_block = 0
new_block = 3
[]
[block3d_rename_mg]
type = RenameBlockGenerator
input = block3d_renumber_mg
old_block = 3
new_block = 'block3d'
[]
[boundary3d_rename_mg]
type = RenameBoundaryGenerator
input = block3d_rename_mg
old_boundary = 'left right bottom top back front'
new_boundary = 'left3d right3d bottom3d top3d back3d front3d'
[]
# combine blocks
[combiner_mg]
type = CombinerGenerator
inputs = 'block1d_translate_mg block2d_translate_mg boundary3d_rename_mg'
[]
[]
[Postprocessors]
[dim_1d]
type = BlocksMaxDimensionPostprocessor
block = 'block1d'
execute_on = 'INITIAL'
[]
[dim_1d_2d]
type = BlocksMaxDimensionPostprocessor
block = 'block1d block2d'
execute_on = 'INITIAL'
[]
[dim_1d_2d_3d]
type = BlocksMaxDimensionPostprocessor
block = 'block1d block2d block3d'
execute_on = 'INITIAL'
[]
[]
[Executioner]
type = Steady
[]
[Problem]
solve = false
[]
[Outputs]
csv = true
execute_on = 'INITIAL'
[]
(test/tests/meshgenerators/combiner_generator/combiner_merge_names.i)
[Mesh]
[Top_Block]
type = GeneratedMeshGenerator
dim = 3
nx = 10
ny = 10
nz = 10
xmax = 2
ymax = 2
zmax = 2
xmin = 0
ymin = 0
zmin = 1
boundary_name_prefix = 'Upper'
boundary_id_offset = 10
[]
[Bottom_Block]
type = GeneratedMeshGenerator
dim = 3
nx = 10
ny = 10
nz = 10
xmax = 2
ymax = 2
zmax = 1
boundary_name_prefix = 'Lower'
[]
[Combine]
type = CombinerGenerator
inputs = 'Top_Block Bottom_Block'
positions = '0 0 0 0.12 0.12 0'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/elements_to_tetrahedrons_convertor/pyramid_elems.i)
p0 = '0 0 0'
p1 = '1 0 0'
p2 = '1 1 0'
p3 = '0 1 0'
p4 = '0.5 0.5 1'
[Mesh]
[pyramid5_0]
type = ElementGenerator
elem_type = PYRAMID5
create_sidesets = true
element_connectivity = '0 1 2 3 4'
nodal_positions = '${p0} ${p1} ${p2} ${p3} ${p4}'
[]
[pyramid5_1]
type = ElementGenerator
elem_type = PYRAMID5
create_sidesets = true
element_connectivity = '3 0 1 2 4'
nodal_positions = '${p1} ${p2} ${p3} ${p0} ${p4}'
[]
[pyramid5_2]
type = ElementGenerator
elem_type = PYRAMID5
create_sidesets = true
element_connectivity = '2 3 0 1 4'
nodal_positions = '${p2} ${p3} ${p0} ${p1} ${p4}'
[]
[pyramid5_3]
type = ElementGenerator
elem_type = PYRAMID5
create_sidesets = true
element_connectivity = '1 2 3 0 4'
nodal_positions = '${p3} ${p0} ${p1} ${p2} ${p4}'
[]
[cmb]
type = CombinerGenerator
inputs = 'pyramid5_0 pyramid5_1
pyramid5_2 pyramid5_3'
positions = '0 0 0 2 0 0
0 2 0 2 2 0'
[]
[convert]
type = ElementsToTetrahedronsConverter
input = cmb
[]
[]
(modules/contact/test/tests/verification/patch_tests/automatic_patch_update/iteration_adaptivity_parallel_node_face.i)
[GlobalParams]
order = FIRST
family = LAGRANGE
displacements = 'disp_x disp_y'
volumetric_locking_correction = true
[]
[Mesh]
coord_type = XYZ
patch_update_strategy = iteration
patch_size = 8
ghosting_patch_size = 20
[cube1]
type = GeneratedMeshGenerator
dim = 2
boundary_name_prefix = cube1
xmax = 1
ymax = 1
nx = 2
ny = 2
[]
[cube2]
type = GeneratedMeshGenerator
dim = 2
boundary_name_prefix = cube2
boundary_id_offset = 5
xmax = 1
ymax = 1
nx = 2
ny = 2
[]
[block_id]
type = SubdomainIDGenerator
input = cube2
subdomain_id = 2
[]
[combine]
inputs = 'cube1 block_id'
type = CombinerGenerator
positions = '0 0 0
0 1 0'
[]
[rename2]
type = RenameBlockGenerator
input = combine
old_block = '0 2'
new_block = 'cube1 cube2'
[]
[]
[Adaptivity]
initial_marker = box
initial_steps = 1
max_h_level = 1
[Markers]
[box]
type = BoxMarker
bottom_left = '0 0 0'
top_right = '0.5 0.5 0'
inside = refine
outside = do_nothing
[]
[]
[]
[Variables]
[disp_x]
block = 'cube1 cube2'
[]
[disp_y]
block = 'cube1 cube2'
[]
[]
[Physics/SolidMechanics/QuasiStatic]
[cube1_mechanics]
strain = FINITE
block = 'cube1 cube2'
[]
[]
[BCs]
[cube1_x]
type = ADDirichletBC
variable = disp_x
boundary = 'cube1_bottom '
value = 0.0
[]
[cube1_y]
type = ADDirichletBC
variable = disp_y
boundary = 'cube1_bottom '
value = 0.0
[]
[cube2_y]
type = ADFunctionDirichletBC
variable = disp_y
boundary = 'cube2_top'
function = '-t'
preset = false
[]
[cube2_x]
type = ADDirichletBC
variable = disp_x
boundary = 'cube2_top'
value = 0
[]
[]
[Materials]
[cube1_elasticity_tensor]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 68.9e9
poissons_ratio = 0.3
block = 'cube1'
[]
[stress]
type = ComputeFiniteStrainElasticStress
block = 'cube1 cube2'
[]
[cube2_elasticity_tensor]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 140e9
poissons_ratio = 0.3
block = 'cube2'
[]
[]
[Contact]
[contactswell]
secondary = cube1_top
primary = cube2_bottom
model = frictionless
formulation = kinematic
penalty = 1.0e6
normalize_penalty = true
tangential_tolerance = 0.1
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
type = Transient
solve_type = 'NEWTON'
petsc_options_iname = '-pc_type -pc_factor_mat_solver_type'
petsc_options_value = 'lu superlu_dist'
line_search = 'none'
nl_rel_tol = 1e-16
nl_abs_tol = 1e-16
nl_max_its = 50
l_tol = 1e-4
l_max_its = 50
start_time = 0.0
end_time = 0.02e-3
dtmax = 4
dtmin = 0.001e-3
dt = 0.01e-3
automatic_scaling = true
off_diagonals_in_auto_scaling = true
[]
[Debug]
show_var_residual_norms = true
[]
[Outputs]
exodus = true
execute_on = 'FINAL'
[]
(test/tests/meshgenerators/elements_to_tetrahedrons_convertor/prism_elems.i)
p0 = '0 0 0'
p1 = '1 0 0'
p2 = '1 1 0'
p3 = '0 0 1'
p4 = '1 0 1'
p5 = '1 1 1'
[Mesh]
[prism6_0]
type = ElementGenerator
elem_type = PRISM6
create_sidesets = true
element_connectivity = '0 1 2 3 4 5'
nodal_positions = '${p0} ${p1} ${p2} ${p3} ${p4} ${p5}'
[]
[prism6_1]
type = ElementGenerator
elem_type = PRISM6
create_sidesets = true
element_connectivity = '2 0 1 5 3 4'
nodal_positions = '${p1} ${p2} ${p0} ${p4} ${p5} ${p3}'
[]
[prism6_2]
type = ElementGenerator
elem_type = PRISM6
create_sidesets = true
element_connectivity = '1 2 0 4 5 3'
nodal_positions = '${p2} ${p0} ${p1} ${p5} ${p3} ${p4}'
[]
[prism6_3]
type = ElementGenerator
elem_type = PRISM6
create_sidesets = true
element_connectivity = '3 5 4 0 2 1'
nodal_positions = '${p3} ${p5} ${p4} ${p0} ${p2} ${p1}'
[]
[prism6_4]
type = ElementGenerator
elem_type = PRISM6
create_sidesets = true
element_connectivity = '4 3 5 1 0 2'
nodal_positions = '${p4} ${p3} ${p5} ${p1} ${p0} ${p2}'
[]
[prism6_5]
type = ElementGenerator
elem_type = PRISM6
create_sidesets = true
element_connectivity = '5 4 3 2 1 0'
nodal_positions = '${p5} ${p4} ${p3} ${p2} ${p1} ${p0}'
[]
[cmb]
type = CombinerGenerator
inputs = 'prism6_0 prism6_1 prism6_2
prism6_3 prism6_4 prism6_5'
positions = '0 0 0 2 0 0 4 0 0
0 2 0 2 2 0 4 2 0'
[]
[convert]
type = ElementsToTetrahedronsConverter
input = cmb
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/double_vector_cp.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'ConcentricCircleMeshGenerator'
multi_batch_params_method = cartesian_product
mesh_name_prefix = 'gmg'
batch_vector_input_param_names = 'radii rings'
batch_vector_input_param_types = 'REAL UINT'
batch_vector_input_param_values = '0.8;1.0| 1 1;2 1'
fixed_scalar_input_param_names = 'has_outer_square preserve_volumes num_sectors portion pitch'
fixed_scalar_input_param_types = 'BOOL BOOL UINT ENUM REAL'
fixed_scalar_input_param_values = 'on off 4 top_right 2.1'
use_decomposed_index = true
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_1_1 gmg_0_1 gmg_1_0 gmg_0_0'
positions = '3 3 0
0 3 0
3 0 0
0 0 0'
[]
[]
(modules/contact/test/tests/avoid-aligned-node-exception/test.i)
youngs_modulus = 10e11
[Mesh]
type = MeshGeneratorMesh
patch_update_strategy = iteration
#
# Binder
#
[binder_block]
type = GeneratedMeshGenerator
dim = 2
nx = 20
ny = 36
xmin = 0
xmax = 3.75e+2
ymin = 0
ymax = 3.00e+2
boundary_id_offset = 800
subdomain_ids = 800
boundary_name_prefix = 'binder'
elem_type = QUAD4
[]
[binder_rm]
type = SubdomainBoundingBoxGenerator
input = binder_block
block_id = 200
bottom_left = '0.75e+2 0.75e+2 0'
top_right = '3.75e+2 2.25e+2 0'
[]
[binder_rm_nodeset]
type = BoundingBoxNodeSetGenerator
input = binder_rm
new_boundary = 807
bottom_left = '0.75e+2 0.75e+2 0'
top_right = '7.5e+2 4.0e+2 0'
[]
[binder_initial]
type = BlockDeletionGenerator
block = 200
input = binder_rm_nodeset
new_boundary = 815
[]
[binder_inner_top]
type = SideSetsFromBoundingBoxGenerator
input = binder_initial
included_boundaries = 815
boundary_new = 812
bottom_left = '0.7e+2 2.24e+2 0'
top_right = '4e+2 2.5e+2 0'
[]
[binder_inner_bottom]
type = SideSetsFromBoundingBoxGenerator
input = binder_inner_top
included_boundaries = 815
boundary_new = 810
bottom_left = '0.7e+2 0.5e+2 0'
top_right = '4e+2 0.8e+2 0'
[]
[binder]
type = SideSetsFromBoundingBoxGenerator
input = binder_inner_bottom
included_boundaries = 815
boundary_new = 813
bottom_left = '0.6e+2 0.6e+2 0'
top_right = '0.78e+2 2.5e+2 0'
[]
#
# Crystal
#
[crystal_subdomain]
type = GeneratedMeshGenerator
nx = 13
ny = 60
dim = 2
xmin = 0.75e+2
xmax = 3.75e+2
ymin = 0.75e+2
ymax = 2.25e+2
boundary_id_offset = 100
subdomain_ids = 100
boundary_name_prefix = 'sd1'
[]
[crack1_subdomain]
type = SubdomainBoundingBoxGenerator
input = crystal_subdomain
block_id = 510
bottom_left = '1.25e+2 1.125e+2 0'
top_right = '4.0e+2 1.15e+2 0'
[]
[crack1_nodeset]
type = BoundingBoxNodeSetGenerator
input = crack1_subdomain
new_boundary = crack1_ns
bottom_left = '1.25e+2 1.125e+2 0'
top_right = '4.0e+2 1.15e+2 0'
[]
[crystal_c1]
type = BlockDeletionGenerator
block = 510
input = crack1_nodeset
new_boundary = 500
[]
[crack2_subdomain]
type = SubdomainBoundingBoxGenerator
input = crystal_c1
block_id = 610
bottom_left = '1.25e+2 1.5e+2 0'
top_right = '4.0e+2 1.525e+2 0'
[]
[crack2_nodeset]
type = BoundingBoxNodeSetGenerator
input = crack2_subdomain
new_boundary = crack2_ns
bottom_left = '1.25e+2 1.5e+2 0'
top_right = '4.0e+2 1.525e+2 0'
[]
[crystal_c2]
type = BlockDeletionGenerator
block = 610
input = crack2_nodeset
new_boundary = 600
[]
[crack3_subdomain]
type = SubdomainBoundingBoxGenerator
input = crystal_c2
block_id = 710
bottom_left = '1.25e+2 1.875e+2 0'
top_right = '4.0e+2 1.9e+2 0'
[]
[crack3_nodeset]
type = BoundingBoxNodeSetGenerator
input = crack3_subdomain
new_boundary = crack3_ns
bottom_left = '1.25e+2 1.875e+2 0'
top_right = '4.0e+2 1.9e+2 0'
[]
[crystal_c3]
type = BlockDeletionGenerator
block = 710
input = crack3_nodeset
new_boundary = 700
[]
[crack1_lower]
type = SideSetsFromBoundingBoxGenerator
input = crystal_c3
included_boundaries = 500
boundary_new = 511
bottom_left = '1e+2 1.1e+2 0'
top_right = '4.0e+2 1.13e+2 0'
[]
[crack1_upper]
type = SideSetsFromBoundingBoxGenerator
input = crack1_lower
included_boundaries = 500
boundary_new = 512
bottom_left = '1e+2 1.14e+2 0'
top_right = '4.0e+2 1.18e+2 0'
[]
[crack2_lower]
type = SideSetsFromBoundingBoxGenerator
input = crack1_upper
included_boundaries = 600
boundary_new = 611
bottom_left = '1e+2 1.3e+2 0'
top_right = '4.0e+2 1.51e+2 0'
[]
[crack2_upper]
type = SideSetsFromBoundingBoxGenerator
input = crack2_lower
included_boundaries = 600
boundary_new = 612
bottom_left = '1e+2 1.52e+2 0'
top_right = '4.0e+2 1.6e+2 0'
[]
[crack3_lower]
type = SideSetsFromBoundingBoxGenerator
input = crack2_upper
included_boundaries = 700
boundary_new = 711
bottom_left = '1e+2 1.8e+2 0'
top_right = '4.0e+2 1.88e+2 0'
[]
[crystal]
type = SideSetsFromBoundingBoxGenerator
input = crack3_lower
included_boundaries = 700
boundary_new = 712
bottom_left = '1e+2 1.89e+2 0'
top_right = '4.0e+2 1.95e+2 0'
[]
[rve_final]
type = CombinerGenerator
inputs = 'binder crystal'
[]
[]
##################################################################################
[GlobalParams]
displacements = 'disp_x disp_y'
[]
[Variables]
[disp_x]
order = FIRST
family = LAGRANGE
[]
[disp_y]
order = FIRST
family = LAGRANGE
[]
[]
###################################################################################
[AuxVariables]
[temp]
order = CONSTANT
family = MONOMIAL
[]
[irr]
order = CONSTANT
family = MONOMIAL
[]
[initial_x]
order = CONSTANT
family = MONOMIAL
[]
[strain_x]
order = CONSTANT
family = MONOMIAL
[]
[strain_y]
order = CONSTANT
family = MONOMIAL
[]
[]
###################################################################################
[Functions]
[temp_def]
type = ConstantFunction
value = 800
[]
[irr_def]
type = ConstantFunction
value = 9
[]
[initial_x_def]
type = ConstantFunction
value = 825
[]
[]
###################################################################################
[Physics]
[SolidMechanics]
[QuasiStatic]
[all]
eigenstrain_names = 'thermal_strain irr_strain'
add_variables = true
generate_output = 'vonmises_stress'
block = '100 800'
[]
[]
[]
[]
###################################################################################
[AuxKernels]
[initial_x]
type = FunctionAux
variable = initial_x
function = initial_x_def
use_displaced_mesh = false
[]
[tempfuncaux]
type = FunctionAux
variable = temp
function = temp_def
use_displaced_mesh = false
[]
[irrfuncaux]
type = FunctionAux
variable = irr
function = irr_def
use_displaced_mesh = false
[]
[]
###################################################################################
[BCs]
[right]
type = DirichletBC
boundary = 'binder_right sd1_right'
variable = disp_x
value = 0.
[]
[top]
type = DirichletBC
boundary = 'binder_top'
variable = disp_y
value = 0
[]
[]
###################################################################################
[Contact]
[bc_top]
primary = 812
secondary = 102
formulation = mortar
model = frictionless
correct_edge_dropping = true
[]
[bc_bottom]
primary = 810
secondary = 100
formulation = mortar
model = frictionless
correct_edge_dropping = true
[]
[bc_left]
primary = 103
secondary = 813
formulation = mortar
model = frictionless
correct_edge_dropping = true
[]
[crack_1]
primary = 511
secondary = 512
formulation = mortar
model = frictionless
correct_edge_dropping = true
[]
[crack_2]
primary = 611
secondary = 612
formulation = mortar
model = frictionless
correct_edge_dropping = true
[]
[crack_3]
primary = 711
secondary = 712
formulation = mortar
model = frictionless
correct_edge_dropping = true
[]
[]
###################################################################################
[Materials]
#
# Binder properties - isotropic elasticity + 2 eigenstrains
#
[binder_elasticity_tensor]
block = '800'
type = ComputeIsotropicElasticityTensor
youngs_modulus = ${youngs_modulus}
poissons_ratio = 0.01
[]
[binder_therm_prefactor]
type = DerivativeParsedMaterial
block = '800'
coupled_variables = 'temp'
property_name = binder_therm_prefactor
constant_names = 'a T'
constant_expressions = '1.3e-5 298' #'1.3e-5 298'
expression = '(a*(temp-T))'
[]
[binder_thermal_strain]
type = ComputeVariableEigenstrain
block = '800'
eigen_base = '1 0 0 0 1 0 0 0 1'
args = 'temp'
prefactor = binder_therm_prefactor
eigenstrain_name = thermal_strain
[]
[binder_irr_prefactor]
type = DerivativeParsedMaterial
block = '800'
coupled_variables = 'irr initial_x'
property_name = binder_irr_prefactor
constant_names = 'm'
constant_expressions = '0'
expression = '((m*irr)/100)'
[]
[binder_irr_strain]
type = ComputeVariableEigenstrain
block = '800'
eigen_base = '1 0 0 0 1 0 0 0 1'
args = 'irr'
prefactor = binder_irr_prefactor
eigenstrain_name = irr_strain
[]
#
# Crystal properties - orthotropic elasticity + 2 eigenstrains
#
[elasticity_tensor]
type = ComputeElasticityTensor
block = '100'
fill_method = orthotropic
C_ijkl = '1.095e9 3.65e7 1.095e9 2.8568e8 9.549e6 9.549e6 0.01 0.01 0.3 0.3 0.01 0.01'
[]
[therm_prefactor]
type = DerivativeParsedMaterial
block = '100'
coupled_variables = 'temp'
property_name = therm_prefactor
constant_names = 'a T'
constant_expressions = '1.3e-5 298' #'2.65e-5 298'
expression = '(a*(temp-T))'
[]
[thermal_strain]
type = ComputeVariableEigenstrain
block = '100'
eigen_base = '-0.0577 0 0 0 1 0 0 0 1'
args = 'temp'
prefactor = therm_prefactor
eigenstrain_name = thermal_strain
[]
[irr_prefactor]
type = DerivativeParsedMaterial
block = '100'
coupled_variables = 'irr initial_x'
property_name = irr_prefactor
constant_names = 'm'
constant_expressions = '1'
expression = '((m*irr)/100)'
[]
[irr_strain]
type = ComputeVariableEigenstrain
block = '100'
eigen_base = '-0.31 0 0 0 1 0 0 0 1'
args = 'irr'
prefactor = irr_prefactor
eigenstrain_name = irr_strain
[]
[stress]
type = ComputeLinearElasticStress
block = '100 800'
[]
[]
[Preconditioning]
[prec1]
type = SMP
full = true
[]
[]
[Executioner]
type = Steady
solve_type = 'Newton'
petsc_options = '-snes_ksp_ew'
petsc_options_iname = '-pc_type -pc_factor_mat_solver_package'
petsc_options_value = 'lu superlu_dist'
nl_rel_tol = 1e-7
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/xy_delaunay_generator/xydelaunay_from_1d_sbdids.i)
[Mesh]
[left_bdy]
type = PolyLineMeshGenerator
points = '-3.0 0.0 0.0
-2.0 -1.0 0.0
-1.0 0.0 0.0
-2.0 2.0 0.0'
loop = true
[]
[right_bdy]
type = PolyLineMeshGenerator
points = '3.0 0.0 0.0
2.0 -1.0 0.0
1.0 0.0 0.0
2.0 2.0 0.0'
loop = true
[]
[right_sbd1]
type = SubdomainIDGenerator
input = right_bdy
subdomain_id = 1
[]
[both_bdy]
type = CombinerGenerator
inputs = 'left_bdy right_sbd1'
[]
[triang]
type = XYDelaunayGenerator
boundary = 'both_bdy'
input_subdomain_names = 1 # only the right half
refine_boundary = true
desired_area = 0.2
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/real_vector_value_mixed.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'TransformGenerator'
mesh_name_prefix = 'rotate'
batch_scalar_input_param_names = 'input'
batch_scalar_input_param_types = 'MGNAME'
batch_scalar_input_param_values = 'gmg_0 gmg_1'
fixed_scalar_input_param_names = 'transform vector_value'
fixed_scalar_input_param_types = 'ENUM REALVECTORVALUE'
fixed_scalar_input_param_values = 'ROTATE 45 0 0'
[]
[]
[gmg_0]
type = GeneratedMeshGenerator
dim = 2
subdomain_ids = 1
[]
[gmg_1]
type = GeneratedMeshGenerator
dim = 2
subdomain_ids = 2
[]
[cmbn]
type = CombinerGenerator
inputs = 'rotate_0 rotate_1'
positions = '0 0 0
2 0 0'
[]
[]
(test/tests/meshgenerators/mesh_repair_generator/overlapping_fix_test.i)
[Mesh]
[dir1]
type = ElementGenerator
nodal_positions = '0 0 0
1 0 0
0 1 0'
element_connectivity = '0 1 2'
elem_type = 'TRI3'
[]
[dir2]
type = ElementGenerator
nodal_positions = '1 1 0
1 0 0
0 1 0'
element_connectivity = '0 1 2'
elem_type = 'TRI3'
[]
[combine]
type = CombinerGenerator
inputs = 'dir1 dir2'
[]
[diag]
type = MeshRepairGenerator
input = combine
fix_node_overlap = true
[]
[]
[Problem]
solve = false
[]
[Executioner]
type = Steady
[]
[Reporters]
[mesh]
type = MeshInfo
outputs = json
items = 'num_nodes'
[]
[]
[Outputs]
[json]
type = JSON
execute_system_information_on = NONE
[]
[]
(test/tests/meshgenerators/elements_to_tetrahedrons_convertor/hex_elems.i)
p0 = '0 0 0'
p1 = '1 0 0'
p2 = '1 1 0'
p3 = '0 1 0'
p4 = '0 0 1'
p5 = '1 0 1'
p6 = '1 1 1'
p7 = '0 1 1'
[Mesh]
[hex8_0]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '0 1 2 3 4 5 6 7'
nodal_positions = '${p0} ${p1} ${p2} ${p3} ${p4} ${p5} ${p6} ${p7}'
[]
[hex8_1]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '0 4 5 1 3 7 6 2'
nodal_positions = '${p0} ${p3} ${p7} ${p4} ${p1} ${p2} ${p6} ${p5}'
[]
[hex8_2]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '0 3 7 4 1 2 6 5'
nodal_positions = '${p0} ${p4} ${p5} ${p1} ${p3} ${p7} ${p6} ${p2}'
[]
[hex8_3]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '1 0 4 5 2 3 7 6'
nodal_positions = '${p1} ${p0} ${p4} ${p5} ${p2} ${p3} ${p7} ${p6}'
[]
[hex8_4]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '3 0 1 2 7 4 5 6'
nodal_positions = '${p1} ${p2} ${p3} ${p0} ${p5} ${p6} ${p7} ${p4}'
[]
[hex8_5]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '4 0 3 7 5 1 2 6'
nodal_positions = '${p1} ${p5} ${p6} ${p2} ${p0} ${p4} ${p7} ${p3}'
[]
[hex8_6]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '2 3 0 1 6 7 4 5'
nodal_positions = '${p2} ${p3} ${p0} ${p1} ${p6} ${p7} ${p4} ${p5}'
[]
[hex8_7]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '5 1 0 4 6 2 3 7'
nodal_positions = '${p2} ${p1} ${p5} ${p6} ${p3} ${p0} ${p4} ${p7}'
[]
[hex8_8]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '7 4 0 3 6 5 1 2'
nodal_positions = '${p2} ${p6} ${p7} ${p3} ${p1} ${p5} ${p4} ${p0}'
[]
[hex8_9]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '4 5 1 0 7 6 2 3'
nodal_positions = '${p3} ${p2} ${p6} ${p7} ${p0} ${p1} ${p5} ${p4}'
[]
[hex8_10]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '1 2 3 0 5 6 7 4'
nodal_positions = '${p3} ${p0} ${p1} ${p2} ${p7} ${p4} ${p5} ${p6}'
[]
[hex8_11]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '3 7 4 0 2 6 5 1'
nodal_positions = '${p3} ${p7} ${p4} ${p0} ${p2} ${p6} ${p5} ${p1}'
[]
[hex8_12]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '3 2 6 7 0 1 5 4'
nodal_positions = '${p4} ${p5} ${p1} ${p0} ${p7} ${p6} ${p2} ${p3}'
[]
[hex8_13]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '4 7 6 5 0 3 2 1'
nodal_positions = '${p4} ${p7} ${p6} ${p5} ${p0} ${p3} ${p2} ${p1}'
[]
[hex8_14]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '1 5 6 2 0 4 7 3'
nodal_positions = '${p4} ${p0} ${p3} ${p7} ${p5} ${p1} ${p2} ${p6}'
[]
[hex8_15]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '5 4 7 6 1 0 3 2'
nodal_positions = '${p5} ${p4} ${p7} ${p6} ${p1} ${p0} ${p3} ${p2}'
[]
[hex8_16]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '7 3 2 6 4 0 1 5'
nodal_positions = '${p5} ${p6} ${p2} ${p1} ${p4} ${p7} ${p3} ${p0}'
[]
[hex8_17]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '2 1 5 6 3 0 4 7'
nodal_positions = '${p5} ${p1} ${p0} ${p4} ${p6} ${p2} ${p3} ${p7}'
[]
[hex8_18]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '6 7 3 2 5 4 0 1'
nodal_positions = '${p6} ${p7} ${p3} ${p2} ${p5} ${p4} ${p0} ${p1}'
[]
[hex8_19]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '6 5 4 7 2 1 0 3'
nodal_positions = '${p6} ${p5} ${p4} ${p7} ${p2} ${p1} ${p0} ${p3}'
[]
[hex8_20]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '6 2 1 5 7 3 0 4'
nodal_positions = '${p6} ${p2} ${p1} ${p5} ${p7} ${p3} ${p0} ${p4}'
[]
[hex8_21]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '7 6 5 4 3 2 1 0'
nodal_positions = '${p7} ${p6} ${p5} ${p4} ${p3} ${p2} ${p1} ${p0}'
[]
[hex8_22]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '2 6 7 3 1 5 4 0'
nodal_positions = '${p7} ${p4} ${p0} ${p3} ${p6} ${p5} ${p1} ${p2}'
[]
[hex8_23]
type = ElementGenerator
elem_type = HEX8
create_sidesets = true
element_connectivity = '5 6 2 1 4 7 3 0'
nodal_positions = '${p7} ${p3} ${p2} ${p6} ${p4} ${p0} ${p1} ${p5}'
[]
[cmb]
type = CombinerGenerator
inputs = 'hex8_0 hex8_1 hex8_2 hex8_3 hex8_4 hex8_5 hex8_6 hex8_7
hex8_8 hex8_9 hex8_10 hex8_11 hex8_12 hex8_13 hex8_14 hex8_15
hex8_16 hex8_17 hex8_18 hex8_19 hex8_20 hex8_21 hex8_22 hex8_23'
positions = '0 0 0 2 0 0 4 0 0 6 0 0 8 0 0 10 0 0 12 0 0 14 0 0
0 2 0 2 2 0 4 2 0 6 2 0 8 2 0 10 2 0 12 2 0 14 2 0
0 4 0 2 4 0 4 4 0 6 4 0 8 4 0 10 4 0 12 4 0 14 4 0'
[]
[convert]
type = ElementsToTetrahedronsConverter
input = cmb
[]
[]
(test/tests/meshgenerators/combiner_generator/combiner_multi_input.i)
[Mesh]
[gen1]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
xmin=0
xmax=1
ymin=0
ymax=1
[]
[gen2]
type = GeneratedMeshGenerator
dim = 2
nx = 12
ny = 12
xmin=2
xmax=3
ymin=2
ymax=3
[]
[gen3]
type = GeneratedMeshGenerator
dim = 2
nx = 14
ny = 14
xmin=3.5
xmax=5
ymin=3
ymax=4
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen1 gen2 gen3'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/combiner_generator/combiner_generator.i)
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen'
positions = '1 0 0 2 2 2 3 0 0'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/batch_mesh_generation_action/real_vector_value.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'TransformGenerator'
mesh_name_prefix = 'translate'
batch_scalar_input_param_names = 'vector_value'
batch_scalar_input_param_types = 'REALVECTORVALUE'
batch_scalar_input_param_values = '0 0 0 2 0 0 0 2 0 2 2 0'
fixed_scalar_input_param_names = 'input transform'
fixed_scalar_input_param_types = 'MGNAME ENUM'
fixed_scalar_input_param_values = 'gmg TRANSLATE'
[]
[]
[gmg]
type = GeneratedMeshGenerator
dim = 2
subdomain_ids = 1
[]
[cmbn]
type = CombinerGenerator
inputs = 'translate_0 translate_1 translate_2 translate_3'
[]
[]
(modules/heat_transfer/test/tests/gap_heat_transfer_radiation/sphere.i)
#
# This problem is one of radiation boundary conditions between two
# spherical surfaces.
#
# S(T1^4 - T2^4) R1^2
# flux1 = - ---------------- and flux2 = -flux1 * ----
# 1 1 - e2 R1^2 R2^2
# -- + ------ * ----
# e1 e2 R2^2
#
# where S is the Stefan Boltzmann constant 5.67e-8 W/m^2/K^4
# T1 is the temperature on the left surface 278 K
# T2 is the temperature on the right surface 333 K
# e1 is the emissivity for the left surface 0.8
# e2 is the emissivity for the left surface 0.9
# R1 is the radius of the inner surface 0.1 m
# R2 is the radius of the outer surface 0.11 m
#
# Flux1:
# Exact Code
# ------------- -------------
# -267.21 W/m^2 -267.02 W/m^2
#
# Flux2:
# Exact Code
# ------------- -------------
# 220.83 W/m^2 220.70 W/m^2
#
thick = 0.01
R1 = 0.1
R2 = 0.11
[GlobalParams]
order = second
family = lagrange
[]
[Mesh]
coord_type = RSPHERICAL
[mesh1]
type = GeneratedMeshGenerator
dim = 1
elem_type = edge3
nx = 4
xmin = '${fparse R1 - thick}'
xmax = '${R1}'
boundary_name_prefix = left
[]
[mesh2]
type = GeneratedMeshGenerator
dim = 1
elem_type = edge3
nx = 4
ny = 1
xmin = '${R2}'
xmax = '${fparse R2 + thick}'
boundary_id_offset = 4
boundary_name_prefix = right
[]
[final]
type = CombinerGenerator
inputs = 'mesh1 mesh2'
[]
[]
[Variables]
[temperature]
[]
[]
[Kernels]
[heat_conduction]
type = HeatConduction
variable = temperature
[]
[]
[BCs]
[left]
type = DirichletBC
variable = temperature
boundary = left_left
value = 278
[]
[right]
type = DirichletBC
variable = temperature
boundary = right_right
value = 333
[]
[]
[Materials]
[heat]
type = HeatConductionMaterial
thermal_conductivity = 200 # W/m/K
specific_heat = 4.2e5
[]
[]
[ThermalContact]
[thermal_contact]
type = GapHeatTransfer
variable = temperature
primary = left_right
secondary = right_left
emissivity_primary = 0.8
emissivity_secondary = 0.9
quadrature = true
gap_conductivity = 1e-40 # requires a positive value
gap_geometry_type = sphere
[]
[]
[Functions]
[analytic_flux_1]
type = ParsedFunction
symbol_names = 'S T1 T2 e1 e2 R1 R2'
symbol_values = '5.67e-8 278 333 0.8 0.9 ${R1} ${R2}'
expression = 'T14 := T1*T1*T1*T1;
T24 := T2*T2*T2*T2;
S*(T14-T24)/(1/e1+(1-e2)/e2*R1*R1/R2/R2)'
[]
[analytic_flux_2]
type = ParsedFunction
symbol_names = 'S T1 T2 e1 e2 R1 R2'
symbol_values = '5.67e-8 278 333 0.8 0.9 ${R1} ${R2}'
expression = 'T14 := T1*T1*T1*T1;
T24 := T2*T2*T2*T2;
-S*(T14-T24)/(1/e1+(1-e2)/e2*R1*R1/R2/R2)*R1*R1/R2/R2'
[]
[]
[Postprocessors]
[code_flux_1]
type = SideDiffusiveFluxAverage
variable = temperature
boundary = left_right
diffusivity = thermal_conductivity
execute_on = 'initial timestep_end'
[]
[analytic_flux_1]
type = FunctionValuePostprocessor
function = analytic_flux_1
execute_on = 'initial timestep_end'
[]
[error_1]
type = ParsedPostprocessor
pp_names = 'code_flux_1 analytic_flux_1'
expression = '(analytic_flux_1 - code_flux_1)/analytic_flux_1*100'
execute_on = 'initial timestep_end'
[]
[code_flux_2]
type = SideDiffusiveFluxAverage
variable = temperature
boundary = right_left
diffusivity = thermal_conductivity
execute_on = 'initial timestep_end'
[]
[analytic_flux_2]
type = FunctionValuePostprocessor
function = analytic_flux_2
execute_on = 'initial timestep_end'
[]
[error_2]
type = ParsedPostprocessor
pp_names = 'code_flux_2 analytic_flux_2'
expression = '(analytic_flux_2 - code_flux_2)/analytic_flux_2*100'
execute_on = 'initial timestep_end'
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
type = Transient
solve_type = newton
num_steps = 1
dt = 1
end_time = 1
nl_abs_tol = 1e-12
nl_rel_tol = 1e-10
[]
[Outputs]
csv = true
[]
(modules/heat_transfer/test/tests/thermal_materials/2d.i)
power = 2.0
rho0 = 0.0
rho1 = 1.0
TC0 = 1.0e-16
TC1 = 1.0
[Mesh]
[planet]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 1
num_sectors = 10
rings = 2
preserve_volumes = false
[]
[moon]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 0.5
num_sectors = 8
rings = 2
preserve_volumes = false
[]
[combine]
type = CombinerGenerator
inputs = 'planet moon'
positions = '0 0 0 -1.5 -0.5 0'
[]
[]
[GlobalParams]
illumination_flux = '1 1 0'
[]
[AuxVariables]
[mat_den]
family = MONOMIAL
order = CONSTANT
initial_condition = 0.1
[]
[]
[Variables]
[u]
[]
[v]
[]
[]
[Kernels]
[diff_u]
type = Diffusion
variable = u
[]
[dt_u]
type = TimeDerivative
variable = u
[]
[diff_v]
type = Diffusion
variable = v
[]
[dt_v]
type = TimeDerivative
variable = v
[]
[]
[Materials]
[thermal_compliance]
type = ThermalCompliance
temperature = u
thermal_conductivity = thermal_cond
outputs = 'exodus'
[]
[thermal_cond]
type = DerivativeParsedMaterial
expression = "A1:=(${TC0}-${TC1})/(${rho0}^${power}-${rho1}^${power}); "
"B1:=${TC0}-A1*${rho0}^${power}; TC1:=A1*mat_den^${power}+B1; TC1"
coupled_variables = 'mat_den'
property_name = thermal_cond
outputs = 'exodus'
[]
[thermal_compliance_sensitivity]
type = ThermalSensitivity
design_density = mat_den
thermal_conductivity = thermal_cond
temperature = u
outputs = 'exodus'
[]
[]
[BCs]
[flux_u]
type = DirectionalFluxBC
variable = u
boundary = outer
[]
[flux_v]
type = DirectionalFluxBC
variable = v
boundary = outer
self_shadow_uo = shadow
[]
[]
[Postprocessors]
[ave_v_all]
type = SideAverageValue
variable = v
boundary = outer
[]
[ave_v_exposed]
type = ExposedSideAverageValue
variable = v
boundary = outer
self_shadow_uo = shadow
[]
[]
[UserObjects]
[shadow]
type = SelfShadowSideUserObject
boundary = outer
execute_on = INITIAL
[]
[]
[Executioner]
type = Transient
dt = 0.1
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/batch_mesh_generation_action/double_vector_corr.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'ConcentricCircleMeshGenerator'
multi_batch_params_method = corresponding
mesh_name_prefix = 'gmg'
batch_vector_input_param_names = 'radii rings'
batch_vector_input_param_types = 'REAL UINT'
batch_vector_input_param_values = '0.8;1.0;1.2;1.4| 1;2;1;2'
fixed_scalar_input_param_names = 'has_outer_square preserve_volumes num_sectors portion'
fixed_scalar_input_param_types = 'BOOL BOOL UINT ENUM'
fixed_scalar_input_param_values = 'off off 8 top_right'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_3 gmg_2 gmg_1 gmg_0'
positions = '3 3 0
0 3 0
3 0 0
0 0 0'
[]
[]
(test/tests/meshgenerators/mesh_repair_generator/flip_element.i)
[Mesh]
[dir1]
type = ElementGenerator
nodal_positions = '0 0 0
1 0 0
0 1 0'
element_connectivity = '0 1 2'
elem_type = 'TRI3'
[]
[rename]
type = RenameBlockGenerator
input = dir1
old_block = 0
new_block = 1
[]
[dir2]
type = ElementGenerator
nodal_positions = '0 0 0
1 0 0
0 1 0'
element_connectivity = '0 2 1'
elem_type = 'TRI3'
[]
[combine]
type = CombinerGenerator
inputs = 'dir2 rename'
[]
[extrude]
type = MeshExtruderGenerator
input = combine
extrusion_vector = '0 0 1'
[]
[flip]
type = MeshRepairGenerator
input = extrude
fix_elements_orientation = true
[]
[]
[Problem]
solve = false
[]
[Executioner]
type = Steady
[]
[Postprocessors]
[vol0]
type = VolumePostprocessor
block = 0
[]
[vol1]
type = VolumePostprocessor
block = 1
[]
[]
[Outputs]
csv = true
[]
(test/tests/meshgenerators/coarsen_block_generator/coarsen_quad.i)
[Mesh]
allow_renumbering = false
[big_one]
type = GeneratedMeshGenerator
dim = 2
nx = 1
ny = 1
xmin = 1
xmax = 2
ymin = 0
ymax = 1
[]
[cut_one]
type = CartesianMeshGenerator
dim = 2
dx = 1
dy = 1
ix = 2
iy = 2
[]
[cmbn]
type = CombinerGenerator
inputs = 'big_one cut_one'
[]
[coarsen]
type = CoarsenBlockGenerator
input = cmbn
block = 0
coarsening = 1
starting_point = '0.25 0.25 0'
[]
# Stitch now as the coarsening does not stitch
[stitch]
type = MeshRepairGenerator
input = coarsen
fix_node_overlap = true
[]
[]
[Outputs]
exodus = true
[]
(test/tests/convergence/default_steady_state_convergence/base.i)
# Solves the IVPs
#
# dS/dt = CS*(S1 - S) x in (x1,x2)
# S(0) = S0
#
# dT/dt = CT*(T1 - T) x in (x3,x4)
# T(0) = T0
#
# on each node, which have the solutions
#
# S(t) = S1 + (S0 - S1) exp(-CS t)
# T(t) = T1 + (T0 - T1) exp(-CT t)
#
# Also define the aux variable:
#
# U(S) = S^2
S0 = 500.0
S1 = 300.0
CS = 100.0
T0 = 500.0
T1 = 300.0
CT = 1.0
x1 = 0
x2 = 10
x3 = 11
x4 = 13
ss_tol = 1e-6
[Mesh]
[S_meshgen]
type = GeneratedMeshGenerator
dim = 1
xmin = ${x1}
xmax = ${x2}
nx = 1
subdomain_ids = 0
subdomain_name = S_mesh
[]
[T_meshgen]
type = GeneratedMeshGenerator
dim = 1
xmin = ${x3}
xmax = ${x4}
nx = 1
subdomain_ids = 1
subdomain_name = T_mesh
[]
[combined]
type = CombinerGenerator
inputs = 'S_meshgen T_meshgen'
[]
[]
[Variables]
[S]
block = S_mesh
initial_condition = ${S0}
[]
[T]
initial_condition = ${T0}
[]
[]
[FunctorMaterials]
[S_mat]
type = ADParsedFunctorMaterial
expression = 'CS*(S1 - S)'
functor_symbols = 'CS S1 S'
functor_names = '${CS} ${S1} S'
property_name = 'S_source'
[]
[T_mat]
type = ADParsedFunctorMaterial
expression = 'CT*(T1 - T)'
functor_symbols = 'CT T1 T'
functor_names = '${CT} ${T1} T'
property_name = 'T_source'
[]
[]
[Kernels]
[S_time]
type = TimeDerivative
variable = S
[]
[S_source]
type = FunctorKernel
variable = S
functor = S_source
functor_on_rhs = true
[]
[T_time]
type = TimeDerivative
variable = T
[]
[T_source]
type = FunctorKernel
variable = T
functor = T_source
functor_on_rhs = true
[]
[]
[AuxVariables]
[U]
block = S_mesh
[]
[]
[AuxKernels]
[U_aux]
type = ParsedAux
variable = U
expression = 'S^2'
functor_names = 'S'
functor_symbols = 'S'
[]
[]
[Executioner]
type = Transient
dt = 1.0
end_time = 100.0
steady_state_detection = true
steady_state_convergence = steady_conv
solve_type = NEWTON
[]
[Postprocessors]
[num_time_steps]
type = NumTimeSteps
execute_on = 'TIMESTEP_END'
[]
[]
[Outputs]
[out]
type = CSV
execute_on = 'FINAL'
[]
[]
(test/tests/meshgenerators/parsed_element_deletion_generator/cut_the_small.i)
[Mesh]
[elem1]
type = ElementGenerator
nodal_positions = '0 0 0
1 0 0
1 1 0'
element_connectivity = '0 1 2'
elem_type = "TRI3"
[]
[elem2]
type = ElementGenerator
nodal_positions = '0 0 0
1e-2 0 0
1e-2 1e-2 0'
element_connectivity = '0 1 2'
elem_type = "TRI3"
[]
[combine]
type = CombinerGenerator
inputs = 'elem1 elem2'
[]
[delete]
type = ParsedElementDeletionGenerator
input = combine
expression = 'volume < 0.1'
[]
[]
[Problem]
solve = false
[]
[Executioner]
type = Steady
[]
[Reporters]
[mesh]
type = MeshInfo
outputs = json
items = 'num_nodes'
[]
[]
[Outputs]
[json]
type = JSON
execute_system_information_on = NONE
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/mg_sd_name.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'RenameBlockGenerator'
mesh_name_prefix = 'rbg'
fixed_scalar_input_param_names = 'input'
fixed_scalar_input_param_types = 'MGNAME'
fixed_scalar_input_param_values = 'gmg'
fixed_vector_input_param_names = 'old_block'
fixed_vector_input_param_types = 'SDNAME'
fixed_vector_input_param_values = '0'
batch_vector_input_param_names = 'new_block'
batch_vector_input_param_types = 'SDNAME'
batch_vector_input_param_values = '1;2;3;4'
[]
[]
[gmg]
type = GeneratedMeshGenerator
dim = 2
nx = 1
ny = 1
[]
[cmbn]
type = CombinerGenerator
inputs = 'rbg_0 rbg_1 rbg_2 rbg_3'
positions = '0 0 0
0 0 1
0 0 2
0 0 3'
[]
[]
(test/tests/meshgenerators/mesh_repair_generator/mixed_elements.i)
[Mesh]
[dir1]
type = ElementGenerator
nodal_positions = '0 0 0
1 0 0
0 1 0'
element_connectivity = '0 1 2'
elem_type = 'TRI3'
[]
[dir2]
type = ElementGenerator
nodal_positions = '0 0 0
1 0 0
1 1 0
0 1 0'
element_connectivity = '0 1 2 3'
elem_type = 'QUAD4'
[]
[combine]
type = CombinerGenerator
inputs = 'dir1 dir2'
[]
[separate]
type = MeshRepairGenerator
input = 'combine'
separate_blocks_by_element_types = true
[]
[]
[Problem]
solve = false
[]
[Executioner]
type = Steady
[]
[Reporters]
[mesh]
type = MeshInfo
outputs = json
items = 'subdomains'
[]
[]
[Outputs]
[json]
type = JSON
execute_system_information_on = NONE
[]
[]
(modules/reactor/test/tests/meshgenerators/azimuthal_block_split_generator/err_mixed_order.i)
[Mesh]
# The element order check is after the replicated mesh check
# So we enforce the replicated mesh here
parallel_type = REPLICATED
[gmg1]
type = GeneratedMeshGenerator
dim = 2
elem_type = QUAD4
subdomain_ids = 1
[]
[gmg2]
type = GeneratedMeshGenerator
dim = 2
xmin = 2
xmax = 3
elem_type = QUAD8
subdomain_ids = 2
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg1 gmg2'
[]
[metadata]
type = AddMetaDataGenerator
input = cmbn
uint_vector_metadata_names = 'num_sectors_per_side_meta'
uint_vector_metadata_values = '2 2 2 2'
[]
[cd_azi_define]
type = AzimuthalBlockSplitGenerator
input = metadata
start_angle = 280
angle_range = 100
old_blocks = '10 15 20'
new_block_ids = '100 150 200'
new_block_names = 'center_tri_new center_new cd_ring_new'
preserve_volumes = true
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/scalar_vector_corr.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'GeneratedMeshGenerator'
multi_batch_params_method = corresponding
mesh_name_prefix = 'gmg'
batch_scalar_input_param_names = 'nx'
batch_scalar_input_param_types = 'UINT'
batch_scalar_input_param_values = '2 3 4 5'
batch_vector_input_param_names = 'subdomain_ids'
batch_vector_input_param_types = 'USHORT'
batch_vector_input_param_values = '1;2;3;4'
fixed_scalar_input_param_names = 'dim'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = '2'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_3 gmg_2 gmg_1 gmg_0'
positions = '2 2 0
0 2 0
2 0 0
0 0 0'
[]
[]
(modules/heat_transfer/test/tests/directional_flux_bc/2d.i)
[Mesh]
[planet]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 1
num_sectors = 10
rings = 2
preserve_volumes = false
[]
[moon]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 0.5
num_sectors = 8
rings = 2
preserve_volumes = false
[]
[combine]
type = CombinerGenerator
inputs = 'planet moon'
positions = '0 0 0 -1.5 -0.5 0'
[]
[]
[GlobalParams]
illumination_flux = '1 1 0'
[]
[Variables]
[u]
[]
[v]
[]
[]
[Kernels]
[diff_u]
type = Diffusion
variable = u
[]
[dt_u]
type = TimeDerivative
variable = u
[]
[diff_v]
type = Diffusion
variable = v
[]
[dt_v]
type = TimeDerivative
variable = v
[]
[]
[BCs]
[flux_u]
type = DirectionalFluxBC
variable = u
boundary = outer
[]
[flux_v]
type = DirectionalFluxBC
variable = v
boundary = outer
self_shadow_uo = shadow
[]
[]
[Postprocessors]
[ave_v_all]
type = SideAverageValue
variable = v
boundary = outer
[]
[ave_v_exposed]
type = ExposedSideAverageValue
variable = v
boundary = outer
self_shadow_uo = shadow
[]
[]
[UserObjects]
[shadow]
type = SelfShadowSideUserObject
boundary = outer
execute_on = INITIAL
[]
[]
[Executioner]
type = Transient
dt = 0.1
num_steps = 2
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/xy_delaunay_generator/xydelaunay_from_2d_bcids.i)
[Mesh]
[left_bdy]
type = PolyLineMeshGenerator
points = '-3.0 0.0 0.0
-2.0 -1.0 0.0
-1.0 0.0 0.0
-2.0 2.0 0.0'
loop = true
[]
[right_bdy]
type = PolyLineMeshGenerator
points = '3.0 0.0 0.0
2.0 -1.0 0.0
1.0 0.0 0.0
2.0 2.0 0.0'
loop = true
[]
[left_2d]
type = XYDelaunayGenerator
boundary = 'left_bdy'
[]
[right_2d]
type = XYDelaunayGenerator
boundary = 'right_bdy'
output_boundary = 'right_outer'
[]
[both_2d]
type = CombinerGenerator
inputs = 'left_2d right_2d'
[]
[triang]
type = XYDelaunayGenerator
boundary = 'both_2d'
input_boundary_names = 'right_outer' # only the right half
refine_boundary = true
desired_area = 0.2
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/double_scalar_cp.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'GeneratedMeshGenerator'
mesh_name_prefix = 'gmg'
batch_scalar_input_param_names = 'nx ny'
batch_scalar_input_param_types = 'UINT UINT'
batch_scalar_input_param_values = '2 3; 1 2'
fixed_scalar_input_param_names = 'dim'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = '2'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_3 gmg_2 gmg_1 gmg_0'
positions = '2 2 0
0 2 0
2 0 0
0 0 0'
[]
[]
(test/tests/meshgenerators/combiner_generator/combiner_generator_from_file.i)
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen'
positions_file = 'positions.txt'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/batch_mesh_generation_action/scalar_enum_test.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'ConcentricCircleMeshGenerator'
multi_batch_params_method = corresponding
mesh_name_prefix = 'gmg'
batch_scalar_input_param_names = 'portion'
batch_scalar_input_param_types = 'ENUM'
batch_scalar_input_param_values = 'top_right top_left bottom_right bottom_left'
fixed_scalar_input_param_names = 'has_outer_square preserve_volumes num_sectors'
fixed_scalar_input_param_types = 'BOOL BOOL UINT'
fixed_scalar_input_param_values = 'off off 8'
fixed_vector_input_param_names = 'radii rings'
fixed_vector_input_param_types = 'REAL UINT'
fixed_vector_input_param_values = '1.0;1'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_0 gmg_1 gmg_2 gmg_3'
positions = '0 0 0
3 0 0
0 3 0
3 3 0'
[]
[]
(test/tests/coord_type/coord_type_rz_general.i)
# Tests using different coordinate systems in different blocks:
# block1: XYZ translated by (0,-1,0)
# block2: RZ with origin=(0,0,0) and direction=(0,1,0)
# block3: RZ with origin=(0,0,1) and direction=(1,0,0)
# block4: RZ with origin=(-1,-2,-3) and direction=(1,1,0)
#
# A transient heat conduction equation is solved with uniform properties.
# The same power is applied to each block via a uniform heat flux boundary
# condition on the outer cylindrical surface (top surface for block1).
# Conservation is checked for each via post-processors.
# Blocks block2, block3, and block4 should have identical solutions.
rho = 1000.0
cp = 500.0
k = 15.0
length = 1.5
radius = 0.5
perimeter = ${fparse 2 * pi * radius}
nz = 10
nr = 5
power = 1e3
heat_flux = ${fparse power / (perimeter * length)}
[Mesh]
# block1
[genmesh1]
type = GeneratedMeshGenerator
dim = 2
nx = ${nz}
ny = ${nr}
xmin = 0.0
xmax = ${length}
ymin = -1.0
ymax = ${fparse -1.0 + radius}
boundary_id_offset = 10
[]
[renumberblock1]
type = RenameBlockGenerator
input = genmesh1
old_block = 0
new_block = 1
[]
[renameblock1]
type = RenameBlockGenerator
input = renumberblock1
old_block = 1
new_block = block1
[]
[renameboundary1]
type = RenameBoundaryGenerator
input = renameblock1
old_boundary = '10 11 12 13'
new_boundary = 'bottom1 right1 top1 left1'
[]
# block2
[genmesh2]
type = GeneratedMeshGenerator
dim = 2
nx = ${nr}
ny = ${nz}
xmin = 0.0
xmax = ${radius}
ymin = 0
ymax = ${length}
boundary_id_offset = 20
[]
[renumberblock2]
type = RenameBlockGenerator
input = genmesh2
old_block = 0
new_block = 2
[]
[renameblock2]
type = RenameBlockGenerator
input = renumberblock2
old_block = 2
new_block = block2
[]
[renameboundary2]
type = RenameBoundaryGenerator
input = renameblock2
old_boundary = '20 21 22 23'
new_boundary = 'bottom2 right2 top2 left2'
[]
# block3
[genmesh3]
type = GeneratedMeshGenerator
dim = 2
nx = ${nz}
ny = ${nr}
xmin = 0.0
xmax = ${length}
ymin = 0
ymax = ${radius}
boundary_id_offset = 30
[]
[translate3]
type = TransformGenerator
input = genmesh3
transform = TRANSLATE
vector_value = '0 0 1'
[]
[renumberblock3]
type = RenameBlockGenerator
input = translate3
old_block = 0
new_block = 3
[]
[renameblock3]
type = RenameBlockGenerator
input = renumberblock3
old_block = 3
new_block = block3
[]
[renameboundary3]
type = RenameBoundaryGenerator
input = renameblock3
old_boundary = '30 31 32 33'
new_boundary = 'bottom3 right3 top3 left3'
[]
# block4
[genmesh4]
type = GeneratedMeshGenerator
dim = 2
nx = ${nz}
ny = ${nr}
xmin = 0.0
xmax = ${length}
ymin = 0
ymax = ${radius}
boundary_id_offset = 40
[]
[rotate4]
type = TransformGenerator
input = genmesh4
transform = ROTATE
vector_value = '45 0 0'
[]
[translate4]
type = TransformGenerator
input = rotate4
transform = TRANSLATE
vector_value = '-1 -2 -3'
[]
[renumberblock4]
type = RenameBlockGenerator
input = translate4
old_block = 0
new_block = 4
[]
[renameblock4]
type = RenameBlockGenerator
input = renumberblock4
old_block = 4
new_block = block4
[]
[renameboundary4]
type = RenameBoundaryGenerator
input = renameblock4
old_boundary = '40 41 42 43'
new_boundary = 'bottom4 right4 top4 left4'
[]
[combiner]
type = CombinerGenerator
inputs = 'renameboundary1 renameboundary2 renameboundary3 renameboundary4'
[]
coord_block = 'block1 block2 block3 block4'
coord_type = 'XYZ RZ RZ RZ'
rz_coord_blocks = 'block2 block3 block4'
rz_coord_origins = '0 0 0
0 0 1
-1 -2 -3'
rz_coord_directions = '0 1 0
1 0 0
1 1 0'
[]
[Variables]
[T]
family = LAGRANGE
order = FIRST
[]
[]
[Functions]
[T_ic_fn]
type = ParsedFunction
expression = 'x'
[]
[theoretical_energy_added_fn]
type = ParsedFunction
expression = '${power} * t'
[]
[]
[ICs]
[T_ic]
type = FunctionIC
variable = T
function = T_ic_fn
[]
[]
[Kernels]
[time_derivative]
type = ADTimeDerivative
variable = T
[]
[heat_conduction]
type = CoefDiffusion
variable = T
coef = ${fparse k / (rho * cp)}
[]
[]
[BCs]
[heat_flux_bc]
type = ADFunctionNeumannBC
variable = T
boundary = 'top1 right2 top3 top4'
# The heat conduction equation has been divided by rho*cp
function = '${fparse heat_flux / (rho * cp)}'
[]
[]
[Postprocessors]
[theoretical_energy_change]
type = FunctionValuePostprocessor
function = theoretical_energy_added_fn
execute_on = 'INITIAL TIMESTEP_END'
[]
# block1 conservation
[T_integral1]
type = ElementIntegralVariablePostprocessor
variable = T
block = 'block1'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy1]
type = ParsedPostprocessor
pp_names = 'T_integral1'
expression = 'T_integral1 * ${rho} * ${cp} * ${perimeter}'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change1]
type = ChangeOverTimePostprocessor
postprocessor = energy1
change_with_respect_to_initial = true
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change_error1]
type = RelativeDifferencePostprocessor
value1 = energy_change1
value2 = theoretical_energy_change
execute_on = 'INITIAL TIMESTEP_END'
[]
# block2 conservation
[T_integral2]
type = ElementIntegralVariablePostprocessor
variable = T
block = 'block2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy2]
type = ParsedPostprocessor
pp_names = 'T_integral2'
expression = 'T_integral2 * ${rho} * ${cp}'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change2]
type = ChangeOverTimePostprocessor
postprocessor = energy2
change_with_respect_to_initial = true
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change_error2]
type = RelativeDifferencePostprocessor
value1 = energy_change2
value2 = theoretical_energy_change
execute_on = 'INITIAL TIMESTEP_END'
[]
# block3 conservation
[T_integral3]
type = ElementIntegralVariablePostprocessor
variable = T
block = 'block3'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy3]
type = ParsedPostprocessor
pp_names = 'T_integral3'
expression = 'T_integral3 * ${rho} * ${cp}'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change3]
type = ChangeOverTimePostprocessor
postprocessor = energy3
change_with_respect_to_initial = true
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change_error3]
type = RelativeDifferencePostprocessor
value1 = energy_change3
value2 = theoretical_energy_change
execute_on = 'INITIAL TIMESTEP_END'
[]
# block4 conservation
[T_integral4]
type = ElementIntegralVariablePostprocessor
variable = T
block = 'block4'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy4]
type = ParsedPostprocessor
pp_names = 'T_integral4'
expression = 'T_integral4 * ${rho} * ${cp}'
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change4]
type = ChangeOverTimePostprocessor
postprocessor = energy4
change_with_respect_to_initial = true
execute_on = 'INITIAL TIMESTEP_END'
[]
[energy_change_error4]
type = RelativeDifferencePostprocessor
value1 = energy_change4
value2 = theoretical_energy_change
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[Preconditioning]
[pc]
type = SMP
full = true
[]
[]
[Executioner]
type = Transient
scheme = bdf2
dt = 1.0
num_steps = 10
petsc_options_iname = '-pc_type'
petsc_options_value = 'lu'
nl_rel_tol = 1e-10
[]
[Outputs]
file_base = 'coord_type_rz_general'
[console]
type = Console
show = 'energy_change_error1 energy_change_error2 energy_change_error3 energy_change_error4'
[]
[exodus]
type = Exodus
show = 'T energy_change_error1 energy_change_error2 energy_change_error3 energy_change_error4'
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/single_vector.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'GeneratedMeshGenerator'
mesh_name_prefix = 'gmg'
batch_vector_input_param_names = 'subdomain_ids'
batch_vector_input_param_types = 'USHORT'
batch_vector_input_param_values = '1;2;3;4'
fixed_scalar_input_param_names = 'dim'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = '2'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_0 gmg_1 gmg_2 gmg_3'
positions = '0 0 0
2 0 0
0 2 0
2 2 0'
[]
[]
(modules/heat_transfer/test/tests/gap_perfect_transfer/perfect_transfer_gap.i)
#
# 1-D Gap Perfect Heat Transfer
#
# The mesh consists of two element blocks containing one element each. Each
# element is a unit line. They sit next to one another with a unit between
# them.
#
# The temperature of the far left boundary is ramped from 100 to 200 over one
# second and then held fixed. The temperature of the far right boundary
# follows due to the perfect heat transfer.
#
[Mesh]
[left]
type = GeneratedMeshGenerator
dim = 1
boundary_name_prefix = left
[]
[right]
type = GeneratedMeshGenerator
dim = 1
xmin = 2
xmax = 3
boundary_name_prefix = right
boundary_id_offset = 2
[]
[right_block]
type = SubdomainIDGenerator
input = right
subdomain_id = 1
[]
[collect]
type = CombinerGenerator
inputs = 'left right_block'
[]
[]
[Functions]
[temperature]
type = PiecewiseLinear
x = '0 1 2'
y = '100 200 200'
[]
[]
[Variables]
[temperature]
order = FIRST
family = LAGRANGE
initial_condition = 100
[]
[]
[Kernels]
[heat]
type = HeatConduction
variable = temperature
[]
[]
[BCs]
[temp_far_left]
type = FunctionDirichletBC
boundary = 0
variable = temperature
function = temperature
[]
[]
[ThermalContact]
[thermal_contact_1]
type = GapPerfectConductance
penalty = 1e3
variable = temperature
primary = 1
secondary = 2
[]
[]
[Materials]
[heat1]
type = HeatConductionMaterial
block = 0
specific_heat = 1.0
thermal_conductivity = 1.0
[]
[heat2]
type = HeatConductionMaterial
block = 1
specific_heat = 1.0
thermal_conductivity = 10.0
[]
[]
[Executioner]
type = Transient
solve_type = 'PJFNK'
petsc_options_iname = '-pc_type -pc_factor_mat_solver_type'
petsc_options_value = 'lu superlu_dist'
line_search = 'none'
nl_abs_tol = 1e-8
nl_rel_tol = 1e-14
l_tol = 1e-3
l_max_its = 100
start_time = 0.0
dt = 1e-1
end_time = 2.0
num_steps = 50
[]
[Postprocessors]
[aveTempLeft]
type = SideAverageValue
boundary = 0
variable = temperature
execute_on = 'initial timestep_end'
[]
[aveTempRight]
type = SideAverageValue
boundary = 3
variable = temperature
execute_on = 'initial timestep_end'
[]
[]
[Outputs]
csv = true
[]
(modules/solid_mechanics/test/tests/umat/multiple_blocks/multiple_blocks_two_materials.i)
# Testing the UMAT Interface - linear elastic model using the large strain formulation.
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
[mesh_1]
type = GeneratedMeshGenerator
dim = 3
xmin = -0.5
xmax = 0.5
ymin = -0.5
ymax = 0.5
zmin = -0.5
zmax = 0.5
[]
[block_1]
type = SubdomainIDGenerator
input = mesh_1
subdomain_id = 1
[]
[mesh_2]
type = GeneratedMeshGenerator
dim = 3
xmin = -2.0
xmax = -1.0
ymin = -2.0
ymax = -1.0
zmin = -2.0
zmax = -1.
boundary_name_prefix = 'second'
[]
[block_2]
type = SubdomainIDGenerator
input = mesh_2
subdomain_id = 2
[]
[combined]
type = CombinerGenerator
inputs = 'block_1 block_2'
[]
[]
[Functions]
[top_pull]
type = ParsedFunction
value = t/100
[]
# Forced evolution of temperature
[temperature_load]
type = ParsedFunction
value = '273'
[]
# Factor to multiply the elasticity tensor in MOOSE
[elasticity_prefactor]
type = ParsedFunction
value = '1'
[]
[]
[AuxVariables]
[temperature]
[]
[]
[AuxKernels]
[temperature_function]
type = FunctionAux
variable = temperature
function = temperature_load
[]
[]
[Physics/SolidMechanics/QuasiStatic]
[all]
add_variables = true
strain = FINITE
generate_output = 'stress_yy'
[]
[]
[BCs]
[y_pull_function]
type = FunctionDirichletBC
variable = disp_y
boundary = top
function = top_pull
[]
[x_bot]
type = DirichletBC
variable = disp_x
boundary = left
value = 0.0
[]
[y_bot]
type = DirichletBC
variable = disp_y
boundary = bottom
value = 0.0
[]
[z_bot]
type = DirichletBC
variable = disp_z
boundary = front
value = 0.0
[]
[]
[Materials]
[umat_1]
type = AbaqusUMATStress
constant_properties = '1000 0.3'
plugin = '../../../plugins/elastic_temperature'
num_state_vars = 0
temperature = temperature
use_one_based_indexing = true
block = '1'
[]
# Linear strain hardening
[umat_2]
type = AbaqusUMATStress
# Young's modulus, Poisson's Ratio, Yield, Hardening
constant_properties = '1000 0.3 100 100'
plugin = '../../../plugins/linear_strain_hardening'
num_state_vars = 3
use_one_based_indexing = true
block = '2'
[]
[elastic]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 1000
poissons_ratio = 0.3
elasticity_tensor_prefactor = 'elasticity_prefactor'
[]
[]
[Executioner]
type = Transient
solve_type = 'PJFNK'
petsc_options = '-snes_ksp_ew'
petsc_options_iname = '-ksp_gmres_restart'
petsc_options_value = '101'
line_search = 'none'
l_max_its = 100
nl_max_its = 100
nl_rel_tol = 1e-12
nl_abs_tol = 1e-10
l_tol = 1e-9
start_time = 0.0
num_steps = 30
dt = 1.0
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Outputs]
exodus = true
[]
(modules/heat_transfer/test/tests/gap_heat_transfer_htonly/1D.i)
[GlobalParams]
order = SECOND
family = LAGRANGE
[]
[Mesh]
coord_type = RZ
[fred]
type = GeneratedMeshGenerator
dim = 1
nx = 25
xmin = 0
xmax = 1
boundary_name_prefix = left
elem_type = edge3
[]
[wilma]
type = GeneratedMeshGenerator
dim = 1
nx = 25
xmin = 2
xmax = 3
boundary_id_offset = 10
boundary_name_prefix = right
elem_type = edge3
[]
[combine]
type = CombinerGenerator
inputs = 'fred wilma'
[]
[]
[Functions]
[temp]
type = PiecewiseLinear
x = '0 1 2'
y = '100 200 200'
[]
[]
[Variables]
[temp]
initial_condition = 100
[]
[]
[Kernels]
[heat]
type = HeatConduction
variable = temp
[]
[]
[BCs]
[temp_far_left]
type = FunctionDirichletBC
boundary = left_left
variable = temp
function = temp
[]
[temp_far_right]
type = DirichletBC
boundary = right_right
variable = temp
value = 100
[]
[]
[ThermalContact]
[thermal_contact]
type = GapHeatTransfer
variable = temp
primary = right_left
secondary = left_right
emissivity_primary = 0
emissivity_secondary = 0
[]
[]
[Materials]
[heat]
type = HeatConductionMaterial
specific_heat = 1.0
thermal_conductivity = 1.0e6
[]
[]
[Executioner]
type = Transient
solve_type = 'PJFNK'
petsc_options_iname = '-ksp_gmres_restart -pc_type -pc_hypre_type -pc_hypre_boomeramg_max_iter'
petsc_options_value = '201 hypre boomeramg 4'
line_search = 'none'
nl_abs_tol = 1e-3
nl_rel_tol = 1e-12
l_tol = 1e-8
l_max_its = 100
start_time = 0.0
dt = 2e-1
end_time = 2.0
[]
[Postprocessors]
[temp_left]
type = SideAverageValue
boundary = left_right
variable = temp
execute_on = 'initial timestep_end'
[]
[temp_right]
type = SideAverageValue
boundary = right_left
variable = temp
execute_on = 'initial timestep_end'
[]
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate.i)
[Mesh]
[gen1]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[gen2]
type = GeneratedMeshGenerator
dim = 2
nx = 12
ny = 12
[]
[gen3]
type = GeneratedMeshGenerator
dim = 2
nx = 14
ny = 14
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen1 gen2 gen3'
positions = '1 0 0 2 2 2 3 0 0'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/batch_mesh_generation_action/double_scalar_corr.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'GeneratedMeshGenerator'
multi_batch_params_method = corresponding
mesh_name_prefix = 'gmg'
batch_scalar_input_param_names = 'nx ny'
batch_scalar_input_param_types = 'UINT UINT'
batch_scalar_input_param_values = '2 3 4 5; 1 2 3 4'
fixed_scalar_input_param_names = 'dim'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = '2'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_3 gmg_2 gmg_1 gmg_0'
positions = '2 2 0
0 2 0
2 0 0
0 0 0'
[]
[]
(modules/solid_mechanics/test/tests/umat/multiple_blocks/multiple_blocks_two_materials_parallel.i)
# Testing the UMAT Interface - linear elastic model using the large strain formulation.
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
[mesh_1]
type = GeneratedMeshGenerator
dim = 3
xmin = -0.5
xmax = 0.5
ymin = -0.5
ymax = 0.5
zmin = -0.5
zmax = 0.5
nx = 2
ny = 2
nz = 2
[]
[block_1]
type = SubdomainIDGenerator
input = mesh_1
subdomain_id = 1
[]
[mesh_2]
type = GeneratedMeshGenerator
dim = 3
xmin = -2.0
xmax = -1.0
ymin = -2.0
ymax = -1.0
zmin = -2.0
zmax = -1.0
nx = 2
ny = 2
nz = 2
boundary_name_prefix = 'second'
[]
[block_2]
type = SubdomainIDGenerator
input = mesh_2
subdomain_id = 2
[]
[combined]
type = CombinerGenerator
inputs = 'block_1 block_2'
[]
[]
[Functions]
[top_pull]
type = ParsedFunction
expression = t/100
[]
# Forced evolution of temperature
[temperature_load]
type = ParsedFunction
expression = '273'
[]
# Factor to multiply the elasticity tensor in MOOSE
[elasticity_prefactor]
type = ParsedFunction
expression = '1'
[]
[]
[AuxVariables]
[temperature]
[]
[]
[AuxKernels]
[temperature_function]
type = FunctionAux
variable = temperature
function = temperature_load
[]
[]
[Physics/SolidMechanics/QuasiStatic]
[all]
add_variables = true
strain = FINITE
generate_output = 'stress_yy'
[]
[]
[BCs]
[y_pull_function]
type = FunctionDirichletBC
variable = disp_y
boundary = top
function = top_pull
[]
[x_bot]
type = DirichletBC
variable = disp_x
boundary = left
value = 0.0
[]
[y_bot]
type = DirichletBC
variable = disp_y
boundary = bottom
value = 0.0
[]
[z_bot]
type = DirichletBC
variable = disp_z
boundary = front
value = 0.0
[]
[]
[Materials]
[umat_1]
type = AbaqusUMATStress
constant_properties = '1000 0.3'
plugin = '../../../plugins/elastic_temperature'
num_state_vars = 0
temperature = temperature
use_one_based_indexing = true
block = '1'
[]
# Linear strain hardening
[umat_2]
type = AbaqusUMATStress
# Young's modulus, Poisson's Ratio, Yield, Hardening
constant_properties = '1000 0.3 100 100'
plugin = '../../../plugins/linear_strain_hardening'
num_state_vars = 3
use_one_based_indexing = true
block = '2'
[]
[elastic]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 1000
poissons_ratio = 0.3
elasticity_tensor_prefactor = 'elasticity_prefactor'
[]
[]
[Executioner]
type = Transient
solve_type = 'PJFNK'
petsc_options = '-snes_ksp_ew'
petsc_options_iname = '-ksp_gmres_restart'
petsc_options_value = '101'
line_search = 'none'
l_max_its = 100
nl_max_its = 100
nl_rel_tol = 1e-12
nl_abs_tol = 1e-10
l_tol = 1e-9
start_time = 0.0
num_steps = 30
dt = 1.0
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/mesh_diagnostics_generator/node_based_test.i)
[Mesh]
[copy1]
type = ElementGenerator
nodal_positions = '0 0 0
0 2 0
2 2 0
2 0 0'
element_connectivity = '0 1 2 3'
elem_type = 'QUAD4'
[]
[gen]
input = copy1
type = RenameBlockGenerator
old_block = "0"
new_block = "1"
[]
[copy2]
type = ElementGenerator
nodal_positions = '0 3 0
0 2 0
1 1 0
2 3 0'
element_connectivity = '0 1 2 3'
elem_type = 'QUAD4'
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen copy2'
[]
[diag]
type = MeshDiagnosticsGenerator
input = cmbn
examine_element_overlap = INFO
[]
[]
[Outputs]
exodus = true
[]
(modules/heat_transfer/test/tests/directional_flux_bc/3d_elem.i)
[Mesh]
[shade]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 3
nz = 3
xmax = 0.2
ymax = 0.5
zmax = 0.5
[]
[screen]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 20
nz = 20
xmax = 0.05
[]
[screen_block]
type = SubdomainIDGenerator
input = screen
subdomain_id = 1
[]
[combine]
type = CombinerGenerator
inputs = 'shade screen_block'
positions = '0 0 0 1 0 0'
[]
[all_sides]
type = SideSetsAroundSubdomainGenerator
block = '0 1'
new_boundary = 100
input = combine
[]
[shaded_side]
type = SideSetsAroundSubdomainGenerator
normal = '-1 0 0'
block = 1
input = all_sides
new_boundary = 101
[]
[]
[GlobalParams]
illumination_flux = '1 0 0'
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[dt]
type = TimeDerivative
variable = u
[]
[]
[BCs]
[flux]
type = DirectionalFluxBC
variable = u
boundary = 101
self_shadow_uo = shadow
[]
[]
[UserObjects]
[shadow]
type = SelfShadowSideUserObject
boundary = 100
execute_on = INITIAL
[]
[]
[Postprocessors]
[light]
type = SideIntegralVariablePostprocessor
variable = u
boundary = 101
[]
[]
[Executioner]
type = Transient
dt = 0.01
num_steps = 1
[]
[Outputs]
csv = true
[]
(test/tests/meshgenerators/mesh_diagnostics_generator/elem_types_test.i)
[Mesh]
[copy1]
type = ElementGenerator
nodal_positions = '0 0 0
2 2 0
2 0 0'
element_connectivity = '0 1 2'
elem_type = 'TRI3'
[]
[copy2]
type = ElementGenerator
nodal_positions = '0 1 0
0 3 0
2 3 0
2 1 0'
element_connectivity = '0 1 2 3'
elem_type = 'QUAD4'
[]
[cmbn]
type = CombinerGenerator
inputs = 'copy1 copy2'
[]
[diag]
type = MeshDiagnosticsGenerator
input = cmbn
examine_element_types = INFO
[]
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/coarsen_block_generator/coarsen_hex.i)
[Mesh]
allow_renumbering = false
[big_one]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 1
nz = 1
xmin = 1
xmax = 2
ymin = 0
ymax = 1
zmin = 0
zmax = 1
[]
[cut_one]
type = CartesianMeshGenerator
dim = 3
dx = 1
dy = 1
dz = 1
ix = 2
iy = 2
iz = 2
[]
[cmbn]
type = CombinerGenerator
inputs = 'big_one cut_one'
[]
[coarsen]
type = CoarsenBlockGenerator
input = cmbn
block = 0
coarsening = 1
starting_point = '0.25 0.25 0.1'
[]
# Stitch now as the coarsening does not stitch
[stitch]
type = MeshRepairGenerator
input = coarsen
fix_node_overlap = true
[]
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/batch_mesh_generation_action/scalar_vector_cp.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'GeneratedMeshGenerator'
multi_batch_params_method = cartesian_product
mesh_name_prefix = 'gmg'
batch_scalar_input_param_names = 'nx'
batch_scalar_input_param_types = 'UINT'
batch_scalar_input_param_values = '2 3'
batch_vector_input_param_names = 'subdomain_ids'
batch_vector_input_param_types = 'USHORT'
batch_vector_input_param_values = '1;2'
fixed_scalar_input_param_names = 'dim'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = '2'
use_decomposed_index = true
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_1_1 gmg_0_1 gmg_1_0 gmg_0_0'
positions = '2 2 0
0 2 0
2 0 0
0 0 0'
[]
[]
(modules/heat_transfer/test/tests/gap_heat_transfer_radiation/cylinder.i)
#
# This problem is one of radiation boundary conditions between two
# cylindrical surfaces.
#
# S(T1^4 - T2^4) R1
# flux1 = - ---------------- and flux2 = -flux1 * --
# 1 1 - e2 R1 R2
# -- + ------ * --
# e1 e2 R2
#
# where S is the Stefan Boltzmann constant 5.67e-8 W/m^2/K^4
# T1 is the temperature on the left surface 278 K
# T2 is the temperature on the right surface 333 K
# e1 is the emissivity for the left surface 0.8
# e2 is the emissivity for the left surface 0.9
# R1 is the radius of the inner surface 0.1 m
# R2 is the radius of the outer surface 0.11 m
#
# Flux1:
# Exact Code
# ------------- -------------
# -265.29 W/m^2 -265.26 W/m^2
#
# Flux2:
# Exact Code
# ------------- -------------
# 241.26 W/m^2 241.15 W/m^2
#
thick = 0.01
R1 = 0.1
R2 = 0.11
[GlobalParams]
order = second
family = lagrange
[]
[Mesh]
coord_type = RZ
[mesh1]
type = GeneratedMeshGenerator
dim = 2
elem_type = quad8
nx = 4
ny = 1
xmin = '${fparse R1 - thick}'
xmax = '${R1}'
ymin = 0
ymax = '${R1}'
boundary_name_prefix = left
[]
[mesh2]
type = GeneratedMeshGenerator
dim = 2
elem_type = quad8
nx = 4
ny = 1
xmin = '${R2}'
xmax = '${fparse R2 + thick}'
ymin = 0
ymax = '${R1}'
boundary_id_offset = 4
boundary_name_prefix = right
[]
[final]
type = CombinerGenerator
inputs = 'mesh1 mesh2'
[]
[]
[Variables]
[temperature]
[]
[]
[Kernels]
[heat_conduction]
type = HeatConduction
variable = temperature
[]
[]
[BCs]
[left]
type = DirichletBC
variable = temperature
boundary = left_left
value = 278
[]
[right]
type = DirichletBC
variable = temperature
boundary = right_right
value = 333
[]
[]
[Materials]
[heat]
type = HeatConductionMaterial
thermal_conductivity = 200 # W/m/K
specific_heat = 4.2e5
[]
[]
[ThermalContact]
[thermal_contact]
type = GapHeatTransfer
variable = temperature
primary = left_right
secondary = right_left
emissivity_primary = 0.8
emissivity_secondary = 0.9
quadrature = true
gap_conductivity = 1e-40 # requires a positive value
gap_geometry_type = cylinder
[]
[]
[Functions]
[analytic_flux_1]
type = ParsedFunction
symbol_names = 'S T1 T2 e1 e2 R1 R2'
symbol_values = '5.67e-8 278 333 0.8 0.9 ${R1} ${R2}'
expression = 'T14 := T1*T1*T1*T1;
T24 := T2*T2*T2*T2;
S*(T14-T24)/(1/e1+(1-e2)/e2*R1/R2)'
[]
[analytic_flux_2]
type = ParsedFunction
symbol_names = 'S T1 T2 e1 e2 R1 R2'
symbol_values = '5.67e-8 278 333 0.8 0.9 ${R1} ${R2}'
expression = 'T14 := T1*T1*T1*T1;
T24 := T2*T2*T2*T2;
-S*(T14-T24)/(1/e1+(1-e2)/e2*R1/R2)*R1/R2'
[]
[]
[Postprocessors]
[code_flux_1]
type = SideDiffusiveFluxAverage
variable = temperature
boundary = left_right
diffusivity = thermal_conductivity
execute_on = 'initial timestep_end'
[]
[analytic_flux_1]
type = FunctionValuePostprocessor
function = analytic_flux_1
execute_on = 'initial timestep_end'
[]
[error_1]
type = ParsedPostprocessor
pp_names = 'code_flux_1 analytic_flux_1'
expression = '(analytic_flux_1 - code_flux_1)/analytic_flux_1*100'
execute_on = 'initial timestep_end'
[]
[code_flux_2]
type = SideDiffusiveFluxAverage
variable = temperature
boundary = right_left
diffusivity = thermal_conductivity
execute_on = 'initial timestep_end'
[]
[analytic_flux_2]
type = FunctionValuePostprocessor
function = analytic_flux_2
execute_on = 'initial timestep_end'
[]
[error_2]
type = ParsedPostprocessor
pp_names = 'code_flux_2 analytic_flux_2'
expression = '(analytic_flux_2 - code_flux_2)/analytic_flux_2*100'
execute_on = 'initial timestep_end'
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
type = Transient
solve_type = newton
num_steps = 1
dt = 1
end_time = 1
nl_abs_tol = 1e-12
nl_rel_tol = 1e-10
[]
[Outputs]
csv = true
[]
(test/tests/meshgenerators/batch_mesh_generation_action/mg_bdry_name.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'RenameBoundaryGenerator'
mesh_name_prefix = 'rbg'
fixed_scalar_input_param_names = 'input'
fixed_scalar_input_param_types = 'MGNAME'
fixed_scalar_input_param_values = 'gmg'
fixed_vector_input_param_names = 'old_boundary'
fixed_vector_input_param_types = 'BDRYNAME'
fixed_vector_input_param_values = 'bottom right top left'
batch_vector_input_param_names = 'new_boundary'
batch_vector_input_param_types = 'BDRYNAME'
batch_vector_input_param_values = 'b0 r0 t0 l0;b1 r1 t1 l1;b2 r2 t2 l2;b3 r3 t3 l3'
[]
[]
[gmg]
type = GeneratedMeshGenerator
dim = 2
nx = 1
ny = 1
[]
[cmbn]
type = CombinerGenerator
inputs = 'rbg_0 rbg_1 rbg_2 rbg_3'
avoid_merging_boundaries = true
positions = '0 0 0
0 0 1
0 0 2
0 0 3'
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/single_scalar.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'GeneratedMeshGenerator'
mesh_name_prefix = 'gmg'
batch_scalar_input_param_names = 'nx'
batch_scalar_input_param_types = 'UINT'
batch_scalar_input_param_values = '2 3 4 5'
fixed_scalar_input_param_names = 'dim'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = '2'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'gmg_3 gmg_2 gmg_1 gmg_0'
positions = '2 2 0
0 2 0
2 0 0
0 0 0'
[]
[]
(test/tests/meshgenerators/mesh_diagnostics_generator/detect_amr_hex.i)
[Mesh]
[big_one]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 1
nz = 1
xmin = 1
xmax = 2
ymin = 0
ymax = 1
zmin = 0
zmax = 1
[]
[cut_one]
type = GeneratedMeshGenerator
dim = 3
xmax = 1
ymax = 1
zmax = 1
nx = 2
ny = 2
nz = 2
[]
[cmbn]
type = CombinerGenerator
inputs = 'big_one cut_one'
[]
[diag]
type = MeshDiagnosticsGenerator
input = cmbn
search_for_adaptivity_nonconformality = INFO
[]
[]
[Outputs]
exodus = true
[]
(modules/optimization/test/tests/simp/2d_twoconstraints.i)
cost_frac = 0.3
vol_frac = 0.2
[Mesh]
[planet]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 1
num_sectors = 10
rings = 2
preserve_volumes = false
[]
[moon]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 0.5
num_sectors = 8
rings = 2
preserve_volumes = false
[]
[combine]
type = CombinerGenerator
inputs = 'planet moon'
positions = '0 0 0 -1.5 -0.5 0'
[]
[]
[AuxVariables]
[mat_den]
family = MONOMIAL
order = CONSTANT
initial_condition = 0.1
[]
[Dc]
family = MONOMIAL
order = CONSTANT
initial_condition = -1.0
[]
[Cc]
family = MONOMIAL
order = CONSTANT
initial_condition = -1.0
[]
[Cost]
family = MONOMIAL
order = CONSTANT
initial_condition = 1.0
[]
[]
[Variables]
[u]
[]
[v]
[]
[]
[Kernels]
[diff_u]
type = Diffusion
variable = u
[]
[dt_u]
type = TimeDerivative
variable = u
[]
[diff_v]
type = Diffusion
variable = v
[]
[dt_v]
type = TimeDerivative
variable = v
[]
[]
[Materials]
[thermal_cond]
type = GenericFunctionMaterial
prop_values = '-1.4*abs(y)-2.7*abs(x)'
prop_names = thermal_cond
outputs = 'exodus'
[]
[thermal_compliance_sensitivity]
type = GenericFunctionMaterial
prop_values = '-3*abs(y)-1.5*abs(x)'
prop_names = thermal_sensitivity
outputs = 'exodus'
[]
[cost_sensitivity]
type = GenericFunctionMaterial
prop_values = '-0.3*y*y-0.5*abs(x*y)'
prop_names = cost_sensitivity
outputs = 'exodus'
[]
[cost_sensitivity_parsed]
type = DerivativeParsedMaterial
expression = "if(mat_den<0.2,1.0,0.5)"
coupled_variables = 'mat_den'
property_name = cost_sensitivity_parsed
[]
[cc]
type = CostSensitivity
design_density = mat_den
cost = cost_sensitivity_parsed
outputs = 'exodus'
declare_suffix = 'for_testing'
[]
[]
[BCs]
[flux_u]
type = DirichletBC
variable = u
boundary = outer
value = 3.0
[]
[flux_v]
type = DirichletBC
variable = v
boundary = outer
value = 7.0
[]
[]
[UserObjects]
[rad_avg]
type = RadialAverage
radius = 0.1
weights = linear
prop_name = thermal_sensitivity
execute_on = TIMESTEP_END
force_preaux = true
[]
[rad_avg_cost]
type = RadialAverage
radius = 1.2
weights = linear
prop_name = cost_sensitivity
execute_on = TIMESTEP_END
force_preaux = true
[]
[update]
type = DensityUpdateTwoConstraints
density_sensitivity = Dc
cost_density_sensitivity = Cc
cost = Cost
cost_fraction = ${cost_frac}
design_density = mat_den
volume_fraction = ${vol_frac}
bisection_lower_bound = 0
bisection_upper_bound = 1.0e16
relative_tolerance = 1.0e-3
bisection_move = 0.15
execute_on = TIMESTEP_BEGIN
[]
[calc_sense]
type = SensitivityFilter
density_sensitivity = Dc
design_density = mat_den
filter_UO = rad_avg
execute_on = TIMESTEP_END
force_postaux = true
[]
[calc_sense_cost]
type = SensitivityFilter
density_sensitivity = Cc
design_density = mat_den
filter_UO = rad_avg_cost
execute_on = TIMESTEP_END
force_postaux = true
[]
[]
[Executioner]
type = Transient
dt = 0.1
num_steps = 3
nl_rel_tol = 1e-04
[]
[Outputs]
exodus = true
[]
(modules/optimization/test/tests/simp/2d.i)
vol_frac = 0.2
[Mesh]
[planet]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 1
num_sectors = 10
rings = 2
preserve_volumes = false
[]
[moon]
type = ConcentricCircleMeshGenerator
has_outer_square = false
radii = 0.5
num_sectors = 8
rings = 2
preserve_volumes = false
[]
[combine]
type = CombinerGenerator
inputs = 'planet moon'
positions = '0 0 0 -1.5 -0.5 0'
[]
[]
[AuxVariables]
[mat_den]
family = MONOMIAL
order = CONSTANT
initial_condition = 0.1
[]
[Dc]
family = MONOMIAL
order = CONSTANT
initial_condition = -1.0
[]
[]
[Variables]
[u]
[]
[v]
[]
[]
[Kernels]
[diff_u]
type = Diffusion
variable = u
[]
[dt_u]
type = TimeDerivative
variable = u
[]
[diff_v]
type = Diffusion
variable = v
[]
[dt_v]
type = TimeDerivative
variable = v
[]
[]
[Materials]
[thermal_cond]
type = GenericFunctionMaterial
prop_values = '-1.4*abs(y)-2.7*abs(x)'
prop_names = thermal_cond
outputs = 'exodus'
[]
[thermal_compliance_sensitivity]
type = GenericFunctionMaterial
prop_values = '-3*abs(y)-1.5*abs(x)'
prop_names = thermal_sensitivity
outputs = 'exodus'
[]
[]
[BCs]
[flux_u]
type = DirichletBC
variable = u
boundary = outer
value = 3.0
[]
[flux_v]
type = DirichletBC
variable = v
boundary = outer
value = 7.0
[]
[]
[UserObjects]
[rad_avg]
type = RadialAverage
radius = 0.1
weights = linear
prop_name = thermal_sensitivity
execute_on = TIMESTEP_END
force_preaux = true
[]
[update]
type = DensityUpdate
density_sensitivity = Dc
design_density = mat_den
volume_fraction = ${vol_frac}
execute_on = TIMESTEP_BEGIN
[]
[calc_sense]
type = SensitivityFilter
density_sensitivity = Dc
design_density = mat_den
filter_UO = rad_avg
execute_on = TIMESTEP_END
force_postaux = true
[]
[]
[Executioner]
type = Transient
dt = 0.1
num_steps = 15
nl_rel_tol = 1e-04
[]
[Outputs]
exodus = true
[]
(modules/heat_transfer/test/tests/directional_flux_bc/3d.i)
[Mesh]
[planet]
type = SphereMeshGenerator
radius = 1
nr = 2 # increase for a better visualization
[]
[moon]
type = SphereMeshGenerator
radius = 0.3
nr = 1 # increase for a better visualization
[]
[combine]
type = CombinerGenerator
inputs = 'planet moon'
positions = '0 0 0 -1.2 -1 -1'
[]
[]
[GlobalParams]
illumination_flux = '1 1 1'
[]
[Variables]
[u]
[]
[v]
[]
[]
[Kernels]
[diff_u]
type = Diffusion
variable = u
[]
[dt_u]
type = TimeDerivative
variable = u
[]
[diff_v]
type = Diffusion
variable = v
[]
[dt_v]
type = TimeDerivative
variable = v
[]
[]
[BCs]
[flux_u]
type = DirectionalFluxBC
variable = u
boundary = 0
[]
[flux_v]
type = DirectionalFluxBC
variable = v
boundary = 0
self_shadow_uo = shadow
[]
[]
[Postprocessors]
[ave_v_all]
type = SideAverageValue
variable = v
boundary = 0
[]
[ave_v_exposed]
type = ExposedSideAverageValue
variable = v
boundary = 0
self_shadow_uo = shadow
[]
[]
[UserObjects]
[shadow]
type = SelfShadowSideUserObject
boundary = 0
execute_on = INITIAL
[]
[]
[Executioner]
type = Transient
dt = 0.1
num_steps = 1
[]
[Outputs]
[out]
type = Exodus
execute_on = FINAL
[]
[]
(test/tests/meshgenerators/elem_order_conversion_generator/order_conversion.i)
[Mesh]
[gen_1d_edge2]
type = GeneratedMeshGenerator
dim = 1
elem_type = EDGE2
subdomain_ids = '1'
boundary_id_offset = 0
boundary_name_prefix = 'gen_1d_edge2'
[]
[gen_1d_edge3]
type = GeneratedMeshGenerator
dim = 1
xmin = 2
xmax = 3
elem_type = EDGE3
subdomain_ids = '2'
boundary_id_offset = 10
boundary_name_prefix = 'gen_1d_edge3'
[]
[gen_2d_tri3]
type = GeneratedMeshGenerator
dim = 2
ymin = 2
ymax = 3
elem_type = TRI3
subdomain_ids = '3'
boundary_id_offset = 20
boundary_name_prefix = 'gen_2d_tri3'
[]
[gen_2d_tri6]
type = GeneratedMeshGenerator
dim = 2
xmin = 2
xmax = 3
ymin = 2
ymax = 3
elem_type = TRI6
subdomain_ids = '4'
boundary_id_offset = 30
boundary_name_prefix = 'gen_2d_tri6'
[]
[gen_2d_tri7]
type = GeneratedMeshGenerator
dim = 2
xmin = 4
xmax = 5
ymin = 2
ymax = 3
elem_type = TRI7
subdomain_ids = '5'
boundary_id_offset = 40
boundary_name_prefix = 'gen_2d_tri7'
[]
[gen_2d_quad4]
type = GeneratedMeshGenerator
dim = 2
ymin = 4
ymax = 5
elem_type = QUAD4
subdomain_ids = '6'
boundary_id_offset = 50
boundary_name_prefix = 'gen_2d_quad4'
[]
[gen_2d_quad8]
type = GeneratedMeshGenerator
dim = 2
xmin = 2
xmax = 3
ymin = 4
ymax = 5
elem_type = QUAD8
subdomain_ids = '7'
boundary_id_offset = 60
boundary_name_prefix = 'gen_2d_quad8'
[]
[gen_2d_quad9]
type = GeneratedMeshGenerator
dim = 2
xmin = 4
xmax = 5
ymin = 4
ymax = 5
elem_type = QUAD9
subdomain_ids = '8'
boundary_id_offset = 70
boundary_name_prefix = 'gen_2d_quad9'
[]
[gen_3d_hex8]
type = GeneratedMeshGenerator
dim = 3
ymin = 6
ymax = 7
elem_type = HEX8
subdomain_ids = '9'
boundary_id_offset = 80
boundary_name_prefix = 'gen_3d_hex8'
[]
[gen_3d_hex20]
type = GeneratedMeshGenerator
dim = 3
xmin = 2
xmax = 3
ymin = 6
ymax = 7
elem_type = HEX20
subdomain_ids = '10'
boundary_id_offset = 90
boundary_name_prefix = 'gen_3d_hex20'
[]
[gen_3d_hex27]
type = GeneratedMeshGenerator
dim = 3
xmin = 4
xmax = 5
ymin = 6
ymax = 7
elem_type = HEX27
subdomain_ids = '11'
boundary_id_offset = 100
boundary_name_prefix = 'gen_3d_hex27'
[]
[gen_3d_tet4]
type = GeneratedMeshGenerator
dim = 3
ymin = 8
ymax = 9
elem_type = TET4
subdomain_ids = '12'
boundary_id_offset = 110
boundary_name_prefix = 'gen_3d_tet4'
[]
[gen_3d_tet10]
type = GeneratedMeshGenerator
dim = 3
xmin = 2
xmax = 3
ymin = 8
ymax = 9
elem_type = TET10
subdomain_ids = '13'
boundary_id_offset = 120
boundary_name_prefix = 'gen_3d_tet10'
[]
[gen_3d_tet14]
type = GeneratedMeshGenerator
dim = 3
xmin = 4
xmax = 5
ymin = 8
ymax = 9
elem_type = TET14
subdomain_ids = '14'
boundary_id_offset = 130
boundary_name_prefix = 'gen_3d_tet14'
[]
[gen_3d_prism6]
type = GeneratedMeshGenerator
dim = 3
ymin = 10
ymax = 11
elem_type = PRISM6
subdomain_ids = '15'
boundary_id_offset = 140
boundary_name_prefix = 'gen_3d_prism6'
[]
[gen_3d_prism15]
type = GeneratedMeshGenerator
dim = 3
xmin = 2
xmax = 3
ymin = 10
ymax = 11
elem_type = PRISM15
subdomain_ids = '16'
boundary_id_offset = 150
boundary_name_prefix = 'gen_3d_prism15'
[]
[gen_3d_prism18]
type = GeneratedMeshGenerator
dim = 3
xmin = 4
xmax = 5
ymin = 10
ymax = 11
elem_type = PRISM18
subdomain_ids = '17'
boundary_id_offset = 160
boundary_name_prefix = 'gen_3d_prism18'
[]
[gen_3d_pyramid5]
type = GeneratedMeshGenerator
dim = 3
ymin = 12
ymax = 13
elem_type = PYRAMID5
subdomain_ids = '18'
boundary_id_offset = 170
boundary_name_prefix = 'gen_3d_pyramid5'
[]
[gen_3d_pyramid13]
type = GeneratedMeshGenerator
dim = 3
xmin = 2
xmax = 3
ymin = 12
ymax = 13
elem_type = PYRAMID13
subdomain_ids = '19'
boundary_id_offset = 180
boundary_name_prefix = 'gen_3d_pyramid13'
[]
[gen_3d_pyramid14]
type = GeneratedMeshGenerator
dim = 3
xmin = 4
xmax = 5
ymin = 12
ymax = 13
elem_type = PYRAMID14
subdomain_ids = '20'
boundary_id_offset = 190
boundary_name_prefix = 'gen_3d_pyramid14'
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen_1d_edge2 gen_1d_edge3
gen_2d_tri3 gen_2d_tri6 gen_2d_tri7
gen_2d_quad4 gen_2d_quad8 gen_2d_quad9
gen_3d_hex8 gen_3d_hex20 gen_3d_hex27
gen_3d_tet4 gen_3d_tet10 gen_3d_tet14
gen_3d_prism6 gen_3d_prism15 gen_3d_prism18
gen_3d_pyramid5 gen_3d_pyramid13 gen_3d_pyramid14'
[]
[order_conversion]
type = ElementOrderConversionGenerator
input = cmbn
conversion_type = FIRST_ORDER
[]
[]
(test/tests/meshgenerators/batch_mesh_generation_action/vector_point.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'ElementGenerator'
mesh_name_prefix = 'eg'
batch_vector_input_param_names = 'nodal_positions'
batch_vector_input_param_types = 'POINT'
batch_vector_input_param_values = '0 0 0 1 0 0 1 1 0;
2 0 0 3 0 0 3 1 0;
1 2 0 2 2 0 2 3 0'
fixed_scalar_input_param_names = 'elem_type'
fixed_scalar_input_param_types = 'ENUM'
fixed_scalar_input_param_values = 'TRI3'
fixed_vector_input_param_names = 'element_connectivity'
fixed_vector_input_param_types = 'DOFIDTYPE'
fixed_vector_input_param_values = '0 1 2'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'eg_0 eg_1 eg_2'
[]
[]
(modules/solid_mechanics/test/tests/umat/multiple_blocks/multiple_blocks.i)
# Testing the UMAT Interface - linear elastic model using the large strain formulation.
[GlobalParams]
displacements = 'disp_x disp_y disp_z'
[]
[Mesh]
[mesh_1]
type = GeneratedMeshGenerator
dim = 3
xmin = -0.5
xmax = 0.5
ymin = -0.5
ymax = 0.5
zmin = -0.5
zmax = 0.5
[]
[block_1]
type = SubdomainIDGenerator
input = mesh_1
subdomain_id = 1
[]
[mesh_2]
type = GeneratedMeshGenerator
dim = 3
xmin = -2.0
xmax = -1.0
ymin = -2.0
ymax = -1.0
zmin = -2.0
zmax = -1.
boundary_name_prefix = 'second'
[]
[block_2]
type = SubdomainIDGenerator
input = mesh_2
subdomain_id = 2
[]
[combined]
type = CombinerGenerator
inputs = 'block_1 block_2'
[]
[]
[Functions]
[top_pull]
type = ParsedFunction
value = t/100
[]
# Forced evolution of temperature
[temperature_load]
type = ParsedFunction
value = '273 + 10*t'
[]
# Factor to multiply the elasticity tensor in MOOSE
[elasticity_prefactor]
type = ParsedFunction
value = '273/(273 + 10*t)'
[]
[]
[AuxVariables]
[temperature]
[]
[]
[AuxKernels]
[temperature_function]
type = FunctionAux
variable = temperature
function = temperature_load
[]
[]
[Physics/SolidMechanics/QuasiStatic]
[all]
add_variables = true
strain = FINITE
generate_output = 'stress_yy'
[]
[]
[BCs]
[y_pull_function]
type = FunctionDirichletBC
variable = disp_y
boundary = top
function = top_pull
[]
[x_bot]
type = DirichletBC
variable = disp_x
boundary = left
value = 0.0
[]
[y_bot]
type = DirichletBC
variable = disp_y
boundary = bottom
value = 0.0
[]
[z_bot]
type = DirichletBC
variable = disp_z
boundary = front
value = 0.0
[]
[]
[Materials]
[umat_1]
type = AbaqusUMATStress
constant_properties = '1000 0.3'
plugin = '../../../plugins/elastic_temperature'
num_state_vars = 0
temperature = temperature
use_one_based_indexing = true
block = '1'
[]
[umat_2]
type = AbaqusUMATStress
constant_properties = '10000 0.3'
plugin = '../../../plugins/elastic_temperature'
num_state_vars = 0
temperature = temperature
use_one_based_indexing = true
block = '2'
[]
[elastic]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 1000
poissons_ratio = 0.3
elasticity_tensor_prefactor = 'elasticity_prefactor'
[]
[]
[Executioner]
type = Transient
solve_type = 'PJFNK'
petsc_options = '-snes_ksp_ew'
petsc_options_iname = '-ksp_gmres_restart'
petsc_options_value = '101'
line_search = 'none'
l_max_its = 100
nl_max_its = 100
nl_rel_tol = 1e-12
nl_abs_tol = 1e-10
l_tol = 1e-9
start_time = 0.0
num_steps = 30
dt = 1.0
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Outputs]
exodus = true
[]
(modules/contact/test/tests/verification/patch_tests/automatic_patch_update/iteration_adaptivity_parallel.i)
[GlobalParams]
order = FIRST
family = LAGRANGE
displacements = 'disp_x disp_y'
volumetric_locking_correction = true
[]
[Mesh]
coord_type = XYZ
patch_update_strategy = iteration
patch_size = 8
ghosting_patch_size = 20
[cube1]
type = GeneratedMeshGenerator
dim = 2
boundary_name_prefix = cube1
xmax = 1
ymax = 1
nx = 2
ny = 2
[]
[cube2]
type = GeneratedMeshGenerator
dim = 2
boundary_name_prefix = cube2
boundary_id_offset = 5
xmax = 1
ymax = 1
nx = 2
ny = 2
[]
[block_id]
type = SubdomainIDGenerator
input = cube2
subdomain_id = 2
[]
[combine]
inputs = 'cube1 block_id'
type = CombinerGenerator
positions = '0 0 0
0 1 0'
[]
[rename2]
type = RenameBlockGenerator
input = combine
old_block = '0 2'
new_block = 'cube1 cube2'
[]
[]
[Adaptivity]
initial_marker = box
initial_steps = 1
max_h_level = 1
[Markers]
[box]
type = BoxMarker
bottom_left = '0 0 0'
top_right = '0.5 0.5 0'
inside = refine
outside = do_nothing
[]
[]
[]
[Variables]
[disp_x]
block = 'cube1 cube2'
[]
[disp_y]
block = 'cube1 cube2'
[]
[]
[Physics/SolidMechanics/QuasiStatic]
[cube1_mechanics]
strain = FINITE
block = 'cube1 cube2'
[]
[]
[BCs]
[cube1_x]
type = ADDirichletBC
variable = disp_x
boundary = 'cube1_bottom '
value = 0.0
[]
[cube1_y]
type = ADDirichletBC
variable = disp_y
boundary = 'cube1_bottom '
value = 0.0
[]
[cube2_y]
type = ADFunctionDirichletBC
variable = disp_y
boundary = 'cube2_top'
function = '-t'
preset = false
[]
[cube2_x]
type = ADDirichletBC
variable = disp_x
boundary = 'cube2_top'
value = 0
[]
[]
[Materials]
[cube1_elasticity_tensor]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 68.9e9
poissons_ratio = 0.3
block = 'cube1'
[]
[stress]
type = ComputeFiniteStrainElasticStress
block = 'cube1 cube2'
[]
[cube2_elasticity_tensor]
type = ComputeIsotropicElasticityTensor
youngs_modulus = 140e9
poissons_ratio = 0.3
block = 'cube2'
[]
[]
[Contact]
[contactswell]
secondary = cube1_top
primary = cube2_bottom
model = frictionless
formulation = mortar_penalty
penalty = 1.0e12
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
type = Transient
solve_type = 'NEWTON'
petsc_options_iname = '-pc_type -pc_factor_mat_solver_type'
petsc_options_value = 'lu superlu_dist'
line_search = 'none'
nl_rel_tol = 1e-9
nl_abs_tol = 1e-9
nl_max_its = 50
l_tol = 1e-4
l_max_its = 50
start_time = 0.0
end_time = 0.02e-3
dtmax = 4
dtmin = 0.001e-3
dt = 0.01e-3
automatic_scaling = true
off_diagonals_in_auto_scaling = true
[]
[Debug]
show_var_residual_norms = true
[]
[Outputs]
exodus = true
print_linear_residuals = true
[]
(modules/heat_transfer/test/tests/directional_flux_bc/2d_elem.i)
[Mesh]
[shade]
type = GeneratedMeshGenerator
dim = 2
nx = 1
ny = 3
xmax = 0.2
ymax = 0.5
[]
[screen]
type = GeneratedMeshGenerator
dim = 2
nx = 1
ny = 20
xmax = 0.05
[]
[screen_block]
type = SubdomainIDGenerator
input = screen
subdomain_id = 1
[]
[combine]
type = CombinerGenerator
inputs = 'shade screen_block'
positions = '0 0 0 1 0 0'
[]
[all_sides]
type = SideSetsAroundSubdomainGenerator
block = '0 1'
new_boundary = 100
input = combine
[]
[shaded_side]
type = SideSetsAroundSubdomainGenerator
normal = '-1 0 0'
block = 1
input = all_sides
new_boundary = 101
[]
[]
[GlobalParams]
illumination_flux = '1 0 0'
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[dt]
type = TimeDerivative
variable = u
[]
[]
[BCs]
[flux]
type = DirectionalFluxBC
variable = u
boundary = 101
self_shadow_uo = shadow
[]
[]
[UserObjects]
[shadow]
type = SelfShadowSideUserObject
boundary = 100
execute_on = INITIAL
[]
[]
[Postprocessors]
[light]
type = SideIntegralVariablePostprocessor
variable = u
boundary = 101
[]
[]
[Executioner]
type = Transient
dt = 0.01
num_steps = 1
[]
[Outputs]
csv = true
[]
(test/tests/meshgenerators/mesh_diagnostics_generator/detect_amr_quad.i)
[Mesh]
[big_one]
type = GeneratedMeshGenerator
dim = 2
nx = 1
ny = 1
xmin = 1
xmax = 2
ymin = 0
ymax = 1
[]
[cut_one]
type = GeneratedMeshGenerator
dim = 2
xmax = 1
ymax = 1
nx = 2
ny = 2
[]
[cmbn]
type = CombinerGenerator
inputs = 'big_one cut_one'
[]
[diag]
type = MeshDiagnosticsGenerator
input = cmbn
search_for_adaptivity_nonconformality = INFO
[]
[]
[Outputs]
exodus = true
[]
(test/tests/meshgenerators/combiner_generator/combiner_multi_input_translate_from_file.i)
[Mesh]
[gen1]
type = GeneratedMeshGenerator
dim = 2
nx = 10
ny = 10
[]
[gen2]
type = GeneratedMeshGenerator
dim = 2
nx = 12
ny = 12
[]
[gen3]
type = GeneratedMeshGenerator
dim = 2
nx = 14
ny = 14
[]
[cmbn]
type = CombinerGenerator
inputs = 'gen1 gen2 gen3'
positions_file = 'positions.txt'
[]
[]
[Variables]
[u]
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[]
[BCs]
[left]
type = DirichletBC
variable = u
boundary = 'left'
value = 0
[]
[right]
type = DirichletBC
variable = u
boundary = 'right'
value = 1
[]
[]
[Executioner]
type = Steady
solve_type = PJFNK
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
(test/tests/mortar/coincident-nodes/test.i)
[Mesh]
[top]
type = GeneratedMeshGenerator
dim = 2
ymin = 0.5
ymax = 1
nx = 2
ny = 1
subdomain_ids = '0 0'
[]
[bottom]
type = GeneratedMeshGenerator
dim = 2
ymin = 0
ymax = 0.5
nx = 2
ny = 1
subdomain_ids = '1 1'
[]
[combine]
type = CombinerGenerator
inputs = 'top bottom'
[]
[secondary]
type = LowerDBlockFromSidesetGenerator
input = combine
sidesets = left
new_block_id = 11
new_block_name = secondary
[]
[primary]
type = LowerDBlockFromSidesetGenerator
input = secondary
sidesets = right
new_block_id = 12
new_block_name = primary
[]
[]
[Problem]
solve = false
[]
[Variables]
[u][]
[]
[Constraints]
[mortar]
type = PenaltyEqualValueConstraint
secondary_variable = u
primary_boundary = right
secondary_boundary = left
primary_subdomain = 12
secondary_subdomain = 11
penalty_value = 10
[]
[]
[Executioner]
type = Transient
num_steps = 1
[]
(test/tests/meshgenerators/batch_mesh_generation_action/mfname.i)
[Mesh]
[BatchMeshGeneratorAction]
[batch1]
mesh_generator_type = 'FileMeshGenerator'
mesh_name_prefix = 'fmg'
batch_scalar_input_param_names = 'file'
batch_scalar_input_param_types = 'MFNAME'
batch_scalar_input_param_values = 'gold/element_generator_in.e gold/element_generator_ss_in.e'
[]
[]
[cmbn]
type = CombinerGenerator
inputs = 'fmg_0 fmg_1'
positions = '0 0 0
0 0 2'
[]
[]
(test/tests/postprocessors/nearest_node_number/nearest_node_number_2.i)
# Using NearestNodeNumber, finds the node number of the nearest node to the point in the mesh
# In this case, the mesh has two disjoint parts and the point is equidistant from the two parts, so the closest node with the smallest ID is chosen.
# This input file is run multiple times:
# - 1 thread and 1 process
# - 2 threads and 1 process
# - 1 thread and 2 processes
# - 2 threads and 2 processes
# Each time should give the same result
[Mesh]
[left]
type = GeneratedMeshGenerator
dim = 1
nx = 4
xmin = 0
xmax = 8
[]
[right]
type = GeneratedMeshGenerator
dim = 1
nx = 4
xmin = 12
xmax = 20
[]
[combiner]
type = CombinerGenerator
inputs = 'left right'
[]
# For consistency with distributed mesh
allow_renumbering = false
[]
[UserObjects]
[nnn_uo]
type = NearestNodeNumberUO
point = '10 0 0'
execute_on = 'initial timestep_begin'
[]
[]
[Postprocessors]
[nnn]
type = NearestNodeNumber
nearest_node_number_uo = nnn_uo
execute_on = 'initial timestep_begin'
[]
[]
[Problem]
solve = false
[]
[Executioner]
type = Transient
end_time = 2
[]
[Outputs]
csv = true
[]