Boundary Constraint with Criteria vs Boundary Constraint of Tesselation subset

I am working on creating an automated wind tunnel for my Fluids/CFD students to use. I create a rectangular solid using simple plane STL files and scale and insert (with inverted faces) a user specified STL object into the middle of the rectangular solid. When setting up the no-slip boundary constraint for the object, I can use the interior volume (of the combined rectangle-object tesselation) with position-based criteria (bounding box surrounding the object) in a pointwise boundary constraint. Unless I am misunderstanding the operations it carries out, I could also pass a tesselation of the original scaled object.

Passing the original object (no outer rectangular solid) to the pointwise boundary constraint with no required criteria takes significantly less time and memory to set up. I don’t see any SDF use within the boundary constraint or its parent classes, is this a feasible approach? Or am I missing a bigger picture problem that would prevent this from working?

I don’t think the SDF is in the boundary constraints here because when sampling the boundary we know the exact surface of it from the STL file. Since its exact on the discrete mesh, the SDF is always zero. Note in the tessalation code here the sample function which looks at the mesh triangles to build a pseudo curves object which is used to sample boundary points.

Regarding you comment, yes it is approximately possible with only one small issue which is that you could potentially be sampling inside the object when getting points inside your wind tunnel volume! The STL sampling with a closed volume will make sure the points are in fact in the wind tunnel but also not the object. This could potentially impact training (it could not at all). So just something to be aware of, it things look like they converge (who knows it may be fine) then sounds like a good solution.

Sounds good, I’ll run some test cases with large sample counts to make sure it is sampling where I expect it to occur.