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 | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | CompName | |||
logical, | intent(in) | :: | FirstHVACIteration | |||
integer, | intent(in) | :: | ZoneNum | |||
integer, | intent(in) | :: | ZoneNodeNum | |||
integer, | intent(inout) | :: | CompIndex |
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 SimulateSingleDuct(CompName,FirstHVACIteration, ZoneNum, ZoneNodeNum, CompIndex)
! SUBROUTINE INFORMATION:
! AUTHOR Richard Liesen
! DATE WRITTEN January 2000
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! This subroutine manages Sys system simulation.
! It is called from the ManageZoneEquip
! at the system time step.
! METHODOLOGY EMPLOYED:
! na
! REFERENCES:
! na
! USE STATEMENTS:
USE InputProcessor, ONLY: FindItemInList
USE General, ONLY: TrimSigDigits
IMPLICIT NONE
! SUBROUTINE ARGUMENT DEFINITIONS:
CHARACTER(len=*), INTENT(IN) :: CompName
LOGICAL, INTENT (IN):: FirstHVACIteration
INTEGER, INTENT (IN):: ZoneNum
INTEGER, INTENT (IN):: ZoneNodeNum
INTEGER, INTENT (INOUT):: CompIndex
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: SysNum ! The Sys that you are currently loading input into
! FLOW:
! Obtains and Allocates Sys related parameters from input file
IF (GetInputFlag) THEN !First time subroutine has been entered
CALL GetSysInput
GetInputFlag=.false.
End If
! Find the correct SysNumber with the Component Name
IF (CompIndex == 0) THEN
SysNum = FindItemInList(CompName,Sys%SysName,NumSys)
IF (SysNum == 0) THEN
CALL ShowFatalError('SimulateSingleDuct: System not found='//TRIM(CompName))
ENDIF
CompIndex=SysNum
ELSE
SysNum=CompIndex
IF (SysNum > NumSys .or. SysNum < 1) THEN
CALL ShowFatalError('SimulateSingleDuct: Invalid CompIndex passed='//TRIM(TrimSigDigits(CompIndex))// &
', Number of Systems='//TRIM(TrimSigDigits(NumSys))//', System name='//TRIM(CompName))
ENDIF
IF (CheckEquipName(SysNum)) THEN
IF (CompName /= Sys(SysNum)%SysName) THEN
CALL ShowFatalError('SimulateSingleDuct: Invalid CompIndex passed='//TRIM(TrimSigDigits(CompIndex))// &
', System name='//TRIM(CompName)//', stored System Name for that index='//TRIM(Sys(SysNum)%SysName))
ENDIF
CheckEquipName(SysNum)=.false.
ENDIF
ENDIF
TermUnitSingDuct = .TRUE.
! With the correct SysNum Initialize the system
CALL InitSys(SysNum,FirstHVACIteration) ! Initialize all Sys related parameters
! Calculate the Correct Sys Model with the current SysNum
SELECT CASE(Sys(SysNum)%SysType_Num)
CASE (SingleDuctConstVolReheat) ! AirTerminal:SingleDuct:ConstantVolume:Reheat
Call SimConstVol(SysNum, FirstHVACIteration, ZoneNum, ZoneNodeNum)
CASE (SingleDuctVAVReheat) ! SINGLE DUCT:VAV:REHEAT
Call SimVAV(SysNum, FirstHVACIteration, ZoneNum, ZoneNodeNum)
CASE (SingleDuctVAVNoReheat) ! SINGLE DUCT:VAV:NOREHEAT
Call SimVAV(SysNum, FirstHVACIteration, ZoneNum, ZoneNodeNum)
CASE (SingleDuctVAVReheatVSFan) ! SINGLE DUCT:VAV:REHEAT:VS FAN
Call SimVAVVS(SysNum, FirstHVACIteration, ZoneNum, ZoneNodeNum)
CASE (SingleDuctCBVAVReheat) ! SINGLE DUCT:VAVHEATANDCOOL:REHEAT
Call SimCBVAV(SysNum, FirstHVACIteration, ZoneNum, ZoneNodeNum)
CASE (SingleDuctCBVAVNoReheat) ! SINGLE DUCT:VAVHEATANDCOOL:NOREHEAT
Call SimCBVAV(SysNum, FirstHVACIteration, ZoneNum, ZoneNodeNum)
END SELECT
! Report the current Sys
Call ReportSys(SysNum)
TermUnitSingDuct = .FALSE.
RETURN
END SUBROUTINE SimulateSingleDuct