Module: MediumOffice

Defined in:
lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb

Overview

Custom changes for the MediumOffice prototype. These are changes that are inconsistent with other prototype building types.

AirTerminalSingleDuctVAVReheat collapse

Instance Method Summary collapse

Instance Method Details

#add_door_infiltration(climate_zone, model) ⇒ Boolean

add door infiltration

Parameters:

  • climate_zone (String)

    ASHRAE climate zone, e.g. ‘ASHRAE 169-2013-4A’

  • model (OpenStudio::Model::Model)

    OpenStudio model object

Returns:

  • (Boolean)

    returns true if successful, false if not



94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 94

def add_door_infiltration(climate_zone, model)
  # add extra infiltration for entry door in m3/s (there is no attic in 'DOE Ref Pre-1980')
  return false if template == 'DOE Ref 1980-2004' || template == 'DOE Ref Pre-1980'

  entry_space = model.getSpaceByName('Perimeter_bot_ZN_1').get
  infiltration_entrydoor = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(model)
  infiltration_entrydoor.setName('entry door Infiltration')
  infiltration_per_zone_entrydoor = 0
  if template == '90.1-2004'
    infiltration_per_zone_entrydoor = 1.04300287
    infiltration_entrydoor.setSchedule(model_add_schedule(model, 'OfficeMedium INFIL_Door_Opening_SCH'))
  elsif template == '90.1-2007' || template == '90.1-2010' || template == '90.1-2013' || template == '90.1-2016' || template == '90.1-2019'
    case climate_zone
      when 'ASHRAE 169-2006-0A',
           'ASHRAE 169-2006-1A',
           'ASHRAE 169-2006-0B',
           'ASHRAE 169-2006-1B',
           'ASHRAE 169-2006-2A',
           'ASHRAE 169-2006-2B',
           'ASHRAE 169-2013-0A',
           'ASHRAE 169-2013-1A',
           'ASHRAE 169-2013-0B',
           'ASHRAE 169-2013-1B',
           'ASHRAE 169-2013-2A',
           'ASHRAE 169-2013-2B'
        infiltration_per_zone_entrydoor = 1.04300287
        infiltration_entrydoor.setSchedule(model_add_schedule(model, 'OfficeMedium INFIL_Door_Opening_SCH'))
      else
        infiltration_per_zone_entrydoor = 0.678659786
        infiltration_entrydoor.setSchedule(model_add_schedule(model, 'OfficeMedium INFIL_Door_Opening_SCH'))
    end
  end
  infiltration_entrydoor.setDesignFlowRate(infiltration_per_zone_entrydoor)
  infiltration_entrydoor.setSpace(entry_space)
  return true
end

#air_loop_hvac_supply_air_temperature_reset_type(air_loop_hvac) ⇒ String

Type of SAT reset for this building type

Parameters:

  • air_loop_hvac (OpenStudio::Model::AirLoopHVAC)

    air loop

Returns:

  • (String)

    Returns type of SAT reset



180
181
182
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 180

def air_loop_hvac_supply_air_temperature_reset_type(air_loop_hvac)
  return 'oa'
end

#air_terminal_single_duct_vav_reheat_apply_initial_prototype_damper_position(air_terminal_single_duct_vav_reheat, zone_oa_per_area) ⇒ Boolean

Set the initial minimum damper position based on OA rate of the space and the template. Zones with low OA per area get lower initial guesses. Final position will be adjusted upward as necessary by Standards.AirLoopHVAC.apply_minimum_vav_damper_positions

Parameters:

  • air_terminal_single_duct_vav_reheat (OpenStudio::Model::AirTerminalSingleDuctVAVReheat)

    the air terminal object

  • zone_oa_per_area (Double)

    the zone outdoor air per area in m^3/s*m^2

Returns:

  • (Boolean)

    returns true if successful, false if not



167
168
169
170
171
172
173
174
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 167

def air_terminal_single_duct_vav_reheat_apply_initial_prototype_damper_position(air_terminal_single_duct_vav_reheat, zone_oa_per_area)
  min_damper_position = template == '90.1-2010' || template == '90.1-2013' || template == '90.1-2016' || template == '90.1-2019' ? 0.2 : 0.3

  # Set the minimum flow fraction
  air_terminal_single_duct_vav_reheat.setConstantMinimumAirFlowFraction(min_damper_position)

  return true
end

#model_custom_daylighting_tweaks(building_type, climate_zone, prototype_input, model) ⇒ Object



131
132
133
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 131

def model_custom_daylighting_tweaks(building_type, climate_zone, prototype_input, model)
  return true
end

#model_custom_geometry_tweaks(model, building_type, climate_zone, prototype_input) ⇒ Boolean

geometry adjustments specific to the prototype model

