openstudio-common-measures 0.5.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (57) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +12 -1
  3. data/README.md +7 -2
  4. data/doc_templates/copyright_erb.txt +1 -1
  5. data/lib/measures/AddCostPerFloorAreaUnusedToLights/measure.xml +2 -8
  6. data/lib/measures/AddCostToSupplySideHVACComponentByAirLoop/measure.xml +9 -3
  7. data/lib/measures/AddSimplePvToShadingSurfacesByType/measure.xml +2 -2
  8. data/lib/measures/RemoveUnusedDefaultProfiles/measure.xml +2 -2
  9. data/lib/measures/ReportModelChanges/measure.xml +2 -2
  10. data/lib/measures/SetCOPforSingleSpeedDXCoolingUnits/measure.xml +4 -4
  11. data/lib/measures/SetCOPforTwoSpeedDXCoolingUnits/measure.xml +4 -4
  12. data/lib/measures/SetGasBurnerEfficiency/measure.xml +4 -4
  13. data/lib/measures/ShiftScheduleProfileTime/measure.xml +4 -4
  14. data/lib/measures/SwapLightsDefinition/measure.xml +3 -5
  15. data/lib/measures/add_ems_emissions_reporting/measure.rb +236 -29
  16. data/lib/measures/add_ems_emissions_reporting/measure.xml +362 -10
  17. data/lib/measures/add_ev_load/measure.rb +51 -8
  18. data/lib/measures/add_ev_load/measure.xml +23 -5
  19. data/lib/measures/envelope_and_internal_load_breakdown/measure.xml +3 -3
  20. data/lib/measures/envelope_and_internal_load_breakdown/resources/report.html.erb +5 -1
  21. data/lib/measures/example_report/measure.xml +3 -3
  22. data/lib/measures/example_report/resources/report.html.erb +5 -1
  23. data/lib/measures/generic_qaqc/README.md +19 -4
  24. data/lib/measures/generic_qaqc/README.md.erb +7 -1
  25. data/lib/measures/generic_qaqc/docs/generic_qaqc_detailed.jpg +0 -0
  26. data/lib/measures/generic_qaqc/docs/generic_qaqc_summary.jpg +0 -0
  27. data/lib/measures/generic_qaqc/measure.rb +34 -29
  28. data/lib/measures/generic_qaqc/measure.xml +181 -82
  29. data/lib/measures/generic_qaqc/resources/check_cond_zns.rb +3 -1
  30. data/lib/measures/generic_qaqc/resources/check_domestic_hot_water.rb +13 -8
  31. data/lib/measures/generic_qaqc/resources/check_envelope_conductance.rb +330 -231
  32. data/lib/measures/generic_qaqc/resources/check_eui_by_end_use.rb +59 -20
  33. data/lib/measures/generic_qaqc/resources/check_eui_reasonableness.rb +58 -20
  34. data/lib/measures/generic_qaqc/resources/check_internal_loads.rb +57 -56
  35. data/lib/measures/generic_qaqc/resources/check_mech_sys_capacity.rb +4 -1
  36. data/lib/measures/generic_qaqc/resources/check_mech_sys_efficiency.rb +27 -22
  37. data/lib/measures/generic_qaqc/resources/check_mech_sys_part_load_eff.rb +4 -1
  38. data/lib/measures/generic_qaqc/resources/check_mech_sys_type.rb +3 -3
  39. data/lib/measures/generic_qaqc/resources/check_schedules.rb +65 -101
  40. data/lib/measures/generic_qaqc/resources/check_simultaneous_heating_and_cooling.rb +3 -1
  41. data/lib/measures/generic_qaqc/resources/check_supply_air_and_thermostat_temp_difference.rb +3 -1
  42. data/lib/measures/generic_qaqc/resources/os_lib_reporting_qaqc.rb +49 -15
  43. data/lib/measures/generic_qaqc/resources/report.html.erb +5 -1
  44. data/lib/measures/hvac_psychrometric_chart/measure.xml +3 -3
  45. data/lib/measures/hvac_psychrometric_chart/resources/report.html.erb +5 -1
  46. data/lib/measures/openstudio_results/measure.xml +3 -3
  47. data/lib/measures/openstudio_results/resources/report.html.erb +5 -1
  48. data/lib/measures/set_run_period/measure.xml +2 -2
  49. data/lib/measures/view_data/measure.xml +4 -4
  50. data/lib/measures/view_data/resources/report.html.in +189 -19
  51. data/lib/measures/view_data/resources/va3c.rb +1 -0
  52. data/lib/measures/view_model/measure.xml +9 -9
  53. data/lib/measures/view_model/resources/report.html.in +189 -19
  54. data/lib/measures/view_model/resources/va3c.rb +1 -0
  55. data/lib/openstudio/common_measures/version.rb +1 -1
  56. data/openstudio-common-measures.gemspec +1 -1
  57. metadata +7 -5
