Rebar intersection

longt61
Advocate
Advocate

Rebar intersection

longt61
Advocate
Advocate

    How to I detect if 2 rebars (of the same host) intersect with each other? My rebars can be of any shape, any layout rule (but ideally their layout rule should not be "Single").
I have been tackling this problem for a few days, tried almost anything I can think of:


1. "JoinGeometryUtils": It can not detect if rebars are "joined" since it only works with solid element. Unfortunately, rebar is not a solid element. It is written in the documentation.

 

2. Try to use "BuiltInFailure" with a Rebar overlapped definition: 2 rebars are considered overlapped only if they are of the same RebarBarType, the same RebarShape, the same dimension, and the same location. not even close to what I need.

 

3. Try to manually determine intersection by using Driving curve of the 2 rebars, and I encounter 2 more problems:
    a. Even when I place to straight standard bars so that the 2 rebars completely overlap each other, their driving curves somehow always return a "Disjoin" result. Only when I select the same curve twice, I received the "Equal" result.

    b. I haven't try this with every layout rule but it seems to me that only rules with specific number (such as "Fixed number") that I can use GetBarPositionTransform() to get all the curves for the bars. The other layout rules (such as "Maximum spacing") always return NumberOfBarPositions and Quantity as 1.

 

 

What have I done wrong? Is there a way to detect rebar intersection? Thank you all for your time.

Reply
1,036 Views
2 Replies
Replies (2)

Anonymous
Not applicable

I am running into the same situation. Have you found a solution to this situation yet?

0 Likes

longt61
Advocate
Advocate

I haven't found any solution that can completely solve this problem yet. However, just a few trick/ walk around to solve 1 or 2 specific case and it require the rebar center line must be on the same plane (which) covers most of my requirement):

 

Case 1: if the rebar plane are not parallel - aka the center lines of 2 rebars intersect each other on a plane:

- you can get the center lines using Rebar.GetCenterlineCurves() 

- get the actual rebar number of the Rebar set Rebar.NumberOfBarPositions.

- get the transform of the bar with the barPositionIndex in Rebar.GetCenterlineCurves()  by  Rebar.GetShapeDrivenAccessor()GetBarPositionTransform()

- then determine if 2 rebar center lines intersect each other (each center line is actually a list of curves thogh)

rebar1.png

 

Case 2: if the rebar plane are parallel, which means 2 rebar are on the same plane and they are parallel to each other:

- you find out the center point of each rebar

- compare the distance d  between them with the sum of their radius (R1 and R2).

if d > R1 + R2 then they are not intersect, otherwise, they are.

Note that: the 2 rebar in my case are of shape drive rebar  with the same shape so instead of the center point, I can get any point at the same position from the same centerline curve. If your rebar are not the same as in my case, it could be more tricky.

 

rebar2.PNG

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Hope this help. Still open for any suggestion, contribution or (better) an overall solution.

Regards.

0 Likes