top of page

Air/Light Ratio with Revit

Hi all,


In today's post, we are going to illustrate a solution developed with a friend that permits to automatically calculate the air/light ratio for all the rooms in a Revit project.


How to

Ideal workflow

For architects to efficiently calculate the air/light ratio, the requirements are:

  • the Rooms on which to perform the calculation.

  • the Windows, Doors and/or Curtain Panel to consider.

  • the Parameters for the above category which inform about the correct areas.


pyM4B implementation

No manual calculation is needed... after a few inputs:

  1. The project phase on which to operate.

  2. Pick the Rooms on which to perform the calculation.

  3. Specify the parameters about:

    1. Rooms - area parameter to fill with the sum of all openings areas.

    2. Rooms - Numeric parameter to fill with the calculated ratio

    3. Windows - area parameter to read

    4. Doors - area parameter to read

    5. Curtain Panels - area parameter to read


If you don't want to read parameters for one of the opening categories, just select the "---" input.



Since we don't like to return answers without complete explanations, at the end of the air/light calculation, it is possible to export additional data to CSV. The reason why we choose CSV instead of a window directly in Revit is because a CSV export is both faster and more secure (the pyRevit output window, if overloaded, might crash your Revit session 😅)


Once defined the desired CSV file name, the script will create 2 different files

  • [your name] - summary.csv

  • [your name] - detail.csv

Here is a short extract, with a description, of both:


 

Want to know some back scenes?

A couple of curiosities which I'd like to list, challenges that popped out during the development of this function.


1. why to select project phase?

As you know, Rooms don't quite have phases; a room can only exist in one phase.

Therefore, to ease the element selection and avoid possible misselection, we need to specify the phase so that we always have a handy filter to apply to our FilteredElementCollector().


2. how can the script detect the exterior opening?

By default, Revit has the Properties .FromRoom and .ToRoom, however, they might not be accessible, depending also on the way the family is built, or the thickness of the wall.


We prepared a function, called below get_adjacentRooms(). What it does is to calculate the central point for each openings (e, in the script below) and iterate through all the rooms, collecting the ones at a specific distance from the element. In the case the function return only 1 room, then we consider that element (e) as and external opening.


3. tell me more about the performance enhancement.

In order to permit a quick execution also in large project, we tried to limit as mus as possible the amount of element to be collected per each room. This is possible as per every room we are collecting element using 3 filters:

  • Phase Filter

  • Multicategory Filter

  • BoundingBox Filter



 

And that's all,

I hope you found this content useful and enjoyable... or at least enlightening!




Cheers!




94 views0 comments

Recent Posts

See All

Comentários


bottom of page