Created
April 9, 2023 00:18
-
-
Save gazzar/3a1c2e1ccfb05f773de2bf987151a9ef to your computer and use it in GitHub Desktop.
stl of solid Smith hat monotile
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Generates an stl of the Smith aperiodic monotile | |
https://cs.uwaterloo.ca/~csk/hat/ | |
https://www.sciencenews.org/article/mathematicians-discovered-einstein-tile | |
""" | |
import cadquery as cq | |
from cadquery import exporters | |
vertices = [ | |
(0, 0), | |
(-1, -1), | |
(0, -2), | |
(2, -2), | |
(2, -1), | |
(4, -2), | |
(5, -1), | |
(4, 0), | |
(3, 0), | |
(2, 2), | |
(0, 3), | |
(0, 2), | |
(-1, 2), | |
] | |
monotile_solid = cq.Workplane("XY").polyline(vertices).close().extrude(1) | |
# Export the solid to an STL file | |
exporters.export(monotile_solid, "smith_monotile.stl") | |
exporters.export(monotile_solid, "smith_monotile.svg") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment