Exclusive curve selection using Brep for lattice operation

Hello all grasshopper masters,

I find it difficult to achieve the following goals:

1st Goal:
Select curves that are fully inside the closed Brep (in this case it is a sphere), and these curves are 7712 individual strut curves of a lattice that are not joined together, and they do not intersect the sphere at all

2nd goal:
Regarding the curves that are intersecting with the Brep (sphere), how do I exclusively select part of the curves that are inside the brep?

Essentially, I just need curves that are inside the sphere, including the intersecting curves that are sitting inside. (Like the white lines below)

Please find the attached example file. I haven’t directly plugged the curve and Brep into the workflow, as it crashes my Rhino every time. I have internalised the curves and sphere further below the GH interface. The workflow is what I tried to replicate Claude Ai’s guide, but it doesn’t seem working.

selecting curves inside Brep.gh (201.8 KB)

Any suggestions and tips would be greatly appreciated!

Many thanks!

Sam

I’m not in front of my computer so I have not looked at your file.

Grasshopper has a trim with Brep component…. It outputs curves inside and outside which might help you…

It worked!

Thank you Martin! I have asked this question to claude ai & chagpt, and both of them never mention this trim with Brep component.

Haha, humans still got it :grin: