Our Precast Concrete solution is great for automating modelling, numbering, and shop-drawing creation in Revit, but efficiently modelling reinforcement in a 3D model can still be a challenge. Following our post about using a Dynamo script to create rebar by selected edges, here we show how to make a layout based on certain rules and apply it automatically to elements of different length. This can be done in the same Dynamo script.
You’ll recall that we created a rebar layout via a simple Code Block with a defined bar number and step.
Let’s add another node to select one more Edge, and read its length with the Curve.Length node like this:
Now we can add simple rules to divide that length and create a list of the positions where we want reinforcement. Here, we will divide the length into three parts and distribute bars with a predefined step. The first group of nodes calculates how many rebars will be needed given the predefined start offset and step in the first part of the divided length.
The example above shows the multiple nodes used to divide, subtract, and sum up, and the last one to round down. In fact, though, you can put all of this into one Code Block node, like this:
If you type text into the Code Block, Dynamo will recognize it as an input parameter, and then you can plug other nodes into it and manipulate the information you get from them. An example would be DivLength, StartOff, stepSupport in the picture above. Also, if you type something Dynamo recognizes as a function, you can also type it in the Code Block instead of using a separate node, as with Math.Floor above.
Let’s move on and create the sequence of positions where our rebar should be created:
Repeating the same procedure, we calculate the number of steps and the length of the layout for the middle part of the beam.
Continuing, we then create a sequence starting with the last item in the sequence list at the support and adding other lists to form a list of all positions.
Instead of using just Code Block with a defined number of rebars, we plug this List node into the Geometry.Translate node (used in the previous blog post). We also take the vector direction from this Selected Edge and scale the vector with a negative (or positive) value, in order to be able to control the layout direction of the rebar.
We don’t need to change the rest of what was created in the previous script (see previous post) in order to create reinforcement.
You should get result like this for the automated layout of reinforcement:
You’ll probably want to improve the calculation of the middle part’s layout a bit, but I hope you find this post helpful as a starting point.
Using Dynamo scripts together with the Precast Concrete solution for Revit can help you work more efficiently, eliminate many repetitive tasks and let you focus more on making decisions!
Watch our full-length webinar (hosted May 9, 2019) about using Dynamo scripts in conjuction with Precast Concrete to automate rebar placement in Revit!
Related blog posts:
- Updated schedules functionality in Smart Assemblies
- A Few Ways to Automate Rebars Modeling in Revit®
- Dynamo scripts for rebar (part V): All reinforcement in one script
- Heading to Louisville for The Precast Show 2019
- Dutch firm’s precast work gets a major boost from AGACAD BIM software and support
- Savolainen: Precast suite has “game-breaker” BIM tools
- JPS-Konsult: “We’re hooked on Precast Concrete and other AGACAD solutions”
- Norconsult: “The Precast Concrete suite brought efficiency and flexibility”
- WEBINAR: Modeling Precast in Revit 101
- AGACAD becomes one of Autodesk’s first AEC Industry Partners
- How to Create Concrete Details for Precast Sandwich Walls
- NEW FEATURES for Smart Details: Detection-and-insertion of details, lifting rule, and improved UI
- An Overview of Precast Slabs, Walls, Columns & Beams in Revit