linear_extrude(10) circle(r = 15, $fn = 100);
Incidentally, be careful of setting $fn too high on complex shapes. This can
make OpenSCAD take a long time to process, or even crash (and lose all
your model coding). Be sure to save your model before trying to preview or
render it.
POLYHEDRONS
Now that we have looked at 2D shapes, we can move up to 3D. Polyhedrons
are solid objects that do not have any curved surfaces. For example, a 3D
rectangular box is a polyhedron, but a cylinder is not (because its sides are
curved). Each side of a polyhedron (like the top or bottom of a cube) is called
a face, and we usually call the line connecting two faces an edge.
Just as there is a special category of polygons with all sides equal, there is
also a category for solids that have the same regular polygon making up all
their sides. These are called Platonic Solids, and there are only five of them.
PLATONIC SOLIDS
There are just five solids that meet the definition of Platonic solids, named
after the Greek philosopher Plato, who lived about 2400 years ago and was
very into things being symmetrical and regular. To be a Platonic solid, the
edges must be equal, all the angles at which those edges meet must be
equal, and the same number of faces must meet at each vertex. They are the
tetrahedron (4 triangular faces), the cube ( 6 square faces), the octahedron (8
triangular faces), the dodecahedron (12 pentagonal faces), and the icosahe-
dron (20 triangular faces). We will see a lot more of them in Chapter 9.
PLATONIC SOLIDS MODELS
The file platonicSolids.scad can be used to create these objects, as shown
in Figure 3-3. It creates all of the solids at once, scaled to be size millime-
ters tall when they are resting on one face. If you elect to scale the models in
your slicing software, note that they will cease to be Platonic solids if you do
not scale them uniformly. You can however change the value of size and all
the solids will scale consistently.
We also have a second file, edge_platonic_solids.scad which allows you
to print a set of Platonic solids defined by the length of each edge of the
polygons. You might find this one more useful later on in Chapter 9 when we
study the surface area, and it is more convenient in general for calculation to
38 Chapter 3: Simulating Geometry Make: Geometry 39
Geometry_Chapter10_v15.indd 38Geometry_Chapter10_v15.indd 38 6/23/2021 9:08:40 AM6/23/2021 9:08:40 AM