Looping Cluster Example for Grasshopper2

I put together a Looping Cluster example with Grasshopper2 (attached below). I have to say…this is going to be a remarkable feature to integrate into future graphs… :heart_eyes:

Geometry Curve Loop.ghz (262.4 KB)

How it is set up…

Create a cluster and enable Looping Logic on the Cluster…

Define how where you want your output to loop back into… (here I am looping an output Curve back into a Curve input.)

I added a Loop Repeat to the Looping cluster and set the number of iterations…

And viola!

14 Likes

Fantastic! The native, well-thought-out loop implementation in Grasshopper 2 is a huge plus, not only because of the expanded capabilities but also because it simplifies achieving certain goals. I often found myself building my GH1 definition for a single object, but ultimately having to process multiple objects simultaneously. This transition from single to multiple often meant a very difficult struggle to adjust the data trees to keep everything working as expected. Sometimes I ended up wrapping the entire definition in Anemone loops and it was fine, but in those moments I often wondered – had I just avoided the difficult task of managing data trees and escaped the problem, or had I wisely opted for a more optimal solution?

I hope that the native loop implementation in GH2 won’t make me ask myself such questions, but will instead treat it as a fully fledged solution.

1 Like

Years ago, one of my very first practical instances of needing looping in GH involved solving for a stadium riser formula (which is based on a graphic standard for sectional sightline measurement). The problem required me to take my first steps into scripting to iteratively create each riser. I revisited this problem yesterday and found that this is easily solved with the new cluster looping.

I have a LI post here with a short demo.

5 Likes