Find coresponding lines from points

I have a linked Autocad File and i would like to “find” doors, wall-lines and connect them in Revit, so that afterwards i could create a room seperator-line with it. I could already “find” the doors (trough arcs), wall-lines and all the points which connects the doors with the wall-lines. My problem is now, that i can’t find out the corresponding line which is connected to the door through the points which connects the door with the wall-line.
In the attachement you see a list with lines (which is corresponding to all the wall-lines which dynamo found in the linked Autocad File) and a list with points (which is corresponding to all the points which connects the doors with the wall-lines)

Does someone has an idea ?

If your “setup” always has three lines and a curve, one line tangent on the other two lines you just have to make some small calculations to find out which curve is the one which doesn’t have the same direction as the other two.

Unfortunately it is not always three lines and a curve.
But thanks already for the reply

Just to be clear, you want to find the two points representing the door opening right?

Also, is the Arc of the door always in the same direction, i.e. does it always have the same end/ startpoint, that could help.

no, not at all. The aim is not to find out the door opening.
The aim is to find out which lines connect to the door

Oh i see!

Check out the GroupByDistance node from the Springs package. This node groups curves by their distance relative to eachother.

Thanks, but this does not work. This node needs two equal length of lists.

Are you sure you have the right one?

I tried out both geometry.groubbydistance nodes from spring, but this does not give me the solution.

Could you please share some screenshots?

Assuming all your doors are arcs and have a leaf line going back to the wall line, you can find which line is crossing the door by getting the arc centre as well as start/end point. Make lines between the arc centre and these two points, and we know one of these must be the door leaf line, and the other our door threshold (which has no line). Get all midpoints of lines in the line set, then check if the midpoint of the lines we drew exists in those points as a string. If it doesn’t then we know this line isn’t drawn and must be our threshold line.

find door line.dyn (44.8 KB)

get door line


Thanks Gavin but i need not the blue lines. I need the red lines from your example.


In which case you can look for all lines that are:

  1. Not an arc
  2. Do not have a midpoint related to the midpoint of the other door lines in my example (the IN lines vs the OUT lines)

Midpoint comparison should suit this approach as well.

1 Like


Here is an approach


Hello Christian.stan
I get error on the element Solid.ByUnion

Sorry, I misunderstood your original problem.

I started with the wall elements.