The key take-away is that:
- In most finite element methods, the jump of a quantity across a surface does not require a specific orientation. For instance, in DG methods, you get jump integrals across all internal facets of the grids, but mathematically the formulation doesn’t care which cell is positive and which one is negative.
- DOLFINx follows the same notion, that for an interior facet integral (
dS) which cell comes first (+) and which one is last (-) doesn’t matter if put in the correct variational formulation. - that you get the same result for the two is by chance. Running the problem in parallel might produce a different results as the mesh gets parititioned and the ording might differ.
- Using a one-sided integral will always be correct. You could manually make the interior facet entities orient, but that just requires more memory.