mirror of
https://github.com/JustinSDK/dotSCAD.git
synced 2025-08-14 10:44:48 +02:00
add polar_zonohedra
This commit is contained in:
@@ -363,6 +363,7 @@ These examples incubate dotSCAD and dotSCAD refactors these examples. See [examp
|
|||||||
Signature | Description
|
Signature | Description
|
||||||
--|--
|
--|--
|
||||||
[**polyhedra/star**([outerRadius, innerRadius, height, n])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_star.html) | create a 3D star.
|
[**polyhedra/star**([outerRadius, innerRadius, height, n])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_star.html) | create a 3D star.
|
||||||
|
[**polyhedra/polar_zonohedra**(n[, theta])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_polar_zonohedra.html) | create a [polar zonohedra](https://mathworld.wolfram.com/PolarZonohedron.html).
|
||||||
[**polyhedra/tetrahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_tetrahedron.html) | create a tetrahedron.
|
[**polyhedra/tetrahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_tetrahedron.html) | create a tetrahedron.
|
||||||
[**polyhedra/hexahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_hexahedron.html) | create a hexahedron.
|
[**polyhedra/hexahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_hexahedron.html) | create a hexahedron.
|
||||||
[**polyhedra/octahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_octahedron.html) | create a octahedron.
|
[**polyhedra/octahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_octahedron.html) | create a octahedron.
|
||||||
|
BIN
docs/images/lib3x-polyhedra_polar_zonohedra-1.JPG
Normal file
BIN
docs/images/lib3x-polyhedra_polar_zonohedra-1.JPG
Normal file
Binary file not shown.
After Width: | Height: | Size: 41 KiB |
22
docs/lib3x-polyhedra_polar_zonohedra.md
Normal file
22
docs/lib3x-polyhedra_polar_zonohedra.md
Normal file
@@ -0,0 +1,22 @@
|
|||||||
|
# octahedron
|
||||||
|
|
||||||
|
Creates a [polar zonohedra](https://mathworld.wolfram.com/PolarZonohedron.html).
|
||||||
|
|
||||||
|
**Since:** 3.2
|
||||||
|
|
||||||
|
## Parameters
|
||||||
|
|
||||||
|
- `n` : n equal rhombs surrounding one vertex. (rotational symmetry)
|
||||||
|
- `theta` : the pitch angle of the edges.
|
||||||
|
|
||||||
|
## Examples
|
||||||
|
|
||||||
|
use <polyhedra/polar_zonohedra.scad>;
|
||||||
|
|
||||||
|
for(n = [3:8]) {
|
||||||
|
translate([0.5 * n * (n - 3), 0, 0])
|
||||||
|
polar_zonohedra(n);
|
||||||
|
}
|
||||||
|
|
||||||
|

|
||||||
|
|
@@ -40,7 +40,7 @@ release:
|
|||||||
Signature | Description
|
Signature | Description
|
||||||
--|--
|
--|--
|
||||||
[**polyhedra/star**([outerRadius, innerRadius, height, n])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_star.html) | create a 3D star.
|
[**polyhedra/star**([outerRadius, innerRadius, height, n])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_star.html) | create a 3D star.
|
||||||
polyhedra/polar_zonohedra | ...
|
[**polyhedra/polar_zonohedra**(n[, theta])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_polar_zonohedra.html) | create a [polar zonohedra](https://mathworld.wolfram.com/PolarZonohedron.html).
|
||||||
[**polyhedra/tetrahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_tetrahedron.html) | create a tetrahedron.
|
[**polyhedra/tetrahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_tetrahedron.html) | create a tetrahedron.
|
||||||
[**polyhedra/hexahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_hexahedron.html) | create a hexahedron.
|
[**polyhedra/hexahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_hexahedron.html) | create a hexahedron.
|
||||||
[**polyhedra/octahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_octahedron.html) | create a octahedron.
|
[**polyhedra/octahedron**(radius[, detail])](https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_octahedron.html) | create a octahedron.
|
||||||
|
@@ -1,6 +1,8 @@
|
|||||||
use <../util/sum.scad>;
|
use <../util/sum.scad>;
|
||||||
use <../util/flat.scad>;
|
use <../util/flat.scad>;
|
||||||
|
|
||||||
|
// http://archive.bridgesmathart.org/2021/bridges2021-7.pdf
|
||||||
|
|
||||||
function vertex(i, j, n, theta) =
|
function vertex(i, j, n, theta) =
|
||||||
i > j ? [0, 0, 0] :
|
i > j ? [0, 0, 0] :
|
||||||
sum([
|
sum([
|
||||||
|
@@ -1,13 +1,12 @@
|
|||||||
// http://archive.bridgesmathart.org/2021/bridges2021-7.pdf
|
/**
|
||||||
|
* polar_zonohedra.scad
|
||||||
// use <util/sum.scad>;
|
*
|
||||||
// use <util/flat.scad>;
|
* @copyright Justin Lin, 2021
|
||||||
// use <polyhedra/polar_zonohedra.scad>;
|
* @license https://opensource.org/licenses/lgpl-3.0.html
|
||||||
|
*
|
||||||
// for(n = [3:8]) {
|
* @see https://openhome.cc/eGossip/OpenSCAD/lib3x-polyhedra_polar_zonohedra.html
|
||||||
// translate([0.5 * n * (n - 3), 0, 0])
|
*
|
||||||
// polar_zonohedra(n);
|
**/
|
||||||
// }
|
|
||||||
|
|
||||||
use <geom_polar_zonohedra.scad>;
|
use <geom_polar_zonohedra.scad>;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user