fairyfly_therm.condition.steadystate module

SteadyState THERM condition.

class fairyfly_therm.condition.steadystate.SteadyState(temperature, film_coefficient, emissivity=1.0, radiant_temperature=None, heat_flux=0, relative_humidity=0.5, identifier=None)[source]

Bases: _ThermConditionBase

Typical steady state condition.

Parameters:
  • temperature – A number for the temperature at the boundary in degrees Celsius. For NFRC conditions, this temperature should be 21C for interior boundary conditions and -18 C for winter exterior boundary conditions.

  • film_coefficient – A number in W/m2-K that represents the convective resistance of the air film at the boundary condition. Typical film coefficient values range from 36 W/m2-K (for an exterior condition where outdoor wind strips away most convective resistance) to 2.5 W/m2-K (for a vertically-oriented interior wood/vinyl surface). For NFRC conditions, this should be 26 for exterior boundary conditions and around 3 for interior boundary conditions.

  • emissivity – An optional number between 0 and 1 to set the emissivity along the boundary, which represents the emissivity of the environment to which the material in contact with the boundary is radiating to. (Default: 1).

  • radiant_temperature – A number for the radiant temperature at the boundary in degrees Celsius. If None, this will be the same as the specified temperature. (Default: None).

  • heat_flux – An optional number in W/m2 that represents additional energy flux across the boundary. This can be used to account for solar flux among other forms of heat flux. (Default: 0).

  • relative_humidity – An optional value between 0 and 1 for the relative humidity along the boundary. (Default: 0.5).

  • identifier – Text string for a unique object ID. Must be a UUID in the format xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx. If None, a UUID will automatically be generated. (Default: None).

Properties:
  • identifier

  • display_name

  • temperature

  • film_coefficient

  • emissivity

  • radiant_temperature

  • heat_flux

  • relative_humidity

  • color

  • protected

  • project_tag

  • user_data

ToString()

Overwrite .NET ToString.

duplicate()

Get a copy of this construction.

static extract_all_from_xml_file(xml_file)[source]

Extract all Condition objects from a THERM XML file.

Parameters:

xml_file – A path to an XML file containing objects Condition objects.

Returns:

A list of all Comprehensive Condition objects in the file.

classmethod from_dict(data)[source]

Create a SteadyState from a dictionary.

Parameters:

data – A python dictionary in the following format

{
"type": 'SteadyState',
"identifier": 'f26f3597-e3ee-43fe-a0b3-ec673f993d86',
"display_name": 'NFRC 100-2010 Exterior',
"temperature": -18,
"film_coefficient": 26,
"emissivity": 1,
"radiant_temperature": -18,
"heat_flux": 0,
"relative_humidity": 0.5
}
classmethod from_therm_xml(xml_element)[source]

Create SteadyState from an XML element of a THERM BoundaryCondition.

Parameters:

xml_element – An XML element of a THERM BoundaryCondition.

classmethod from_therm_xml_str(xml_str)[source]

Create SteadyState from an XML string of a THERM BoundaryCondition.

Parameters:

xml_str – An XML text string of a THERM BoundaryCondition.

lock()
to_dict()[source]

SteadyState dictionary representation.

to_therm_xml(bcs_element=None)[source]

Get an THERM XML element of the boundary condition.

Parameters:

bcs_element – An optional XML Element for the BoundaryConditions to which the generated objects will be added. If None, a new XML Element will be generated.

<BoundaryCondition>
    <UUID>1810f37a-de4d-4e2d-95d5-09fe01157c34</UUID>
    <Name>NFRC 100-2010 Exterior</Name>
    <ProjectNameTag></ProjectNameTag>
    <Protected>true</Protected>
    <Color>0x0080C0</Color>
    <IGUSurface>false</IGUSurface>
    <Comprehensive>
        <RelativeHumidity>0.5</RelativeHumidity>
        <Convection>
            <Temperature>-18</Temperature>
            <FilmCoefficient>26</FilmCoefficient>
        </Convection>
        <ConstantFlux>
            <Flux>0</Flux>
        </ConstantFlux>
        <Radiation>
            <BlackBodyRadiation>
                <Temperature>-18</Temperature>
                <Emissivity>1</Emissivity>
                <ViewFactor>1</ViewFactor>
            </BlackBodyRadiation>
        </Radiation>
    </Comprehensive>
</BoundaryCondition>
to_therm_xml_str()[source]

Get an THERM XML string of the condition.

unlock()
property color

Get or set an optional color for the condition as it displays in THERM.

This will always be a Ladybug Color object when getting this property but the setter supports specifying hex codes. If unspecified, a radom color will automatically be assigned.

property display_name

Get or set a string for the object name without any character restrictions.

If not set, this will be equal to the identifier.

property emissivity

Get or set the hemispherical emissivity of the environment of the condition.

property film_coefficient

Get or set the film coefficient along the boundary [ W/m2-K].

property heat_flux

Get or set the additional energy flux across the boundary [W/m2].

property identifier

Get or set a text string for the unique object identifier.

This must be a UUID in the format xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx and it remains constant as the object is mutated, copied, and serialized to different formats (eg. therm XML). As such, this property is used to reference the object across a Model.

property project_tag

Get or set a string for the condition’s project name.

property protected

Get or set a boolean for whether the condition is protected in THERM.

property radiant_temperature

Get or set the radiant temperature along the boundary.

property relative_humidity

Get or set a number between zero and one for the relative humidity.

property temperature

Get or set the temperature of the condition [C].

property user_data

Get or set an optional dictionary for additional meta data for this object.

This will be None until it has been set. All keys and values of this dictionary should be of a standard Python type to ensure correct serialization of the object to/from JSON (eg. str, float, int, list, dict)