@@ -3,8 +3,8 @@
3
3
  <schema_version>3.0</schema_version>
4
4
  <name>add_ems_emissions_reporting</name>
5
5
  <uid>e8fe9153-5e70-4769-afa0-6da0045aa529</uid>
6
- <version_id>0395788b-e770-4887-bec9-149c0b88bcf9</version_id>
7
- <version_modified>20211013T192425Z</version_modified>
6
+ <version_id>ebb131d4-44c3-4c0c-8b5b-1d50fe282cda</version_id>
7
+ <version_modified>20220504T174701Z</version_modified>
8
8
  <xml_checksum>976EB6EB</xml_checksum>
9
9
  <class_name>AddEMSEmissionsReporting</class_name>
10
10
  <display_name>Add EMS to Report Emissions</display_name>
@@ -15,55 +15,407 @@
15
15
  <name>future_subregion</name>
16
16
  <display_name>Future subregion</display_name>
17
17
  <description>Future subregion. Options are: AZNMc, CAMXc, ERCTc, FRCCc, MROEc, MROWc, NEWEc, NWPPc, NYSTc, RFCEc, RFCMc, RFCWc, RMPAc, SPNOc, SPSOc, SRMVc, SRMWc, SRSOc, SRTVc, and SRVCc</description>
18
- <type>String</type>
18
+ <type>Choice</type>
19
19
  <required>true</required>
20
20
  <model_dependent>false</model_dependent>
21
21
  <default_value>RMPAc</default_value>
22
+ <choices>
23
+ <choice>
24
+ <value>AZNMc</value>
25
+ <display_name>AZNMc</display_name>
26
+ </choice>
27
+ <choice>
28
+ <value>CAMXc</value>
29
+ <display_name>CAMXc</display_name>
30
+ </choice>
31
+ <choice>
32
+ <value>ERCTc</value>
33
+ <display_name>ERCTc</display_name>
34
+ </choice>
35
+ <choice>
36
+ <value>FRCCc</value>
37
+ <display_name>FRCCc</display_name>
38
+ </choice>
39
+ <choice>
40
+ <value>MROEc</value>
41
+ <display_name>MROEc</display_name>
42
+ </choice>
43
+ <choice>
44
+ <value>MROWc</value>
45
+ <display_name>MROWc</display_name>
46
+ </choice>
47
+ <choice>
48
+ <value>NEWEc</value>
49
+ <display_name>NEWEc</display_name>
50
+ </choice>
51
+ <choice>
52
+ <value>NWPPc</value>
53
+ <display_name>NWPPc</display_name>
54
+ </choice>
55
+ <choice>
56
+ <value>NYSTc</value>
57
+ <display_name>NYSTc</display_name>
58
+ </choice>
59
+ <choice>
60
+ <value>RFCEc</value>
61
+ <display_name>RFCEc</display_name>
62
+ </choice>
63
+ <choice>
64
+ <value>RFCMc</value>
65
+ <display_name>RFCMc</display_name>
66
+ </choice>
67
+ <choice>
68
+ <value>RFCWc</value>
69
+ <display_name>RFCWc</display_name>
70
+ </choice>
71
+ <choice>
72
+ <value>RMPAc</value>
73
+ <display_name>RMPAc</display_name>
74
+ </choice>
75
+ <choice>
76
+ <value>SPNOc</value>
77
+ <display_name>SPNOc</display_name>
78
+ </choice>
79
+ <choice>
80
+ <value>SPSOc</value>
81
+ <display_name>SPSOc</display_name>
82
+ </choice>
83
+ <choice>
84
+ <value>SRMVc</value>
85
+ <display_name>SRMVc</display_name>
86
+ </choice>
87
+ <choice>
88
+ <value>SRMWc</value>
89
+ <display_name>SRMWc</display_name>
90
+ </choice>
91
+ <choice>
92
+ <value>SRSOc</value>
93
+ <display_name>SRSOc</display_name>
94
+ </choice>
95
+ <choice>
96
+ <value>SRTVc</value>
97
+ <display_name>SRTVc</display_name>
98
+ </choice>
99
+ <choice>
100
+ <value>SRVCc</value>
101
+ <display_name>SRVCc</display_name>
102
+ </choice>
103
+ </choices>
22
104
  </argument>
