is a set of high-performance vectorized MATLAB functions for building
a triangulation of a unit sphere based on recursive partitioning of each
of Icosahedron faces into 4 triangles with vertices in the middles of
original face edgeMidMat. spheretri
function takes a number of requested
points as an input. An exact number of points in the returned
triangulation may not match this number, the function will choose a depth
of Icosahedron partitioning minimally sufficient to provide the requested
number of points. Alternatively you can use spheretribydepth
function
that expects a partitioning depth as an input.
[vMat, fMat] = spheretri(500);
patch('Vertices',vMat,'Faces',fMat,'FaceColor','g','EdgeColor','k');
[vMat, fMat] = spheretribydepth(3);
patch('Vertices',vMat,'Faces',fMat,'FaceColor','g','EdgeColor','k');
Peter Gagarinov, PhD,
Moscow State University,
Faculty of Computational Mathematics and Computer Science,
System Analysis Department 2011-2017
@misc{Gagarinov2017,
author = {Gagarinov, P.V.},
title = {SphereTri},
year = {2017},
publisher = {GitHub},
journal = {GitHub repository},
howpublished = {\url{https://github.com/pgagarinov/spheretri}},
commit = {a6c89644e2451b0cf73ce386e52ff37f75a503cc}
}