Commit fafa89ee authored by Dennis Gläser's avatar Dennis Gläser Committed by Timo Koch

[md][cclocalassembler] make coupling work for coupling-dependent vars

If variables (e.g. flux vars cache) depend on variables of a coupled
domain, we have to reset them before jumping to the next element in
the coupling stencil. Otherwise subsequent residual computations are
parent 1cc98dd2
......@@ -525,23 +525,14 @@ public:
// restore the undeflected state of the coupling context
this->couplingManager().updateCouplingContext(domainI, *this, domainJ, globalJ, priVarsJ, pvIdx);
// TODO do we have to restore here again???
// if (enableGridFluxVarsCache)
// this->couplingManager().updateCoupledVariables(domainI, *this, curElemVolVars, gridVariables.gridFluxVarsCache());
// else
// this->couplingManager().updateCoupledVariables(domainI, *this, curElemVolVars, elemFluxVarsCache);
// restore original state of the flux vars cache and/or vol vars in case of global caching.
// This has to be done in order to guarantee that everything is in an undeflected
// state before the assembly of another element is called. In the case of local caching
// this is obsolete because the local views used here go out of scope after this.
// We only have to do this for the last primary variable, for all others the flux var cache
// is updated with the correct element volume variables before residual evaluations
// This has to be done in order to guarantee that the undeflected residual computation done
// above is correct when jumping to the next coupled element.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment