PLANARIZE cells coming from Kangaroo simulation

Hello everyone! Hope you are doing well ))

I have generated a hexagonal cell in a first kangaroo simulation, but the resulting cells are not planar as you can see at the pictures. I have tried to make a second simulation by using the components of coplanar (kangaro 2) and planarize (kanagaro physics). Some of the cells are now in the same plane so it is possible to apply a boundary surfaces , but some others are still not planar. Furthermore, the hexagonal cell system morphs too much so the system doesn-t looks good.

I don’t know if it is me that I am not setting properly some parameters or I am missing some components or something that I can not see. If you have any suggestions I would be very helpful! Thanks in advance!

PS> pics and gh file are attached




Hex Cells.gh (226.6 KB)

Making planar hexagons is quite different from making planar quads.

With quads, provided they are reasonably close to the surface curvature directions, it is usually possible to make them planar without changing the shape too much.

With hexagons though, when you have regions of negative curvature (which your shape does around the funnels, and between the domes), it is geometrically impossible to make all the hexagons both planar and convex. Some of them have to become ‘bowtie’ shaped.
If you use a weak anchor to the starting positions of the vertices, and gradually increase the highlighted planarization slider all the way up, you can can make them planar without intersecting themselves or each other. The second example shows how you can also apply Laplacian smoothing (you’ll need to set the assembly reference of the scripted component when you open it, and it also uses the ‘topologizer’ component). You can get different results by changing the ratio of the anchor strength and the smoothing strength.

HexCells_1.gh (115.8 KB)

HexCells_2.gh (127.4 KB)
Topologizer.gha (19 KB)

Fundamentally though, with freeform hexagonal meshes, when trying to make them planar, there’s always the question of which sides of which hexagons to make concave, and which to align with the curvature.
I’ve never really liked the methods which assign these directions essentially arbitrarily (which includes all the examples of tangent plane intersection method, and agent based approaches I’ve seen), as I find the resulting cells rather ugly where the regions clash.

I think the only way to make all nicely shaped planar hexagons on surfaces with multiple saddle regions would be to systematically create some non hexagonal faces at key points, and control the alignment of the ‘bowties’ in different regions and where they meet. That’s a big challenge though, as it is closely related to generating a perfect curvature aligned mesh and ideal singularity placement on arbitrary surfaces, which is still an unsolved problem and topic of ongoing research.

The problem becomes a little simpler if your shape doesn’t have inflections of curvature, or umbilic points, as then you can keep all the bowties in the same direction. In that case there are a couple of approaches I’ve shown in other posts which can help:


These won’t work as-is on your shape though, because the changes of curvature are more complex, so a single global direction won’t work.

2 Likes

Hi Daniel,

Thanks for the great and valuable information! I am now taking a look to all of them and understanding how it works.

Yesterday I found this diagram (see picture) where they do apparently a different opperation. In the last step they find a point near the center of each cell whose angle sumation with its vertices is 360 degrees in orter to reduce the numner of seams when unfolded. So I am trying to understand/apply also these logic to check what it gives to me.

Thanks again for your answer and time to explain! Best regards.

Ah yes, the ShellStar pavilion - a very nice project by @akudless with Matsys. I https://www.matsys.design/shellstar-pavilion
I think this was maybe the first full scale built outdoor structure ever designed using Kangaroo.

Here the cells do not need to be exactly planar, but are made from plastic sheets with a hole in the middle that can twist a bit, so this is less restrictive geometrically.

As it says in the description, for each cell they triangulated it to a central point, positioned so the angles around the centre summed to 360 degrees. This means that although each cell is not flat, it can unroll to flat without having to stretch.
Perhaps there is a geometric way of finding this point directly without optimisation, but here is a way of getting it with Kangaroo, using a new Goal I created recently for making a set of angles sum to 2Pi:
HexCells_3.gh (133.2 KB)