@@ -943,8 +943,8 @@ def argument_errors(args)
943943 error = ![ HPXML ::FoundationTypeSlab , HPXML ::FoundationTypeAboveApartment ] . include? ( args [ :geometry_foundation_type_type ] ) && ( args [ :geometry_foundation_type_height ] == 0 )
944944 errors << "Foundation type of '#{ args [ :geometry_foundation_type_type ] } ' cannot have a height of zero." if error
945945
946- error = ( args [ :geometry_unit_type_facility_type ] == HPXML ::ResidentialTypeApartment ) && ( [ HPXML :: FoundationTypeBasementConditioned , HPXML ::FoundationTypeCrawlspaceConditioned ] . include? args [ :geometry_foundation_type_type ] )
947- errors << 'Conditioned basement/crawlspace foundation type for apartment units is not currently supported.' if error
946+ error = ( args [ :geometry_unit_type_facility_type ] == HPXML ::ResidentialTypeApartment ) && ( args [ :geometry_foundation_type_type ] == HPXML ::FoundationTypeBasementConditioned )
947+ errors << 'Conditioned basement foundation type for apartment units is not currently supported.' if error
948948
949949 error = ( args [ :hvac_heating_system ] == 'None' ) && ( args [ :hvac_heat_pump ] == 'None' ) && ( args [ :hvac_heating_system_2 ] != 'None' )
950950 errors << 'A second heating system was specified without a primary heating system.' if error
@@ -1716,8 +1716,7 @@ def set_rim_joists(hpxml_bldg, model, args, sorted_surfaces)
17161716 next unless [ HPXML ::LocationBasementConditioned ,
17171717 HPXML ::LocationBasementUnconditioned ,
17181718 HPXML ::LocationCrawlspaceUnvented ,
1719- HPXML ::LocationCrawlspaceVented ,
1720- HPXML ::LocationCrawlspaceConditioned ] . include? interior_adjacent_to
1719+ HPXML ::LocationCrawlspaceVented ] . include? interior_adjacent_to
17211720
17221721 exterior_adjacent_to = HPXML ::LocationOutside
17231722 if surface . outsideBoundaryCondition == EPlus ::BoundaryConditionAdiabatic # can be adjacent to foundation space
@@ -1893,8 +1892,7 @@ def set_foundation_walls(hpxml_bldg, model, args, sorted_surfaces)
18931892 next unless [ HPXML ::LocationBasementConditioned ,
18941893 HPXML ::LocationBasementUnconditioned ,
18951894 HPXML ::LocationCrawlspaceUnvented ,
1896- HPXML ::LocationCrawlspaceVented ,
1897- HPXML ::LocationCrawlspaceConditioned ] . include? interior_adjacent_to
1895+ HPXML ::LocationCrawlspaceVented ] . include? interior_adjacent_to
18981896
18991897 exterior_adjacent_to = HPXML ::LocationGround
19001898 if surface . outsideBoundaryCondition == EPlus ::BoundaryConditionAdiabatic # can be adjacent to foundation space
@@ -1990,8 +1988,7 @@ def set_floors(hpxml_bldg, args, sorted_surfaces)
19901988 next if interior_adjacent_to == exterior_adjacent_to
19911989 next if ( surface . surfaceType == EPlus ::SurfaceTypeRoofCeiling ) && ( exterior_adjacent_to == HPXML ::LocationOutside )
19921990 next if [ HPXML ::LocationConditionedSpace ,
1993- HPXML ::LocationBasementConditioned ,
1994- HPXML ::LocationCrawlspaceConditioned ] . include? exterior_adjacent_to
1991+ HPXML ::LocationBasementConditioned ] . include? exterior_adjacent_to
19951992
19961993 hpxml_bldg . floors . add ( id : "Floor#{ hpxml_bldg . floors . size + 1 } " ,
19971994 exterior_adjacent_to : exterior_adjacent_to ,
@@ -2064,7 +2061,6 @@ def set_slabs(hpxml_bldg, model, args, sorted_surfaces)
20642061 has_foundation_walls = false
20652062 if [ HPXML ::LocationCrawlspaceVented ,
20662063 HPXML ::LocationCrawlspaceUnvented ,
2067- HPXML ::LocationCrawlspaceConditioned ,
20682064 HPXML ::LocationBasementUnconditioned ,
20692065 HPXML ::LocationBasementConditioned ] . include? interior_adjacent_to
20702066 has_foundation_walls = true
@@ -2115,12 +2111,6 @@ def set_slabs(hpxml_bldg, model, args, sorted_surfaces)
21152111 hpxml_slab . carpet_fraction = args [ :enclosure_carpet_fraction ]
21162112 hpxml_slab . carpet_r_value = args [ :enclosure_carpet_r_value ]
21172113 end
2118-
2119- next unless interior_adjacent_to == HPXML ::LocationCrawlspaceConditioned
2120-
2121- # Increase Conditioned Building Volume
2122- conditioned_crawlspace_volume = hpxml_slab . area * args [ :geometry_foundation_type_height ]
2123- hpxml_bldg . building_construction . conditioned_building_volume += conditioned_crawlspace_volume
21242114 end
21252115 end
21262116
@@ -2325,8 +2315,7 @@ def set_foundations(hpxml_bldg, args)
23252315 foundation_locations = [ HPXML ::LocationBasementConditioned ,
23262316 HPXML ::LocationBasementUnconditioned ,
23272317 HPXML ::LocationCrawlspaceUnvented ,
2328- HPXML ::LocationCrawlspaceVented ,
2329- HPXML ::LocationCrawlspaceConditioned ]
2318+ HPXML ::LocationCrawlspaceVented ]
23302319
23312320 surf_ids . each do |surf_type , surf_hash |
23322321 surf_hash [ 'surfaces' ] . each do |surface |
@@ -2698,7 +2687,7 @@ def set_geothermal_loop(hpxml_bldg, args)
26982687 '1-1/4" pipe' => 1.25 } [ args [ :hvac_geothermal_loop_pipe_diameter ] ]
26992688
27002689 hpxml_bldg . geothermal_loops . add ( id : "GeothermalLoop#{ hpxml_bldg . geothermal_loops . size + 1 } " ,
2701- loop_configuration : args [ :hvac_geothermal_loop_configuration ] ,
2690+ loop_config : args [ :hvac_geothermal_loop_configuration ] ,
27022691 loop_flow : args [ :hvac_geothermal_loop_loop_flow ] ,
27032692 bore_config : args [ :hvac_geothermal_loop_borefield_configuration ] ,
27042693 num_bore_holes : args [ :hvac_geothermal_loop_boreholes_count ] ,
@@ -2864,24 +2853,23 @@ def set_duct_leakages(args, hvac_distribution)
28642853 #
28652854 # @param building_component [String] the building component of interest
28662855 # @param location [String] the location of interest (HPXML::LocationCrawlspace or HPXML::LocationAttic)
2867- # @param foundation_type [String] the specific HPXML foundation type (unvented crawlspace, vented crawlspace, conditioned crawlspace)
2868- # @param attic_type [String] the specific HPXML attic type (unvented attic, vented attic, conditioned attic)
2856+ # @param hpxml_bldg [HPXML::Building] HPXML Building object representing an individual dwelling unit
28692857 # @return [nil]
2870- def get_location ( building_component , location , foundation_type , attic_type )
2858+ def get_location ( building_component , location , hpxml_bldg )
28712859 return if location . nil?
28722860
28732861 if location == HPXML ::LocationCrawlspace
2862+ foundation_type = hpxml_bldg . foundations [ -1 ] . foundation_type
28742863 case foundation_type
28752864 when HPXML ::FoundationTypeCrawlspaceUnvented
28762865 return HPXML ::LocationCrawlspaceUnvented
28772866 when HPXML ::FoundationTypeCrawlspaceVented
28782867 return HPXML ::LocationCrawlspaceVented
2879- when HPXML ::FoundationTypeCrawlspaceConditioned
2880- return HPXML ::LocationCrawlspaceConditioned
28812868 else
28822869 fail "Specified '#{ location } ' for #{ building_component } location but foundation type is '#{ foundation_type } '."
28832870 end
28842871 elsif location == HPXML ::LocationAttic
2872+ attic_type = hpxml_bldg . attics [ -1 ] . attic_type
28852873 case attic_type
28862874 when HPXML ::AtticTypeUnvented
28872875 return HPXML ::LocationAtticUnvented
@@ -2893,6 +2881,7 @@ def get_location(building_component, location, foundation_type, attic_type)
28932881 fail "Specified '#{ location } ' for #{ building_component } location but attic type is '#{ attic_type } '."
28942882 end
28952883 elsif location == HPXML ::LocationBasement
2884+ foundation_type = hpxml_bldg . foundations [ -1 ] . foundation_type
28962885 case foundation_type
28972886 when HPXML ::FoundationTypeBasementConditioned
28982887 return HPXML ::LocationBasementConditioned
@@ -2912,8 +2901,8 @@ def get_location(building_component, location, foundation_type, attic_type)
29122901 # @param hvac_distribution [HPXML::HVACDistribution] HPXML HVAC Distribution object
29132902 # @return [nil]
29142903 def set_ducts ( hpxml_bldg , args , hvac_distribution )
2915- ducts_supply_location = get_location ( 'supply ducts' , args [ :hvac_ducts_supply_location_location ] , hpxml_bldg . foundations [ - 1 ] . foundation_type , hpxml_bldg . attics [ - 1 ] . attic_type )
2916- ducts_return_location = get_location ( 'return ducts' , args [ :hvac_ducts_return_location_location ] , hpxml_bldg . foundations [ - 1 ] . foundation_type , hpxml_bldg . attics [ - 1 ] . attic_type )
2904+ ducts_supply_location = get_location ( 'supply ducts' , args [ :hvac_ducts_supply_location_location ] , hpxml_bldg )
2905+ ducts_return_location = get_location ( 'return ducts' , args [ :hvac_ducts_return_location_location ] , hpxml_bldg )
29172906
29182907 ncfl = hpxml_bldg . building_construction . number_of_conditioned_floors
29192908 ncfl_ag = hpxml_bldg . building_construction . number_of_conditioned_floors_above_grade
@@ -3146,7 +3135,7 @@ def set_ventilation_fans(hpxml_bldg, args)
31463135 def set_water_heating_systems ( hpxml_bldg , args )
31473136 return if args [ :dhw_water_heater ] == 'None'
31483137
3149- location = get_location ( 'water heater' , args [ :dhw_water_heater_location_location ] , hpxml_bldg . foundations [ - 1 ] . foundation_type , hpxml_bldg . attics [ - 1 ] . attic_type )
3138+ location = get_location ( 'water heater' , args [ :dhw_water_heater_location_location ] , hpxml_bldg )
31503139
31513140 if not [ HPXML ::WaterHeaterTypeCombiStorage , HPXML ::WaterHeaterTypeCombiTankless ] . include? args [ :dhw_water_heater_type ]
31523141 case args [ :dhw_water_heater_efficiency_type ]
0 commit comments