3D Printed Hexagonal Clay Cup
A clay cup with a hexagonal base and walls formed by rotating the hexagon by an offset at each layer. Printed on potterbot. The gcode for potterbot is manually generated using Grasshopper with Rhino.
Downloads
Supplies
- Rhino
- Grasshopper potterbot example
- Potterbot (actually expensive for how much work you have to do for it to work properly)
- Clay
- Manual labor (mainly for potterbot)
Modifying Cylinder Example With Base
I started with the example code for generating a cylinder with circular bases. I modified the code to print hexagons instead of circles at each layer. Each layer of the base has to spiral towards the center, then spiral back out since once the clay starts extruding, it cannot retract so the toolpath has to be continuous.
While the code seemingly works for a hexagon, it breaks for any other N-gons (e.g. squares (4-gon) and pentagons (5-gon) even though I designed for it to support different regular polygons. There's likely some logic error in calculating how each spiral of the base offset from one another. Additionally, the generated gcode had way more lines than it needed to have since I created a point every 2mm based off of the original cylinder code despite the fact that a hexagon has way fewer edges than a circle does (which both approaches infinite edges and no edge).
Rewriting for Cleaner Algorithm to Generate N-gon
To clean up the logic for the code and reduce the chances for bugs, I turned to a different way to generate the toolpath. Instead of outlining the toolpath by creating a bunch of points along the path like I would a circle, it is only the vertices of the polygon that is important for generating a correct toolpath.
By using the fact that the vertices of a regular polygon are evenly distributed along a circle, it was a lot cleaner to compute the vertices using the inner angles of a hexagon.
Debugging the Base
I ran into bugs where there is a double path in spiraling the base which doesn't quite overlap with each other.
Odd. But it looks kind of cool.
Apparently, I messed up the spiral count so it was tracing the spiral twice 4 times rather than 2?? Not sure, something happened.
However, it then seems like the connection to the next layer of the spiral now disrupts one edge of the hexagon. This is because we are only using 6 points per spiral such that the 6th point of an outer spiral is connecting directly with the 1st point of the next inner spiral. Well, that's not what we wanted
Adding a 7th Point
At first, I tried appending the first point in a spiral as the last point of the spiral as well. Unsurprisingly, Rhino Points are not literal, but rather references so this might've created some weird behaviors.
By generating new point objects as the 7th point, it seems like we are successfully closing each spiral. Except, we have to account for the nozzle width. Otherwise when it tries to close each spiral and move on to the next, the nozzle will run itself into the existing print.
By calculating for a slight offset from the 1st point of each spiral based on trigonometry, we now have the base generating properly.
Generating Hexagonal Cup
Now we apply the same algorithm for generating N-gons to wall generation. Without any rotation for each layer of the wall, our hexagonal prism looks pretty good.
Rotating Each Layer of Wall
The good thing with generating vertices by distributing the points along a circle is that it also makes applying rotation offsets to each layer fairly trivial. It comes down to adding a slight angle offset when computing the vertices based on the inner angles of the polygon.
Well, as long as you don't apply the angle offset to the wrong term which will result in some cool unprintable geometry. But cool, nonetheless.
It is important to adjust this rotation offset so that each layer of the wall can provide sufficient support for the next, and that no significant overhangs is occuring.
Parameterizing N-gons
Since we created the design to be generic by parameterizing the number of sides for the regular polygon, we can create the design from squares or octagons as well.
Printing (unsuccessfully)
Unfortunately, our first attempts at printing were not particularly successful.
First, you have the potterbot not lowering the nozzle all the way to the bed when it starts the printing, resulting in spaghettis.
Next, you have the potterbot severly deforming the base, and subsequently the walls since this is a design that is heavily dependent on each layer providing support for the next as each layer rotates slightly from the previous.
At least one side of the print is somewhat presentable.
I'm sure potterbot tried its best, but the clay might be drying out, causing the print to be lumpy and breaks off the extrusion every once in a while.
Printing (Successfully)
At last, we were able to get successful prints. Some adjustments had to be made for this to happen:
- there was a bug in the code where the spiraling in and spiraling out of the base were happening on the same z-height, which means there was a big increase in height between the first layer of the base and the third
- Increased the radius of the design so the printer has more space to draw out the angle at each vertex