Parameters:

  • model (OpenStudio::Model::Model)

    OpenStudio model object

  • building_type (String the building type)

    uilding_type [String the building type

  • climate_zone (String)

    ASHRAE climate zone, e.g. ‘ASHRAE 169-2013-4A’

  • prototype_input (Hash)

    hash of prototype inputs

Returns:

  • (Boolean)

    returns true if successful, false if not



153
154
155
156
157
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 153

def model_custom_geometry_tweaks(model, building_type, climate_zone, prototype_input)
  # Set original building North axis
  OpenstudioStandards::Geometry.model_set_building_north_axis(model, 0.0)
  return true
end

#model_custom_hvac_tweaks(model, building_type, climate_zone, prototype_input) ⇒ Boolean

hvac adjustments specific to the prototype model

Parameters:

  • model (OpenStudio::Model::Model)

    OpenStudio model object

  • building_type (String the building type)

    uilding_type [String the building type

  • climate_zone (String)

    ASHRAE climate zone, e.g. ‘ASHRAE 169-2013-4A’

  • prototype_input (Hash)

    hash of prototype inputs

Returns:

  • (Boolean)

    returns true if successful, false if not



11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 11

def model_custom_hvac_tweaks(model, building_type, climate_zone, prototype_input)
  OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Started building type specific HVAC adjustments')

  # add transformer
  # efficiency based on a 45 kVA transformer
  case template
  when '90.1-2004', '90.1-2007'
    transformer_efficiency = 0.961
  when '90.1-2010', '90.1-2013'
    transformer_efficiency = 0.977
  when '90.1-2016', '90.1-2019'
    transformer_efficiency = 0.984
  else
    transformer_efficiency = nil
  end
  return true unless !transformer_efficiency.nil?

  # Change to output variable name in E+ 9.4 (OS 3.1.0)
  excluded_interiorequip_variable = if model.version < OpenStudio::VersionString.new('3.1.0')
                                      'Electric Equipment Electric Energy'
                                    else
                                      'Electric Equipment Electricity Energy'
                                    end

  model_add_transformer(model,
                        wired_lighting_frac: 0.0281,
                        transformer_size: 45000,
                        transformer_efficiency: transformer_efficiency,
                        excluded_interiorequip_key: '2 Elevator Lift Motors',
                        excluded_interiorequip_meter: excluded_interiorequip_variable)

  model.getSpaces.sort.each do |space|
    if space.name.get.to_s == 'Core_bottom'
      model_add_elevator(model,
                         space,
                         prototype_input['number_of_elevators'],
                         prototype_input['elevator_type'],
                         prototype_input['elevator_schedule'],
                         prototype_input['elevator_fan_schedule'],
                         prototype_input['elevator_fan_schedule'],
                         building_type)
    end
  end

  OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Finished building type specific adjustments')

  # add extra infiltration for entry door
  add_door_infiltration(climate_zone, model)
  OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Added door infiltration')

  # set infiltration schedule for plenums
  # @todo remove once infil_sch in Standards.Space pulls from default building infiltration schedule
  model.getSpaces.each do |space|
    next unless space.name.get.to_s.include? 'Plenum'

    # add infiltration if DOE Ref vintage
    if template == 'DOE Ref 1980-2004' || template == 'DOE Ref Pre-1980'
      # Create an infiltration rate object for this space
      infiltration = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(space.model)
      infiltration.setName("#{space.name} Infiltration")
      all_ext_infil_m3_per_s_per_m2 = OpenStudio.convert(0.2232, 'ft^3/min*ft^2', 'm^3/s*m^2').get
      infiltration.setFlowperExteriorSurfaceArea(all_ext_infil_m3_per_s_per_m2)
      infiltration.setSchedule(model_add_schedule(model, 'Medium Office Infil Quarter On'))
      infiltration.setConstantTermCoefficient(1.0)
      infiltration.setTemperatureTermCoefficient(0.0)
      infiltration.setVelocityTermCoefficient(0.0)
      infiltration.setVelocitySquaredTermCoefficient(0.0)
      infiltration.setSpace(space)
    else
      space.spaceInfiltrationDesignFlowRates.each do |infiltration_object|
        infiltration_object.setSchedule(model_add_schedule(model, 'OfficeMedium INFIL_SCH_PNNL'))
      end
    end
  end

  return true
end

#model_custom_swh_tweaks(model, building_type, climate_zone, prototype_input) ⇒ Boolean

swh adjustments specific to the prototype model

Parameters:

  • model (OpenStudio::Model::Model)

    OpenStudio model object

  • building_type (String the building type)

    uilding_type [String the building type

  • climate_zone (String)

    ASHRAE climate zone, e.g. ‘ASHRAE 169-2013-4A’

  • prototype_input (Hash)

    hash of prototype inputs

Returns:

  • (Boolean)

    returns true if successful, false if not



142
143
144
# File 'lib/openstudio-standards/prototypes/common/buildings/Prototype.MediumOffice.rb', line 142

def model_custom_swh_tweaks(model, building_type, climate_zone, prototype_input)
  return true
end