# Automating Steel Lintels and Tags

During my time at Autodesk University this year an attendee approached me, thanking me for a class I taught at a BIM workshop in 2014. That was a great feeling that a small topic on formulas triggered him to explore the possibilities and ultimately launch him into a great career. I am going to do my best to turn that class into an article in hopes that it triggers some greatness amongst the readers. A special thanks goes out to Marcello Sgambelluri for helping me through some sticking points when I first developed this workshop.

## Setting the Goal

The goal of this development project was to take a standard steel lintel legend that our structural group uses on projects and end up automating the steel lintel and the tag.

Figure 1: Steel lintel legend

## The Family

My first task was to create the steel lintel family. When I looked over the legend I determined that I would create every instance of the steel section types shown in the legend into one family. From there I would just control the visibility based on a formula. Easier said than done, right? Yes! This did prove to be very tedious, but worth the effort.

Figure 2: 3D view of the family

Of course, more than just the visibility of each steel section had to be taken into consideration. I still needed to control all of the typical parameters such as height, length, thickness, offset, etc.

Figure 3: Plan view of the family

## Creating the Parameters

Based on the legend, the steel lintel to be used was based on the maximum masonry opening and the thickness of the wall. Based on the combination of those two values I would be able to determine the steel lintel section to use.

Figure 4: Parameter overview

Item A, shown in Figure 4, is the value to be used in a tag to tag the steel lintel once it was placed in the model. We will take a look at the formula used to generate that label later in the article.

Item B is converting the format of the basic parameters controlling the height, length, and thickness of the lintel into an integer. This is necessary for the formulas to interpret the value correctly.

Item C shows the parameters to control the visibility of the different steel lintel sections. The formula used in the parameter takes into consideration the masonry opening and the wall thickness.

Item D is a parameter that contains the formula to produce a number. The resulting number controls the visibility parameters. Later in the article the formula will be displayed and explained.

## The Formulas

A simple IF statement is as follows:

**Simple IF**: =IF (Length < 3000mm, 200mm, 300mm)

This basically means if the length is less than 3000mm give a result of 200mm. With our steel lintel legend, we have more than one parameter to meet. We have the length of the masonry opening and the thickness of the wall. This would require an IF statement with a logical AND as follows:

**IF with logical AND**: =IF ( AND (x = 1 , y = 2), 8 , 3 )

This would tell a parameter that IF x=1 AND y=2 give a result of 8, and if not, give a result of 3. This logic is perfect for our steel lintel family and tag.

### Formula for Controlling Visibility

if(and(ConvertLength < 6.334, ConvertThickness = 8), 108,

if(and(ConvertLength < 6.334, ConvertThickness = 10), 110,

if(and(ConvertLength < 6.334, ConvertThickness = 12), 112,

if(and(ConvertLength < 8.334, ConvertLength > 6.334, ConvertThickness = 16), 216,

if(and(ConvertLength < 8.334, ConvertLength> 6.334, ConvertThickness = 18), 218,

if(and(ConvertLength < 8.334, ConvertLength > 6.334, ConvertThickness = 20), 220,

if(and(ConvertLength < 13.334, ConvertLength > 8.334, ConvertThickness = 8), 308,

if(and(ConvertLength < 13.334, ConvertLength > 8.334, ConvertThickness = 10), 310,

if(and(ConvertLength < 13.334, ConvertLength> 8.334, ConvertThickness = 12), 312,

99999999999999997000000000000000000)))))))))

This formula goes through a series of IF/AND statements to produce a number. The result of this number is the “VIS_AS_NUMBER” parameter in our family. The formula looks at the ConvertLength, which is the masonry opening, and the ConvertThickness, which is the wall thickness to determine the value. Once we have this number, the visibility parameters for all the different steel sections are easy to control. If you refer to Figure 4 you can see steel lintel visibility L1_08 will be turned on if VIS_AS_NUMBER=108.

### The Formula for the Tag

if(and(ConvertLength < 6.334, ConvertThickness = 8), "L1",

if(and(ConvertLength< 6.334, ConvertThickness = 10), "L1",

if(and(ConvertLength < 6.334, ConvertThickness = 12), "L1",

if(and(ConvertLength < 8.334, ConvertLength > 6.334, ConvertThickness = 16), "L2",

if(and(ConvertLength < 8.334, ConvertLength > 6.334, ConvertThickness = 18), "L2",

if(and(ConvertLength < 8.334, ConvertLength > 6.334, ConvertThickness = 20), "L2",

if(and(ConvertLength < 13.334, ConvertLength > 8.334, ConvertThickness = 8), "L3",

if(and(ConvertLength < 13.334, ConvertLength > 8.334, ConvertThickness = 10), "L3",

if(and(ConvertLength < 13.334, ConvertLength > 8.334, ConvertThickness = 12), "L3",

"NEEDS ENGINEERING")))))))))

The same exact formula and logic is used for the parameter controlling the tag, with the exception that the resulting value is a text value instead of an integer. Based on our lintel legend each lintel type has a value of L1, L2, L3, etc. At the end of the formula, if none of the parameters are met the result is “NEEDS ENGINEERING.” This is great for the engineers to isolate areas for which they need to run calculations. With this set up we can now use the SL_LABEL parameter in our tag family.

## Tag Family

This is just a simple annotation tag family that uses the shared parameter SL_LABEL that is used in the steel lintel family to populate the tag.

Figure 5: Tag family for steel lintel

## The Result

Figure 6 shows several lintels placed in a floor plan view that have been tagged. Each one is a different length and wall thickness to ensure the formula is working correctly with the family and the tag.

Figure 6: Plan view for all steel lintel sizes

Figure 7 shows one of the Steel Lintels in section to test the visibility and tag formulas in a section view.

Figure 7: Section view of lintel family

## Summary

I hope you found this article useful and that it triggers some creativity in yourself to produce more intelligent families in the future.