Assume you have a FEM level-set function indicating the interior of an object inside a rectangular domain, and assume you want to extract the volume mesh of that object.
I need a command which acts similarly to the FreeFem++ “trunc”:
mesh3 Rh = trunc(Th, uh > 0.0);
that gives a mesh Rh obtained from a mesh Th truncating this last one on the cells and vertices such that uh is greater than zero.
Is it possible to do something similar in dolfin? I am using the C++ API.