Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BuildResidentialHPXML measure: Shared recirculation #1310

Open
wants to merge 23 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 14 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
67b2852
Add new hw dist recirc num units served argument.
joseph-robertson Mar 8, 2023
b22d98d
Build the shared recirc sample file with BuildResHPXML.
joseph-robertson Mar 8, 2023
d94d473
Update build measure test.
joseph-robertson Mar 8, 2023
acfbe0c
Make the new argument optional since a recirc is optional.
joseph-robertson Mar 8, 2023
eb5869c
Update the changelog.
joseph-robertson Mar 8, 2023
16786ea
Argument description updates.
joseph-robertson Mar 9, 2023
63ad3e3
Merge branch 'master' into shared-recirc
joseph-robertson Mar 14, 2023
a9f6d99
Merge branch 'master' into shared-recirc
joseph-robertson Mar 21, 2023
973826e
Merge branch 'master' into shared-recirc
joseph-robertson Apr 25, 2023
a63b2af
Merge branch 'master' into shared-recirc
joseph-robertson May 22, 2023
cc8711e
Fix measure xml merge conflict.
joseph-robertson May 22, 2023
d58b5e9
Merge branch 'master' into shared-recirc
joseph-robertson Jun 23, 2023
8bf088a
Merge branch 'master' into shared-recirc
joseph-robertson Jun 28, 2023
d232795
Merge branch 'master' into shared-recirc
joseph-robertson Aug 14, 2023
4a99ddc
Merge branch 'master' into shared-recirc
joseph-robertson May 28, 2024
1a00313
Update the changelog. [ci skip]
joseph-robertson May 28, 2024
6d3ee17
Fix build test.
joseph-robertson May 28, 2024
623e4d5
Merge branch 'master' into shared-recirc
joseph-robertson May 29, 2024
625a9c1
Merge branch 'master' into shared-recirc
joseph-robertson Jun 4, 2024
1715d40
Merge branch 'master' into shared-recirc
joseph-robertson Jun 7, 2024
aba84db
Update measure descriptions, etc.
joseph-robertson Jun 7, 2024
8101b4d
Merge branch 'master' into shared-recirc
joseph-robertson Jun 25, 2024
4d44413
Merge branch 'master' into shared-recirc
joseph-robertson Jul 8, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
58 changes: 43 additions & 15 deletions BuildResidentialHPXML/measure.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1970,6 +1970,12 @@ def arguments(model) # rubocop:disable Lint/UnusedMethodArgument
arg.setDescription("If the distribution system is #{HPXML::DHWDistTypeRecirc}, the recirculation pump power. If not provided, the OS-HPXML default is used.")
args << arg

arg = OpenStudio::Measure::OSArgument::makeIntegerArgument('hot_water_distribution_recirc_num_units_served', false)
joseph-robertson marked this conversation as resolved.
Show resolved Hide resolved
arg.setDisplayName('Hot Water Distribution: Recirculation Number of Units Served')
arg.setDescription("If the distribution system is #{HPXML::DHWDistTypeRecirc}, number of dwelling units served by the recirculation system. Can only be 1 if #{HPXML::ResidentialTypeSFD}. Used to apportion recirculation pump power to the unit.")
arg.setUnits('#')
args << arg

arg = OpenStudio::Measure::OSArgument::makeDoubleArgument('hot_water_distribution_pipe_r', false)
arg.setDisplayName('Hot Water Distribution: Pipe Insulation Nominal R-Value')
arg.setUnits('h-ft^2-R/Btu')
Expand Down Expand Up @@ -5606,25 +5612,43 @@ def self.set_hot_water_distribution(hpxml, args)
end
end

if args[:hot_water_distribution_system_type] == HPXML::DHWDistTypeStandard
system_type = args[:hot_water_distribution_system_type]
if system_type == HPXML::DHWDistTypeStandard || ((system_type == HPXML::DHWDistTypeRecirc) && args[:hot_water_distribution_recirc_num_units_served].is_initialized && (args[:hot_water_distribution_recirc_num_units_served].get > 1))
if args[:hot_water_distribution_standard_piping_length].is_initialized
standard_piping_length = args[:hot_water_distribution_standard_piping_length].get
end
else
if args[:hot_water_distribution_recirc_control_type].is_initialized
recirculation_control_type = args[:hot_water_distribution_recirc_control_type].get
end
end