23
105
  <argument>
24
106
  <name>hourly_historical_subregion</name>
25
107
  <display_name>Historical hourly subregion</display_name>
26
108
  <description>Historical hourly subregion. Options are: California, Carolinas, Central, Florida, Mid-Atlantic, Midwest, New England, New York, Northwest, Rocky Mountains, Southeast, Southwest, Tennessee, and Texas</description>
27
- <type>String</type>
109
+ <type>Choice</type>
28
110
  <required>true</required>
29
111
  <model_dependent>false</model_dependent>
30
112
  <default_value>Rocky Mountains</default_value>
113
+ <choices>
114
+ <choice>
115
+ <value>California</value>
116
+ <display_name>California</display_name>
117
+ </choice>
118
+ <choice>
119
+ <value>Carolinas</value>
120
+ <display_name>Carolinas</display_name>
121
+ </choice>
122
+ <choice>
123
+ <value>Central</value>
124
+ <display_name>Central</display_name>
125
+ </choice>
126
+ <choice>
127
+ <value>Florida</value>
128
+ <display_name>Florida</display_name>
129
+ </choice>
130
+ <choice>
131
+ <value>Mid-Atlantic</value>
132
+ <display_name>Mid-Atlantic</display_name>
133
+ </choice>
134
+ <choice>
135
+ <value>Midwest</value>
136
+ <display_name>Midwest</display_name>
137
+ </choice>
138
+ <choice>
139
+ <value>New England</value>
140
+ <display_name>New England</display_name>
141
+ </choice>
142
+ <choice>
143
+ <value>New York</value>
144
+ <display_name>New York</display_name>
145
+ </choice>
146
+ <choice>
147
+ <value>Northwest</value>
148
+ <display_name>Northwest</display_name>
149
+ </choice>
150
+ <choice>
151
+ <value>Rocky Mountains</value>
152
+ <display_name>Rocky Mountains</display_name>
153
+ </choice>
154
+ <choice>
155
+ <value>Southeast</value>
156
+ <display_name>Southeast</display_name>
157
+ </choice>
158
+ <choice>
159
+ <value>Southwest</value>
160
+ <display_name>Southwest</display_name>
161
+ </choice>
162
+ <choice>
163
+ <value>Tennessee</value>
164
+ <display_name>Tennessee</display_name>
165
+ </choice>
166
+ <choice>
167
+ <value>Texas</value>
168
+ <display_name>Texas</display_name>
169
+ </choice>
170
+ </choices>
31
171
  </argument>
32
172
  <argument>
33
173
  <name>annual_historical_subregion</name>
34
174
  <display_name>Historical annual subregion</display_name>
35
175
  <description>Historical annual subregion. Options are: AKGD, AKMS, AZNM, CAMX, ERCT, FRCC, HIMS, HIOA, MROE, MROW, NEWE, NWPP, NYCW, NYLI, NYUP, RFCE, RFCM, RFCW, RMPA, SPNO, SPSO, SRMV, SRMW, SRSO, SRTV, and SRVC</description>
36
- <type>String</type>
176
+ <type>Choice</type>
37
177
  <required>true</required>
38
178
  <model_dependent>false</model_dependent>
39
179
  <default_value>RMPA</default_value>
