CompFab 2D Grid
For this project, I tried to create an object that could be 3D-printed for the first time! This model was largely based off the class tutorial, with some modifications to the Grasshopper Python script to create a slightly different final structure.
Supplies
Rhino 6 with Grasshopper (for Windows 10)
Pufferfish Rhino extension
Ultimaker Cura
Set Initial Points in Rhino
Open Rhino and select a canvas. I used the "Small Objects- Feet and Inches" canvas.
Place two points on the canvas. The two points I used, shown in the screenshot above, were approximately (0,0) and (42,42). These points will determine the extreme corners of the grid that will be generated with Grasshopper.
Generating the Grid Pattern in Grasshopper
Open Grasshopper (using the search bar in Rhino to find the Grasshopper command) and create a new file. Then, add the components described in the list below to the Grasshopper canvas and connect them to create the structure shown in the screenshot above:
- 2 Pt objects
- Right-click, then click "Set one point" and assign each of these to one of the points you placed earlier in the Rhino canvas
- 4 number slider objects
- mod and rx should be set to the integer domain, while dist and Distance can have decimal values
- dist is used to determine the number of edges in the figure
- Distance is used to determine the width of each linear component (the distance of the offset edges from the grid edges)
-
1 Python script object
- The attached grasshopper_script.py file holds the contents of this script object, and describes each input and output
- It generates a list of points in the grid and a list of edges between them.
-
1 Curve object
- This converts the set of edges generated by the Python script to a set of curves
- 1 Offset Curve object from Pufferfish
- This will not be on the standard Grasshopper object menu- Pufferfish must be properly installed
- This will place 2 curves on either side of the existing curves (from the Curve component) to give each edge a width
-
1 Boundary object
- This "fills in" those offset curves to create physical surfaces along the grid edges
- 1 Extrude object
- This converts the surfaces from the Boundary object to actual volumes
- 1 Vector object
- This determines the height of the extruded pattern. You should add a new vector in the Rhino canvas, then click "Set one vector" on this Grasshopper object and select the Rhino vector to connect these components.
-
1 SurfaceUnion object
- This is meant to combine all the extruded objects into a single object, but it doesn't work reliably for complicated patterns.
The main output from the Python script object that we care about is the set of edges between the points, but the screenshot above also shows another Pt output that receives the list of points used in the grid. This is connected to a DelaunayEdge component for visualization of the grid generated by the script, but these components aren't actually used in generating the object.
If the Grasshopper system is built correctly and the script doesn't have any errors, you should see the structure generated in the Rhino canvas.
Downloads
Baking and Unifying the Object
If the Surface Union in Grasshopper works, then right-click the component and select "Bake" in the drop-down menu. This should generate a single solid form in Rhino. If it doesn't work, then select "Bake" in the right-click menu of the Extrude component instead. This makes the form generated by Grasshopper into a bunch of intersecting solid objects. Then, to unify those smaller forms, select them all in Rhino and run the "BooleanUnion" command. You should get a final result that looks like the screenshot (when the object is deselected afterwards).
I personally ran into a lot of problems with this step. The Surface Union component rarely worked for me, so I often went the route of baking the extrusion and then trying to unify it in Rhino. However, the operation kept failing when I had more complex shapes, so I had to keep simplifying my code and the input parameters in Grasshopper to get a shape that was simple enough to unify and that I still thought looked interesting.
I found this article that explained why the union operation fails so often and I tried to follow the steps it described by hand, but Rhino kept crashing on me when I tried to run Split on complicated forms as well.
Slicing the Object in Cura
Select the object in Rhino and run the Scale command to resize it to the amount you want. Click "Export Selected" in the File menu and export the object as an STL (stereolithography) object.
Then, open the file in Ultimaker Cura and click "Slice". This separates the model into the different layers it'll be printed in and gives you an estimate of how long it would take to print. When I accidentally had my model scaled to 42 feet, I got an estimate of almost 2 hours (shown in the screenshot above). I eventually scaled my model down to about 6"X7", which gave me a build time of under a minute. I decided to keep the screenshot of the larger model for the example screenshot, however, since it shows more detail of the sliced object.