How to Calculate Brickwork Dimensions Automatically in Revit

Designing buildings with masonry is a common method used in different countries. The challenge with masonry, however, is to find the right dimensions for your wall so you only end with full or half bricks.

With Revit, we can solve this issue by setting the units of the half or full-size bricks in the early designing part. This way we avoid a lot of unnecessary cutting of bricks and waist. Also, you want to prevent the bricklayer to fill up the masonry with too small bricks, or too thick joints.

This article will show you how to use Dynamo Revit to create a check for coordinated masonry dimensions. The focus of this article will lay on the horizontal measurements of masonry.

Standard brick sizes

If we talk about brick sizes, we can say that there are a lot of different variants all over the world. Each country has its own standard brick sizes. In the table below you can see an example of the most common standard brick size per country. For the explanation of the Dynamo Script, we focus on the UK standard brick size.

CountryBrick size (L x W x H)
Netherlands210 x 100 x 50 (mm)
Germany240 x 115 x 52 (mm)
United Kingdom215 x 102,5 x 65 (mm)
United States203 x 92 x 57 (mm) (not modular)
Australia230 x 110 x 76 (mm)

Most standard bricks are modular. This simply means that the length of a brick (stretcher) is equal to twice its width (header) plus 10mm for a mortar joint. The picture below shows an example of the UK standard brick size ((102,5mm * 2) + 10) = 215mm.

modular brick size
Example: UK standard brick size

Brick bonds

At the start of designing a building, an architect should start thinking about a pattern for the bricks. Bricks can be designed with a lot of different patterns. In the early stage of engineering, take into consideration the sizing of the masonry to avoid a lot of cutting bricks. The table below will give an example of some common brick bonds used by different countries.

  • Stretcher bond
  • Header bond
  • Wild bond
  • Stack bond (stretcher or header)

Stretcher bond

The stretcher bond is made with courses laid as stretchers with the mortar joint falling in the midway of the course above or below. This is a very popular bond because it’s very effective in saving time and costs (less brick cutting).

mansonry strecther bond
Stretcher bond

Header bond

The header bond is made with courses laid as headers with the mortar joint falling in the midway of the course above or below. This pattern is used a lot for building cellars and fortifications in the past. Furthermore, this pattern can be used to create a radial in the masonry because the headers are smaller than the stretchers.

mansonry header bond
Header bond

Wild bond

The wild bond is made without any pattern, so this pattern is in a random formation. The mortar joints are not allowed to be aligned.

mansonry wild bond
Wild bond

Stack bond (stretcher or header)

The stack bond is made with vertical or horizontal stacks. The bricks may not be overlapping each other. You can find this pattern mostly as a decorative part of a building, because of its arrangement it is weaker than other bonds. To stabilize the bonding, it is recommended to use bed-joint reinforcements every three layers.

mansonry stack bond
Stacker bond (left stretcher, right header)

Brickwork dimensions

As you can see there are a lot of different brick sizes and bonds. It is time to get more into the depth of the modular size. For this explanation, we focus on the standard UK brick size (215 x 102,5 x 65mm).

In the UK they speak of Co-ordinating brick size, which can be determined by one of three conditions.

  1. CO-
  2. CO
  3. CO+
coordinated brick size revit dynamo

1. CO-

Brick without a mortar joint can be described as (x)B-J (x = amount of brick headers). CO- can be used with brick piers or panels between openings.

example brick dimensions dynamo
example of CO- (Brick – joint)

2. CO

Brick with 1 mortar joint can be described as (x)B. CO can be used with external to internal corners of the masonry. Another example could be a part of masonry that will be placed backward a few millimeters.

example brick dimensions dynamo
example of CO (Brick)

3. CO+

Brick with 2 mortar joints, can be described as (x)B+J. CO+ can be used for openings such as doors and windows.

example brick dimensions dynamo
example of CO+ (Brick + joint)


Wherever possible, it would be the best practice for engineers/architects to set out the brick dimensions with coordination. By following this advice you will circumvent the need for unsightly and unnecessary cutting bricks.

Dynamo – Brickwork dimensions

To put the coordinated brickwork dimensions into practice, we can use a script with the help of Dynamo Revit and a part of Python code inside of Dynamo. With this script, you can check your dimensions with brickwork coordinated dimensions. This tool can also be used inside the execution drawing to show the bricklayer how many bricks he needs to use. The output will be text below the dimension lines.

Dynamo – Script

Below you will see an overview of the Dynamo script. I have divided the script into three parts to make clear what each part does. The script contains a part that is made in Python.

The script requires the installation of the following packages:

  • Clockwork for Dynamo 2.x
  • Spring nodes
brick dimensions script dynamo revit

1. Get Sheets/Views

This part of the script will check if there is a single view or multiple views on the sheet that you have opened. This means you can put the brickwork dimensions to multiple views at once if preferred.

