Currently we automate the error estimation step by simply switching the test function(s) for adjoint solution(s) and multiplying throughout by a $\mathbb{P}0$ indicator field. To be more consistent with the standard approach in the literature, we should try to automate the integration by parts process to separate out residual and flux terms. This has previously been done in FEniCS in [Rognes & Logg, 2013].
Currently we automate the error estimation step by simply switching the test function(s) for adjoint solution(s) and multiplying throughout by a $\mathbb{P}0$ indicator field. To be more consistent with the standard approach in the literature, we should try to automate the integration by parts process to separate out residual and flux terms. This has previously been done in FEniCS in [Rognes & Logg, 2013].
Parent issue: https://github.com/pyroteus/pyroteus/issues/9.