Class: EnergyPlus::SlabGtpFile

Inherits:
Object
  • Object
show all
Defined in:
lib/energyplus/SlabGtpFile.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path) ⇒ SlabGtpFile

Returns a new instance of SlabGtpFile.



28
29
30
31
32
33
34
# File 'lib/energyplus/SlabGtpFile.rb', line 28

def initialize(path)
  @path = Pathname.new(path)
  @convergence = false
  @months = []
  @averageTemps = []
  init
end

Instance Attribute Details

#averageTempsObject

Returns the value of attribute averageTemps.



26
27
28
# File 'lib/energyplus/SlabGtpFile.rb', line 26

def averageTemps
  @averageTemps
end

#convergenceObject

Returns the value of attribute convergence.



24
25
26
# File 'lib/energyplus/SlabGtpFile.rb', line 24

def convergence
  @convergence
end

#monthsObject

Returns the value of attribute months.



25
26
27
# File 'lib/energyplus/SlabGtpFile.rb', line 25

def months
  @months
end

Instance Method Details

#getGroundTempsObject



36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# File 'lib/energyplus/SlabGtpFile.rb', line 36

def getGroundTemps
  result = "Site:GroundTemperature:BuildingSurface,\n"
  result+= "  #{@averageTemps[0]},  !- January Ground Temperature {C}\n"
  result+= "  #{@averageTemps[1]},  !- February Ground Temperature {C}\n"
  result+= "  #{@averageTemps[2]},  !- March Ground Temperature {C}\n"
  result+= "  #{@averageTemps[3]},  !- April Ground Temperature {C}\n"
  result+= "  #{@averageTemps[4]},  !- May Ground Temperature {C}\n"
  result+= "  #{@averageTemps[5]},  !- June Ground Temperature {C}\n"
  result+= "  #{@averageTemps[6]},  !- July Ground Temperature {C}\n"
  result+= "  #{@averageTemps[7]},  !- August Ground Temperature {C}\n"
  result+= "  #{@averageTemps[8]},  !- September Ground Temperature {C}\n"
  result+= "  #{@averageTemps[9]},  !- October Ground Temperature {C}\n"
  result+= "  #{@averageTemps[10]},  !- November Ground Temperature {C}\n"
  result+= "  #{@averageTemps[11]};  !- December Ground Temperature {C}\n"
  return result
end