openstudio-standards 0.1.9 → 0.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/data/standards/OpenStudio_Standards.xlsx +0 -0
- data/lib/openstudio-standards/btap/compliance.rb +17 -7
- data/lib/openstudio-standards/btap/hvac.rb +6 -5
- data/lib/openstudio-standards/btap/measures.rb +137 -102
- data/lib/openstudio-standards/hvac_sizing/Siz.Model.rb +2 -2
- data/lib/openstudio-standards/prototypes/Prototype.FanVariableVolume.rb +1 -1
- data/lib/openstudio-standards/prototypes/Prototype.Model.rb +96 -31
- data/lib/openstudio-standards/prototypes/Prototype.Model.swh.rb +1 -1
- data/lib/openstudio-standards/prototypes/Prototype.building_specific_methods.rb +163 -0
- data/lib/openstudio-standards/prototypes/Prototype.full_service_restaurant.rb +54 -52
- data/lib/openstudio-standards/prototypes/Prototype.high_rise_apartment.rb +28 -26
- data/lib/openstudio-standards/prototypes/Prototype.hospital.rb +41 -39
- data/lib/openstudio-standards/prototypes/Prototype.large_hotel.rb +19 -17
- data/lib/openstudio-standards/prototypes/Prototype.large_office.rb +16 -13
- data/lib/openstudio-standards/prototypes/Prototype.medium_office.rb +13 -11
- data/lib/openstudio-standards/prototypes/Prototype.mid_rise_apartment.rb +33 -31
- data/lib/openstudio-standards/prototypes/Prototype.outpatient.rb +66 -64
- data/lib/openstudio-standards/prototypes/Prototype.primary_school.rb +8 -88
- data/lib/openstudio-standards/prototypes/Prototype.quick_service_restaurant.rb +54 -52
- data/lib/openstudio-standards/prototypes/Prototype.retail_standalone.rb +13 -11
- data/lib/openstudio-standards/prototypes/Prototype.retail_stripmall.rb +15 -13
- data/lib/openstudio-standards/prototypes/Prototype.secondary_school.rb +11 -9
- data/lib/openstudio-standards/prototypes/Prototype.small_hotel.rb +13 -11
- data/lib/openstudio-standards/prototypes/Prototype.small_office.rb +7 -5
- data/lib/openstudio-standards/prototypes/Prototype.utilities.rb +18 -13
- data/lib/openstudio-standards/prototypes/Prototype.warehouse.rb +11 -9
- data/lib/openstudio-standards/standards/Standards.AirLoopHVAC.rb +23 -12
- data/lib/openstudio-standards/standards/Standards.Fan.rb +7 -4
- data/lib/openstudio-standards/standards/Standards.Model.rb +4 -4
- data/lib/openstudio-standards/standards/Standards.WaterHeaterMixed.rb +9 -4
- data/lib/openstudio-standards/utilities/simulation.rb +6 -1
- data/lib/openstudio-standards/version.rb +1 -1
- data/lib/openstudio-standards/weather/Weather.Model.rb +1 -1
- metadata +3 -2
@@ -1,7 +1,8 @@
|
|
1
1
|
|
2
|
-
#
|
3
|
-
|
4
|
-
|
2
|
+
# Modules for building-type specific methods
|
3
|
+
module PrototypeBuilding
|
4
|
+
module PrimarySchool
|
5
|
+
def self.define_space_type_map(building_type, template, climate_zone)
|
5
6
|
space_type_map = nil
|
6
7
|
case template
|
7
8
|
when 'NECB 2011'
|
@@ -35,89 +36,9 @@ class OpenStudio::Model::Model
|
|
35
36
|
return space_type_map
|
36
37
|
end
|
37
38
|
|
38
|
-
def define_hvac_system_map(building_type, template, climate_zone)
|
39
|
+
def self.define_hvac_system_map(building_type, template, climate_zone)
|
39
40
|
system_to_space_map = nil
|
40
41
|
|
41
|
-
# case template
|
42
|
-
# when 'DOE Ref Pre-1980', 'DOE Ref 1980-2004'
|
43
|
-
# system_to_space_map = [
|
44
|
-
# {
|
45
|
-
# 'type' => 'PVAV',
|
46
|
-
# 'name' => 'PVAV_POD_1',
|
47
|
-
# 'space_names' =>
|
48
|
-
# [
|
49
|
-
# 'Corner_Class_1_Pod_1_ZN_1_FLR_1',
|
50
|
-
# 'Mult_Class_1_Pod_1_ZN_1_FLR_1',
|
51
|
-
# 'Corridor_Pod_1_ZN_1_FLR_1',
|
52
|
-
# 'Corner_Class_2_Pod_1_ZN_1_FLR_1',
|
53
|
-
# 'Mult_Class_2_Pod_1_ZN_1_FLR_1',
|
54
|
-
# 'Corner_Class_1_Pod_2_ZN_1_FLR_1'
|
55
|
-
# ]
|
56
|
-
# },
|
57
|
-
# {
|
58
|
-
# 'type' => 'PVAV',
|
59
|
-
# 'name' => 'PVAV_POD_2',
|
60
|
-
# 'space_names' =>
|
61
|
-
# [
|
62
|
-
# 'Mult_Class_1_Pod_2_ZN_1_FLR_1',
|
63
|
-
# 'Corridor_Pod_2_ZN_1_FLR_1',
|
64
|
-
# 'Corner_Class_2_Pod_2_ZN_1_FLR_1',
|
65
|
-
# 'Mult_Class_2_Pod_2_ZN_1_FLR_1'
|
66
|
-
# ]
|
67
|
-
# },
|
68
|
-
# {
|
69
|
-
# 'type' => 'PVAV',
|
70
|
-
# 'name' => 'PVAV_POD_3',
|
71
|
-
# 'space_names' =>
|
72
|
-
# [
|
73
|
-
# 'Corner_Class_1_Pod_3_ZN_1_FLR_1',
|
74
|
-
# 'Mult_Class_1_Pod_3_ZN_1_FLR_1',
|
75
|
-
# 'Corridor_Pod_3_ZN_1_FLR_1',
|
76
|
-
# 'Corner_Class_2_Pod_3_ZN_1_FLR_1',
|
77
|
-
# 'Mult_Class_2_Pod_3_ZN_1_FLR_1'
|
78
|
-
# ]
|
79
|
-
# },
|
80
|
-
# {
|
81
|
-
# 'type' => 'PVAV',
|
82
|
-
# 'name' => 'PVAV_OTHER',
|
83
|
-
# 'space_names' =>
|
84
|
-
# [
|
85
|
-
# 'Computer_Class_ZN_1_FLR_1',
|
86
|
-
# 'Main_Corridor_ZN_1_FLR_1',
|
87
|
-
# 'Lobby_ZN_1_FLR_1',
|
88
|
-
# 'Mech_ZN_1_FLR_1',
|
89
|
-
# 'Bath_ZN_1_FLR_1',
|
90
|
-
# 'Offices_ZN_1_FLR_1',
|
91
|
-
# 'Library_Media_Center_ZN_1_FLR_1'
|
92
|
-
# ]
|
93
|
-
# },
|
94
|
-
# {
|
95
|
-
# 'type' => 'PSZ-AC',
|
96
|
-
# 'name' => 'PSZ-AC_1-6',
|
97
|
-
# 'space_names' =>
|
98
|
-
# [
|
99
|
-
# 'Kitchen_ZN_1_FLR_1'
|
100
|
-
# ]
|
101
|
-
# },
|
102
|
-
# {
|
103
|
-
# 'type' => 'PSZ-AC',
|
104
|
-
# 'name' => 'PSZ-AC_2-5',
|
105
|
-
# 'space_names' =>
|
106
|
-
# [
|
107
|
-
# 'Gym_ZN_1_FLR_1'
|
108
|
-
# ]
|
109
|
-
# },
|
110
|
-
# {
|
111
|
-
# 'type' => 'PSZ-AC',
|
112
|
-
# 'name' => 'PSZ-AC_2-7',
|
113
|
-
# 'space_names' =>
|
114
|
-
# [
|
115
|
-
# 'Cafeteria_ZN_1_FLR_1'
|
116
|
-
# ]
|
117
|
-
# }
|
118
|
-
# ]
|
119
|
-
|
120
|
-
# when '90.1-2004', '90.1-2007', '90.1-2010', '90.1-2013'
|
121
42
|
system_to_space_map = [
|
122
43
|
{
|
123
44
|
'type' => 'PVAV',
|
@@ -229,16 +150,15 @@ class OpenStudio::Model::Model
|
|
229
150
|
}
|
230
151
|
]
|
231
152
|
|
232
|
-
# end
|
233
|
-
|
234
153
|
return system_to_space_map
|
235
154
|
end
|
236
155
|
|
237
|
-
def custom_hvac_tweaks(building_type, template, climate_zone, prototype_input)
|
156
|
+
def self.custom_hvac_tweaks(building_type, template, climate_zone, prototype_input, model)
|
238
157
|
return true
|
239
158
|
end
|
240
159
|
|
241
|
-
def custom_swh_tweaks(building_type, template, climate_zone, prototype_input)
|
160
|
+
def self.custom_swh_tweaks(building_type, template, climate_zone, prototype_input, model)
|
242
161
|
return true
|
243
162
|
end
|
244
163
|
end
|
164
|
+
end
|
@@ -1,7 +1,8 @@
|
|
1
1
|
|
2
|
-
#
|
3
|
-
|
4
|
-
|
2
|
+
# Modules for building-type specific methods
|
3
|
+
module PrototypeBuilding
|
4
|
+
module QuickServiceRestaurant
|
5
|
+
def self.define_space_type_map(building_type, template, climate_zone)
|
5
6
|
space_type_map = nil
|
6
7
|
case template
|
7
8
|
when 'DOE Ref Pre-1980'
|
@@ -26,7 +27,7 @@ class OpenStudio::Model::Model
|
|
26
27
|
return space_type_map
|
27
28
|
end
|
28
29
|
|
29
|
-
def define_hvac_system_map(building_type, template, climate_zone)
|
30
|
+
def self.define_hvac_system_map(building_type, template, climate_zone)
|
30
31
|
case template
|
31
32
|
when 'DOE Ref Pre-1980', 'DOE Ref 1980-2004'
|
32
33
|
system_to_space_map = [
|
@@ -309,75 +310,75 @@ class OpenStudio::Model::Model
|
|
309
310
|
return system_to_space_map
|
310
311
|
end
|
311
312
|
|
312
|
-
def custom_hvac_tweaks(building_type, template, climate_zone, prototype_input)
|
313
|
+
def self.custom_hvac_tweaks(building_type, template, climate_zone, prototype_input, model)
|
313
314
|
OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Started building type specific adjustments')
|
314
315
|
|
315
316
|
# add extra equipment for kitchen
|
316
|
-
add_extra_equip_kitchen(template)
|
317
|
+
PrototypeBuilding::QuickServiceRestaurant.add_extra_equip_kitchen(template, model)
|
317
318
|
# add extra infiltration for dining room door and attic
|
318
|
-
add_door_infiltration(template, climate_zone)
|
319
|
+
PrototypeBuilding::QuickServiceRestaurant.add_door_infiltration(template, climate_zone, model)
|
319
320
|
# add zone_mixing between kitchen and dining
|
320
|
-
add_zone_mixing(template)
|
321
|
+
PrototypeBuilding::QuickServiceRestaurant.add_zone_mixing(template, model)
|
321
322
|
# Update Sizing Zone
|
322
|
-
update_sizing_zone(template)
|
323
|
+
PrototypeBuilding::QuickServiceRestaurant.update_sizing_zone(template, model)
|
323
324
|
# adjust the cooling setpoint
|
324
|
-
adjust_clg_setpoint(template, climate_zone)
|
325
|
+
PrototypeBuilding::QuickServiceRestaurant.adjust_clg_setpoint(template, climate_zone, model)
|
325
326
|
# reset the design OA of kitchen
|
326
|
-
reset_kitchen_oa(template)
|
327
|
+
PrototypeBuilding::QuickServiceRestaurant.reset_kitchen_oa(template, model)
|
327
328
|
|
328
329
|
OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Finished building type specific adjustments')
|
329
330
|
|
330
331
|
return true
|
331
332
|
end
|
332
333
|
|
333
|
-
def add_door_infiltration(template, climate_zone)
|
334
|
+
def self.add_door_infiltration(template, climate_zone, model)
|
334
335
|
# add extra infiltration for dining room door and attic (there is no attic in 'DOE Ref Pre-1980')
|
335
336
|
unless template == 'DOE Ref 1980-2004' || template == 'DOE Ref Pre-1980'
|
336
|
-
dining_space = getSpaceByName('Dining').get
|
337
|
-
attic_space = getSpaceByName('Attic').get
|
338
|
-
infiltration_diningdoor = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(
|
339
|
-
infiltration_attic = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(
|
337
|
+
dining_space = model.getSpaceByName('Dining').get
|
338
|
+
attic_space = model.getSpaceByName('Attic').get
|
339
|
+
infiltration_diningdoor = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(model)
|
340
|
+
infiltration_attic = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(model)
|
340
341
|
infiltration_diningdoor.setName('Dining door Infiltration')
|
341
342
|
infiltration_per_zone_diningdoor = 0
|
342
343
|
infiltration_per_zone_attic = 0.0729
|
343
344
|
if template == '90.1-2004'
|
344
345
|
infiltration_per_zone_diningdoor = 0.902834611
|
345
|
-
infiltration_diningdoor.setSchedule(add_schedule('RestaurantFastFood DOOR_INFIL_SCH'))
|
346
|
+
infiltration_diningdoor.setSchedule(model.add_schedule('RestaurantFastFood DOOR_INFIL_SCH'))
|
346
347
|
elsif template == '90.1-2007'
|
347
348
|
case climate_zone
|
348
349
|
when 'ASHRAE 169-2006-1A', 'ASHRAE 169-2006-2A', 'ASHRAE 169-2006-2B', 'ASHRAE 169-2006-3A', 'ASHRAE 169-2006-3B',
|
349
350
|
'ASHRAE 169-2006-3C', 'ASHRAE 169-2006-4A', 'ASHRAE 169-2006-4B', 'ASHRAE 169-2006-4C'
|
350
351
|
infiltration_per_zone_diningdoor = 0.902834611
|
351
|
-
infiltration_diningdoor.setSchedule(add_schedule('RestaurantFastFood DOOR_INFIL_SCH'))
|
352
|
+
infiltration_diningdoor.setSchedule(model.add_schedule('RestaurantFastFood DOOR_INFIL_SCH'))
|
352
353
|
else
|
353
354
|
infiltration_per_zone_diningdoor = 0.583798439
|
354
|
-
infiltration_diningdoor.setSchedule(add_schedule('RestaurantFastFood VESTIBULE_DOOR_INFIL_SCH'))
|
355
|
+
infiltration_diningdoor.setSchedule(model.add_schedule('RestaurantFastFood VESTIBULE_DOOR_INFIL_SCH'))
|
355
356
|
end
|
356
357
|
elsif template == '90.1-2010' || template == '90.1-2013'
|
357
358
|
case climate_zone
|
358
359
|
when 'ASHRAE 169-2006-1A', 'ASHRAE 169-2006-2A', 'ASHRAE 169-2006-2B', 'ASHRAE 169-2006-3A', 'ASHRAE 169-2006-3B', 'ASHRAE 169-2006-3C'
|
359
360
|
infiltration_per_zone_diningdoor = 0.902834611
|
360
|
-
infiltration_diningdoor.setSchedule(add_schedule('RestaurantFastFood DOOR_INFIL_SCH'))
|
361
|
+
infiltration_diningdoor.setSchedule(model.add_schedule('RestaurantFastFood DOOR_INFIL_SCH'))
|
361
362
|
else
|
362
363
|
infiltration_per_zone_diningdoor = 0.583798439
|
363
|
-
infiltration_diningdoor.setSchedule(add_schedule('RestaurantFastFood VESTIBULE_DOOR_INFIL_SCH'))
|
364
|
+
infiltration_diningdoor.setSchedule(model.add_schedule('RestaurantFastFood VESTIBULE_DOOR_INFIL_SCH'))
|
364
365
|
end
|
365
366
|
end
|
366
367
|
infiltration_diningdoor.setDesignFlowRate(infiltration_per_zone_diningdoor)
|
367
368
|
infiltration_diningdoor.setSpace(dining_space)
|
368
369
|
infiltration_attic.setDesignFlowRate(infiltration_per_zone_attic)
|
369
|
-
infiltration_attic.setSchedule(add_schedule('Always On'))
|
370
|
+
infiltration_attic.setSchedule(model.add_schedule('Always On'))
|
370
371
|
infiltration_attic.setSpace(attic_space)
|
371
372
|
end
|
372
373
|
end
|
373
374
|
|
374
375
|
# add extra equipment for kitchen
|
375
|
-
def add_extra_equip_kitchen(template)
|
376
|
-
kitchen_space = getSpaceByName('Kitchen')
|
376
|
+
def self.add_extra_equip_kitchen(template, model)
|
377
|
+
kitchen_space = model.getSpaceByName('Kitchen')
|
377
378
|
kitchen_space = kitchen_space.get
|
378
379
|
kitchen_space_type = kitchen_space.spaceType.get
|
379
|
-
elec_equip_def1 = OpenStudio::Model::ElectricEquipmentDefinition.new(
|
380
|
-
elec_equip_def2 = OpenStudio::Model::ElectricEquipmentDefinition.new(
|
380
|
+
elec_equip_def1 = OpenStudio::Model::ElectricEquipmentDefinition.new(model)
|
381
|
+
elec_equip_def2 = OpenStudio::Model::ElectricEquipmentDefinition.new(model)
|
381
382
|
elec_equip_def1.setName('Kitchen Electric Equipment Definition1')
|
382
383
|
elec_equip_def2.setName('Kitchen Electric Equipment Definition2')
|
383
384
|
case template
|
@@ -402,8 +403,8 @@ class OpenStudio::Model::Model
|
|
402
403
|
elec_equip2.setName('Kitchen_Reach-in-Refrigerator')
|
403
404
|
elec_equip1.setSpaceType(kitchen_space_type)
|
404
405
|
elec_equip2.setSpaceType(kitchen_space_type)
|
405
|
-
elec_equip1.setSchedule(add_schedule('RestaurantFastFood ALWAYS_ON'))
|
406
|
-
elec_equip2.setSchedule(add_schedule('RestaurantFastFood ALWAYS_ON'))
|
406
|
+
elec_equip1.setSchedule(model.add_schedule('RestaurantFastFood ALWAYS_ON'))
|
407
|
+
elec_equip2.setSchedule(model.add_schedule('RestaurantFastFood ALWAYS_ON'))
|
407
408
|
when 'DOE Ref Pre-1980', 'DOE Ref 1980-2004'
|
408
409
|
elec_equip_def1.setDesignLevel(577)
|
409
410
|
elec_equip_def1.setFractionLatent(0)
|
@@ -413,42 +414,42 @@ class OpenStudio::Model::Model
|
|
413
414
|
elec_equip1 = OpenStudio::Model::ElectricEquipment.new(elec_equip_def1)
|
414
415
|
elec_equip1.setName('Kitchen_ExhFan_Equip')
|
415
416
|
elec_equip1.setSpaceType(kitchen_space_type)
|
416
|
-
elec_equip1.setSchedule(add_schedule('RestaurantFastFood Kitchen_Exhaust_SCH'))
|
417
|
+
elec_equip1.setSchedule(model.add_schedule('RestaurantFastFood Kitchen_Exhaust_SCH'))
|
417
418
|
end
|
418
419
|
end
|
419
420
|
|
420
|
-
def update_sizing_zone(template)
|
421
|
+
def self.update_sizing_zone(template, model)
|
421
422
|
case template
|
422
423
|
when '90.1-2007', '90.1-2010', '90.1-2013'
|
423
|
-
zone_sizing = getSpaceByName('Dining').get.thermalZone.get.sizingZone
|
424
|
+
zone_sizing = model.getSpaceByName('Dining').get.thermalZone.get.sizingZone
|
424
425
|
zone_sizing.setCoolingDesignAirFlowMethod('DesignDayWithLimit')
|
425
426
|
zone_sizing.setCoolingMinimumAirFlowperZoneFloorArea(0.003581176)
|
426
|
-
zone_sizing = getSpaceByName('Kitchen').get.thermalZone.get.sizingZone
|
427
|
+
zone_sizing = model.getSpaceByName('Kitchen').get.thermalZone.get.sizingZone
|
427
428
|
zone_sizing.setCoolingDesignAirFlowMethod('DesignDayWithLimit')
|
428
429
|
zone_sizing.setCoolingMinimumAirFlowperZoneFloorArea(0)
|
429
430
|
when '90.1-2004'
|
430
|
-
zone_sizing = getSpaceByName('Dining').get.thermalZone.get.sizingZone
|
431
|
+
zone_sizing = model.getSpaceByName('Dining').get.thermalZone.get.sizingZone
|
431
432
|
zone_sizing.setCoolingDesignAirFlowMethod('DesignDayWithLimit')
|
432
433
|
zone_sizing.setCoolingMinimumAirFlowperZoneFloorArea(0.007111554)
|
433
|
-
zone_sizing = getSpaceByName('Kitchen').get.thermalZone.get.sizingZone
|
434
|
+
zone_sizing = model.getSpaceByName('Kitchen').get.thermalZone.get.sizingZone
|
434
435
|
zone_sizing.setCoolingDesignAirFlowMethod('DesignDayWithLimit')
|
435
436
|
zone_sizing.setCoolingMinimumAirFlowperZoneFloorArea(0)
|
436
437
|
end
|
437
438
|
end
|
438
439
|
|
439
|
-
def adjust_clg_setpoint(template, climate_zone)
|
440
|
+
def self.adjust_clg_setpoint(template, climate_zone, model)
|
440
441
|
['Dining', 'Kitchen'].each do |space_name|
|
441
|
-
space_type_name = getSpaceByName(space_name).get.spaceType.get.name.get
|
442
|
+
space_type_name = model.getSpaceByName(space_name).get.spaceType.get.name.get
|
442
443
|
thermostat_name = space_type_name + ' Thermostat'
|
443
|
-
thermostat = getThermostatSetpointDualSetpointByName(thermostat_name).get
|
444
|
+
thermostat = model.getThermostatSetpointDualSetpointByName(thermostat_name).get
|
444
445
|
case template
|
445
446
|
when '90.1-2004', '90.1-2007', '90.1-2010'
|
446
447
|
if climate_zone == 'ASHRAE 169-2006-2B' || climate_zone == 'ASHRAE 169-2006-1B' || climate_zone == 'ASHRAE 169-2006-3B'
|
447
448
|
case space_name
|
448
449
|
when 'Dining'
|
449
|
-
thermostat.setCoolingSetpointTemperatureSchedule(add_schedule('RestaurantFastFood CLGSETP_SCH_NO_OPTIMUM'))
|
450
|
+
thermostat.setCoolingSetpointTemperatureSchedule(model.add_schedule('RestaurantFastFood CLGSETP_SCH_NO_OPTIMUM'))
|
450
451
|
when 'Kitchen'
|
451
|
-
thermostat.setCoolingSetpointTemperatureSchedule(add_schedule('RestaurantFastFood CLGSETP_KITCHEN_SCH_NO_OPTIMUM'))
|
452
|
+
thermostat.setCoolingSetpointTemperatureSchedule(model.add_schedule('RestaurantFastFood CLGSETP_KITCHEN_SCH_NO_OPTIMUM'))
|
452
453
|
end
|
453
454
|
end
|
454
455
|
end
|
@@ -458,8 +459,8 @@ class OpenStudio::Model::Model
|
|
458
459
|
# In order to provide sufficient OSA to replace exhaust flow through kitchen hoods (3,300 cfm),
|
459
460
|
# modeled OSA to kitchen is different from OSA determined based on ASHRAE 62.1.
|
460
461
|
# It takes into account the available OSA in dining as transfer air.
|
461
|
-
def reset_kitchen_oa(template)
|
462
|
-
space_kitchen = getSpaceByName('Kitchen').get
|
462
|
+
def self.reset_kitchen_oa(template, model)
|
463
|
+
space_kitchen = model.getSpaceByName('Kitchen').get
|
463
464
|
ventilation = space_kitchen.designSpecificationOutdoorAir.get
|
464
465
|
ventilation.setOutdoorAirFlowperPerson(0)
|
465
466
|
ventilation.setOutdoorAirFlowperFloorArea(0)
|
@@ -471,10 +472,10 @@ class OpenStudio::Model::Model
|
|
471
472
|
end
|
472
473
|
end
|
473
474
|
|
474
|
-
def update_exhaust_fan_efficiency(template)
|
475
|
+
def self.update_exhaust_fan_efficiency(template, model)
|
475
476
|
case template
|
476
477
|
when '90.1-2004', '90.1-2007', '90.1-2010', '90.1-2013'
|
477
|
-
getFanZoneExhausts.sort.each do |exhaust_fan|
|
478
|
+
model.getFanZoneExhausts.sort.each do |exhaust_fan|
|
478
479
|
fan_name = exhaust_fan.name.to_s
|
479
480
|
if fan_name.include? 'Dining'
|
480
481
|
exhaust_fan.setFanEfficiency(1)
|
@@ -482,21 +483,21 @@ class OpenStudio::Model::Model
|
|
482
483
|
end
|
483
484
|
end
|
484
485
|
when 'DOE Ref Pre-1980', 'DOE Ref 1980-2004'
|
485
|
-
getFanZoneExhausts.sort.each do |exhaust_fan|
|
486
|
+
model.getFanZoneExhausts.sort.each do |exhaust_fan|
|
486
487
|
exhaust_fan.setFanEfficiency(1)
|
487
488
|
exhaust_fan.setPressureRise(0.000001)
|
488
489
|
end
|
489
490
|
end
|
490
491
|
end
|
491
492
|
|
492
|
-
def add_zone_mixing(template)
|
493
|
+
def self.add_zone_mixing(template, model)
|
493
494
|
# add zone_mixing between kitchen and dining
|
494
|
-
space_kitchen = getSpaceByName('Kitchen').get
|
495
|
+
space_kitchen = model.getSpaceByName('Kitchen').get
|
495
496
|
zone_kitchen = space_kitchen.thermalZone.get
|
496
|
-
space_dining = getSpaceByName('Dining').get
|
497
|
+
space_dining = model.getSpaceByName('Dining').get
|
497
498
|
zone_dining = space_dining.thermalZone.get
|
498
499
|
zone_mixing_kitchen = OpenStudio::Model::ZoneMixing.new(zone_kitchen)
|
499
|
-
zone_mixing_kitchen.setSchedule(add_schedule('RestaurantFastFood Hours_of_operation'))
|
500
|
+
zone_mixing_kitchen.setSchedule(model.add_schedule('RestaurantFastFood Hours_of_operation'))
|
500
501
|
case template
|
501
502
|
when 'DOE Ref Pre-1980', 'DOE Ref 1980-2004'
|
502
503
|
zone_mixing_kitchen.setDesignFlowRate(0.834532374)
|
@@ -509,19 +510,20 @@ class OpenStudio::Model::Model
|
|
509
510
|
zone_mixing_kitchen.setDeltaTemperature(0)
|
510
511
|
end
|
511
512
|
|
512
|
-
def update_waterheater_loss_coefficient(template)
|
513
|
+
def self.update_waterheater_loss_coefficient(template, model)
|
513
514
|
case template
|
514
515
|
when '90.1-2004', '90.1-2007', '90.1-2010', '90.1-2013', 'NECB 2011'
|
515
|
-
getWaterHeaterMixeds.sort.each do |water_heater|
|
516
|
+
model.getWaterHeaterMixeds.sort.each do |water_heater|
|
516
517
|
water_heater.setOffCycleLossCoefficienttoAmbientTemperature(7.561562668)
|
517
518
|
water_heater.setOnCycleLossCoefficienttoAmbientTemperature(7.561562668)
|
518
519
|
end
|
519
520
|
end
|
520
521
|
end
|
521
522
|
|
522
|
-
def custom_swh_tweaks(building_type, template, climate_zone, prototype_input)
|
523
|
-
update_waterheater_loss_coefficient(template)
|
523
|
+
def self.custom_swh_tweaks(building_type, template, climate_zone, prototype_input, model)
|
524
|
+
PrototypeBuilding::QuickServiceRestaurant.update_waterheater_loss_coefficient(template, model)
|
524
525
|
|
525
526
|
return true
|
526
527
|
end
|
527
528
|
end
|
529
|
+
end
|
@@ -1,12 +1,13 @@
|
|
1
1
|
|
2
2
|
# Extend the class to add Medium Office specific stuff
|
3
|
-
|
3
|
+
module PrototypeBuilding
|
4
|
+
module RetailStandalone
|
4
5
|
# TODO: The ElectricEquipment schedules are wrong in OpenStudio Standards... It needs to be 'RetailStandalone BLDG_EQUIP_SCH' for 90.1-2010 at least but probably all
|
5
6
|
# TODO: There is an OpenStudio bug where two heat exchangers are on the equipment list and it references the same single heat exchanger for both. This doubles the heat recovery energy.
|
6
7
|
# TODO: The HeatExchangerAirToAir is not calculating correctly. It does not equal the legacy IDF and has higher energy usage due to that.
|
7
8
|
# TODO: Need to determine if WaterHeater can be alone or if we need to 'fake' it.
|
8
9
|
|
9
|
-
def define_space_type_map(building_type, template, climate_zone)
|
10
|
+
def self.define_space_type_map(building_type, template, climate_zone)
|
10
11
|
space_type_map = nil
|
11
12
|
case template
|
12
13
|
when 'NECB 2011'
|
@@ -28,7 +29,7 @@ class OpenStudio::Model::Model
|
|
28
29
|
return space_type_map
|
29
30
|
end
|
30
31
|
|
31
|
-
def define_hvac_system_map(building_type, template, climate_zone)
|
32
|
+
def self.define_hvac_system_map(building_type, template, climate_zone)
|
32
33
|
system_to_space_map = [
|
33
34
|
{
|
34
35
|
'type' => 'PSZ-AC',
|
@@ -42,18 +43,18 @@ class OpenStudio::Model::Model
|
|
42
43
|
return system_to_space_map
|
43
44
|
end
|
44
45
|
|
45
|
-
def custom_hvac_tweaks(building_type, template, climate_zone, prototype_input)
|
46
|
+
def self.custom_hvac_tweaks(building_type, template, climate_zone, prototype_input, model)
|
46
47
|
OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Started building type specific adjustments')
|
47
48
|
|
48
49
|
# Add the door infiltration for template 2004,2007,2010,2013
|
49
50
|
case template
|
50
51
|
when '90.1-2004', '90.1-2007', '90.1-2010', '90.1-2013'
|
51
|
-
entry_space = getSpaceByName('Front_Entry').get
|
52
|
-
infiltration_entry = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(
|
52
|
+
entry_space = model.getSpaceByName('Front_Entry').get
|
53
|
+
infiltration_entry = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(model)
|
53
54
|
infiltration_entry.setName('Entry door Infiltration')
|
54
55
|
infiltration_per_zone = 1.418672682
|
55
56
|
infiltration_entry.setDesignFlowRate(infiltration_per_zone)
|
56
|
-
infiltration_entry.setSchedule(add_schedule('RetailStandalone INFIL_Door_Opening_SCH'))
|
57
|
+
infiltration_entry.setSchedule(model.add_schedule('RetailStandalone INFIL_Door_Opening_SCH'))
|
57
58
|
infiltration_entry.setSpace(entry_space)
|
58
59
|
end
|
59
60
|
|
@@ -62,19 +63,20 @@ class OpenStudio::Model::Model
|
|
62
63
|
return true
|
63
64
|
end
|
64
65
|
|
65
|
-
def update_waterheater_loss_coefficient(template)
|
66
|
+
def self.update_waterheater_loss_coefficient(template, model)
|
66
67
|
case template
|
67
68
|
when '90.1-2004', '90.1-2007', '90.1-2010', '90.1-2013', 'NECB 2011'
|
68
|
-
getWaterHeaterMixeds.sort.each do |water_heater|
|
69
|
+
model.getWaterHeaterMixeds.sort.each do |water_heater|
|
69
70
|
water_heater.setOffCycleLossCoefficienttoAmbientTemperature(4.10807252)
|
70
71
|
water_heater.setOnCycleLossCoefficienttoAmbientTemperature(4.10807252)
|
71
72
|
end
|
72
73
|
end
|
73
74
|
end
|
74
75
|
|
75
|
-
def custom_swh_tweaks(building_type, template, climate_zone, prototype_input)
|
76
|
-
update_waterheater_loss_coefficient(template)
|
76
|
+
def self.custom_swh_tweaks(building_type, template, climate_zone, prototype_input, model)
|
77
|
+
PrototypeBuilding::RetailStandalone.update_waterheater_loss_coefficient(template, model)
|
77
78
|
|
78
79
|
return true
|
79
80
|
end
|
80
81
|
end
|
82
|
+
end
|
@@ -1,7 +1,8 @@
|
|
1
1
|
|
2
|
-
#
|
3
|
-
|
4
|
-
|
2
|
+
# Modules for building-type specific methods
|
3
|
+
module PrototypeBuilding
|
4
|
+
module RetailStripmall
|
5
|
+
def self.define_space_type_map(building_type, template, climate_zone)
|
5
6
|
space_type_map = nil
|
6
7
|
case template
|
7
8
|
|
@@ -20,7 +21,7 @@ class OpenStudio::Model::Model
|
|
20
21
|
return space_type_map
|
21
22
|
end
|
22
23
|
|
23
|
-
def define_hvac_system_map(building_type, template, climate_zone)
|
24
|
+
def self.define_hvac_system_map(building_type, template, climate_zone)
|
24
25
|
system_to_space_map = [
|
25
26
|
{
|
26
27
|
'type' => 'PSZ-AC',
|
@@ -84,10 +85,10 @@ class OpenStudio::Model::Model
|
|
84
85
|
return system_to_space_map
|
85
86
|
end
|
86
87
|
|
87
|
-
def custom_hvac_tweaks(building_type, template, climate_zone, prototype_input)
|
88
|
+
def self.custom_hvac_tweaks(building_type, template, climate_zone, prototype_input, model)
|
88
89
|
OpenStudio.logFree(OpenStudio::Info, 'openstudio.model.Model', 'Started building type specific adjustments')
|
89
90
|
|
90
|
-
system_to_space_map = define_hvac_system_map(building_type, template, climate_zone)
|
91
|
+
system_to_space_map = PrototypeBuilding::RetailStripmall.define_hvac_system_map(building_type, template, climate_zone)
|
91
92
|
|
92
93
|
# Add infiltration door opening
|
93
94
|
# Spaces names to design infiltration rates (m3/s)
|
@@ -98,13 +99,13 @@ class OpenStudio::Model::Model
|
|
98
99
|
|
99
100
|
door_infiltration_map.each_pair do |space_names, infiltration_design_flowrate|
|
100
101
|
space_names.each do |space_name|
|
101
|
-
space = getSpaceByName(space_name).get
|
102
|
+
space = model.getSpaceByName(space_name).get
|
102
103
|
# Create the infiltration object and hook it up to the space type
|
103
|
-
infiltration = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(
|
104
|
+
infiltration = OpenStudio::Model::SpaceInfiltrationDesignFlowRate.new(model)
|
104
105
|
infiltration.setName("#{space_name} Door Open Infiltration")
|
105
106
|
infiltration.setSpace(space)
|
106
107
|
infiltration.setDesignFlowRate(infiltration_design_flowrate)
|
107
|
-
infiltration_schedule = add_schedule('RetailStripmall INFIL_Door_Opening_SCH')
|
108
|
+
infiltration_schedule = model.add_schedule('RetailStripmall INFIL_Door_Opening_SCH')
|
108
109
|
if infiltration_schedule.nil?
|
109
110
|
OpenStudio.logFree(OpenStudio::Error, 'openstudio.model.Model', "Can't find schedule (RetailStripmall INFIL_Door_Opening_SCH).")
|
110
111
|
return false
|
@@ -119,19 +120,20 @@ class OpenStudio::Model::Model
|
|
119
120
|
return true
|
120
121
|
end # add hvac
|
121
122
|
|
122
|
-
def update_waterheater_loss_coefficient(template)
|
123
|
+
def self.update_waterheater_loss_coefficient(template, model)
|
123
124
|
case template
|
124
125
|
when '90.1-2004', '90.1-2007', '90.1-2010', '90.1-2013', 'NECB 2011'
|
125
|
-
getWaterHeaterMixeds.sort.each do |water_heater|
|
126
|
+
model.getWaterHeaterMixeds.sort.each do |water_heater|
|
126
127
|
water_heater.setOffCycleLossCoefficienttoAmbientTemperature(1.205980747)
|
127
128
|
water_heater.setOnCycleLossCoefficienttoAmbientTemperature(1.205980747)
|
128
129
|
end
|
129
130
|
end
|
130
131
|
end
|
131
132
|
|
132
|
-
def custom_swh_tweaks(building_type, template, climate_zone, prototype_input)
|
133
|
-
update_waterheater_loss_coefficient(template)
|
133
|
+
def self.custom_swh_tweaks(building_type, template, climate_zone, prototype_input, model)
|
134
|
+
PrototypeBuilding::RetailStripmall.update_waterheater_loss_coefficient(template, model)
|
134
135
|
|
135
136
|
return true
|
136
137
|
end
|
137
138
|
end
|
139
|
+
end
|