Dual Polyhedra Generator

by Tuğrul Yazar | August 3, 2017 13:03

According to Wolfram, “By the duality principle, for every polyhedron, another polyhedron exists in which faces and polyhedron vertices occupy complementary locations. This polyhedron is known as the dual, or reciprocal”. We can use this method to generate new polyhedra from known ones. I tried to develop a Dual Polyhedra Generator in this Rhino Python[1] script. First, the script asks a user to select a closed polysurface object. Then, it attempts to identify the area centroids of the faces. By joining the neighboring centroids, it generates a dual polyhedron. However, it has some bugs and is not working in some cases. This task could be much better solved with polygon meshes because the main problem is to identify the neighborhoods of faces. Works pretty well with simple objects like boxes or Platonic Solids.

This Rhino Python code attempts to generate the dual polyhedron of any closed polysurface. The output of the code is generally a closed polysurface. So it is ready for 3D printing. I tested the code in Rhinoceros 5, 6, and 7 Iron Python but should also work well with Rhinoceros 8 Python 3. So, you don’t need extra add-ons. In Rhinoceros 7, you will type the EditPythonScript command and type and run the code by hitting F5. In Rhinoceros 8, you can access the new script editor by the ScriptEditor command.

dual polyhedra generator

You can rebuild the Rhino Python code by looking at the image above. However, would you consider being my Patreon if you want to support this website by downloading my working Python file? Here is the link to my Patreon page[2], including the Dual Polyhedra Generator and more. Thank you.

Endnotes:
  1. Rhino Python: https://www.designcoding.net/category/tools-and-languages/rhino-python/
  2. Here is the link to my Patreon page: https://www.patreon.com/posts/dual-polyhedra-97061986?utm_medium=clipboard_copy&utm_source=copyLink&utm_campaign=postshare_creator&utm_content=join_link

Source URL: https://www.designcoding.net/dual-polyhedra-generator/