1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-01-17 06:08:31 +01:00

update doc

This commit is contained in:
Justin Lin 2022-07-19 10:18:26 +08:00
parent c93d1ae897
commit 97860fdf67
2 changed files with 7 additions and 9 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 49 KiB

After

Width:  |  Height:  |  Size: 67 KiB

View File

@ -1,6 +1,6 @@
# fibonacci_lattice # fibonacci_lattice
Creates visually even spacing of n points on the surface of the sphere. Nearest-neighbor points will all be approximately the same distance apart. There're 8 spirals on the sphere. Creates visually even spacing of n points on the surface of the sphere. Nearest-neighbor points will all be approximately the same distance apart. There're max 21 spirals on the sphere.
(It's called "visually even spacing" because only the vertices of the 5 [Platonic solids](https://en.wikipedia.org/wiki/Platonic_solid) can be said to be truly evenly spaced around the surface of a sphere.) (It's called "visually even spacing" because only the vertices of the 5 [Platonic solids](https://en.wikipedia.org/wiki/Platonic_solid) can be said to be truly evenly spaced around the surface of a sphere.)
@ -30,9 +30,6 @@ Creates visually even spacing of n points on the surface of the sphere. Nearest-
![fibonacci_lattice](images/lib3x-fibonacci_lattice-1.JPG) ![fibonacci_lattice](images/lib3x-fibonacci_lattice-1.JPG)
use <fibonacci_lattice.scad>
use <polyline_join.scad>
n = 200; n = 200;
radius = 20; radius = 20;
pts = fibonacci_lattice(n, radius); pts = fibonacci_lattice(n, radius);
@ -41,16 +38,17 @@ Creates visually even spacing of n points on the surface of the sphere. Nearest-
translate(p) translate(p)
sphere(1); sphere(1);
} }
sphere(radius);
spirals = [for(j = [0:7]) sphere(radius * 0.9);
[for(i = j; i < len(pts); i = i + 8) pts[i]]
spirals = [for(j = [0:20])
[for(i = j; i < len(pts); i = i + 21) pts[i]]
]; ];
for(spiral = spirals) { for(spiral = spirals) {
polyline_join(spiral) polyline_join(spiral)
sphere(.5); sphere(.25);
} }
![fibonacci_lattice](images/lib3x-fibonacci_lattice-2.JPG) ![fibonacci_lattice](images/lib3x-fibonacci_lattice-2.JPG)