Hoopsnake

Update:

Hoopsnake is now Open Source!

Check out the repo in Github!

Fork it and fix it :)

Hoopsnake is a component that allows feedback loops within Grasshopper.

three closest points

I have two lists, List "A" with 3 points, and list "B" with 100. I need to separate the 100 points in list "B" into 3 lists containing the closest points to those on list "A" in a way that no point is repeated on any of the 3 lists.

What I have managed so far is attached, it is finding the closest points, but it is not creating the lists and it eventually repeats points.

I you can help me with this file, or suggest a better way to do it, I´ll appreciate it a lot.

Thanks

  • up

    Gui Talarico

    I have done this once, but with only two points instead of 3.

    I did it by calculating the Dist. between ptA <> allPts and then comparing to ptB <> all Pts

    and then Dispatching the allPts into two categories based on the result of the comparison.

    It worked for me, and you can probably make it work with 3 points, but I don't think it is the best way to do it - and it is not scalable....

    3