%% Plot 3-D Delaunay Triangulation
% Create a 3-D delaunayTriangulation object for 20 random points.

rng('default');
x = rand([20 1]);
y = rand([20 1]);
z = rand([20 1]);
DT = delaunayTriangulation(x,y,z)

% Plot the tetrahedron mesh.

tetramesh(DT)

%
% Change the color of the tetrahedra. Plot it again with the new colors and with more transparent faces.

tetramesh(DT,106:-2:1,'FaceAlpha',0.1)

%
% Copyright 2020 The MathWorks, Inc.