Skip to content

Framing a Complex Roof Structure Using Dynamo

These days, architecture is getting bolder and more wavy. As a result many structural engineering firms are having to model in Revit against this bold architecture. To say the least, it can be quite challenging and time intensive to model curved structural framing members that correctly follow complex forms. It can be even more frustrating, when these members have been modeled, and then the architect further tweaks the design resulting in a massive rework on the part of the modeler. For this reason, during a recent advanced training class for a world-renowned structural engineering firm, I thought up a new workflow using Dynamo which could allow designers to respond to frequent architectural changes and reduce tedious rework where possible. I knew I had seen Marcello Sgambelluri do something similar using grid lines, but that doesn’t seem to accommodate the wide variation in structural framing strategies that can be used to rationalize a complex structure. So I came up with a revised workflow:

  1. It is assumed that the architect provides a mass form and that the form is in design flux (i.e. it is changing constantly). Pre-requisite: Revit 2016-2018 with Dynamo 1.3.1 installed.
    Note that this definition does not use any external packages, and can actually be recreated in older versions of Dynamo (just be sure to use Lacing: cross-product for the intersections).
  2. The structural modeler will simply use a flat 2D representation using model lines of how the structural members frame the complex structure. These lines can be hidden and placed in a separate workset for visibility control.
  3. We then use a Dynamo script to grab these model lines and project them onto the mass surface to create the actual structural framing that will follow the surface. Note that the provided script can be refined further so that different model lines are modeled with different member sizes (i.e. girders vs secondary members).
  4. If the surface changes, then the Dynamo script is used again, by first pointing to the updated surface. Or similarly, if framing needs to be revised, the model lines can be changed/added and re-selected to update the structural framing. It is a useful workflow as both surface and model lines can be modified and the script re-run.

The entire process is shown in the following video and demonstrates the ease and flexibility of the workflow. One thing that is noted is that the Cross-Section Rotation seems to be reset to strange values depending on the surface you use. Similarly, some members will cut-back excessively and that can be fixed by right clicking on the end blue node and selecting to Disallow Join. The sample files used in the video are included at the end of this post for review.

YouTube video describing workflow

Sample files for download here (.zip) – Contains the files used in the video (Using Revit 2017 and Dynamo 1.3.1. Should work with Revit 2016-2018)

Posted in , , ,
Edwin Guerra

Edwin Guerra

Edwin is a BIM Consultant with Summit BIM Consulting Ltd., a leading provider of BIM consulting services based in Vancouver, BC. Edwin brings to his projects advanced skills in data visualization, workflow development, workflow implementation, automation, research, project management and communication. He believes that there is great opportunity within the AECO industry to streamline processes and workflows to deliver high performance buildings.


  1. Avatar FRANK on February 10, 2018 at 5:31 pm

    hello Edwin,

    I tried this interesting code of dynamo in revit 2018 using the files you have attached.
    unfortunately the last block “StructuralFraming.BeamByCurve” gives me the following error:
    “StructuralFraming: BeamByCurve operation failed.
    The multiplicities of other interior knots must be at most degree – 2.
    Parameter name: knots ”
    (message appearing above the yellow block);happens when I connect the “structuralframingType” to the “StructuralFraming.BeamByCurve” block
    I tried to use other families of structural beams, to use other surfaces, another dynamo code similar to yours but working with the grids, and also revit 2016 rewriting all the dynamo code but it works all the time until I make the connection of the “structuralframingType”
    can you check if there is a revit 2018 problem?

    thank you

  2. Avatar Marinela on February 12, 2018 at 5:54 am

    Hi Edwin,

    Thank you so much for this tutorial – it is very useful. However, I keep having problems with the structural framing – it keeps showing me this error above the StructuralFraming.BeamByCurve:
    Warning: StructuralFraming.BeamByCurve operation failed.
    The multiplicities of other interior knots must be at most degree – 2.
    Parameter name: knots

    Can you please let me know how I can fix it?

    Kind regards,

  3. Edwin Guerra Edwin Guerra on February 14, 2018 at 4:28 pm

    Thank you both for your comments. It appears that something has broken down in Dynamo 1.3.2. I can confirm that the workflow works when tested in Revit 2017 and Dynamo 1.3.1. I have submitted an issue to the Dynamo for Revit GitHub and my hope is that resolution is reached for those using 2018, where I haven’t been able to downgrade to Dynamo 1.3.1 to see if it works. For 2017 and prior, if you uninstall Dynamo 1.3.2 and reinstall 1.3.1 ( it will run successfully. In fact, even using Dynamo 0.9.2 in 2016 has yielded positive results using the same Dynamo script for 1.3.1 without edits.

    • Avatar FRANK on February 15, 2018 at 5:46 pm

      Hi Edwin,

      I’ve checked version of dynamo included in revit 2018:
      there is only one option that i can chose in options>experimental>activate t-spline node (and reboot dynamo)
      but anything change….
      do you know if is possible to upgrade this dynamo version to 1.3.1?

      Kind regards,


    • Avatar FRANK on February 16, 2018 at 3:58 am

      Hi Edwin,

      update my previous message:
      from i’ve downloaded and installed 1.3.1 version in revit 2018, but the error remain the same…

      Kind regards,


      • Edwin Guerra Edwin Guerra on April 20, 2018 at 2:29 pm

        Hello Frank. Unfortunately this seems to be an issue in 2018. Not sure why it is happening. My suggestion is that the more people generating support requests to Autodesk may help the odds of resolving the issue.

Leave a Comment

  • This field is for validation purposes and should be left unchanged.