brick dimensions script dynamo revit

2. Get dimension and filter

After the views are collected in part 1, the script will collect all dimension lines inside the view(s). For this, we are going to use the following Python script.

brick dimensions script dynamo revit
import clr
from Autodesk.DesignScript.Geometry import *
#Import DocumentManager
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
#Import RevitAPI
import Autodesk
#Import ToDSType(bool) extension method
import Revit
from Autodesk.Revit.DB import *
from Autodesk.Revit.Creation import *
# The inputs to this node will be stored as a list in the IN variables.
doc = DocumentManager.Instance.CurrentDBDocument
uidoc = DocumentManager.Instance.CurrentUIApplication.ActiveUIDocument
views = UnwrapElement(IN[0])
dimensionsperview = list()
# Collect dimensions in Views
for v in views:
	dimensions = list()	
	colldimension = FilteredElementCollector(doc, v.Id)
	filtdimension = ElementCategoryFilter(BuiltInCategory.OST_Dimensions)
	dimensions = colldimension.WherePasses(filtdimension).ToElements()	
OUT = dimensionsperview

If you add a filter to the Type Name of the Linear Dimension Style, you can filter the dimensions and only put the text under the lines you want. In this example, I gave the Linear Dimension Style a Type Name: LB_brickdimensions_1.8mm.

dimension style revit

3. Brick header size – set text

At this part, we know which views contain dimensions and which dimensions contain the filter to collect. Now we can put the filtered dimensions into the last part of the script.

brick dimensions script dynamo revit

The script requires a few variables that are already set. An important one is the brickheaderM in line 16. This is the brick header size and has to be modular, as explained before. For example, for the Dutch standard brick size of 210 x 100 x 50mm, it will be 100mm (Length – Joint) / 2)).

# Load the Python Standard and DesignScript Libraries
import clr
import RevitServices
import math
from Autodesk.DesignScript.Geometry import *
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager
doc = DocumentManager.Instance.CurrentDBDocument
# The inputs to this node will be stored as a list in the IN variables.
dimlines = UnwrapElement(IN[0])
# Variables
brickheaderM = 102.5
jointM = 10
ftmmconversion = 304.8
brickwork_headersize = brickheaderM + jointM
brick_text = []
# Methods
def round_off_rating(number):
    return round(number * 2) / 2
def headersize_form(dim, brickheaderM, jointM):
	value_mm = round_off_rating(dim.Value * ftmmconversion)
	header_count = int(round(value_mm / (brickwork_headersize)))
	total_size_headers = (brickwork_headersize * header_count)
	additional_measurement = (value_mm - total_size_headers)
	total_headers = str(int(round(value_mm / (brickwork_headersize))))
	if value_mm % brickwork_headersize == jointM:
		result = total_headers + "B+J"
	elif value_mm % brickwork_headersize == brickheaderM:
		result = total_headers + "B-J"
	elif value_mm % brickwork_headersize == 0:
		result = total_headers + "B"
	elif value_mm % brickwork_headersize >= (brickwork_headersize / 2):
		result = str(int(math.ceil(value_mm / brickwork_headersize))) + "B " + str(additional_measurement) + "R" 
		result = str(int(value_mm // brickwork_headersize)) + "B+" + str(additional_measurement) + "R"
	dim.Below = result
	return result
for dims in dimlines:
	if dims.Value == None:
		form = []
		for dim in dims.Segments:
			form.append(headersize_form(dim, brickheaderM, jointM))
		form = []
		form.append(headersize_form(dims, brickheaderM, jointM))
# Assign your output to the OUT variable
OUT = brick_text

The output of the script will be a text below each dimension segment. The outcomes can exist of five different types.

  1. (x)B-J
  2. (x)B
  3. (x)B+J
  4. (x)B-(y)R
  5. (x)B+(y)R

The last two (4 and 5) will show if a dimension is not a coordinated brickwork dimension. In that case, you see an additional measurement with the letter R as a suffix for Remaining. This will indicate how much length you have to solve by cutting bricks or making thicker mortar joints. The challenge is to end with full or half bricks of course.

example brick dimensions dynamo revit

Wrapping Up

Coordinated brickwork dimensions are a great way to set up a building with masonry. This can only be done with modular brick sizes and the use of a 10mm mortar joint. The dynamo script will check every dimension segment for you, and shows if it is fitting to the modular brickwork size.

I hope this article helped you to understand the coordinated brickwork dimensions, and how to check them automatically with the help of a Dynamo script. If you have any questions, just drop a comment below.

Get more stuff like this

Revit, Dynamo, Sketchup and BIM Tips

I hate spam too, so you can unsubscribe at any time.

1 thought on “How to Calculate Brickwork Dimensions Automatically in Revit”

Leave a Comment