forked from idaholab/moose
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allow skipping adjustment without error and allow two negative adjust…
…ers in conservative transfers (idaholab#15952)
- Loading branch information
schuseba
authored and
jain651
committed
Apr 19, 2021
1 parent
2ccc74a
commit 85de18c
Showing
8 changed files
with
295 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+59.5 KB
.../tests/transfers/multiapp_conservative_transfer/gold/primary_negative_adjuster_out_sub0.e
Binary file not shown.
Binary file added
BIN
+59.5 KB
test/tests/transfers/multiapp_conservative_transfer/gold/primary_skipped_adjuster_out_sub0.e
Binary file not shown.
87 changes: 87 additions & 0 deletions
87
test/tests/transfers/multiapp_conservative_transfer/primary_negative_adjuster.i
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,87 @@ | ||
[Mesh] | ||
type = GeneratedMesh | ||
dim = 2 | ||
nx = 1 | ||
ny = 1 | ||
[] | ||
|
||
[Variables] | ||
[u] | ||
[] | ||
[] | ||
|
||
[Kernels] | ||
[diff] | ||
type = Diffusion | ||
variable = u | ||
[] | ||
[] | ||
|
||
[BCs] | ||
[left] | ||
type = DirichletBC | ||
variable = u | ||
boundary = left | ||
value = 0 | ||
[] | ||
[right] | ||
type = DirichletBC | ||
variable = u | ||
boundary = right | ||
value = 1 | ||
[] | ||
[] | ||
|
||
[AuxVariables] | ||
[var] | ||
family = MONOMIAL | ||
order = THIRD | ||
[] | ||
[] | ||
|
||
[ICs] | ||
[var_ic] | ||
type = FunctionIC | ||
variable = var | ||
function = '-exp(x * y)' | ||
[] | ||
[] | ||
|
||
[Executioner] | ||
type = Steady | ||
solve_type = 'PJFNK' | ||
petsc_options_iname = '-pc_type -pc_hypre_type' | ||
petsc_options_value = 'hypre boomeramg' | ||
[] | ||
|
||
[MultiApps] | ||
[sub] | ||
type = FullSolveMultiApp | ||
input_files = secondary_negative_adjuster.i | ||
execute_on = timestep_end | ||
[] | ||
[] | ||
|
||
[Postprocessors] | ||
[from_postprocessor] | ||
type = ElementIntegralVariablePostprocessor | ||
variable = var | ||
execute_on = 'TIMESTEP_BEGIN' | ||
[] | ||
[] | ||
|
||
[Transfers] | ||
[to_sub] | ||
type = MultiAppMeshFunctionTransfer | ||
direction = to_multiapp | ||
source_variable = var | ||
variable = var | ||
multi_app = sub | ||
from_postprocessors_to_be_preserved = 'from_postprocessor' | ||
to_postprocessors_to_be_preserved = 'to_postprocessor' | ||
[] | ||
[] | ||
|
||
[Outputs] | ||
exodus = true | ||
[] |
88 changes: 88 additions & 0 deletions
88
test/tests/transfers/multiapp_conservative_transfer/primary_skipped_adjuster.i
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
[Mesh] | ||
type = GeneratedMesh | ||
dim = 2 | ||
nx = 1 | ||
ny = 1 | ||
[] | ||
|
||
[Variables] | ||
[u] | ||
[] | ||
[] | ||
|
||
[Kernels] | ||
[diff] | ||
type = Diffusion | ||
variable = u | ||
[] | ||
[] | ||
|
||
[BCs] | ||
[left] | ||
type = DirichletBC | ||
variable = u | ||
boundary = left | ||
value = 0 | ||
[] | ||
[right] | ||
type = DirichletBC | ||
variable = u | ||
boundary = right | ||
value = 1 | ||
[] | ||
[] | ||
|
||
[AuxVariables] | ||
[var] | ||
family = MONOMIAL | ||
order = THIRD | ||
[] | ||
[] | ||
|
||
[ICs] | ||
[var_ic] | ||
type = FunctionIC | ||
variable = var | ||
function = '-exp(x * y)' | ||
[] | ||
[] | ||
|
||
[Executioner] | ||
type = Steady | ||
solve_type = 'PJFNK' | ||
petsc_options_iname = '-pc_type -pc_hypre_type' | ||
petsc_options_value = 'hypre boomeramg' | ||
[] | ||
|
||
[MultiApps] | ||
[sub] | ||
type = FullSolveMultiApp | ||
input_files = secondary_negative_adjuster.i | ||
execute_on = timestep_begin | ||
[] | ||
[] | ||
|
||
[Postprocessors] | ||
[from_postprocessor] | ||
type = ElementIntegralVariablePostprocessor | ||
variable = var | ||
execute_on = 'TIMESTEP_BEGIN' | ||
[] | ||
[] | ||
|
||
[Transfers] | ||
[to_sub] | ||
type = MultiAppMeshFunctionTransfer | ||
direction = to_multiapp | ||
source_variable = var | ||
variable = var | ||
multi_app = sub | ||
from_postprocessors_to_be_preserved = 'from_postprocessor' | ||
to_postprocessors_to_be_preserved = 'to_postprocessor' | ||
allow_skipped_adjustment = true | ||
[] | ||
[] | ||
|
||
[Outputs] | ||
exodus = true | ||
[] |
64 changes: 64 additions & 0 deletions
64
test/tests/transfers/multiapp_conservative_transfer/secondary_negative_adjuster.i
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
[Mesh] | ||
type = GeneratedMesh | ||
dim = 2 | ||
nx = 20 | ||
ny = 20 | ||
[] | ||
|
||
[Variables] | ||
[u] | ||
[] | ||
[] | ||
|
||
[Kernels] | ||
[diff] | ||
type = Diffusion | ||
variable = u | ||
[] | ||
[] | ||
|
||
[AuxVariables] | ||
[var] | ||
family = MONOMIAL | ||
order = CONSTANT | ||
[] | ||
[] | ||
|
||
[BCs] | ||
[left] | ||
type = DirichletBC | ||
variable = u | ||
boundary = left | ||
value = 0 | ||
[] | ||
[right] | ||
type = DirichletBC | ||
variable = u | ||
boundary = right | ||
value = 1 | ||
[] | ||
[] | ||
|
||
[Postprocessors] | ||
[to_postprocessor] | ||
type = ElementIntegralVariablePostprocessor | ||
variable = var | ||
execute_on = 'transfer nonlinear TIMESTEP_END' | ||
[] | ||
[] | ||
|
||
[Problem] | ||
type = FEProblem | ||
[] | ||
|
||
[Executioner] | ||
type = Steady | ||
solve_type = 'PJFNK' | ||
nl_abs_tol = 1e-12 | ||
petsc_options_iname = '-pc_type -pc_hypre_type' | ||
petsc_options_value = 'hypre boomeramg' | ||
[] | ||
|
||
[Outputs] | ||
exodus = true | ||
[] |
Oops, something went wrong.