AuxKernel required for proper Postprocessor evaluations with ExternalProblem #17534
Labels
C: Framework
P: normal
A defect affecting operation with a low possibility of significantly affects.
T: defect
An anomaly, which is anything that deviates from expectations.
Bug Description
When using the
ExternalProblem
interface, postprocessors of variables added viaaddExternalVariables
and written insyncSolutions
are lagged by one time step if the input file lacks any AuxKernels. For our OpenMC wrapping, our input files are quite slim, and don't have any AuxVariables or AuxKernels defined in the XML files. For the first time step, the lack of an AuxKernel is causing ourElementIntegralVariablePostprocessor
of an external variable that we write to withinsyncSolutions
to evaluate to 0.0, even though the variable is displayed correctly in the Exodus output and is nonzero.Steps to Reproduce
I have attached a minimum working example with a very slimmed down
BasicExternalProblem
that creates a CONSTANT MONOMIAL variableheat_source
and writes a value of12345.0
to it withinsyncSolutions
. If the input file looks like this:then even if we are writing correctly to
heat_source
(and the Exodus file shows a heat source of 12345.0), the postprocessor evaluates to zero:However, if you just add a dummy AuxKernel that has nothing to do with the physics, i.e. adding this to the above file:
then the postprocessor evaluates correctly:
If you increase
num_steps
, you'll see that the values are lagged by one time step for some reason.What I think is the problem
So it seems that something needs to be fixed along the lines of:
The absence of auxkernels should not be what triggers when
_u
orcoupledValue
are evaluated (i.e. whatever Postprocessors grab) when usingExternalProblem
. I made aFEProblem
input (seetest.i
) that haskernel_coverage_check = false
andskip_nl_system_check = true
, and I did not see the same behavior - so it seems that this error is specific toExternalProblem
.Impact
Annoyance - we can just add dummy AuxVariables and AuxKernels to all our inputs to get around this, but this is prone to errors for anyone who doesn't understand that dummy AuxKernels are needed to get correct problem output.
The text was updated successfully, but these errors were encountered: