freeBoundary
自由边界面
说明
示例
二维 Delaunay 三角剖分
您可以使用 freeBoundary
函数来突出显示二维 Delaunay 三角剖分的外边。
基于一组二维点创建三角剖分。
rng('default')
x = rand([20,1]);
y = rand([20,1]);
TR = delaunayTriangulation(x,y);
查找自由边界边。
F = freeBoundary(TR);
绘制三角剖分并用红色突出显示自由边界边。
triplot(TR) hold on plot(x(F),y(F),'-r','LineWidth',2)
三维三角剖分的曲面图
您可以使用 freeBoundary
函数提取三维三角剖分中覆盖对象曲面的各分面。
加载三维三角剖分。
load tetmesh
TR = triangulation(tet,X);
计算边界三角剖分。
[F,P] = freeBoundary(TR);
绘制边界三角剖分。
trisurf(F,P(:,1),P(:,2),P(:,3), ... 'FaceColor','cyan','FaceAlpha',0.8);
输入参数
TR
— 三角剖分表示法
标量三角剖分对象
三角剖分表示法,指定为标量 triangulation
或 delaunayTriangulation
对象。
数据类型: triangulation
| delaunayTriangulation
输出参数
F
— 三角剖分连接列表
矩阵
三角剖分连接列表,以矩阵形式返回。
如果您使用一个输出参数调用 freeBoundary
,则 F
的元素是输入三角剖分的 Points
属性中的行号。如果您使用两个输出参数调用 freeBoundary
,则 F
的元素是 P
中的行号。
数据类型: double
P
— 自由边界点
矩阵
自由边界点,作为包含自由边界面的顶点坐标的矩阵返回。P
的每一行包含一个顶点的坐标。
数据类型: double
扩展功能
基于线程的环境
使用 MATLAB® backgroundPool
在后台运行代码或使用 Parallel Computing Toolbox™ ThreadPool
加快代码运行速度。
版本历史记录
在 R2013a 中推出
MATLAB 命令
您点击的链接对应于以下 MATLAB 命令:
请在 MATLAB 命令行窗口中直接输入以执行命令。Web 浏览器不支持 MATLAB 命令。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)