Split Geometry At a given length

So. I want to split the conduits of my project to automatically insert a union fitting after three meters
I already filtered it by type and by length. The last thing for me to do is to split it at the given length
Any Tips?
Thank you all in advanceSplit Conduits By Length.dyn (10.1 KB)

Can anybody please help me?
Thank you!

From what I can read splitting conduit isn’t accessible via the API so you have to recreate the conduit.

Get the location line, split the line into parts with a gap To allow the union, and delete the old one. Then create new ones for each line in the list. The union may or may not place automatically (not a conduit or MEP systems guru), if not try using the line endpoints to place one.

1 Like

Two birds with one graph! Nice one @erfajo!

Well, Thank you for your support
it did exactly what i needed it to do, however it was not the solution.
There is no union fitting in the splitted region.

What i thought it would do was inserting the union fitting automatically… But it seems i was wrong…

Tot add to @erfajo’s post: you could try using this on the newly created curves:

2 Likes

If the fitting by curves doesn’t work as is, try adding a gapbetween the ducts - the previous code split the lines consistently at 3 units. You need breaks at something like 2.99 and 3 (3 and 3.01 may also work) for a connector to automatically join the system (if it even will). To do this I would subtract 0.01 units from the break sequence which was built (specifically the 0…1…step codeblock).

Note that you will have to remove the last curve for the upper input and remove the first curve for the lower one in order for the fitting by curves node to work.

Well… Thank you for your routine
But unfortunately it doesn’t work properly.
See what happens.
But i’ll have to thank you for your unconditional support!

That worked perfectly!
Thank you @erfajo

9 posts were split to a new topic: Element.CopyByVector custom node

This looks like what I’ve been searching the entire internet for!
thank you!
do you know if there is a way to apply this solution to pipe types?
when I draw pipes I need a split every 10 feet for the union coupling I added in routing preferences to work automatically. I’ve been fiddling with this solution for hours in Dynamo and I can’t figure it out…

Thank you in advance!

Hi,

You can use the Split ByPoints node of the Genius Loci package for this task.

2 Likes

Hello,
I am having trouble picking the correct install. I am running Revit 2020.2

Thank you,
Nicholas

image.png

Hi,

Not sure about this error but you should install the latest version of the Genius Loci package.
It is compatbile with Revit 2020.