algorithmic modeling for Rhino
Good day GH friends,
Its already taking me days contemplating on this problem and yet still unsuccessful to come up with a solution.
I wish to combine the branches that share the same value in some of the items within a branch. Kindly refer to the snapshot below for better understanding of the goal i wish to achieve: All effort to help will be much appreciated - Homar
Tags:
Looks really tricky, because as you merge sets of values you have to deal with those new intermediate sets.
Are you interested only in integers, or also floating point number or other data types?
Thank you very much David. The C# is the last piece for my work puzzle.
BR,
Homar
Hello Homar,
You can use the "set union" and "set intersection" components to achieve what you want.
1- With the "set intersection" component you can check if there is a common value between two branches of the tree.
2- If the above is true, then you can "set union" both branches (that you have already checked)
PS: this might be a repetitive process, however you can do it once and add it in a cluster and then use the cluster for the repetitions.
Check the attached image.
Cheers ..
Hi Ibrahim,
Thank you for your help and time in this problem of mine. For now David's solution is best for my work now.
BR,
Homar
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
© 2024 Created by Scott Davidson. Powered by