Improves h/e radiation

This commit is contained in:
mwerezak
2014-08-05 14:50:00 -04:00
parent ac2b8aee02
commit 319b9181e6
3 changed files with 15 additions and 8 deletions

View File

@@ -200,9 +200,13 @@ datum/pipeline
if(network)
network.update = 1
proc/radiate_heat(surface, thermal_conductivity)
//surface must be the surface area in m^2
proc/radiate_heat_to_space(surface, thermal_conductivity)
var/total_heat_capacity = air.heat_capacity()
var/heat = STEFAN_BOLTZMANN_CONSTANT * surface * air.temperature ** 4 * thermal_conductivity
air.temperature = max(0, air.temperature - heat / total_heat_capacity)
//if the h/e pipes radiate less than the AVERAGE_SOLAR_RADIATION, then they will heat up, otherwise they will cool down. It turns out the critical temperature is -26 C
var/heat_gain = surface*(AVERAGE_SOLAR_RADIATION - STEFAN_BOLTZMANN_CONSTANT*thermal_conductivity*(air.temperature - COSMIC_RADIATION_TEMPERATURE) ** 4)
air.add_thermal_energy(heat_gain)
if(network)
network.update = 1