Residual-type a posteriori error estimator


Assuming that I have the 2D diffusion-reaction problem with pure Neumann b.c., is there a way to obtain a residual type estimator for H1 norm, in order to use it in an adaptive algorithm? Namely, I would like to compute the following quantity for every element K on the mesh,

[\eta_{1, K}=\left{h_K^2\left|f+\Delta u_h-u_h\right|K^2+\frac{1}{2} \sum{S \in \partial K \cap S_{int}} h_S\left|\left[ \nabla u_h\cdot \vec{n}\right]\right|S^2+\sum{S\in \partial K\cap \partial \Omega} h_S\left|g- \nabla u_h\cdot \vec{n}\right|_S^2\right}^{\frac{1}{2}}.]

Here f and g are the right hand side on the domain and the boundary, respectively, while S is an edge and S_{int} is the set of all interior edges.

Best regards,