You are not getting the results your are expecting because you are inputting DataTrees to the Region Difference components (note the dashed lines).
If you flatten these inputs, you will get the results you expect but your file that was slow to solve gets even slower.
If you examine the inputs to the Region Difference components you will see that there are many duplicated curves:
After culling these duplicate curves, things work as expected in seconds instead of minutes:
Also note that the third Region Difference has no effect (80 curves at input A → same 80 curves at the output).
Attempt 3_re.gh (58.3 KB)
Edit: One curve is referenced from the rhino file posted above:
Edit #2:
Was a bit short on time earlier today. Had some time later to examine your code more closely. Better to fix the code causing the duplicate curves instead of culling them.
Changed this code:
To this:
Note that now the output is a list instead of a tree (solid line).
You had this identical code block 2 times in your file so I combined them into one block using trees:
Removed the code for culling duplicates as it is not needed now.
Also changed this part of your code that generates the random numbers for your scale factors:
To this:
Even though the input to the Random is named “Range”, if you hover over it you can see from the pop-up that it is expecting a Domain.
Re-arranged some components to make the code more readable and enabled the components you had disabled.
Now it produces this output:
Attempt 3_re2.gh (52.6 KB)
All geometry internalized in this GH file.
-Kevin









