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) | :: | UnitarySysNum | |||
logical, | intent(in) | :: | FirstHVACIteration | |||
logical, | intent(in) | :: | SensibleLoad | |||
logical, | intent(in) | :: | LatentLoad | |||
real(kind=R64), | intent(in) | :: | PartLoadFrac | |||
integer, | intent(in) | :: | CoilType | |||
integer, | intent(in), | optional | :: | SpeedNumber |
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 SimMultiSpeedCoils(UnitarySysNum, FirstHVACIteration, SensibleLoad, LatentLoad, PartLoadFrac, CoilType, SpeedNumber)
! SUBROUTINE INFORMATION:
! AUTHOR Chandan Sharma, FSEC
! DATE WRITTEN March 2013
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! This subroutine manages multispeed and variable speed cooling coil simulation.
! METHODOLOGY EMPLOYED:
! na
! REFERENCES:
! na
! USE STATEMENTS:
USE DXCoils, ONLY: SimDXCoilMultiSpeed, DXCoilOutletTemp
USE VariableSpeedCoils, ONLY: SimVariableSpeedCoils
USE HeatingCoils, ONLY: SimulateHeatingCoilComponents
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
INTEGER, INTENT(IN) :: UnitarySysNum ! Index of AirloopHVAC:UnitarySystem object
LOGICAL, INTENT(IN) :: FirstHVACIteration ! True when first HVAC iteration
LOGICAL, INTENT(IN) :: SensibleLoad
LOGICAL, INTENT(IN) :: LatentLoad
INTEGER, INTENT(IN) :: CoilType
REAL(R64), INTENT(IN) :: PartLoadFrac
INTEGER, OPTIONAL,INTENT(IN) :: SpeedNumber
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
CHARACTER(len=MaxNameLength) :: CompName ! Name of Unitary System object
REAL(R64) :: Dummy
REAL(R64) :: SensLoad
REAL(R64) :: LatLoad
REAL(R64) :: OnOffAirFlowRatio
INTEGER :: CoilTypeNum
INTEGER :: SpeedNum
INTEGER :: CoilOutletNodeNum
INTEGER :: CompIndex
LOGICAL :: CoolLoad
LOGICAL :: HeatLoad
Dummy = 0.0d0
IF(PRESENT(SpeedNumber))THEN
SpeedNum = SpeedNumber
ELSE
SpeedNum = 1
END IF
IF (CoilType == CoolingCoil) THEN
CompName = UnitarySystem(UnitarySysNum)%CoolingCoilName
CompIndex = UnitarySystem(UnitarySysNum)%CoolingCoilIndex
CoilTypeNum = UnitarySystem(UnitarySysNum)%CoolingCoilType_Num
CoilOutletNodeNum = UnitarySystem(UnitarySysNum)%CoolCoilOutletNodeNum
IF(SensibleLoad)THEN
SensLoad = -1.0d0
CoolLoad = .TRUE.
HeatLoad = .FALSE.
END IF
IF(LatentLoad)LatLoad = -1.0d0
ELSE
CompName = UnitarySystem(UnitarySysNum)%HeatingCoilName
CompIndex = UnitarySystem(UnitarySysNum)%HeatingCoilIndex
CoilTypeNum = UnitarySystem(UnitarySysNum)%HeatingCoilType_Num
CoilOutletNodeNum = UnitarySystem(UnitarySysNum)%HeatCoilOutletNodeNum
IF(SensibleLoad)THEN
SensLoad = 1.0d0
CoolLoad = .FALSE.
HeatLoad = .TRUE.
ELSE
SensLoad = 0.0d0
HeatLoad = .FALSE.
END IF
LatLoad = 0.0d0
UnitarySystem(UnitarySysNum)%FanOpMode = 1
END IF
OnOffAirFlowRatio = 1.0d0
CALL SetOnOffMassFlowRate(UnitarySysNum, OnOffAirFlowRatio, PartLoadFrac) !1.0d0 = PartLoadRatio
CALL CalcPassiveSystem(UnitarySysNum, FirstHVACIteration)
SELECT CASE(CoilTypeNum)
CASE(CoilDX_MultiSpeedCooling, CoilDX_MultiSpeedHeating)
CALL SimDXCoilMultiSpeed(CompName,0.0d0,PartLoadFrac,CompIndex,SpeedNum,UnitarySystem(UnitarySysNum)%FanOpMode,1)
CASE(Coil_CoolingAirToAirVariableSpeed)
CALL SimVariableSpeedCoils(CompName,CompIndex, &
UnitarySystem(UnitarySysNum)%FanOpMode,UnitarySystem(UnitarySysNum)%MaxONOFFCyclesperHour, &
UnitarySystem(UnitarySysNum)%HPTimeConstant,UnitarySystem(UnitarySysNum)%FanDelayTime, &
1, PartLoadFrac, OnOffAirFlowRatio,SpeedNum, 0.0d0,UnitarySystem(UnitarySysNum)%CoolingCoilSensDemand,Dummy )
CASE(Coil_HeatingAirToAirVariableSpeed)
CALL SimVariableSpeedCoils(CompName,CompIndex, &
UnitarySystem(UnitarySysNum)%FanOpMode,UnitarySystem(UnitarySysNum)%MaxONOFFCyclesperHour, &
UnitarySystem(UnitarySysNum)%HPTimeConstant,UnitarySystem(UnitarySysNum)%FanDelayTime, &
1, PartLoadFrac, OnOffAirFlowRatio,SpeedNum, 0.0d0,UnitarySystem(UnitarySysNum)%HeatingCoilSensDemand,Dummy )
CASE(Coil_CoolingWaterToAirHPVSEquationFit)
CALL SimVariableSpeedCoils(CompName,CompIndex, &
UnitarySystem(UnitarySysNum)%FanOpMode,UnitarySystem(UnitarySysNum)%MaxONOFFCyclesperHour, &
UnitarySystem(UnitarySysNum)%HPTimeConstant,UnitarySystem(UnitarySysNum)%FanDelayTime, &
1, PartLoadFrac, OnOffAirFlowRatio,SpeedNum, 0.0d0,UnitarySystem(UnitarySysNum)%CoolingCoilSensDemand,Dummy )
CASE(Coil_HeatingWaterToAirHPVSEquationFit)
CALL SimVariableSpeedCoils(CompName,CompIndex, &
UnitarySystem(UnitarySysNum)%FanOpMode,UnitarySystem(UnitarySysNum)%MaxONOFFCyclesperHour, &
UnitarySystem(UnitarySysNum)%HPTimeConstant,UnitarySystem(UnitarySysNum)%FanDelayTime, &
1, PartLoadFrac, OnOffAirFlowRatio,SpeedNum, 0.0d0,UnitarySystem(UnitarySysNum)%HeatingCoilSensDemand,Dummy )
CASE(Coil_HeatingElectric_MultiStage, Coil_HeatingGas_MultiStage)
CALL SimulateHeatingCoilComponents(CompName,FirstHVACIteration, &
CompIndex = CompIndex, &
FanOpMode = UnitarySystem(UnitarySysNum)%FanOpMode, &
PartLoadRatio = PartLoadFrac, &
StageNum = SpeedNum, &
SpeedRatio = 0.0d0)
CASE DEFAULT
END SELECT
RETURN
END SUBROUTINE SimMultiSpeedCoils