Skip to content

Commit

Permalink
update measures
Browse files Browse the repository at this point in the history
  • Loading branch information
yzhou601 committed Apr 8, 2024
1 parent 19b35c8 commit 4c00d44
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
2 changes: 2 additions & 0 deletions rulesets/resources/301ruleset.rb
Original file line number Diff line number Diff line change
Expand Up @@ -831,6 +831,7 @@ def self.set_enclosure_ceilings_iad(orig_bldg, new_bldg)
sum_ceiling_area = 0.0
new_bldg.floors.each do |new_floor|
next unless new_floor.is_ceiling

if Constants.ERIVersions.index(@eri_version) >= Constants.ERIVersions.index('2022')
# Only include ceilings above Conditioned Space Volume and below an Attic, Unconditioned Space Volume, Unrated Heated Space, Multifamily Buffer Boundary, Non-Freezing Space, or outdoor environment
next unless new_floor.is_thermal_boundary
Expand All @@ -840,6 +841,7 @@ def self.set_enclosure_ceilings_iad(orig_bldg, new_bldg)
end
new_bldg.floors.each do |new_floor|
next unless new_floor.is_ceiling

if Constants.ERIVersions.index(@eri_version) >= Constants.ERIVersions.index('2022')
new_floor.area = new_floor.is_thermal_boundary ? 1200.0 * new_floor.area / sum_ceiling_area : 0.01
else
Expand Down
10 changes: 5 additions & 5 deletions rulesets/tests/test_enclosure.rb
Original file line number Diff line number Diff line change
Expand Up @@ -537,17 +537,17 @@ def test_enclosure_ceilings
# Check ANSI-301-2022 with themal boundary ceilings
hpxml = HPXML.new(hpxml_path: File.join(@root_path, 'workflow', 'sample_files', hpxml_name))
hpxml_bldg = hpxml.buildings[0]
orig_ceiling = hpxml_bldg.floors.find{|floor| floor.is_ceiling}
orig_ceiling = hpxml_bldg.floors.find { |floor| floor.is_ceiling }
orig_ceiling.area /= 3
hpxml_bldg.floors << orig_ceiling.dup
hpxml_bldg.floors[-1].exterior_adjacent_to = HPXML::LocationOtherMultifamilyBufferSpace
hpxml_bldg.floors[-1].id = "Floor#{hpxml_bldg.floors.size.to_s}"
hpxml_bldg.floors[-1].insulation_id = "Floor#{hpxml_bldg.floors.size.to_s}Insulation"
hpxml_bldg.floors[-1].id = "Floor#{hpxml_bldg.floors.size}"
hpxml_bldg.floors[-1].insulation_id = "Floor#{hpxml_bldg.floors.size}Insulation"
hpxml_bldg.floors[-1].insulation_assembly_r_value = 3.0
hpxml_bldg.floors << orig_ceiling.dup
hpxml_bldg.floors[-1].exterior_adjacent_to = HPXML::LocationOtherNonFreezingSpace
hpxml_bldg.floors[-1].id = "Floor#{hpxml_bldg.floors.size.to_s}"
hpxml_bldg.floors[-1].insulation_id = "Floor#{hpxml_bldg.floors.size.to_s}Insulation"
hpxml_bldg.floors[-1].id = "Floor#{hpxml_bldg.floors.size}"
hpxml_bldg.floors[-1].insulation_id = "Floor#{hpxml_bldg.floors.size}Insulation"
hpxml_bldg.floors[-1].insulation_assembly_r_value = 4.0
hpxml_name = File.basename(@tmp_hpxml_path)
XMLHelper.write_file(hpxml.to_doc, @tmp_hpxml_path)
Expand Down

0 comments on commit 4c00d44

Please sign in to comment.