Skip to content

Latest commit

 

History

History
39 lines (31 loc) · 1.46 KB

README.md

File metadata and controls

39 lines (31 loc) · 1.46 KB

SPHERETRI

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.

Examples:
[vMat, fMat] = spheretri(500);
patch('Vertices',vMat,'Faces',fMat,'FaceColor','g','EdgeColor','k');

Result:

[vMat, fMat] = spheretribydepth(3);
patch('Vertices',vMat,'Faces',fMat,'FaceColor','g','EdgeColor','k');

Result:

Copyright:

Peter Gagarinov, PhD,
Moscow State University,
    Faculty of Computational Mathematics and Computer Science,
    System Analysis Department 2011-2017

Citing key:
	@misc{Gagarinov2017,
	  author = {Gagarinov, P.V.},
	  title = {SphereTri},
	  year = {2017},
	  publisher = {GitHub},
	  journal = {GitHub repository},
	  howpublished = {\url{https://github.com/pgagarinov/spheretri}},
	  commit = {a6c89644e2451b0cf73ce386e52ff37f75a503cc}
	}