180
+ <choices>
181
+ <choice>
182
+ <value>AKGD</value>
183
+ <display_name>AKGD</display_name>
184
+ </choice>
185
+ <choice>
186
+ <value>AKMS</value>
187
+ <display_name>AKMS</display_name>
188
+ </choice>
189
+ <choice>
190
+ <value>AZNM</value>
191
+ <display_name>AZNM</display_name>
192
+ </choice>
193
+ <choice>
194
+ <value>CAMX</value>
195
+ <display_name>CAMX</display_name>
196
+ </choice>
197
+ <choice>
198
+ <value>ERCT</value>
199
+ <display_name>ERCT</display_name>
200
+ </choice>
201
+ <choice>
202
+ <value>FRCC</value>
203
+ <display_name>FRCC</display_name>
204
+ </choice>
205
+ <choice>
206
+ <value>HIMS</value>
207
+ <display_name>HIMS</display_name>
208
+ </choice>
209
+ <choice>
210
+ <value>HIOA</value>
211
+ <display_name>HIOA</display_name>
212
+ </choice>
213
+ <choice>
214
+ <value>MROE</value>
215
+ <display_name>MROE</display_name>
216
+ </choice>
217
+ <choice>
218
+ <value>MROW</value>
219
+ <display_name>MROW</display_name>
220
+ </choice>
221
+ <choice>
222
+ <value>NEWE</value>
223
+ <display_name>NEWE</display_name>
224
+ </choice>
225
+ <choice>
226
+ <value>NWPP</value>
227
+ <display_name>NWPP</display_name>
228
+ </choice>
229
+ <choice>
230
+ <value>NYCW</value>
231
+ <display_name>NYCW</display_name>
232
+ </choice>
233
+ <choice>
234
+ <value>NYLI</value>
235
+ <display_name>NYLI</display_name>
236
+ </choice>
237
+ <choice>
238
+ <value>NYUP</value>
239
+ <display_name>NYUP</display_name>
240
+ </choice>
241
+ <choice>
242
+ <value>RFCE</value>
243
+ <display_name>RFCE</display_name>
244
+ </choice>
245
+ <choice>
246
+ <value>RFCM</value>
247
+ <display_name>RFCM</display_name>
248
+ </choice>
249
+ <choice>
250
+ <value>RFCW</value>
251
+ <display_name>RFCW</display_name>
252
+ </choice>
253
+ <choice>
254
+ <value>RMPA</value>
255
+ <display_name>RMPA</display_name>
256
+ </choice>
257
+ <choice>
258
+ <value>SPNO</value>
259
+ <display_name>SPNO</display_name>
260
+ </choice>
261
+ <choice>
262
+ <value>SPSO</value>
263
+ <display_name>SPSO</display_name>
264
+ </choice>
265
+ <choice>
266
+ <value>SRMV</value>
267
+ <display_name>SRMV</display_name>
268
+ </choice>
269
+ <choice>
270
+ <value>SRMW</value>
271
+ <display_name>SRMW</display_name>
272
+ </choice>
273
+ <choice>
274
+ <value>SRSO</value>
275
+ <display_name>SRSO</display_name>
276
+ </choice>
277
+ <choice>
278
+ <value>SRTV</value>
279
+ <display_name>SRTV</display_name>
280
+ </choice>
281
+ <choice>
282
+ <value>SRVC</value>
283
+ <display_name>SRVC</display_name>
284
+ </choice>
285
+ </choices>
40
286
  </argument>
41
287
  <argument>
42
288
  <name>future_year</name>
43
289
  <display_name>Future Year</display_name>
44
290
  <description>Future Year. Options are: 2020 to 2050 in two year increments</description>
45
- <type>Integer</type>
291
+ <type>Choice</type>
46
292
  <required>true</required>
47
293
  <model_dependent>false</model_dependent>
48
294
  <default_value>2020</default_value>
295
+ <choices>
296
+ <choice>
297
+ <value>2020</value>
298
+ <display_name>2020</display_name>
299
+ </choice>
300
+ <choice>
301
+ <value>2022</value>
302
+ <display_name>2022</display_name>
303
+ </choice>
304
+ <choice>
305
+ <value>2024</value>
306
+ <display_name>2024</display_name>
307
+ </choice>
308
+ <choice>
309
+ <value>2026</value>
310
+ <display_name>2026</display_name>
311
+ </choice>
312
+ <choice>
313
+ <value>2028</value>
314
+ <display_name>2028</display_name>
315
+ </choice>
316
+ <choice>
317
+ <value>2030</value>
318
+ <display_name>2030</display_name>
319
+ </choice>
320
+ <choice>
321
+ <value>2032</value>
322
+ <display_name>2032</display_name>
323
+ </choice>
324
+ <choice>
325
+ <value>2034</value>
326
+ <display_name>2034</display_name>
327
+ </choice>
328
+ <choice>
329
+ <value>2036</value>
330
+ <display_name>2036</display_name>
331
+ </choice>
332
+ <choice>
333
+ <value>2038</value>
334
+ <display_name>2038</display_name>
335
+ </choice>
336
+ <choice>
337
+ <value>2040</value>
338
+ <display_name>2040</display_name>
339
+ </choice>
340
+ <choice>
341
+ <value>2042</value>
342
+ <display_name>2042</display_name>
343
+ </choice>
344
+ <choice>
345
+ <value>2044</value>
346
+ <display_name>2044</display_name>
347
+ </choice>
348
+ <choice>
349
+ <value>2046</value>
350
+ <display_name>2046</display_name>
351
+ </choice>
352
+ <choice>
353
+ <value>2048</value>
354
+ <display_name>2048</display_name>
355
+ </choice>
356
+ <choice>
357
+ <value>2050</value>
358
+ <display_name>2050</display_name>
359
+ </choice>
360
+ </choices>
49
361
  </argument>