if args[:hot_water_distribution_recirc_piping_length].is_initialized
recirculation_piping_length = args[:hot_water_distribution_recirc_piping_length].get
end
if system_type == HPXML::DHWDistTypeRecirc
if args[:hot_water_distribution_recirc_num_units_served].is_initialized && args[:hot_water_distribution_recirc_num_units_served].get > 1
system_type = HPXML::DHWDistTypeStandard

if args[:hot_water_distribution_recirc_branch_piping_length].is_initialized
recirculation_branch_piping_length = args[:hot_water_distribution_recirc_branch_piping_length].get
end
has_shared_recirculation = true
shared_recirculation_number_of_units_served = args[:hot_water_distribution_recirc_num_units_served].get

if args[:hot_water_distribution_recirc_control_type].is_initialized
shared_recirculation_control_type = args[:hot_water_distribution_recirc_control_type].get
end

if args[:hot_water_distribution_recirc_pump_power].is_initialized
recirculation_pump_power = args[:hot_water_distribution_recirc_pump_power].get
if args[:hot_water_distribution_recirc_pump_power].is_initialized
shared_recirculation_pump_power = args[:hot_water_distribution_recirc_pump_power].get
end
else
if args[:hot_water_distribution_recirc_control_type].is_initialized
recirculation_control_type = args[:hot_water_distribution_recirc_control_type].get
end

if args[:hot_water_distribution_recirc_piping_length].is_initialized
recirculation_piping_length = args[:hot_water_distribution_recirc_piping_length].get
end

if args[:hot_water_distribution_recirc_branch_piping_length].is_initialized
recirculation_branch_piping_length = args[:hot_water_distribution_recirc_branch_piping_length].get
end

if args[:hot_water_distribution_recirc_pump_power].is_initialized
recirculation_pump_power = args[:hot_water_distribution_recirc_pump_power].get
end
end
end

Expand All @@ -5633,7 +5657,7 @@ def self.set_hot_water_distribution(hpxml, args)
end

hpxml.hot_water_distributions.add(id: "HotWaterDistribution#{hpxml.hot_water_distributions.size + 1}",
system_type: args[:hot_water_distribution_system_type],
system_type: system_type,
standard_piping_length: standard_piping_length,
recirculation_control_type: recirculation_control_type,
recirculation_piping_length: recirculation_piping_length,
Expand All @@ -5642,7 +5666,11 @@ def self.set_hot_water_distribution(hpxml, args)
pipe_r_value: pipe_r_value,
dwhr_facilities_connected: dwhr_facilities_connected,
dwhr_equal_flow: dwhr_equal_flow,
dwhr_efficiency: dwhr_efficiency)
dwhr_efficiency: dwhr_efficiency,
has_shared_recirculation: has_shared_recirculation,
shared_recirculation_number_of_units_served: shared_recirculation_number_of_units_served,
shared_recirculation_pump_power: shared_recirculation_pump_power,
shared_recirculation_control_type: shared_recirculation_control_type)
end

