James wrote
I used the external reaction formula to calculate the reaction rates. I found that in Featool, the grids that I used to calculate the reaction rates by external function are not those that are used to couple the reactions to the mass transport. This caused a problem - in external function, I can force concentration to be positive at each grid, but when reactions are coupled to mass transport in other grids, the concentration can be negative, which may cause a strong oscillation pattern. Is there any solution that the grids in the external function can be used to couple the reactions to mass transport?
The evaluation points for custom functions are "quadrature" points (of the selected numerical quadrature rule) of the grid, typically in the interior of the cells. As such, if you for example have a function defined on a grid (for example a triangle), linear (affine) interpolation is monotonicity preserving and should give you a result without over or undershoots. Can you explain further why the external function would cause negative concentrations?