50
362
  <argument>
51
363
  <name>hourly_historical_year</name>
52
364
  <display_name>Hourly Historical Year</display_name>
53
365
  <description>Hourly Historical Year. Options are: 2019.</description>
54
- <type>Integer</type>
366
+ <type>Choice</type>
55
367
  <required>true</required>
56
368
  <model_dependent>false</model_dependent>
57
369
  <default_value>2019</default_value>
370
+ <choices>
371
+ <choice>
372
+ <value>2019</value>
373
+ <display_name>2019</display_name>
374
+ </choice>
375
+ </choices>
58
376
  </argument>
59
377
  <argument>
60
378
  <name>annual_historical_year</name>
61
379
  <display_name>Annual Historical Year</display_name>
62
380
  <description>Annual Historical Year. Options are: 2007, 2009, 2010, 2012, 2014, 2016, 2018, and 2019.</description>
63
- <type>Integer</type>
381
+ <type>Choice</type>
64
382
  <required>true</required>
65
383
  <model_dependent>false</model_dependent>
66
384
  <default_value>2019</default_value>
385
+ <choices>
386
+ <choice>
387
+ <value>2007</value>
388
+ <display_name>2007</display_name>
389
+ </choice>
390
+ <choice>
391
+ <value>2009</value>
392
+ <display_name>2009</display_name>
393
+ </choice>
394
+ <choice>
395
+ <value>2010</value>
396
+ <display_name>2010</display_name>
397
+ </choice>
398
+ <choice>
399
+ <value>2012</value>
400
+ <display_name>2012</display_name>
401
+ </choice>
402
+ <choice>
403
+ <value>2014</value>
404
+ <display_name>2014</display_name>
405
+ </choice>
406
+ <choice>
407
+ <value>2016</value>
408
+ <display_name>2016</display_name>
409
+ </choice>
410
+ <choice>
411
+ <value>2018</value>
412
+ <display_name>2018</display_name>
413
+ </choice>
414
+ <choice>
415
+ <value>2019</value>
416
+ <display_name>2019</display_name>
417
+ </choice>
418
+ </choices>
67
419
  </argument>
68
420
  </arguments>
69
421
  <outputs />
@@ -230,7 +582,7 @@
230
582
  <filename>add_ems_emissions_reporting_test.rb</filename>
231
583
  <filetype>rb</filetype>
232
584
  <usage_type>test</usage_type>
233
- <checksum>2124C39D</checksum>
585
+ <checksum>E9CE2D1A</checksum>
234
586
  </file>
235
587
  <file>
236
588
  <version>
@@ -241,7 +593,7 @@
241
593
  <filename>measure.rb</filename>
242
594
  <filetype>rb</filetype>
243
595
  <usage_type>script</usage_type>
244
- <checksum>097E1A3B</checksum>
596
+ <checksum>AD699109</checksum>
245
597
  </file>
246
598
  </files>
247
599
  </measure>
@@ -98,10 +98,16 @@ class AddEVLoad < OpenStudio::Measure::ModelMeasure
98
98
  # Make an argument for the % of vehicles parked at the building that are EVs.
99
99
  ev_percent = OpenStudio::Measure::OSArgument.makeDoubleArgument('ev_percent', true)
100
100
  ev_percent.setDisplayName('Percent of Vehicles Parked at Building That Are EVs')
101
- ev_percent.setDefaultValue(1.0)
101
+ ev_percent.setDefaultValue(100)
102
102
  ev_percent.setDescription('Denotes percentage of vehicles between 0 to 100 that are electric on site.')
103
103
  args << ev_percent
104
104
 
105
+ # Make an argument for using occupancy from OpenStudio Model.
106
+ ev_use_model_occupancy = OpenStudio::Measure::OSArgument.makeBoolArgument('ev_use_model_occupancy', true)
107
+ ev_use_model_occupancy.setDisplayName('Use occupancy from OpenStudio Model to determine number of electric vehicles')
108
+ ev_use_model_occupancy.setDefaultValue(true)
109
+ args << ev_use_model_occupancy
110
+
105
111
  return args
