algorithmic modeling for Rhino
Hi all,
I'm testing one definition to create hexagonal surface patterns using a Lunchbox component like this image.
Because cells coming out from the Lunchbox component have different number of outlines like 4, 5, and 6 lines, I sorted out all the cells based on number of boundary lines to make coplanar surfaces.
Now I want to match the manipulated data structure of these surfaces to the original cell data structure. I want to give an ID to each surface following the original cell number order as shown in the image above, so each cell will have two surfaces.
Cell numbers will be 1, 2, 3, ...., n
Surface numbers will be 1-1, 1-2, 2-1, 2-2, 3-1, 3-2,...., n-1, n-2.
I thought I could do this for some contemplation, but my brain is not running well as I wish today...
I attached my GH file to seek for a help from greater minds.
Thank you!
Tags:
I came back to this post without much hope, but it is a nice surprise to see your reply.
The Unflatten Tree with a guide option does the trick!!
Thanks a lot for taking your time to look at this problem!
After I spend a little bit more time, I'm wondering if it's possible to give panel IDs based on the location of cells which each panel belongs to. That way, numbering of panel IDs would always work, even if the number of panels inside each cell varies. The current solution works when the number of panels inside each cell is always two or other same numbers, but it wouldn't work if the number of panels inside frames are different in each cell. It would be perfect, if numbering of panels are automatically added correctly next to the cell number based on the number of panel division instead of feeding the fixed number.
To take an example, let's assume that the cell #80 has three panels and the #81 has two ones. In this case, three panels within the cell #80 would be numbered like 80-1, 80-2, 80-3, while two panels within the #81 would be numbered such as 81-1 and 81-2 automatically.
I'm sorry I came back to your replies late, but I was tied up with other things until now.
Thanks again for checking this out, but I was questioning about the connection between "Frames" and the panel structure in your solution that is highlighted in the image below. Because that specific connection forces that there are two panels in each cell by manually adding another item in each data branch. I was curious if I could count the number of panels within each cell and use that data to number panels to relate the panel and cell IDs automatically.
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by