Class: BTAP::EQuest::DOEFloor
- Inherits:
-
DOESurface
- Object
- DOECommand
- DOESurface
- BTAP::EQuest::DOEFloor
- Defined in:
- lib/openstudio-standards/btap/equest.rb
Instance Attribute Summary collapse
-
#absorptance ⇒ Object
The absorptance of the exterior surface of the floor (see rule #4.3.5.3.(6).
-
#polygon ⇒ Object
Returns the value of attribute polygon.
-
#thermal_insulation ⇒ Object
thermal insulation of floors.
-
#type ⇒ Object
a string object which defines the type of roof (e.g. attic).
Attributes inherited from DOESurface
Attributes inherited from DOECommand
#building, #children, #commandName, #commandType, #comments, #exempt, #keywordPairs, #non_utype_commands, #one_line_commands, #parents, #utype, #uvalue
Instance Method Summary collapse
- #convert_to_openstudio(model, runner = nil) ⇒ Object
-
#get_area ⇒ Object
This method returns the floor area.
- #get_azimuth ⇒ Object
-
#get_height ⇒ Object
gets the height of the floor.
- #get_origin ⇒ Object
- #get_rotation_matrix ⇒ Object
-
#get_space_height ⇒ Object
gets the space height.
- #get_transformation_matrix ⇒ Object
-
#get_volume ⇒ Object
This method returns the volume of the floor space.
-
#initialize ⇒ DOEFloor
constructor
A new instance of DOEFloor.
Methods inherited from DOESurface
#determine_user_defined_construction, #get_3d_polygon, #get_doors, #get_sub_surface_origin, #get_tilt, #get_windows
Methods inherited from DOECommand
#basic_output, #check_keyword?, #depth, #doe_scope, #get_children, #get_children_of_command, #get_command_from_string, #get_keyword_value, #get_name, #get_parent, #get_parents, #name, #output, #remove, #remove_keyword_pair, #set_keyword_value, #set_parent
Constructor Details
#initialize ⇒ DOEFloor
Returns a new instance of DOEFloor.
1700 1701 1702 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1700 def initialize super() end |
Instance Attribute Details
#absorptance ⇒ Object
The absorptance of the exterior surface of the floor (see rule #4.3.5.3.(6)
1696 1697 1698 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1696 def absorptance @absorptance end |
#polygon ⇒ Object
Returns the value of attribute polygon.
1691 1692 1693 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1691 def polygon @polygon end |
#thermal_insulation ⇒ Object
thermal insulation of floors
1698 1699 1700 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1698 def thermal_insulation @thermal_insulation end |
#type ⇒ Object
a string object which defines the type of roof (e.g. attic)
1693 1694 1695 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1693 def type @type end |
Instance Method Details
#convert_to_openstudio(model, runner = nil) ⇒ Object
1762 1763 1764 1765 1766 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1762 def convert_to_openstudio(model,runner = nil) floor = OpenStudio::Model::BuildingStory.new(model) floor.setName(self.name) BTAP::runner_register("Info", "\tBuildingStory: " + self.name + " created",runner) end |
#get_area ⇒ Object
This method returns the floor area
1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1705 def get_area # get the keyword for the shape of the floor case get_keyword_value("SHAPE") # if the keyword value is "BOX", the width and depth values are defined when "BOX" return get_keyword_value("WIDTH").to_f * get_keyword_value("DEPTH").to_f # if the keyword value is "POLYGON", the get_area is defined as the area of the # given polygon when "POLYGON" return @polygon.get_area # if the keyword value of the floor is "No-SHAPE", the get_area is given as the # get_area keyword value when "NO-SHAPE" return get_keyword_value("AREA").to_f else raise "Error: The area could not be evaluated. Please check inputs\n " end end |
#get_azimuth ⇒ Object
1750 1751 1752 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1750 def get_azimuth() return self.check_keyword?("AZIMUTH")? self.get_keyword_value("AZIMUTH").to_f : 0.0 end |
#get_height ⇒ Object
gets the height of the floor
1734 1735 1736 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1734 def get_height return get_keyword_value("FLOOR-HEIGHT").to_f end |
#get_origin ⇒ Object
1743 1744 1745 1746 1747 1748 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1743 def get_origin() space_xref = self.check_keyword?("X")? self.get_keyword_value("X").to_f : 0.0 space_yref = self.check_keyword?("Y")? self.get_keyword_value("Y").to_f : 0.0 space_zref = self.check_keyword?("Z")? self.get_keyword_value("Z").to_f : 0.0 return OpenStudio::Vector3d.new(space_xref,space_yref,space_zref) end |
#get_rotation_matrix ⇒ Object
1758 1759 1760 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1758 def get_rotation_matrix() return OpenStudio::Transformation::rotation(OpenStudio::Vector3d.new(0.0, 0.0, 1.0), OpenStudio::degToRad(360.0 - self.get_azimuth())) end |
#get_space_height ⇒ Object
gets the space height
1739 1740 1741 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1739 def get_space_height return get_keyword_value("SPACE-HEIGHT").to_f end |
#get_transformation_matrix ⇒ Object
1754 1755 1756 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1754 def get_transformation_matrix() return OpenStudio::createTranslation(self.get_origin) * OpenStudio::Transformation::rotation(OpenStudio::Vector3d.new(0.0, 0.0, 1.0), OpenStudio::degToRad(360.0 - self.get_azimuth())) end |
#get_volume ⇒ Object
This method returns the volume of the floor space
1729 1730 1731 |
# File 'lib/openstudio-standards/btap/equest.rb', line 1729 def get_volume return get_floor_height.to_f * get_area.to_f end |