def self.set_water_fixtures(hpxml, args)
Expand Down
17 changes: 13 additions & 4 deletions BuildResidentialHPXML/measure.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
<schema_version>3.1</schema_version>
<name>build_residential_hpxml</name>
<uid>a13a8983-2b01-4930-8af2-42030b6e4233</uid>
<version_id>a5a42263-d8b3-45cc-a81f-0348eaabd6ba</version_id>
<version_modified>2023-07-31T19:28:38Z</version_modified>
<version_id>004851f3-a48f-4418-81e6-fe3a430c851a</version_id>
<version_modified>2023-08-14T16:40:59Z</version_modified>
<xml_checksum>2C38F48B</xml_checksum>
<class_name>BuildResidentialHPXML</class_name>
<display_name>HPXML Builder</display_name>
Expand Down Expand Up @@ -4098,6 +4098,15 @@
<required>false</required>
<model_dependent>false</model_dependent>
</argument>
<argument>
<name>hot_water_distribution_recirc_num_units_served</name>
<display_name>Hot Water Distribution: Recirculation Number of Units Served</display_name>
<description>If the distribution system is Recirculation, number of dwelling units served by the recirculation system. Can only be 1 if single-family detached. Used to apportion recirculation pump power to the unit.</description>
<type>Integer</type>
<units>#</units>
<required>false</required>
<model_dependent>false</model_dependent>
</argument>
<argument>
<name>hot_water_distribution_pipe_r</name>
<display_name>Hot Water Distribution: Pipe Insulation Nominal R-Value</display_name>
Expand Down Expand Up @@ -6709,7 +6718,7 @@
<filename>measure.rb</filename>
<filetype>rb</filetype>
<usage_type>script</usage_type>
<checksum>85ADFF0F</checksum>
<checksum>B71BE789</checksum>
</file>
<file>
<filename>geometry.rb</filename>
Expand All @@ -6721,7 +6730,7 @@
<filename>build_residential_hpxml_test.rb</filename>
<filetype>rb</filetype>
<usage_type>test</usage_type>
<checksum>E0489256</checksum>
<checksum>0CDFE6A1</checksum>
</file>
</files>
</measure>
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,7 @@ def _set_measure_argument_values(hpxml_file, args)
args['hot_water_distribution_recirc_piping_length'] = 50
args['hot_water_distribution_recirc_branch_piping_length'] = 50
args['hot_water_distribution_recirc_pump_power'] = 50
args['hot_water_distribution_recirc_num_units_served'] = 1
args['hot_water_distribution_pipe_r'] = 0.0
args['dwhr_facilities_connected'] = 'none'
args['dwhr_equal_flow'] = true
Expand Down
2 changes: 2 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,8 @@ __New Features__
- Stochastic schedules for garage lighting and TV plug loads now use interior lighting and miscellaneous plug load schedules, respectively.
- Performance improvement for HPXML files w/ large numbers of `Building` elements.
- Weather cache files (\*foo-cache.csv) are no longer used/needed.
- BuildResidentialHPXML measure:
- Adds optional argument for the number of dwelling units served by the recirculation system.

__Bugfixes__
- Fixes `BackupHeatingSwitchoverTemperature` for a heat pump w/ *separate* backup system; now correctly ceases backup operation above this temperature.
Expand Down
5 changes: 0 additions & 5 deletions tasks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -1685,11 +1685,6 @@ def apply_hpxml_modification(hpxml_file, hpxml)
hpxml.water_heating.water_fixtures_weekday_fractions = '0.012, 0.006, 0.004, 0.005, 0.010, 0.034, 0.078, 0.087, 0.080, 0.067, 0.056, 0.047, 0.040, 0.035, 0.033, 0.031, 0.039, 0.051, 0.060, 0.060, 0.055, 0.048, 0.038, 0.026'
hpxml.water_heating.water_fixtures_weekend_fractions = '0.012, 0.006, 0.004, 0.005, 0.010, 0.034, 0.078, 0.087, 0.080, 0.067, 0.056, 0.047, 0.040, 0.035, 0.033, 0.031, 0.039, 0.051, 0.060, 0.060, 0.055, 0.048, 0.038, 0.026'
hpxml.water_heating.water_fixtures_monthly_multipliers = '1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0, 1.0'
elsif ['base-bldgtype-multifamily-shared-water-heater-recirc.xml'].include? hpxml_file
hpxml.hot_water_distributions[0].has_shared_recirculation = true
hpxml.hot_water_distributions[0].shared_recirculation_number_of_units_served = 6
hpxml.hot_water_distributions[0].shared_recirculation_pump_power = 220
hpxml.hot_water_distributions[0].shared_recirculation_control_type = HPXML::DHWRecirControlTypeTimer
elsif ['base-bldgtype-multifamily-shared-laundry-room.xml',
'base-bldgtype-multifamily-shared-laundry-room-multiple-water-heaters.xml'].include? hpxml_file
hpxml.water_heating_systems.reverse_each do |water_heating_system|
Expand Down
6 changes: 5 additions & 1 deletion workflow/hpxml_inputs.json
Original file line number Diff line number Diff line change
Expand Up @@ -990,7 +990,11 @@
"water_heater_num_units_served": 6
},
"sample_files/base-bldgtype-multifamily-shared-water-heater-recirc.xml": {
"parent_hpxml": "sample_files/base-bldgtype-multifamily-shared-water-heater.xml"
"parent_hpxml": "sample_files/base-bldgtype-multifamily-shared-water-heater.xml",
"hot_water_distribution_system_type": "Recirculation",
"hot_water_distribution_recirc_control_type": "timer",
"hot_water_distribution_recirc_pump_power": 220.0,
"hot_water_distribution_recirc_num_units_served": 6
},
"sample_files/base-dhw-combi-tankless.xml": {
"parent_hpxml": "sample_files/base-dhw-indirect.xml",
Expand Down