Find length of all chopped pipes, and create a quantity count range

Help me to:

  1. take all of these chopped cylinders & find the length of each one
  2. get a quantity count of how many fall under under 6", 6-9", 9-14", under 15"

here is what I have so far



You will want to use the Length comonent instead of the Length Domain component.

Length Domain measures the length of a curve subdomain (not what you want here).

Edit: I just noticed you’re using a Brep component as the Curve input to the Length Domain component. This will not work.

Please upload a grasshopper file if you want further help.

Something like this should work. I used random numbers since I don’t have your curves to work with.


How do i export the grasshopper file so it includes some of the rhino model that applies to the script?

Or does it automatically save it out

I can’t figure out how you get your panels the way you do
and I’m not sure where to plug my curves in, if I do have them, because I do :slight_smile:
Also, I kind of want to combine this with the one you made for me the other day,
where I first find the centerlines, than I get the lengths using this and sort it by range
also, I hope you’re excited that I have chosen you to tag on everything now :innocent:

Right-click on the parameter that you are referencing from Rhino (point, curve, brep, etc…) and select Internalise data.

Plug your curves into the Curve input of the Length component.

Open both scripts at the same time and copy the components from one script then paste them into the other. If you paste with shift-control-v it will paste them into the center of what’s currently visible on your screen instead of their location in the original file.

Click where it shows the filename at the top-right of the grasshopper window to switch between open files.

You can also use this technique to upload the part of your script you have questions on (instead of your whole script). Just copy the section you want to upload and paste it into a new file and save with a new filename.


1 Like

Thanks Kevin, How do I get these panels?

Just add a Panel component then double-click to edit it. If you’re entering a list of values (like the Numbers input to the Consecutive Domains shown above) right-click in the panel and un-check Multiline Data

You can see from the index numbers at the left of the panel that it is a list.


Thank you! I will check this out soon