Can somebody tell me if this is a bug?
<< NDSolve`FEM`
Table[
x0 = 2.5;
cords = {{-x0, 0, 0}, {x0, 0, 0}};
r =
RegionDifference[
Cuboid[{- L, -L, -L}, {L, L, L}],
RegionUnion[Ball[#, 1] & /@ cords]];
mesh2 = ToElementMesh[ r, "RegionHoles" -> cords];
mesh2["Wireframe"],
{L, 4, 10, 2}]
As you can see the holes in the middle loose their shape as the outer cube becomes larger.
I've tried two different ways of fixing the problem: defining a MeshRefinementFunction
and using implicit region instead of region unions. Neither work. A similar problem I faced with a previous version of Mathematica in 2D is documented here.
If you look carefully at the documentation you can see the same problem:
The inner ellipse has a really bad resolution even though the elements are quite small.
Running 10.3.1 in macosx 10.8.5