Class: DEER Abstract

Inherits:
Standard show all
Defined in:
lib/openstudio-standards/standards/deer/deer.rb,
lib/openstudio-standards/standards/deer/deer.Model.rb,
lib/openstudio-standards/standards/deer/deer.Space.rb,
lib/openstudio-standards/standards/deer/deer.AirLoopHVAC.rb,
lib/openstudio-standards/prototypes/deer/deer.Model.rb

Overview

This class is abstract.

This abstract class holds methods that many versions of DEER share. If a method in this class is redefined by a subclass, the implementation in the subclass is used.

Model collapse

Space collapse

AirLoopHVAC collapse

Instance Method Summary collapse

Constructor Details

#initializeDEER

Returns a new instance of DEER.


6
7
8
# File 'lib/openstudio-standards/standards/deer/deer.rb', line 6

def initialize
  super()
end

Instance Method Details

#air_loop_hvac_economizer_limits(air_loop_hvac, climate_zone) ⇒ Array<Double>

Determine the limits for the type of economizer present on the AirLoopHVAC, if any.

Returns:

  • (Array<Double>)
    drybulb_limit_f, enthalpy_limit_btu_per_lb, dewpoint_limit_f

43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
# File 'lib/openstudio-standards/standards/deer/deer.AirLoopHVAC.rb', line 43

def air_loop_hvac_economizer_limits(air_loop_hvac, climate_zone)
  drybulb_limit_f = nil
  enthalpy_limit_btu_per_lb = nil
  dewpoint_limit_f = nil

  # Get the OA system and OA controller
  oa_sys = air_loop_hvac.airLoopHVACOutdoorAirSystem
  if oa_sys.is_initialized
    oa_sys = oa_sys.get
  else
    return [nil, nil, nil] # No OA system
  end
  oa_control = oa_sys.getControllerOutdoorAir
  economizer_type = oa_control.getEconomizerControlType

  case economizer_type
  when 'NoEconomizer'
    return [nil, nil, nil]
  when 'FixedDryBulb'
    enthalpy_limit_btu_per_lb = 28
    case climate_zone
    when 'CEC T24-CEC7'
      drybulb_limit_f = 69
    when 'CEC T24-CEC1',
      'CEC T24-CEC3',
      'CEC T24-CEC5'
    drybulb_limit_f = 70
    when 'CEC T24-CEC6',
      'CEC T24-CEC8',
      'CEC T24-CEC9'
      drybulb_limit_f = 71
    when 'CEC T24-CEC2',
      'CEC T24-CEC4',
      'CEC T24-CEC10',
      drybulb_limit_f = 73
    when 'CEC T24-CEC11',
      'CEC T24-CEC12',
      'CEC T24-CEC13',
      'CEC T24-CEC14',
      'CEC T24-CEC15',
      'CEC T24-CEC16'
      drybulb_limit_f = 75
    end
  end

  return [drybulb_limit_f, enthalpy_limit_btu_per_lb, dewpoint_limit_f]
end

#air_loop_hvac_economizer_type_allowable?(air_loop_hvac, climate_zone) ⇒ Bool

Check the economizer type currently specified in the ControllerOutdoorAir object on this air loop is acceptable per the standard. Based on the MASControl rules, it appears that only NoEconomizer and FixedDryBulb are allowed.

Returns false if the economizer type is not allowable.

Returns:

  • (Bool)

    Returns true if allowable, if the system has no economizer or no OA system.


10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# File 'lib/openstudio-standards/standards/deer/deer.AirLoopHVAC.rb', line 10

def air_loop_hvac_economizer_type_allowable?(air_loop_hvac, climate_zone)
  # EnergyPlus economizer types
  # 'NoEconomizer'
  # 'FixedDryBulb'
  # 'FixedEnthalpy'
  # 'DifferentialDryBulb'
  # 'DifferentialEnthalpy'
  # 'FixedDewPointAndDryBulb'
  # 'ElectronicEnthalpy'
  # 'DifferentialDryBulbAndEnthalpy'

  # Get the OA system and OA controller
  oa_sys = air_loop_hvac.airLoopHVACOutdoorAirSystem
  if oa_sys.is_initialized
    oa_sys = oa_sys.get
  else
    return true # No OA system
  end
  oa_control = oa_sys.getControllerOutdoorAir
  economizer_type = oa_control.getEconomizerControlType

  # Return true if one of the valid choices is used, false otherwise
  case economizer_type
    when 'NoEconomizer', 'FixedDryBulb'
      return true
    else
      return false
  end
end

#model_economizer_type(model, climate_zone) ⇒ String

Determine the prototypical economizer type for the model. Based on the MASControl rules, it appears that only FixedDryBulb economizers are used.

'NoEconomizer' 'FixedDryBulb' 'FixedEnthalpy' 'DifferentialDryBulb' 'DifferentialEnthalpy' 'FixedDewPointAndDryBulb' 'ElectronicEnthalpy' 'DifferentialDryBulbAndEnthalpy'

Parameters:

  • model (OpenStudio::Model::Model)

    the model

  • climate_zone (String)

    the climate zone

Returns:

  • (String)

    the economizer type. Possible values are:


19
20
21
22
# File 'lib/openstudio-standards/prototypes/deer/deer.Model.rb', line 19

def model_economizer_type(model, climate_zone)
  economizer_type = 'FixedDryBulb'
  return economizer_type
end

#model_get_climate_zone_set_from_list(model, possible_climate_zone_sets) ⇒ Object

Determine which climate zone to use. Uses the most specific climate zone set.


6
7
8
9
10
# File 'lib/openstudio-standards/standards/deer/deer.Model.rb', line 6

def model_get_climate_zone_set_from_list(model, possible_climate_zone_sets)
  # OpenStudio.logFree(OpenStudio::Warn, 'openstudio.model.Model', "SpaceType #{space.spaceType.get.name} does not have a standardsSpaceType assigned.")
  climate_zone_set = possible_climate_zone_sets.sort.last
  return climate_zone_set
end

#space_infiltration_rate_75_pa(space) ⇒ Double

Determine the base infiltration rate at 75 PA. In the MASControl2 rules, there is BDL code which states that the value is 0.038 cfm/ft2 of perimeter wall area at typical building pressures. This translates to 0.338921 cfm/ft2 of perimeter wall area at 75Pa using the assumptions from the DOE Prototypes.

defaults to no infiltration.

Returns:

  • (Double)

    the baseline infiltration rate, in cfm/ft^2


13
14
15
16
# File 'lib/openstudio-standards/standards/deer/deer.Space.rb', line 13

def space_infiltration_rate_75_pa(space)
  basic_infil_rate_cfm_per_ft2 = 0.338921
  return basic_infil_rate_cfm_per_ft2
end