Close all polylines

Hi all,

I’m wondering if there’s a good approach to close all possible polylines in a given set of lines on a plane in order to create boundary surfaces and avoiding splitting a larger bounding surface which is very slow as the number of lines increase.

Please find attached the file (closePly_v1.gh (336.0 KB)) with:

  1. how the set of lines was created
  2. the result with the end pattern with a rectangular boundary
  3. the hidden surface component contains the end goal (done in rhino for now)

Thanks!

Hi,
I might be missing something but since the surfaces you want to create bleed beyond the initial tile rectangle, you have to first repeat the pattern on your target surface and then create the surfaces.

The method I am posting does not take too long to compute for a 3x4 tiling but I don’t know how much more you want your pattern to extend.
alternatively you can create a non rectangular pattern, create your surfaces and then tile them on the big surface (and then trim the edges). But I don’t think it’s worth it.

pattern.gh (17.9 KB)

1 Like

Maybe this discussion can be useful?

2 Likes

that’s amazing - exactly what i need, thank you daniel!

EDIT: there seems to be some lines missing actually (shown in cyan in the screenshot), please refer to the newly attached file below. but pretty close with the script @piac provided as included within the file. thanks again!

closePly_v2.gh (28.0 KB)

[update]
closePly_v3.gh (50.8 KB)

When replacing the initial pattern with a more divided one all made up of quads (with the same initial base subdivision), the python script does successfully identify all polylines. I am, however, still wondering why the original desired pattern doesn’t work.

Thanks!