Bug introduced in 10.4 and persists through 11.1
In answering this question, I realized the OP and I were obtaining different results from the alphaShapes2D
code. This question was updated with additional point sets, but when I tried to use my answer there, it failed. The OP used my answer and got really good results which made me realize something has changed between Mathematica versions 10.3.1 and 10.4. I think I may have tracked the problem down to DelaunayMesh
. To see what I mean, here are the MeshRegion
s generated from the data obtained from the linked question using the same alpha parameter (10.4 is on the right of the following images):
alphaShapes2D[points, 3.0]
You can see it's more pronounced if we try to extract the region boundaries:
When I tried to apply the code to the second data set provided (points2
), Mathematica 10.3.1 returns the nice result shown in the linked question whereas, 10.4 fails to return any useful result. After spending some time debugging the only thing I could come up with is that DelaunayMesh
is doing something different in both versions. For instance the number of mesh cells returned in both versions are different:
$Version
dd = DelaunayMesh[points];
MeshCellCount[dd, All]
Also, as you can see from above, in 10.4 DelaunayMesh
claims there's a degenerate polygon but we don't see this error in 10.3.1. Can anyone reproduce this? Is this a change in algorithm in DelaunayMesh
?
Comments
Post a Comment