Associate a parameter to walls that say the type of occupancy of the room it define

Hi there,
I am completely new in Dynamo and until now I manage to have a boundaries list for room, an occupancy type value list for room and now I want to set in Revit for each wall element the parameter occupancy of room it define.

  1. First problem I have no clue how to copy the occupancy from the rooms to their boundaries.
  2. Many walls appear as boundaries in more then one room of course, so I assume will get an error when comes to report the occupancy for the wall.

If you are asking why I want to have occupancy for my wall, it is because from occupancy I need to set the fire rating of the wall. I am trying to do this automatically but I am far away from a concrete result

What if a wall boarders on say seven occupancies (think the wall between the parking garage, a residential unit, leased office space, a restaurant, the building’s trash room, and a movie theater)?

Instead of looking at the wall, you should look at the areas which demarcate the use types, get the perimeter curves of each (this is one of those areas where the discontinuous curves of rooms and areas help), get the area on each side of those, find out what the difference in occupancy hazard group is between those two uses, and set the rating for that segment of the wall.

After that you can decide if you want “one rating for the full wall”, or variable rating (ie: stop using type X GWB after this point of the assembly).

Interesting problem. I’ve had a go.
I made the script so that the walls get the maximum rating /occupancy value from the rooms they enclose. That’s how I would do it.
Set Wall Fire Rating.dyn (35.7 KB)

How you explain it looks pretty easy except for the part “get the area on each side”, how do you do that?

Thank you for this example, it really solved out my problem. The only thing is I would like to associate the fire rating to the walls by creating a code that say: if the occupancy of the room is Office" and the name of room contain the word " Office" set the wall fire rating be 30 for example, if the room occupancy is “residential” and the name room contain the word “corridor” set the wall fire rating to be 60 and so on. So after setting the rules I can chose the highest value and assigned it to the wall.
Do you have any suggestion for writing a rule like that? I have been tried the "if " and the “function” but something go wrong and return to me a empty list no matter which level I use for sorting list out.

Any suggestion for the dummy boomer inside me ?

  • Take the polygon of each area
  • Pull the coordinate system at parameter 0.5 of each boundary segment
  • Create a point on either side of the Z of said coordinate system, so it would fall in each defined area.
  • Find the polygon which contains that point
  • Map to the area

I think you might have to use dictionaries for this.