This is a read only copy of the old FEniCS QA forum. Please visit the new QA forum to ask questions

Surface integral over non-boundary surface revisited

+1 vote

Hello,

Similar to a previous question I would like calculate integrals over surfaces not lying on the boundary. The motivation is related to a reconstruction problem, where sparse cross sectional slice observations are available from a flow volume.

A solution is provided in the answer to Computing surface integral over surface not on boundary:

class InnerBoundary(SubDomain):
    def inside(self,x, on_boundary):
        [...]
inner_bndr = InnerBoundary()
inner_bndr.mark(boundary_parts,3)
ds = Measure("ds")[boundary_parts]

flux = dot(Constant((1.0,0.0,0)), avg(u)*dS(3)

According to my limited experience this is only practical, if the internal facets of the mesh are aligned with the evaluation surface, such that facet markers can be created based on proximity arguments.

I was wondering if there was a recommended way to enable the use of, non face aligned evaluation surfaces.

Creating a mesh for the surface and integrating the interpolated field might be a solution but it would require external tools in my understanding.

Any help will be much appreciated.

asked Aug 3, 2015 by peter-ma FEniCS Novice (170 points)
...