Find matching columns based on XY Coordinates, and matching their parameters

Hi everyone

I’m trying to do something that should in theory be quite simple.
I have a 35 storey tower with a fairly uniform floor plan for level 1 to 35.


The columns in the project are numbered uniformly based on their location. These numbers are added as “Mark” to the object properties.
image
These values are only added on the first floor, and should be repeated on all other floors.
In essence I want to do the following steps:

  1. Select columns on 1st floor (This set of columns we can call C1)
  2. Retrieve their coordinates
  3. Select all other columns (C2)
  4. Retrieve coordinates for C2
  5. Compare coordinates of columns in C1, against columns in C2
  6. Find matching sets
  7. Apply the “Mark value of columns in C1 to their matching pairs in C2.

The first list C1, will be our reference list. The set of columns from which we want to write the “Mark” value to other columns.
The second list, C2 contain many more columns in multiple floors. These are the columns we need to find a matching column for from C1. There may even be cases that a column in C2 does not have a matching column in C1, and there will indeed be cases where multiple elements in C2, are matched to a single element in C1.

This is how I have done the following steps in Dynamo, and where I am stuck at the moment:

Step 1:

I have selected all columns on level 1. In this case there are 30 elements.

Step 2:

I take the location of the columns and round them to avoid any minor modelling errors. I then create a string of this. I found that this will be crucial for comparing the lists later on:

Step 3:

I have selected all the other columns in the project. In this case there will be 1412 elements:

Step 4:

Before getting the coordinates of the columns in C2, I need to exclude all slanted columns, which due to their geometry cannot be included in this script, because their XY coordinates change at the start and end of the columns. After filtering out the slanted columns the number of elements in C2 is reduced to 1396:

Afterwards the coordinates are rounded up as in Step 2, and converted into a string which will allow us to make the comparison later on:

Step 5 & 6:

This is basically where I get stuck.

I compare the two lists against each other getting the following list with cross-product lacing.

I am not sure how to use these lists to complete step 7.

Is anyone able to help?

1 Like

Hi @n.hedayati

Use List.map along with filterbybool mask node. Below is an example.

1 Like

I’ve had a similar challenge before, and the key was grouping and sorting the columns, then sorting them by the string output of their X/Y location. For projects on an angle, this workflow does rely on the columns being stacked however.

An alternative workflow is to extrude cylinders at each column and group them by whether their locations intersect. This allows a bit of tolerance the user can set by the radius of the cylinder. I will likely upload this workflow to my Youtube channel in new year as I have had other engineers request this for column marking. Note that if your columns are always near grids you could also sort them by their nearest grid intersection then mark them this way.

See attached my attempt at a precise alignment method at least…

Column sort.dyn (44.1 KB)

Column stack.rvt (1.5 MB)

2 Likes