Issue with Flow Trajectory Script

Hello everyone,

I’m working on a script that generates pseudo flow trajectories around random volumes. Here’s a working example I’ve developed:

Flow Geometry Inquiry V1.gh (74.5 KB)

For this script to be useful in my project, it needs to handle a large number of geometries efficiently and ideally support complex data trees. However, I’ve been struggling for the past couple of days to make it work with multiple volumes, and I haven’t been able to find a solution:

I suspect the issue lies in data tree compatibility, but despite trying various approaches, I haven’t been able to resolve it. Here’s a file containing multiple volumes along with my best attempt at making it work:

Flow Geometry Inquiry V2.gh (193.9 KB)

I would really appreciate any insights or suggestions on how to fix this!

Although the datastructure visually seem to line up, in actuality they are different.


To figure out what is going wrong with the datastructure here, it helps naming, but it also helps making sure your two input lists are not of the same length, so you can visually see the difference between tree structures using param viewer.
The solution here would be rerouting as follows:

Flow Geometry Inquiry V2 solved.gh (189.1 KB)

2 Likes

Thanks a lot for the solution!

I’m new to Grasshopper, and your explanation was really helpful. It works perfectly now - really appreciate it!