Nodes of different colours represent the following:
Solid arrows point from a parent (sub)module to the submodule which is descended from it. Dashed arrows point from a module being used to the module or program unit using it. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | SurfaceNum | |||
real(kind=r64), | intent(in) | :: | FluxBtm | |||
real(kind=r64), | intent(out) | :: | TempBtm | |||
real(kind=r64), | intent(in) | :: | ThisDrybulb | |||
real(kind=r64), | intent(in) | :: | ThisWindSpeed | |||
real(kind=r64), | intent(in) | :: | ThisGroundTemp |
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
SUBROUTINE CalcBottomSurfTemp (SurfaceNum, FluxBtm, TempBtm, ThisDrybulb, ThisWindSpeed, &
ThisGroundTemp)
! AUTHOR Simon Rees
! DATE WRITTEN August 2002
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! This subroutine is used to calculate the bottom surface
! temperature for the given surface flux.
! METHODOLOGY EMPLOYED:
! calc surface heat balances
! REFERENCES:
! USE STATEMENTS:
USE ConvectionCoefficients, ONLY : CalcASHRAESimpExtConvectCoeff
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
INTEGER, INTENT(IN) :: SurfaceNum ! surface index number
REAL(r64), INTENT(IN) :: FluxBtm ! bottom surface flux
REAL(r64), INTENT(OUT) :: TempBtm ! bottom surface temperature
REAL(r64), INTENT(IN) :: ThisDrybulb ! dry bulb temperature
REAL(r64), INTENT(IN) :: ThisWindSpeed ! wind speed
REAL(r64), INTENT(IN) :: ThisGroundTemp ! ground temperature
! SUBROUTINE PARAMETER DEFINITIONS:
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
REAL(r64) :: ConvCoef ! convection coefficient
REAL(r64) :: RadCoef ! radiation coefficient
REAL(r64) :: OldSurfTemp ! previous surface temperature
REAL(r64) :: SurfTempAbs ! absolute value of surface temp
REAL(r64) :: ExtTempAbs ! absolute value of sky temp
IF(SurfaceGHE(SurfaceNum)%LowerSurfCond == SurfCond_Exposed)THEN
! make a surface heat balance and solve for temperature
OldSurfTemp = SurfaceGHEQTF(SurfaceNum)%TbtmHistory(1)
! absolute temperatures
SurfTempAbs = OldSurfTemp + KelvinConv
ExtTempAbs = ThisDrybulb + KelvinConv
! ASHRAE simple convection coefficient model for external surfaces.
ConvCoef = CalcASHRAESimpExtConvectCoeff(TopRoughness,ThisWindSpeed)
! radiation coefficient using surf temp from past time step
IF (ABS(SurfTempAbs-ExtTempAbs) > SmallNum) THEN
RadCoef = StefBoltzmann*TopThermAbs*((SurfTempAbs**4)-(ExtTempAbs**4))/ &
(SurfTempAbs-ExtTempAbs)
ELSE
RadCoef=0.0d0
ENDIF
! total absorbed solar - no ground solar
TempBtm = (FluxBtm + ConvCoef*ThisDrybulb + RadCoef*ThisDrybulb)/ &
(ConvCoef + RadCoef)
ELSE ! ground coupled
! just use the supplied ground temperature
TempBtm = ThisGroundTemp
END IF
END SUBROUTINE CalcBottomSurfTemp