106
112
  end
107
113
 
@@ -114,6 +120,7 @@ class AddEVLoad < OpenStudio::Measure::ModelMeasure
114
120
  charge_behavior = runner.getStringArgumentValue('charge_behavior', user_arguments)
115
121
  chg_station_type = runner.getStringArgumentValue('chg_station_type', user_arguments)
116
122
  ev_percent = runner.getDoubleArgumentValue('ev_percent', user_arguments)
123
+ ev_use_model_occupancy = runner.getBoolArgumentValue('ev_use_model_occupancy', user_arguments)
117
124
 
118
125
  # use the built-in error checking
119
126
  if !runner.validateUserArguments(arguments(model), user_arguments)
@@ -155,13 +162,24 @@ class AddEVLoad < OpenStudio::Measure::ModelMeasure
155
162
  # Sets key based on charging station type, for general charging load profiles. Will use this to average columns appropriately.
156
163
  if chg_station_type == 'Typical Home'
157
164
  chg_station_key = 1
165
+ runner.registerInfo("charge station type = #{chg_station_type}")
158
166
  runner.registerInfo("charge station key = #{chg_station_key}")
167
+ # Assumed occupancy density is the typical occupancy density for charging station type determined by using a weighted
168
+ # average of building type and associated occupancy density
169
+ assumed_occupancy_density = 0.003
170
+ runner.registerInfo("assumed occupancy = #{assumed_occupancy_density}")
159
171
  elsif chg_station_type == 'Typical Work'
160
172
  chg_station_key = 2
173
+ runner.registerInfo("charge station type = #{chg_station_type}")
161
174
  runner.registerInfo("charge station key = #{chg_station_key}")
175
+ assumed_occupancy_density = 0.005
176
+ runner.registerInfo("assumed occupancy = #{assumed_occupancy_density}")
162
177
  elsif chg_station_type == 'Typical Public'
163
178
  chg_station_key = 3
179
+ runner.registerInfo("charge station type = #{chg_station_type}")
164
180
  runner.registerInfo("charge station key = #{chg_station_key}")
181
+ assumed_occupancy_density = 0.0226
182
+ runner.registerInfo("assumed occupancy = #{assumed_occupancy_density}")
165
183
  end
166
184
 
167
185
  # Creating a schedule:ruleset
@@ -210,13 +228,26 @@ class AddEVLoad < OpenStudio::Measure::ModelMeasure
210
228
  indices = public_indices
211
229
  end
212
230
 
213
- # Popualte the average weekday load for non PSN case. The load profiles used in this case are averaged based on the selected charging station type,(given the selected charging flexibility option and charging behavior option), and scaled for the percent of vehicles that are EVs.
231
+ space_type = model.getSpaceTypes[0]
232
+ model_occupancy = space_type.people.size
233
+ floor_area = space_type.floorArea
234
+ model_occupancy_density = space_type.getPeoplePerFloorArea(floor_area)
235
+ model_occupancy_density = model_occupancy_density/10.76 # Convert to people per ft2
236
+
237
+ # Populate the average weekday load for non PSN case. The load profiles used in this case are averaged based on the selected charging station type,(given the selected charging flexibility option and charging behavior option), and scaled for the percent of vehicles that are EVs.
214
238
  if chg_station_type != 'Pena Station Next Analysis' && chg_station_type != 'Pena Station Next Analysis--DC Fast Charger'
215
239
  wkday_load_sel = wkday_load.values_at(*indices)
216
240
  avg_load_wkday = []
217
241
  wkday_load_sel = wkday_load_sel.transpose
218
- for i in 0..wkday_load[0].length - 1
219
- avg_load_wkday[i] = (wkday_load_sel[i].reduce(0, :+) / wkday_load_sel[i].length) * ev_percent / assumed_percent # Scale profiles generated from 50% EV scenario by % of vehicles that are EVs.
242
+ if ev_use_model_occupancy
243
+ runner.registerInfo("model occupancy density = #{model_occupancy_density}")
244
+ for i in 0..wkday_load[0].length - 1
245
+ avg_load_wkday[i] = ((wkday_load_sel[i].reduce(0, :+) / wkday_load_sel[i].length) * ev_percent/assumed_percent) * (model_occupancy_density/assumed_occupancy_density) # Scale profiles generated from 50% EV scenario by occupancy of OpenStudio model (number of vehicles is assumed to be the same as occupancy of the building).
246
+ end
247
+ else
248
+ for i in 0..wkday_load[0].length - 1
249
+ avg_load_wkday[i] = (wkday_load_sel[i].reduce(0, :+) / wkday_load_sel[i].length) * ev_percent / assumed_percent # Scale profiles generated from 50% EV scenario by % of vehicles that are EVs.
250
+ end
220
251
  end
