- variableThe variable whose value will be fitted over the patch of elements.
C++ Type:std::vector<VariableName>
Unit:(no unit assumed)
Controllable:No
Description:The variable whose value will be fitted over the patch of elements.
NodalPatchRecoveryVariable
This user object performs the calculations and parallel communication required to carry out the Zienkiewicz–Zhu patch recovery Zienkiewicz and Zhu (1992) for a scalar component of a provided variable.
This object can operate on both Variables and AuxVariables, and supports both nodal and elemental types.
Performs patch recovery using a coupled variable.
Input Parameters
- blockThe list of blocks (ids or names) that this object will be applied
C++ Type:std::vector<SubdomainName>
Controllable:No
Description:The list of blocks (ids or names) that this object will be applied
Optional Parameters
- allow_duplicate_execution_on_initialFalseIn the case where this UserObject is depended upon by an initial condition, allow it to be executed twice during the initial setup (once before the IC and again after mesh adaptivity (if applicable).
Default:False
C++ Type:bool
Controllable:No
Description:In the case where this UserObject is depended upon by an initial condition, allow it to be executed twice during the initial setup (once before the IC and again after mesh adaptivity (if applicable).
- execute_onTIMESTEP_ENDThe list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html.
Default:TIMESTEP_END
C++ Type:ExecFlagEnum
Options:XFEM_MARK, FORWARD, ADJOINT, HOMOGENEOUS_FORWARD, ADJOINT_TIMESTEP_BEGIN, ADJOINT_TIMESTEP_END, NONE, INITIAL, LINEAR, LINEAR_CONVERGENCE, NONLINEAR, NONLINEAR_CONVERGENCE, POSTCHECK, TIMESTEP_END, TIMESTEP_BEGIN, MULTIAPP_FIXED_POINT_END, MULTIAPP_FIXED_POINT_BEGIN, MULTIAPP_FIXED_POINT_CONVERGENCE, FINAL, CUSTOM, TRANSFER
Controllable:No
Description:The list of flag(s) indicating when this object should be executed. For a description of each flag, see https://mooseframework.inl.gov/source/interfaces/SetupInterface.html.
- execution_order_group0Execution order groups are executed in increasing order (e.g., the lowest number is executed first). Note that negative group numbers may be used to execute groups before the default (0) group. Please refer to the user object documentation for ordering of user object execution within a group.
Default:0
C++ Type:int
Controllable:No
Description:Execution order groups are executed in increasing order (e.g., the lowest number is executed first). Note that negative group numbers may be used to execute groups before the default (0) group. Please refer to the user object documentation for ordering of user object execution within a group.
- force_postauxFalseForces the UserObject to be executed in POSTAUX
Default:False
C++ Type:bool
Controllable:No
Description:Forces the UserObject to be executed in POSTAUX
- force_preauxFalseForces the UserObject to be executed in PREAUX
Default:False
C++ Type:bool
Controllable:No
Description:Forces the UserObject to be executed in PREAUX
- force_preicFalseForces the UserObject to be executed in PREIC during initial setup
Default:False
C++ Type:bool
Controllable:No
Description:Forces the UserObject to be executed in PREIC during initial setup
Execution Scheduling Parameters
- control_tagsAdds user-defined labels for accessing object parameters via control logic.
C++ Type:std::vector<std::string>
Controllable:No
Description:Adds user-defined labels for accessing object parameters via control logic.
- enableTrueSet the enabled status of the MooseObject.
Default:True
C++ Type:bool
Controllable:Yes
Description:Set the enabled status of the MooseObject.
- implicitTrueDetermines whether this object is calculated using an implicit or explicit form
Default:True
C++ Type:bool
Controllable:No
Description:Determines whether this object is calculated using an implicit or explicit form
- patch_polynomial_orderPolynomial order used in least squares fitting of material property over the local patch of elements connected to a given node
C++ Type:MooseEnum
Options:CONSTANT, FIRST, SECOND, THIRD, FOURTH
Controllable:No
Description:Polynomial order used in least squares fitting of material property over the local patch of elements connected to a given node
- 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
- prop_getter_suffixAn optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
C++ Type:MaterialPropertyName
Unit:(no unit assumed)
Controllable:No
Description:An optional suffix parameter that can be appended to any attempt to retrieve/get material properties. The suffix will be prepended with a '_' character.
- use_interpolated_stateFalseFor the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Default:False
C++ Type:bool
Controllable:No
Description:For the old and older state use projected material properties interpolated at the quadrature points. To set up projection use the ProjectedStatefulMaterialStorageAction.
Material Property Retrieval Parameters
Input Files
- (test/tests/meshmodifiers/esm_reinitialization/npr_IC_nodal_based_aux.i)
- (test/tests/meshmodifiers/esm_reinitialization/restore_not_restore_test.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies_default.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_no_unsolved_blocks_all_default.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_Quad9.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_output_old_older.i)
- (test/tests/meshmodifiers/esm_reinitialization/setIC_UO_followVar.i)
- (test/tests/meshmodifiers/esm_reinitialization/npr_IC_aux.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_3D_second_order.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_two_variables_npr_for_both.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies_ic_in_var.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies_none_strategy.i)
- (test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_two_variables_npr_normal_set.i)
References
- Olgierd Cecil Zienkiewicz and Jian Zhong Zhu.
The superconvergent patch recovery and a posteriori error estimates. part 1: the recovery technique.
International Journal for Numerical Methods in Engineering, 33(7):1331–1364, 1992.[BibTeX]
@article{zienkiewicz1992superconvergent, author = "Zienkiewicz, Olgierd Cecil and Zhu, Jian Zhong", title = "The superconvergent patch recovery and a posteriori error estimates. Part 1: The recovery technique", journal = "International Journal for Numerical Methods in Engineering", volume = "33", number = "7", pages = "1331--1364", year = "1992", publisher = "Wiley Online Library" }
(test/tests/meshmodifiers/esm_reinitialization/npr_IC_nodal_based_aux.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[u_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'u_recovered'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'u_recovered'
polynomial_fitters = 'u_patch'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[u_recovered]
family = LAGRANGE
order = FIRST
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[u_recovered]
type = ParsedAux
variable = u_recovered
coupled_variables = 'diff'
expression = 'diff^2 -diff-0.5'
execute_on = 'TIMESTEP_END'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/restore_not_restore_test.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch_not_restore]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff_not_restore'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR POLYNOMIAL_NEIGHBOR IC IC"
reinitialize_variables = 'diff diff_not_restore diff_ic_const diff_ic_const_not_restore'
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
polynomial_fitters = 'extrapolation_patch extrapolation_patch_not_restore'
restore_overridden_dofs = "true false true false"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff_not_restore]
order = FIRST
[]
[diff_ic_const]
order = FIRST
initial_condition = 10
[]
[diff_ic_const_not_restore]
order = FIRST
initial_condition = 10
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[diffusion_not_restore]
type = MatDiffusion
variable = diff_not_restore
diffusivity = 'k'
[]
[diff_ic_const]
type = MatDiffusion
variable = diff_ic_const
diffusivity = 'k'
[]
[diff_ic_const_not_restore]
type = MatDiffusion
variable = diff_ic_const_not_restore
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[left_not_restore]
type = DirichletBC
variable = diff_not_restore
boundary = left
value = 10
[]
[bottom_not_restore]
type = DirichletBC
variable = diff_not_restore
boundary = bottom
value = 0
[]
[left_ic_con]
type = DirichletBC
variable = diff_ic_const
boundary = left
value = 10
[]
[bottom_ic_con]
type = DirichletBC
variable = diff_ic_const
boundary = bottom
value = 0
[]
[left_ic_con_not_restore]
type = DirichletBC
variable = diff_ic_const_not_restore
boundary = left
value = 10
[]
[bottom_ic_con_not_restore]
type = DirichletBC
variable = diff_ic_const_not_restore
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies_default.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch2]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR POLYNOMIAL_WHOLE IC"
reinitialize_variables = "diff diff2 diff3"
polynomial_fitters = 'extrapolation_patch extrapolation_patch2'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff2]
order = FIRST
[]
[diff3]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[diffusion3]
type = MatDiffusion
variable = 'diff3'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[left3]
type = DirichletBC
variable = 'diff3'
boundary = left
value = 10
[]
[bottom3]
type = DirichletBC
variable = 'diff3'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
reinitialization_strategy = 'POLYNOMIAL_NEIGHBOR'
reinitialize_variables = 'diff'
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
polynomial_fitters = 'extrapolation_patch'
restore_overridden_dofs = true
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_no_unsolved_blocks_all_default.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
reinitialization_strategy = "IC"
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch2]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch3]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff3'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR POLYNOMIAL_WHOLE POLYNOMIAL_NEARBY"
reinitialize_variables = 'diff diff2 diff3'
nearby_distance_threshold = 0.375
polynomial_fitters = 'extrapolation_patch extrapolation_patch2 extrapolation_patch3'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff2]
order = FIRST
[]
[diff3]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[diffusion3]
type = MatDiffusion
variable = 'diff3'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[left3]
type = DirichletBC
variable = 'diff3'
boundary = left
value = 10
[]
[bottom3]
type = DirichletBC
variable = 'diff3'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_Quad9.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
elem_type = QUAD9
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'diff'
polynomial_fitters = 'extrapolation_patch'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = SECOND
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_output_old_older.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'diff'
polynomial_fitters = 'extrapolation_patch'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[]
[AuxVariables]
[diff_old]
[]
[diff_older]
[]
[]
[AuxKernels]
[diff_old]
type = CopyValueAux
variable = diff_old
source = diff
state = OLD
execute_on = 'initial timestep_end'
[]
[diff_older]
type = CopyValueAux
variable = diff_older
source = diff
state = OLDER
execute_on = 'initial timestep_end'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/setIC_UO_followVar.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'diff'
polynomial_fitters = 'extrapolation_patch'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff2]
order = FIRST
initial_condition = 10
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/npr_IC_aux.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[u_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'u_recovered'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'u_recovered'
polynomial_fitters = 'u_patch'
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[u_recovered]
family = MONOMIAL
order = CONSTANT
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[u_recovered]
type = ParsedAux
variable = u_recovered
coupled_variables = 'diff'
expression = 'diff^2'
execute_on = 'TIMESTEP_END'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = diff
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = diff
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = diff
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_3D_second_order.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 3
nx = 7
ny = 7
nz = 16
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch2]
type = NodalPatchRecoveryVariable
patch_polynomial_order = SECOND
variable = 'diff2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = "diff2"
restore_overridden_dofs = "true"
polynomial_fitters = "extrapolation_patch2"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff2]
order = FIRST
[]
[]
[Kernels]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 1
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_two_variables_npr_for_both.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch2]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'diff diff2'
polynomial_fitters = 'extrapolation_patch extrapolation_patch2'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff2]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies_ic_in_var.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch2]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch3]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff3'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR POLYNOMIAL_WHOLE POLYNOMIAL_NEARBY"
reinitialize_variables = 'diff diff2 diff3'
nearby_distance_threshold = 0.375
polynomial_fitters = 'extrapolation_patch extrapolation_patch2 extrapolation_patch3'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
initial_condition = 50
[]
[diff2]
order = FIRST
[]
[diff3]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[diffusion3]
type = MatDiffusion
variable = 'diff3'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[left3]
type = DirichletBC
variable = 'diff3'
boundary = left
value = 10
[]
[bottom3]
type = DirichletBC
variable = 'diff3'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_three_vars_three_strategies_none_strategy.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR NONE IC"
reinitialize_variables = 'diff diff2 diff3'
polynomial_fitters = 'extrapolation_patch'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff2]
order = FIRST
initial_condition = 10
[]
[diff3]
order = FIRST
initial_condition = 10
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[diffusion3]
type = MatDiffusion
variable = 'diff3'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[left3]
type = DirichletBC
variable = 'diff3'
boundary = left
value = 10
[]
[bottom3]
type = DirichletBC
variable = 'diff3'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]
(test/tests/meshmodifiers/esm_reinitialization/external_moving_boundary_npr_two_variables_npr_normal_set.i)
[GlobalParams]
block = '1'
[]
[Problem]
kernel_coverage_check = 'only_list'
kernel_coverage_block_list = '1'
material_coverage_check = 'only_list'
material_coverage_block_list = '1'
[]
[Mesh]
[gen]
type = GeneratedMeshGenerator
dim = 2
nx = 7
ny = 7
[]
[left]
type = SubdomainBoundingBoxGenerator
input = 'gen'
block_id = 1
bottom_left = '0 0 0'
top_right = '0.25 1 1'
[]
[right]
type = SubdomainBoundingBoxGenerator
input = 'left'
block_id = 2
bottom_left = '0.25 0 0'
top_right = '1 1 1'
[]
[]
[UserObjects]
[extrapolation_patch]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff'
execute_on = 'INITIAL TIMESTEP_END'
[]
[extrapolation_patch2]
type = NodalPatchRecoveryVariable
patch_polynomial_order = FIRST
variable = 'diff2'
execute_on = 'INITIAL TIMESTEP_END'
[]
[]
[MeshModifiers]
[moving_circle]
type = CoupledVarThresholdElementSubdomainModifier
coupled_var = 'phi'
criterion_type = 'BELOW'
threshold = 0
subdomain_id = 1
moving_boundaries = 'moving_boundary'
moving_boundary_subdomain_pairs = '1 2; 1'
block = '1 2'
execute_on = 'INITIAL TIMESTEP_END'
# --- new for setting IC --- #
old_subdomain_reinitialized = false
reinitialize_subdomains = '1'
reinitialization_strategy = "POLYNOMIAL_NEIGHBOR POLYNOMIAL_NEIGHBOR"
reinitialize_variables = 'diff diff2'
polynomial_fitters = 'extrapolation_patch extrapolation_patch2'
restore_overridden_dofs = "true"
[]
[]
[AuxVariables]
[phi]
block = '1 2'
[]
[]
[Functions]
[moving_circle_func]
type = ParsedFunction
expression = (x-t)^2+(y)^2-0.5^2
[]
[]
[AuxKernels]
[phi_kernel]
type = FunctionAux
variable = phi
function = moving_circle_func
block = '1 2'
execute_on = 'INITIAL TIMESTEP_BEGIN'
[]
[]
[Variables]
[diff]
order = FIRST
[]
[diff2]
order = FIRST
[]
[]
[Kernels]
[diffusion]
type = MatDiffusion
variable = 'diff'
diffusivity = 'k'
[]
[diffusion2]
type = MatDiffusion
variable = 'diff2'
diffusivity = 'k'
[]
[]
[Materials]
[material]
type = GenericConstantMaterial
prop_names = 'k'
prop_values = 26.0
[]
[]
[BCs]
[left]
type = DirichletBC
variable = 'diff'
boundary = left
value = 10
[]
[bottom]
type = DirichletBC
variable = 'diff'
boundary = bottom
value = 0
[]
[left2]
type = DirichletBC
variable = 'diff2'
boundary = left
value = 10
[]
[bottom2]
type = DirichletBC
variable = 'diff2'
boundary = bottom
value = 0
[]
[]
[Executioner]
type = Transient
dt = 0.3
num_steps = 3
nl_abs_tol = 1e-12
nl_rel_tol = 1e-50
[]
[Outputs]
exodus = true
[]