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) | :: | WindACNum | |||
logical, | intent(in) | :: | FirstHVACIteration | |||
integer, | intent(in) | :: | OpMode | |||
real(kind=r64), | intent(in) | :: | PartLoadFrac | |||
logical, | intent(in) | :: | HXUnitOn | |||
real(kind=r64), | intent(out) | :: | LoadMet |
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 CalcWindowACOutput(WindACNum,FirstHVACIteration,OpMode,PartLoadFrac,HXUnitOn,LoadMet)
! SUBROUTINE INFORMATION:
! AUTHOR Fred Buhl
! DATE WRITTEN May 2000
! MODIFIED July 2012, Chandan Sharma - FSEC: Added zone sys avail managers
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Simulate the components making up the cycling window AC unit.
! METHODOLOGY EMPLOYED:
! Simulates the unit components sequentially in the air flow direction.
! REFERENCES:
! na
! USE STATEMENTS:
USE MixedAir, ONLY: SimOAMixer
USE Fans, ONLY: SimulateFanComponents
USE DXCoils, ONLY: SimDXCoil
USE HVACHXAssistedCoolingCoil, ONLY: SimHXAssistedCoolingCoil
USE InputProcessor, ONLY: SameString
USE DataHvacGlobals, ONLY: ZoneCompTurnFansOn, ZoneCompTurnFansOff
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
INTEGER, INTENT (IN) :: WindACNum ! Unit index in fan coil array
LOGICAL, INTENT (IN) :: FirstHVACIteration ! flag for 1st HVAV iteration in the time step
INTEGER, INTENT (IN) :: OpMode ! operating mode: CycFanCycCoil | ContFanCycCoil
REAL(r64) , INTENT (IN) :: PartLoadFrac ! unit part load fraction
LOGICAL, INTENT (IN) :: HXUnitOn ! Flag to toggle HX heat recovery as needed
REAL(r64), INTENT (OUT) :: LoadMet ! load met by unit (watts)
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: OutletNode ! unit air outlet node
INTEGER :: InletNode ! unit air inlet node
INTEGER :: OutsideAirNode ! outside air node number in window AC loop
INTEGER :: AirRelNode ! relief air node number in window AC loop
REAL(r64) :: AirMassFlow ! total mass flow through the unit
REAL(r64) :: MinHumRat ! minimum of inlet & outlet humidity ratio
! FLOW
OutletNode = WindAC(WindACNum)%AirOutNode
InletNode = WindAC(WindACNum)%AirInNode
OutsideAirNode = WindAC(WindACNum)%OutsideAirNode
AirRelNode = WindAC(WindACNum)%AirReliefNode
! for cycling fans, pretend we have VAV
IF (OpMode.EQ.CycFanCycCoil) THEN
Node(InletNode)%MassFlowRate = Node(InletNode)%MassFlowRateMax * PartLoadFrac
! Don't let the outside air flow be > supply air flow
Node(OutsideAirNode)%MassFlowRate = MIN(Node(OutsideAirNode)%MassFlowRateMax,Node(InletNode)%MassFlowRate)
Node(AirRelNode)%MassFlowRate = Node(OutsideAirNode)%MassFlowRate
END IF
AirMassFlow = Node(InletNode)%MassFlowRate
CALL SimOAMixer(WindAC(WindACNum)%OAMixName,FirstHVACIteration,WindAC(WindACNum)%OAMixIndex)
! if blow through, simulate fan then coil. For draw through, simulate coil then fan.
IF (WindAC(WindACNum)%FanPlace .EQ. BlowThru) THEN
CALL SimulateFanComponents(WindAC(WindACNum)%FanName,FirstHVACIteration,WindAC(WindACNum)%FanIndex, &
ZoneCompTurnFansOn = ZoneCompTurnFansOn,ZoneCompTurnFansOff = ZoneCompTurnFansOff)
END IF
IF(WindAC(WindACNum)%DXCoilType_Num == CoilDX_CoolingHXAssisted) THEN
CALL SimHXAssistedCoolingCoil(WindAC(WindACNum)%DXCoilName,FirstHVACIteration,On,PartLoadFrac,WindAC(WindACNum)%DXCoilIndex, &
WindAC(WindACNum)%OpMode, HXUnitEnable=HXUnitOn)
ELSE
CALL SimDXCoil(WindAC(WindACNum)%DXCoilName,On,FirstHVACIteration,PartLoadFrac,WindAC(WindACNum)%DXCoilIndex, &
WindAC(WindACNum)%OpMode)
END IF
IF (WindAC(WindACNum)%FanPlace .EQ. DrawThru) THEN
CALL SimulateFanComponents(WindAC(WindACNum)%FanName,FirstHVACIteration,WindAC(WindACNum)%FanIndex, &
ZoneCompTurnFansOn = ZoneCompTurnFansOn,ZoneCompTurnFansOff = ZoneCompTurnFansOff)
END IF
MinHumRat = MIN(Node(InletNode)%HumRat,Node(OutletNode)%HumRat)
LoadMet = AirMassFlow * (PsyHFnTdbW(Node(OutletNode)%Temp,MinHumRat) &
- PsyHFnTdbW(Node(InletNode)%Temp,MinHumRat))
RETURN
END SUBROUTINE CalcWindowACOutput