221
252
 
222
253
  wkday_max_load = avg_load_wkday.max
@@ -225,8 +256,14 @@ class AddEVLoad < OpenStudio::Measure::ModelMeasure
225
256
  sat_load_sel = sat_load.values_at(*indices)
226
257
  avg_load_sat = []
227
258
  sat_load_sel = sat_load_sel.transpose
228
- for i in 0..sat_load[0].length - 1
229
- avg_load_sat[i] = (sat_load_sel[i].reduce(0, :+) / sat_load_sel[i].length) * ev_percent / assumed_percent # Scale profiles generated from 50% EV scenario by % of vehicles that are EVs.
259
+ if ev_use_model_occupancy
260
+ for i in 0..sat_load[0].length - 1
261
+ avg_load_sat[i] = ((sat_load_sel[i].reduce(0, :+) / sat_load_sel[i].length) * ev_percent / assumed_percent) * (model_occupancy_density/assumed_occupancy_density) # Scale profiles generated from 50% EV scenario by occupancy of OpenStudio model and apply ev_percent (number of vehicles is assumed to be the same as occupancy of the building).
262
+ end
263
+ else
264
+ for i in 0..sat_load[0].length - 1
265
+ avg_load_sat[i] = (sat_load_sel[i].reduce(0, :+) / sat_load_sel[i].length) * ev_percent / assumed_percent # Scale profiles generated from 50% EV scenario by % of vehicles that are EVs.
266
+ end
230
267
  end
231
268
 
232
269
  sat_max_load = avg_load_sat.max
@@ -235,8 +272,14 @@ class AddEVLoad < OpenStudio::Measure::ModelMeasure
235
272
  sun_load_sel = sun_load.values_at(*indices)
236
273
  avg_load_sun = []
237
274
  sun_load_sel = sun_load_sel.transpose
238
- for i in 0..sun_load[0].length - 1
239
- avg_load_sun[i] = (sun_load_sel[i].reduce(0, :+) / sun_load_sel[i].length) * ev_percent / assumed_percent # Scale profiles generated from 50% EV scenario by % of vehicles that are EVs.
275
+ if ev_use_model_occupancy
276
+ for i in 0..sun_load[0].length - 1
277
+ avg_load_sun[i] = ((sun_load_sel[i].reduce(0, :+) / sun_load_sel[i].length) * ev_percent / assumed_percent) * (model_occupancy_density/assumed_occupancy_density) # Scale profiles generated from 50% EV scenario by occupancy of OpenStudio model and apply ev_percent (number of vehicles is assumed to be the same as occupancy of the building).
278
+ end
279
+ else
280
+ for i in 0..sun_load[0].length - 1
281
+ avg_load_sun[i] = (sun_load_sel[i].reduce(0, :+) / sun_load_sel[i].length) * ev_percent / assumed_percent # Scale profiles generated from 50% EV scenario by % of vehicles that are EVs.
282
+ end
240
283
  end
241
284
 
242
285
  sun_max_load = avg_load_sun.max
@@ -3,8 +3,8 @@
3
3
  <schema_version>3.0</schema_version>
4
4
  <name>add_ev_load</name>
5
5
  <uid>a23e0493-7357-48ca-b089-4d902efd6b50</uid>
6
- <version_id>90476d7d-d880-4ce4-ada0-5dad10a82954</version_id>
7
- <version_modified>20210406T224047Z</version_modified>
6
+ <version_id>5ef19868-80da-424d-9907-00e8bbd9919a</version_id>
7
+ <version_modified>20220505T194724Z</version_modified>
8
8
  <xml_checksum>9A202986</xml_checksum>
9
9
  <class_name>AddEVLoad</class_name>
10
10
  <display_name>Add_EV_Load</display_name>
@@ -86,7 +86,25 @@
86
86
  <type>Double</type>
87
87
  <required>true</required>
88
88
  <model_dependent>false</model_dependent>
