- boundaryThe list of boundary IDs from the mesh where this object applies
C++ Type:std::vector<BoundaryName>
Controllable:No
Description:The list of boundary IDs from the mesh where this object applies
- exact_solutionThe exact solution.
C++ Type:FunctionName
Controllable:No
Description:The exact solution.
- variableThe name of the variable that this residual object operates on
C++ Type:NonlinearVariableName
Controllable:No
Description:The name of the variable that this residual object operates on
FunctionGradientNeumannBC
FunctionGradientNeumannBC
adds the weak form contribution: where is the unit normal vector at the boundary, is a coefficient (corresponding to thermal conductivity or diffusivity), and is a function of space and time that is specified in the input file through the parameter exact_solution
. As the parameter name suggests, the FunctionGradientNeumannBC
object can be useful for specifying a Neumann condition when the exact solution to the PDE is known.
Imposes the integrated boundary condition arising from integration by parts of a diffusion/heat conduction operator, and where the exact solution can be specified.
Input Parameters
- coeff1The diffusion, thermal conductivity, etc. coefficient
Default:1
C++ Type:double
Controllable:No
Description:The diffusion, thermal conductivity, etc. coefficient
- displacementsThe displacements
C++ Type:std::vector<VariableName>
Controllable:No
Description:The displacements
- prop_getter_suffixAn optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
C++ Type:MaterialPropertyName
Controllable:No
Description:An optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
- use_interpolated_stateFalseFor the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Default:False
C++ Type:bool
Controllable:No
Description:For the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Optional Parameters
- absolute_value_vector_tagsThe tags for the vectors this residual object should fill with the absolute value of the residual contribution
C++ Type:std::vector<TagName>
Controllable:No
Description:The tags for the vectors this residual object should fill with the absolute value of the residual contribution
- extra_matrix_tagsThe extra tags for the matrices this Kernel should fill
C++ Type:std::vector<TagName>
Controllable:No
Description:The extra tags for the matrices this Kernel should fill
- extra_vector_tagsThe extra tags for the vectors this Kernel should fill
C++ Type:std::vector<TagName>
Controllable:No
Description:The extra tags for the vectors this Kernel should fill
- matrix_tagssystemThe tag for the matrices this Kernel should fill
Default:system
C++ Type:MultiMooseEnum
Options:nontime, system
Controllable:No
Description:The tag for the matrices this Kernel should fill
- vector_tagsnontimeThe tag for the vectors this Kernel should fill
Default:nontime
C++ Type:MultiMooseEnum
Options:nontime, time
Controllable:No
Description:The tag for the vectors this Kernel should fill
Tagging Parameters
- control_tagsAdds user-defined labels for accessing object parameters via control logic.
C++ Type:std::vector<std::string>
Controllable:No
Description:Adds user-defined labels for accessing object parameters via control logic.
- diag_save_inThe name of auxiliary variables to save this BC's diagonal jacobian contributions to. Everything about that variable must match everything about this variable (the type, what blocks it's on, etc.)
C++ Type:std::vector<AuxVariableName>
Controllable:No
Description:The name of auxiliary variables to save this BC's diagonal jacobian contributions to. Everything about that variable must match everything about this variable (the type, what blocks it's on, etc.)
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:Yes
Description:Set the enabled status of the MooseObject.
- implicitTrueDetermines whether this object is calculated using an implicit or explicit form
Default:True
C++ Type:bool
Controllable:No
Description:Determines whether this object is calculated using an implicit or explicit form
- save_inThe name of auxiliary variables to save this BC's residual contributions to. Everything about that variable must match everything about this variable (the type, what blocks it's on, etc.)
C++ Type:std::vector<AuxVariableName>
Controllable:No
Description:The name of auxiliary variables to save this BC's residual contributions to. Everything about that variable must match everything about this variable (the type, what blocks it's on, etc.)
- seed0The seed for the master random number generator
Default:0
C++ Type:unsigned int
Controllable:No
Description:The seed for the master random number generator
- use_displaced_meshFalseWhether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.
Default:False
C++ Type:bool
Controllable:No
Description:Whether or not this object should use the displaced mesh for computation. Note that in the case this is true but no displacements are provided in the Mesh block the undisplaced mesh will still be used.
Advanced Parameters
Input Files
- (test/tests/mortar/convergence-studies/solution-continuity/continuity.i)
- (test/tests/mortar/continuity-2d-non-conforming/sequencing-stateful-soln-continuity.i)
- (test/tests/mortar/convergence-studies/continuity-3d/continuity.i)
- (test/tests/mortar/continuity-3d-non-conforming/continuity_non_conforming_tet.i)
- (test/tests/mortar/continuity-2d-non-conforming/soln-continuity-pg.i)
- (test/tests/mortar/continuity-2d-non-conforming/dual-soln-continuity-vcp.i)
- (test/tests/mortar/continuity-3d-non-conforming/continuity_penalty_tet.i)
- (test/tests/preconditioners/vcp/vcp_test.i)
- (test/tests/mortar/convergence-studies/gap-conductance/gap-conductance.i)
- (test/tests/preconditioners/vcp/no_condense_test.i)
- (test/tests/mortar/aux-gap/mismatch.i)
- (test/tests/mortar/aux-gap/gap.i)
- (test/tests/mortar/gap-conductance-2d-non-conforming/gap-conductance.i)
- (test/tests/mortar/continuity-2d-non-conforming/dual-soln-continuity.i)
- (test/tests/mortar/continuity-3d-non-conforming/continuity_tet.i)
- (test/tests/mortar/continuity-3d-non-conforming/continuity_sphere_hex.i)
- (test/tests/mortar/continuity-2d-non-conforming/soln-continuity.i)
- (test/tests/mortar/continuity-3d-non-conforming/continuity_penalty_sphere_hex.i)
- (test/tests/mortar/continuity-3d-non-conforming/continuity_mixed.i)
(test/tests/mortar/convergence-studies/solution-continuity/continuity.i)
[Mesh]
second_order = true
[./left_block]
type = GeneratedMeshGenerator
dim = 2
xmin = 0
xmax = 1
ymin = 0
ymax = 1
nx = 2
ny = 2
elem_type = QUAD4
[../]
[./left_block_sidesets]
type = RenameBoundaryGenerator
input = left_block
old_boundary_id = '0 1 2 3'
new_boundary_name = 'lb_bottom lb_right lb_top lb_left'
[../]
[./left_block_id]
type = SubdomainIDGenerator
input = left_block_sidesets
subdomain_id = 1
[../]
[./right_block]
type = GeneratedMeshGenerator
dim = 2
xmin = 1
xmax = 2
ymin = 0
ymax = 1
nx = 2
ny = 2
elem_type = QUAD4
[../]
[./right_block_id]
type = SubdomainIDGenerator
input = right_block
subdomain_id = 2
[../]
[right_block_change_boundary_id]
type = RenameBoundaryGenerator
input = right_block_id
old_boundary_id = '0 1 2 3'
new_boundary_id = '100 101 102 103'
[]
[./combined]
type = MeshCollectionGenerator
inputs = 'left_block_id right_block_change_boundary_id'
[../]
[./block_rename]
type = RenameBlockGenerator
input = combined
old_block = '1 2'
new_block = 'left_block right_block'
[../]
[right_right_sideset]
type = SideSetsAroundSubdomainGenerator
input = block_rename
new_boundary = rb_right
block = right_block
normal = '1 0 0'
[]
[right_left_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_right_sideset
new_boundary = rb_left
block = right_block
normal = '-1 0 0'
[]
[right_top_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_left_sideset
new_boundary = rb_top
block = right_block
normal = '0 1 0'
[]
[right_bottom_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_top_sideset
new_boundary = rb_bottom
block = right_block
normal = '0 -1 0'
[]
[secondary]
input = right_bottom_sideset
type = LowerDBlockFromSidesetGenerator
sidesets = 'lb_right'
new_block_id = '10001'
new_block_name = 'secondary_lower'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
sidesets = 'rb_left'
new_block_id = '10000'
new_block_name = 'primary_lower'
[]
[]
[Variables]
[./T]
block = 'left_block right_block'
order = SECOND
[../]
[./lambda]
block = 'secondary_lower'
[../]
[]
[BCs]
[./neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = 'lb_bottom lb_top lb_left rb_bottom rb_right rb_top'
[../]
[]
[Kernels]
[./conduction]
type = Diffusion
variable = T
block = 'left_block right_block'
[../]
[./sink]
type = Reaction
variable = T
block = 'left_block right_block'
[../]
[./forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = 'left_block right_block'
[../]
[]
[Functions]
[./forcing_function]
type = ParsedFunction
expression = ''
[../]
[./exact_soln_primal]
type = ParsedFunction
expression = ''
[../]
[exact_soln_lambda]
type = ParsedFunction
expression = ''
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[./mortar]
type = EqualValueConstraint
primary_boundary = rb_left
secondary_boundary = lb_right
primary_subdomain = primary_lower
secondary_subdomain = secondary_lower
secondary_variable = T
variable = lambda
delta = 0.4
[../]
[]
[Preconditioning]
[./smp]
type = SMP
full = true
[../]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options = '-snes_converged_reason -ksp_converged_reason'
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_mat_solver_type'
petsc_options_value = 'lu basic mumps'
[]
[Outputs]
csv = true
[dofmap]
type = DOFMap
execute_on = 'initial'
[]
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary_lower'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = 'left_block right_block'
[]
[h]
type = AverageElementSize
block = 'left_block right_block'
[]
[]
(test/tests/mortar/continuity-2d-non-conforming/sequencing-stateful-soln-continuity.i)
[Mesh]
second_order = true
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[./primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[../]
[./secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[../]
[]
[Variables]
[./T]
block = '1 2'
order = SECOND
[../]
[./lambda]
block = '10'
[../]
[]
[AuxVariables]
[ssm]
order = CONSTANT
family = MONOMIAL
block = '1 2'
[]
[]
[BCs]
[./neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[../]
[]
[Kernels]
[./conduction]
type = Diffusion
variable = T
block = '1 2'
[../]
[./sink]
type = Reaction
variable = T
block = '1 2'
[../]
[./forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[../]
[]
[AuxKernels]
[ssm]
type = MaterialRealAux
variable = ssm
property = diffusivity
block = '1 2'
[]
[]
[Materials]
[./ssm]
type = SpatialStatefulMaterial
block = '1 2'
[../]
[]
[Functions]
[./forcing_function]
type = ParsedFunction
expression= '-4 + x^2 + y^2'
[../]
[./exact_soln]
type = ParsedFunction
expression= 'x^2 + y^2'
[../]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[./mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[../]
[]
[Preconditioning]
[./smp]
type = SMP
full = true
[../]
[]
[Executioner]
solve_type = NEWTON
type = Steady
nl_abs_tol = 1e-12
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
num_grids = 2
[]
[Outputs]
exodus = true
[]
[Adaptivity]
steps = 1
marker = uniform
[Markers]
[uniform]
type = UniformMarker
mark = refine
[]
[]
[]
(test/tests/mortar/convergence-studies/continuity-3d/continuity.i)
[Mesh]
second_order = true
[file]
type = FileMeshGenerator
file = hex_mesh.e
[]
[secondary]
input = file
type = LowerDBlockFromSidesetGenerator
new_block_id = 11
new_block_name = "secondary"
sidesets = '101'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
new_block_id = 12
new_block_name = "primary"
sidesets = '102'
[]
[]
[Problem]
kernel_coverage_check = false
[]
[Variables]
[T]
block = '1 2'
order = SECOND
[]
[lambda]
block = 'secondary'
# family = MONOMIAL
# order = CONSTANT
family = LAGRANGE
order = SECOND
use_dual = true
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = '1 2'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi) + 3*pi^2*sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = 'pi*sin(pi*y)*sin(pi*z)*cos(pi*x)'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = '12'
secondary_subdomain = '11'
variable = lambda
secondary_variable = T
# delta = 0.1
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type '
'-pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
csv = true
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = '1 2'
[]
[h]
type = AverageElementSize
block = '1 2'
[]
[]
(test/tests/mortar/continuity-3d-non-conforming/continuity_non_conforming_tet.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = tet_non_mesh.e
[]
[secondary]
input = file
type = LowerDBlockFromSidesetGenerator
new_block_id = 11
new_block_name = "secondary"
sidesets = '101'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
new_block_id = 12
new_block_name = "primary"
sidesets = '102'
[]
[]
[Problem]
kernel_coverage_check = false
[]
[Variables]
[T]
block = '1 2'
[]
[lambda]
block = 'secondary'
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = '1 2'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi) + 3*pi^2*sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = 'pi*sin(pi*y)*sin(pi*z)*cos(pi*x)'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = '12'
secondary_subdomain = '11'
variable = lambda
secondary_variable = T
delta = 0.1
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type '
'-pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = '1 2'
[]
[h]
type = AverageElementSize
block = '1 2'
[]
[]
(test/tests/mortar/continuity-2d-non-conforming/soln-continuity-pg.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[]
[secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[]
[]
[Variables]
[T]
block = '1 2'
order = FIRST
[]
[lambda]
block = '10'
order = FIRST
use_dual = true
[]
[]
[AuxVariables]
[aux_lm]
block = '10'
order = FIRST
use_dual = false
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = '-4 + x^2 + y^2'
[]
[exact_soln]
type = ParsedFunction
expression = 'x^2 + y^2'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
use_petrov_galerkin = true
aux_lm = aux_lm
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type '
'-pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[]
(test/tests/mortar/continuity-2d-non-conforming/dual-soln-continuity-vcp.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[]
[secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[]
[]
[Variables]
[T]
block = '1 2'
order = FIRST
[]
[lambda]
block = '10'
order = FIRST
use_dual = true
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression= '-4 + x^2 + y^2'
[]
[exact_soln]
type = ParsedFunction
expression= 'x^2 + y^2'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[]
[]
[Preconditioning]
[vcp]
type = VCP
full = true
lm_variable = 'lambda'
primary_variable = 'T'
preconditioner = 'AMG'
is_lm_coupling_diagonal = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = ' -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = ' NONZERO 1e-15'
[]
[Outputs]
file_base = 'dual-soln-continuity_out'
exodus = true
[]
(test/tests/mortar/continuity-3d-non-conforming/continuity_penalty_tet.i)
[Mesh]
second_order = false
[left_block]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 2
nz = 2
xmin = 0
xmax = 0.3
ymin = 0
ymax = .5
zmin = 0
zmax = .5
elem_type = TET4
[]
[left_block_sidesets]
type = RenameBoundaryGenerator
input = left_block
old_boundary = '0 1 2 3 4 5'
new_boundary = 'lb_bottom lb_back lb_right lb_front lb_left lb_top'
[]
[left_block_id]
type = SubdomainIDGenerator
input = left_block_sidesets
subdomain_id = 1
[]
[right_block]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 2
nz = 2
xmin = 0.3
xmax = 0.6
ymin = 0
ymax = .5
zmin = 0
zmax = .5
elem_type = TET4
[]
[right_block_id]
type = SubdomainIDGenerator
input = right_block
subdomain_id = 2
[]
[right_block_change_boundary_id]
type = RenameBoundaryGenerator
input = right_block_id
old_boundary = '0 1 2 3 4 5'
new_boundary = '100 101 102 103 104 105'
[]
[combined]
type = MeshCollectionGenerator
inputs = 'left_block_id right_block_change_boundary_id'
[]
[block_rename]
type = RenameBlockGenerator
input = combined
old_block = '1 2'
new_block = 'left_block right_block'
[]
[right_right_sideset]
type = SideSetsAroundSubdomainGenerator
input = block_rename
new_boundary = rb_right
block = right_block
normal = '1 0 0'
[]
[right_left_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_right_sideset
new_boundary = rb_left
block = right_block
normal = '-1 0 0'
[]
[right_top_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_left_sideset
new_boundary = rb_top
block = right_block
normal = '0 0 1'
[]
[right_bottom_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_top_sideset
new_boundary = rb_bottom
block = right_block
normal = '0 0 -1'
[]
[right_front_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_bottom_sideset
new_boundary = rb_front
block = right_block
normal = '0 1 0'
[]
[right_back_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_front_sideset
new_boundary = rb_back
block = right_block
normal = '0 -1 0'
[]
[secondary]
input = right_back_sideset
type = LowerDBlockFromSidesetGenerator
sidesets = 'lb_right'
new_block_id = '12'
new_block_name = 'secondary'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
sidesets = 'rb_left'
new_block_id = '11'
new_block_name = 'primary'
[]
[]
[Variables]
[T]
block = '1 2'
order = FIRST
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = 'lb_back lb_front lb_left lb_top lb_bottom rb_right rb_top rb_bottom rb_front rb_back'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi) + 3*pi^2*sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = 'pi*sin(pi*y)*sin(pi*z)*cos(pi*x)'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = PenaltyEqualValueConstraint
primary_boundary = 'rb_left'
secondary_boundary = 'lb_right'
primary_subdomain = '11'
secondary_subdomain = '12'
secondary_variable = T
penalty_value = 1.0e5
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = 'left_block right_block'
[]
[h]
type = AverageElementSize
block = 'left_block right_block'
[]
[]
(test/tests/preconditioners/vcp/vcp_test.i)
[Mesh]
[original_file_mesh]
type = FileMeshGenerator
file = non_conform_2blocks.e
[]
[secondary_side]
input = original_file_mesh
type = LowerDBlockFromSidesetGenerator
sidesets = '10'
new_block_id = '100'
new_block_name = 'secondary_side'
[]
[primary_side]
input = secondary_side
type = LowerDBlockFromSidesetGenerator
sidesets = '20'
new_block_id = '200'
new_block_name = 'primary_side'
[]
[]
[Functions]
[exact_sln]
type = ParsedFunction
expression = sin(2*pi*x)*sin(2*pi*y)
[]
[ffn]
type = ParsedFunction
expression = 8*pi*pi*sin(2*pi*x)*sin(2*pi*y)
[]
[]
[Variables]
[u]
order = FIRST
family = LAGRANGE
block = '1 2'
[]
[lm]
order = FIRST
family = LAGRANGE
block = secondary_side
use_dual = true
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[ffn]
type = BodyForce
variable = u
function = ffn
[]
[]
[Constraints]
[ced]
type = EqualValueConstraint
variable = lm
secondary_variable = u
primary_boundary = 20
primary_subdomain = 200
secondary_boundary = 10
secondary_subdomain = 100
[]
[]
[BCs]
[all]
type = DirichletBC
variable = u
boundary = '30 40'
value = 0.0
[]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_sln
variable = u
boundary = '50 60'
[]
[]
[Postprocessors]
[l2_error]
type = ElementL2Error
variable = u
function = exact_sln
block = '1 2'
execute_on = 'initial timestep_end'
[]
[]
[Preconditioning]
[vcp]
type = VCP
full = true
lm_variable = 'lm'
primary_variable = 'u'
preconditioner = 'AMG'
is_lm_coupling_diagonal = true
[]
[]
[Executioner]
type = Steady
solve_type = 'NEWTON'
petsc_options = '-snes_converged_reason -ksp_converged_reason -snes_view'
l_max_its = 100
nl_rel_tol = 1e-6
[]
[Outputs]
csv = true
[]
(test/tests/mortar/convergence-studies/gap-conductance/gap-conductance.i)
[Problem]
error_on_jacobian_nonzero_reallocation = true
[]
[Mesh]
second_order = true
[./left_block]
type = GeneratedMeshGenerator
dim = 2
xmin = 0
xmax = 1
ymin = 0
ymax = 1
nx = 2
ny = 2
elem_type = QUAD4
[../]
[./left_block_sidesets]
type = RenameBoundaryGenerator
input = left_block
old_boundary_id = '0 1 2 3'
new_boundary = 'lb_bottom lb_right lb_top lb_left'
[../]
[./left_block_id]
type = SubdomainIDGenerator
input = left_block_sidesets
subdomain_id = 1
[../]
[./right_block]
type = GeneratedMeshGenerator
dim = 2
xmin = 2
xmax = 3
ymin = 0
ymax = 1
nx = 2
ny = 2
elem_type = QUAD4
[../]
[./right_block_id]
type = SubdomainIDGenerator
input = right_block
subdomain_id = 2
[../]
[right_block_change_boundary_id]
type = RenameBoundaryGenerator
input = right_block_id
old_boundary_id = '0 1 2 3'
new_boundary_id = '100 101 102 103'
[]
[./combined]
type = MeshCollectionGenerator
inputs = 'left_block_id right_block_change_boundary_id'
[../]
[./block_rename]
type = RenameBlockGenerator
input = combined
old_block = '1 2'
new_block = 'left_block right_block'
[../]
[right_right_sideset]
type = SideSetsAroundSubdomainGenerator
input = block_rename
new_boundary = rb_right
block = right_block
normal = '1 0 0'
[]
[right_left_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_right_sideset
new_boundary = rb_left
block = right_block
normal = '-1 0 0'
[]
[right_top_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_left_sideset
new_boundary = rb_top
block = right_block
normal = '0 1 0'
[]
[right_bottom_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_top_sideset
new_boundary = rb_bottom
block = right_block
normal = '0 -1 0'
[]
[secondary]
input = right_bottom_sideset
type = LowerDBlockFromSidesetGenerator
sidesets = 'lb_right'
new_block_id = '10001'
new_block_name = 'secondary_lower'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
sidesets = 'rb_left'
new_block_id = '10000'
new_block_name = 'primary_lower'
[]
[]
[Variables]
[./T]
block = 'left_block right_block'
order = SECOND
[../]
[./lambda]
block = 'secondary_lower'
family = MONOMIAL
order = CONSTANT
[../]
[]
[BCs]
[./neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = 'lb_bottom lb_top lb_left rb_bottom rb_right rb_top'
[../]
[]
[Kernels]
[./conduction]
type = Diffusion
variable = T
block = 'left_block right_block'
[../]
[./sink]
type = Reaction
variable = T
block = 'left_block right_block'
[../]
[./forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = 'left_block right_block'
[../]
[]
[Functions]
[./forcing_function]
type = ParsedFunction
expression = ''
[../]
[./exact_soln_primal]
type = ParsedFunction
expression = ''
[../]
[exact_soln_lambda]
type = ParsedFunction
expression = ''
[]
[mms_secondary]
type = ParsedFunction
expression = ''
[]
[mms_primary]
type = ParsedFunction
expression = ''
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[./mortar]
type = GapHeatConductanceTest
primary_boundary = rb_left
secondary_boundary = lb_right
primary_subdomain = primary_lower
secondary_subdomain = secondary_lower
secondary_variable = T
variable = lambda
secondary_gap_conductance = 1
primary_gap_conductance = 1
secondary_mms_function = mms_secondary
primary_mms_function = mms_primary
[../]
[]
[Preconditioning]
[./smp]
type = SMP
full = true
[../]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options = '-snes_converged_reason'
petsc_options_iname = '-pc_type -pc_hypre_type'
petsc_options_value = 'hypre boomeramg'
[]
[Outputs]
csv = true
[dofmap]
type = DOFMap
execute_on = 'initial'
[]
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary_lower'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = 'left_block right_block'
[]
[h]
type = AverageElementSize
block = 'left_block right_block'
[]
[]
(test/tests/preconditioners/vcp/no_condense_test.i)
[Mesh]
[original_file_mesh]
type = FileMeshGenerator
file = non_conform_2blocks.e
[]
[secondary_side]
input = original_file_mesh
type = LowerDBlockFromSidesetGenerator
sidesets = '10'
new_block_id = '100'
new_block_name = 'secondary_side'
[]
[primary_side]
input = secondary_side
type = LowerDBlockFromSidesetGenerator
sidesets = '20'
new_block_id = '200'
new_block_name = 'primary_side'
[]
[]
[Functions]
[exact_sln]
type = ParsedFunction
expression = sin(2*pi*x)*sin(2*pi*y)
[]
[ffn]
type = ParsedFunction
expression = 8*pi*pi*sin(2*pi*x)*sin(2*pi*y)
[]
[]
[Variables]
[u]
order = FIRST
family = LAGRANGE
block = '1 2'
[]
[lm]
order = FIRST
family = LAGRANGE
block = secondary_side
use_dual = false
[]
[]
[Kernels]
[diff]
type = Diffusion
variable = u
[]
[ffn]
type = BodyForce
variable = u
function = ffn
[]
[]
[Constraints]
[ced]
type = EqualValueConstraint
variable = lm
secondary_variable = u
primary_boundary = 20
primary_subdomain = 200
secondary_boundary = 10
secondary_subdomain = 100
[]
[]
[BCs]
[all]
type = DirichletBC
variable = u
boundary = '30 40'
value = 0.0
[]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_sln
variable = u
boundary = '50 60'
[]
[]
[Postprocessors]
[l2_error]
type = ElementL2Error
variable = u
function = exact_sln
block = '1 2'
execute_on = 'initial timestep_end'
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
type = Steady
solve_type = 'NEWTON'
petsc_options = '-snes_converged_reason -ksp_converged_reason -snes_view'
petsc_options_iname = '-pc_type -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = ' lu NONZERO 1e-12'
l_max_its = 100
nl_rel_tol = 1e-6
[]
[Outputs]
csv = true
[]
(test/tests/mortar/aux-gap/mismatch.i)
[Mesh]
second_order = true
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[]
[secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[]
[]
[Variables]
[T]
block = '1 2'
order = SECOND
[]
[lambda]
block = '10'
use_dual = true
order = SECOND
[]
[]
[AuxVariables]
[gap]
block = '10'
[]
[]
[AuxKernels]
[gap]
type = WeightedGapAux
variable = gap
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = '-4 + x^2 + y^2'
[]
[exact_soln]
type = ParsedFunction
expression = 'x^2 + y^2'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[dofmap]
type = DOFMap
execute_on = 'initial'
[]
[]
(test/tests/mortar/aux-gap/gap.i)
[Mesh]
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[]
[secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[]
[]
[Variables]
[T]
block = '1 2'
[]
[lambda]
block = '10'
use_dual = true
[]
[]
[AuxVariables]
[gap]
block = '10'
[]
[]
[AuxKernels]
[gap]
type = WeightedGapAux
variable = gap
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = '-4 + x^2 + y^2'
[]
[exact_soln]
type = ParsedFunction
expression = 'x^2 + y^2'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[dofmap]
type = DOFMap
execute_on = 'initial'
[]
[]
(test/tests/mortar/gap-conductance-2d-non-conforming/gap-conductance.i)
[Mesh]
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[./primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[../]
[./secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[../]
[]
[Problem]
kernel_coverage_check = false
[]
[Variables]
[./T]
block = '1 2'
[../]
[./lambda]
block = '10'
[../]
[]
[BCs]
[./neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[../]
[]
[Kernels]
[./conduction]
type = Diffusion
variable = T
block = '1 2'
[../]
[./sink]
type = Reaction
variable = T
block = '1 2'
[../]
[./forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[../]
[]
[Functions]
[./forcing_function]
type = ParsedFunction
expression = '-4 + x^2 + y^2'
[../]
[./exact_soln]
type = ParsedFunction
expression = 'x^2 + y^2'
[../]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[./mortar]
type = GapHeatConductanceTest
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[../]
[]
[Materials]
[constant]
type = ADGenericConstantMaterial
prop_names = 'gap_conductance'
prop_values = '.03'
block = '1 2'
[]
[./ssm]
type = SpatialStatefulMaterial
block = '1 2'
[../]
[]
[Preconditioning]
[./smp]
type = SMP
full = true
[../]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type'
petsc_options_value = 'lu basic'
[]
[Outputs]
exodus = true
[dofmap]
type = DOFMap
execute_on = 'initial'
[]
[]
(test/tests/mortar/continuity-2d-non-conforming/dual-soln-continuity.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[./primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[../]
[./secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[../]
[]
[Variables]
[./T]
block = '1 2'
order = FIRST
[../]
[./lambda]
block = '10'
order = FIRST
use_dual = true
[../]
[]
[BCs]
[./neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[../]
[]
[Kernels]
[./conduction]
type = Diffusion
variable = T
block = '1 2'
[../]
[./sink]
type = Reaction
variable = T
block = '1 2'
[../]
[./forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[../]
[]
[Functions]
[./forcing_function]
type = ParsedFunction
expression= '-4 + x^2 + y^2'
[../]
[./exact_soln]
type = ParsedFunction
expression= 'x^2 + y^2'
[../]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[./mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[../]
[]
[Preconditioning]
[./smp]
type = SMP
full = true
[../]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[]
(test/tests/mortar/continuity-3d-non-conforming/continuity_tet.i)
[Mesh]
second_order = false
[left_block]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 2
nz = 2
xmin = 0
xmax = 0.3
ymin = 0
ymax = .5
zmin = 0
zmax = .5
elem_type = TET4
[]
[left_block_sidesets]
type = RenameBoundaryGenerator
input = left_block
old_boundary = '0 1 2 3 4 5'
new_boundary = 'lb_bottom lb_back lb_right lb_front lb_left lb_top'
[]
[left_block_id]
type = SubdomainIDGenerator
input = left_block_sidesets
subdomain_id = 1
[]
[right_block]
type = GeneratedMeshGenerator
dim = 3
nx = 1
ny = 2
nz = 2
xmin = 0.3
xmax = 0.6
ymin = 0
ymax = .5
zmin = 0
zmax = .5
elem_type = TET4
[]
[right_block_id]
type = SubdomainIDGenerator
input = right_block
subdomain_id = 2
[]
[right_block_change_boundary_id]
type = RenameBoundaryGenerator
input = right_block_id
old_boundary = '0 1 2 3 4 5'
new_boundary = '100 101 102 103 104 105'
[]
[combined]
type = MeshCollectionGenerator
inputs = 'left_block_id right_block_change_boundary_id'
[]
[block_rename]
type = RenameBlockGenerator
input = combined
old_block = '1 2'
new_block = 'left_block right_block'
[]
[right_right_sideset]
type = SideSetsAroundSubdomainGenerator
input = block_rename
new_boundary = rb_right
block = right_block
normal = '1 0 0'
[]
[right_left_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_right_sideset
new_boundary = rb_left
block = right_block
normal = '-1 0 0'
[]
[right_top_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_left_sideset
new_boundary = rb_top
block = right_block
normal = '0 0 1'
[]
[right_bottom_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_top_sideset
new_boundary = rb_bottom
block = right_block
normal = '0 0 -1'
[]
[right_front_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_bottom_sideset
new_boundary = rb_front
block = right_block
normal = '0 1 0'
[]
[right_back_sideset]
type = SideSetsAroundSubdomainGenerator
input = right_front_sideset
new_boundary = rb_back
block = right_block
normal = '0 -1 0'
[]
[secondary]
input = right_back_sideset
type = LowerDBlockFromSidesetGenerator
sidesets = 'lb_right'
new_block_id = '12'
new_block_name = 'secondary'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
sidesets = 'rb_left'
new_block_id = '11'
new_block_name = 'primary'
[]
[]
[Problem]
kernel_coverage_check = false
[]
[Variables]
[T]
block = '1 2'
order = FIRST
[]
[lambda]
block = 'secondary'
family = MONOMIAL
order = CONSTANT
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = 'lb_back lb_front lb_left lb_top lb_bottom rb_right rb_top rb_bottom rb_front rb_back'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi) + 3*pi^2*sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = 'pi*sin(pi*y)*sin(pi*z)*cos(pi*x)'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 'rb_left'
secondary_boundary = 'lb_right'
primary_subdomain = '11'
secondary_subdomain = '12'
variable = lambda
secondary_variable = T
delta = .1
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type '
'-pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = 'left_block right_block'
[]
[h]
type = AverageElementSize
block = 'left_block right_block'
[]
[]
(test/tests/mortar/continuity-3d-non-conforming/continuity_sphere_hex.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = spheres_hex8.e
[]
[secondary]
input = file
type = LowerDBlockFromSidesetGenerator
new_block_id = 11
new_block_name = "secondary"
sidesets = '101'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
new_block_id = 12
new_block_name = "primary"
sidesets = '102'
[]
[]
[Problem]
kernel_coverage_check = false
[]
[Variables]
[T]
block = '1 2'
[]
[lambda]
block = 'secondary'
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = '1 2'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'x^2 + y^2 + z^2 - 6'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'x^2 + y^2 + z^2'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = '4'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = '12'
secondary_subdomain = '11'
variable = lambda
secondary_variable = T
correct_edge_dropping = true
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type '
'-pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = '1 2'
[]
[h]
type = AverageElementSize
block = '1 2'
[]
[]
(test/tests/mortar/continuity-2d-non-conforming/soln-continuity.i)
[Mesh]
second_order = true
[file]
type = FileMeshGenerator
file = nodal_normals_test_offset_nonmatching_gap.e
[]
[./primary]
input = file
type = LowerDBlockFromSidesetGenerator
sidesets = '2'
new_block_id = '20'
[../]
[./secondary]
input = primary
type = LowerDBlockFromSidesetGenerator
sidesets = '1'
new_block_id = '10'
[../]
[]
[Variables]
[./T]
block = '1 2'
order = SECOND
[../]
[./lambda]
block = '10'
[../]
[]
[BCs]
[./neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln
variable = T
boundary = '3 4 5 6 7 8'
[../]
[]
[Kernels]
[./conduction]
type = Diffusion
variable = T
block = '1 2'
[../]
[./sink]
type = Reaction
variable = T
block = '1 2'
[../]
[./forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[../]
[]
[Functions]
[./forcing_function]
type = ParsedFunction
expression= '-4 + x^2 + y^2'
[../]
[./exact_soln]
type = ParsedFunction
expression= 'x^2 + y^2'
[../]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[./mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = 20
secondary_subdomain = 10
variable = lambda
secondary_variable = T
[../]
[]
[Preconditioning]
[./smp]
type = SMP
full = true
[../]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type -pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[dofmap]
type = DOFMap
execute_on = 'initial'
[]
[]
(test/tests/mortar/continuity-3d-non-conforming/continuity_penalty_sphere_hex.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = spheres_hex8.e
[]
[secondary]
input = file
type = LowerDBlockFromSidesetGenerator
new_block_id = 11
new_block_name = "secondary"
sidesets = '101'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
new_block_id = 12
new_block_name = "primary"
sidesets = '102'
[]
uniform_refine = 0
[]
[Problem]
error_on_jacobian_nonzero_reallocation = true
[]
[Variables]
[T]
block = '1 2'
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = '1 2'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'x^2 + y^2 + z^2 - 6'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'x^2 + y^2 + z^2'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = '4'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = PenaltyEqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = '12'
secondary_subdomain = '11'
secondary_variable = T
correct_edge_dropping = true
penalty_value = 1.e5
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-ksp_gmres_restart -pc_type -pc_hypre_type -pc_hypre_boomeramg_max_iter'
petsc_options_value = '201 hypre boomeramg 6'
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = '1 2'
[]
[h]
type = AverageElementSize
block = '1 2'
[]
[]
(test/tests/mortar/continuity-3d-non-conforming/continuity_mixed.i)
[Mesh]
second_order = false
[file]
type = FileMeshGenerator
file = mixed_mesh.e
[]
[secondary]
input = file
type = LowerDBlockFromSidesetGenerator
new_block_id = 11
new_block_name = "secondary"
sidesets = '101'
[]
[primary]
input = secondary
type = LowerDBlockFromSidesetGenerator
new_block_id = 12
new_block_name = "primary"
sidesets = '102'
[]
[]
[Problem]
kernel_coverage_check = false
[]
[Variables]
[T]
block = '1 2'
[]
[lambda]
block = 'secondary'
[]
[]
[BCs]
[neumann]
type = FunctionGradientNeumannBC
exact_solution = exact_soln_primal
variable = T
boundary = '1 2'
[]
[]
[Kernels]
[conduction]
type = Diffusion
variable = T
block = '1 2'
[]
[sink]
type = Reaction
variable = T
block = '1 2'
[]
[forcing_function]
type = BodyForce
variable = T
function = forcing_function
block = '1 2'
[]
[]
[Functions]
[forcing_function]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi) + 3*pi^2*sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_primal]
type = ParsedFunction
expression = 'sin(x*pi)*sin(y*pi)*sin(z*pi)'
[]
[exact_soln_lambda]
type = ParsedFunction
expression = 'pi*sin(pi*y)*sin(pi*z)*cos(pi*x)'
[]
[]
[Debug]
show_var_residual_norms = 1
[]
[Constraints]
[mortar]
type = EqualValueConstraint
primary_boundary = 2
secondary_boundary = 1
primary_subdomain = '12'
secondary_subdomain = '11'
variable = lambda
secondary_variable = T
delta = 0.1
[]
[]
[Preconditioning]
[smp]
type = SMP
full = true
[]
[]
[Executioner]
solve_type = NEWTON
type = Steady
petsc_options_iname = '-pc_type -snes_linesearch_type -pc_factor_shift_type '
'-pc_factor_shift_amount'
petsc_options_value = 'lu basic NONZERO 1e-15'
[]
[Outputs]
exodus = true
[]
[Postprocessors]
[L2lambda]
type = ElementL2Error
variable = lambda
function = exact_soln_lambda
execute_on = 'timestep_end'
block = 'secondary'
[]
[L2u]
type = ElementL2Error
variable = T
function = exact_soln_primal
execute_on = 'timestep_end'
block = '1 2'
[]
[h]
type = AverageElementSize
block = '1 2'
[]
[]