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) | :: | DirectAirNum | |||
integer, | intent(in) | :: | ControlledZoneNum | |||
real(kind=r64), | intent(inout) | :: | SensOutputProvided | |||
real(kind=r64), | intent(out) | :: | LatOutputProvided |
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 CalcDirectAir(DirectAirNum,ControlledZoneNum,SensOutputProvided,LatOutputProvided)
! SUBROUTINE INFORMATION:
! AUTHOR Fred Buhl
! DATE WRITTEN Oct 1999
! MODIFIED Shirey, Aug 2009 (LatOutputProvided)
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE
! Calculate the system SensOutputProvided and LatOutputProvided by the direct supply air connection
! METHODOLOGY EMPLOYED:
! Enthalpy balance
! REFERENCES:
! USE STATEMENTS:
USE DataZoneEquipment, ONLY: ZoneEquipConfig
USE DataHVACGlobals, ONLY: SmallMassFlow
USE Psychrometrics, ONLY: PsyHFnTdbW
IMPLICIT NONE
! SUBROUTINE ARGUMENT DEFINITIONS
INTEGER, INTENT(IN) :: DirectAirNum
INTEGER, INTENT(IN) :: ControlledZoneNum
REAL(r64), INTENT(INOUT) :: SensOutputProvided
REAL(r64), INTENT(OUT) :: LatOutputProvided ! Latent output provided, kg/s, dehumidification = negative
! SUBROUTINE PARAMETER DEFINITIONS:
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
REAL(r64) :: MassFlowRate ! Air mass flow rate in kg/s
REAL(r64) :: SpecHumOut ! Specific humidity ratio of outlet air (kg moisture / kg moist air)
REAL(r64) :: SpecHumIn ! Specific humidity ratio of inlet [zone] air (kg moisture / kg moist air)
! Sign convention: SysSensOutputProvided <0 Zone is cooled
! SysSensOutputProvided >0 Zone is heated
! SysLatOutputProvided <0 Zone is dehumidified
! SysLatOutputProvided >0 Zone is humidified
MassFlowRate = Node(DirectAir(DirectAirNum)%ZoneSupplyAirNode)%MassFlowRate
IF (GetCurrentScheduleValue(DirectAir(DirectAirNum)%SchedPtr).GT. 0.0d0 &
.AND. MassFlowRate.GT.SmallMassFlow) THEN
! Change this later ... should be using minimum humidity ratio in the calculation of enthalpy
! MinHumRat = MIN(Node(ZoneEquipConfig(ControlledZoneNum)%ZoneNode)%HumRat, &
! Node(DirectAir(DirectAirNum)%ZoneSupplyAirNode)%HumRat)
SensOutputProvided = MassFlowRate * (PsyHFnTdbW(Node(DirectAir(DirectAirNum)%ZoneSupplyAirNode)%Temp, &
Node(ZoneEquipConfig(ControlledZoneNum)%ZoneNode)%HumRat) &
- PsyHFnTdbW(Node(ZoneEquipConfig(ControlledZoneNum)%ZoneNode)%Temp, &
Node(ZoneEquipConfig(ControlledZoneNum)%ZoneNode)%HumRat))
! CR9155 Remove specific humidity calculations
SpecHumOut = Node(DirectAir(DirectAirNum)%ZoneSupplyAirNode)%HumRat
SpecHumIn = Node(ZoneEquipConfig(ControlledZoneNum)%ZoneNode)%HumRat
LatOutputProvided = MassFlowRate * (SpecHumOut - SpecHumIn) ! Latent rate, kg/s
ELSE
SensOutputProvided = 0.0d0
LatOutputProvided = 0.0d0
END IF
DirectAir(DirectAirNum)%SensOutputProvided = SensOutputProvided
RETURN
END SUBROUTINE CalcDirectAir