platonic_sphere
Version 1.3 (131 KB) by
David Monteverde
Builds class-1 geodesic polyhedra (based on Platonic solids).
The main purpose of this function is to generate points on the surface of a unit sphere that have an optimized uniformity of distribution. A secondary purpose is to facilitate exploration of geodesic polyhedra.
The functional form is:
[polyhedron,properties] = platonic_sphere(symmetry,freq,style)
where inputs are:
symmetry: 'icosahedral', 'octahedral' or 'tetrahedral'
freq: subdivision frequency (natural number)
style: subdivision style ('planar' or 'spherical
The most uniform spherical distribution is produced using icosahedral symmetry. If no input parameters are given, default is icosahedral symmetry with a subdivision frequency of 3 (each face divided as a tetractys) and a planar subdivision style.
Example:
[polyhedron,properties] = platonic_sphere('icosahedral',3)
where output is:
- polyhedron: triangulation object
- properties: structure with fields describing properties of the polyhedron
practicalities:
- visualize: trisurf(polyhedron); axis equal
- make an stl file: stlwrite(polyhedron,'my_psphere')
- make a movie: psphere_movie('octahedral',25)
AUTHOR: David Monteverde
RELEASED: 2024-11-10
UPDATED: 2024-11-29
REV: 1.3
NOTES
1) Surface density of the "platonic sphere" (number of vertices of the subdivided polyhedron) increases quadratically with subdivision frequency:
nvp = (nfb/2)*freq^2 + (neb-3*nfb/2)*freq +( nvb-neb+nfb)
where,
nvp : number of vertices of the subdivided polyhedron
freq : subdivision frequency
nvb : number of vertices of the basis polyhedron
neb : number of edges of the basis polyhedron
nfb : number of faces of the basis polyhedron (platonic solid)
Parenthetically, the above expression is derived from:
nvp = nvb + neb*(freq-1) + nfb*Trinum(freq-2)
where Trinum(n) is the triangular number of n.
For instance, the surface densities for a platonic sphere with icosahedral basis are as follows:
freq: 1 2 3 4 5 6 7 8 9 10 ...
vertices: 12 42 92 162 252 362 492 642 812 1002 ...
2) Additional useful information:
https://en.wikipedia.org/wiki/Geodesic_polyhedron
Pugh, Antony. Polyhedra: a visual approach. University of California Press, 1976
Cite As
David Monteverde (2026). platonic_sphere (https://www.mathworks.com/matlabcentral/fileexchange/175453-platonic_sphere), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2024b
Compatible with R2024a and later releases
Platform Compatibility
Windows macOS LinuxTags
Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
| Version | Published | Release Notes | |
|---|---|---|---|
| 1.3 | streamlined functions, and implemented spherical style subdivision |
|
|
| 1.2 | implemented tetrahedral symmetry, added movie creation function |
||
| 1.1.2 | updated description |
||
| 1.1.1 | modified description |
||
| 1.1 | reverted to planar subdivision |
||
| 1.0.1 | added image to description page |
||
| 1.0.0 |