89
- <default_value>1</default_value>
89
+ <default_value>100</default_value>
90
+ </argument>
91
+ <argument>
92
+ <name>ev_use_model_occupancy</name>
93
+ <display_name>Use occupancy from OpenStudio Model to determine number of electric vehicles</display_name>
94
+ <type>Boolean</type>
95
+ <required>true</required>
96
+ <model_dependent>false</model_dependent>
97
+ <default_value>true</default_value>
98
+ <choices>
99
+ <choice>
100
+ <value>true</value>
101
+ <display_name>true</display_name>
102
+ </choice>
103
+ <choice>
104
+ <value>false</value>
105
+ <display_name>false</display_name>
106
+ </choice>
107
+ </choices>
90
108
  </argument>
91
109
  </arguments>
92
110
  <outputs />
@@ -331,7 +349,7 @@
331
349
  <filename>add_ev_load_test.rb</filename>
332
350
  <filetype>rb</filetype>
333
351
  <usage_type>test</usage_type>
334
- <checksum>5E255354</checksum>
352
+ <checksum>54550A66</checksum>
335
353
  </file>
336
354
  <file>
337
355
  <version>
@@ -342,7 +360,7 @@
342
360
  <filename>measure.rb</filename>
343
361
  <filetype>rb</filetype>
344
362
  <usage_type>script</usage_type>
345
- <checksum>93A1C055</checksum>
363
+ <checksum>0F479CB4</checksum>
346
364
  </file>
347
365
  </files>
348
366
  </measure>
@@ -3,8 +3,8 @@
3
3
  <schema_version>3.0</schema_version>
4
4
  <name>envelope_and_internal_load_breakdown</name>
5
5
  <uid>8f0e1fbb-8bc6-46e5-b6e4-db59177e2c02</uid>
6
- <version_id>682db2ce-3ce6-4536-92ed-d38b7f310919</version_id>
7
- <version_modified>20210423T144509Z</version_modified>
6
+ <version_id>a80bd71f-7c89-4bad-95e2-8f7d02976ab1</version_id>
7
+ <version_modified>20220506T153447Z</version_modified>
8
8
  <xml_checksum>69BA4D91</xml_checksum>
9
9
  <class_name>EnvelopeAndInternalLoadBreakdown</class_name>
10
10
  <display_name>Envelope and Internal Load Breakdown</display_name>
@@ -139,7 +139,7 @@
139
139
  <filename>report.html.erb</filename>
140
140
  <filetype>erb</filetype>
141
141
  <usage_type>resource</usage_type>
142
- <checksum>177CA671</checksum>
142
+ <checksum>B6B35B79</checksum>
143
143
  </file>
144
144
  </files>
145
145
  </measure>
@@ -1,6 +1,6 @@
1
1
  <%
2
2
  # *******************************************************************************
3
- # OpenStudio(R), Copyright (c) 2008-2021, Alliance for Sustainable Energy, LLC.
3
+ # OpenStudio(R), Copyright (c) 2008-2022, Alliance for Sustainable Energy, LLC.
4
4
  # All rights reserved.
5
5
  # Redistribution and use in source and binary forms, with or without
6
6
  # modification, are permitted provided that the following conditions are met:
@@ -41,6 +41,10 @@
41
41
 
42
42
 
43
43
 
44
+
45
+
46
+
47
+
44
48
  <!DOCTYPE html>
45
49
  <html lang="en">
46
50
  <head>
@@ -3,8 +3,8 @@
3
3
  <schema_version>3.0</schema_version>
4
4
  <name>example_report</name>
5
5
  <uid>174a6f71-3e8c-4f99-9e7a-b64f2e7535d4</uid>
6
- <version_id>1d1f4225-bfba-4673-b81d-0ed9e7e769c5</version_id>
7
- <version_modified>20210423T144518Z</version_modified>
6
+ <version_id>a259adf9-ad89-41ba-9463-b57132e6232f</version_id>
7
+ <version_modified>20220506T153442Z</version_modified>
8
8
  <xml_checksum>557BF06F</xml_checksum>
9
9
  <class_name>ExampleReport</class_name>
10
10
  <display_name>Example Report</display_name>
@@ -167,7 +167,7 @@
167
167
  <filename>report.html.erb</filename>
168
168
  <filetype>erb</filetype>
169
169
  <usage_type>resource</usage_type>
170
- <checksum>612E9631</checksum>
170
+ <checksum>6F54D1FE</checksum>
171
171
  </file>
172
172
  </files>
173
173
  </measure>