How do I specify a hole with its coordinates ?

2 次查看(过去 30 天)
Hi,
How do i specify a hole in MATLAB ?
in other words, How do i make matlab realize a hole, from points in cloud ?
Example: Below is code for a slab with a hole. The coordinates of hole and corners of slab are specified. But the faces of hole are not being realized , when the code if executed.
vert=[0 0 0;10 0 0;10 20 0; 0 20 0; 5 5 0;7.5 5 0;7.5 10 0;5 10 0; 5 5 3;7.5 5 3;7.5 10 3;5 10 3; 0 0 3;10 0 3;10 20 3; 0 20 3];
GG=delaunayTriangulation(vert);
faceColor = [0.6875 0.8750 0.8984]; figure
tetramesh(GG,'FaceColor',faceColor,'FaceAlpha',0.3);
[FBtri,FBpoints] = freeBoundary(GG); size(FBtri) size(FBpoints)
Note: The actual answer has to be 32 faces instead of 28. The problem is the faces inside a hole is not taken into account here.

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Delaunay Triangulation 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by