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.
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 GetSteamCoilInput
! SUBROUTINE INFORMATION:
! AUTHOR Rahul Chillar
! DATE WRITTEN Jan 2005
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Obtains input data for coils and stores it in coil data structures
! METHODOLOGY EMPLOYED:
! Uses "Get" routines to read in data.
! REFERENCES:
! na
! USE STATEMENTS:
USE InputProcessor
USE NodeInputManager, ONLY: GetOnlySingleNode
USE BranchNodeConnections, ONLY: TestCompSet
USE FluidProperties , ONLY: FindRefrigerant
USE GlobalNames, ONLY: VerifyUniqueCoilName
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
! na
! SUBROUTINE PARAMETER DEFINITIONS:
CHARACTER(len=*), PARAMETER :: RoutineName='GetSteamCoilInput: ' ! include trailing blank space
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: CoilNum ! The SteamCoil that you are currently loading input into
INTEGER :: NumStmHeat !
INTEGER :: StmHeatNum !
INTEGER :: NumAlphas !
INTEGER :: NumNums !
INTEGER :: IOSTAT !
LOGICAL :: ErrorsFound = .false. ! If errors detected in input
LOGICAL :: IsNotOK ! Flag to verify name
LOGICAL :: IsBlank ! Flag for blank name
CHARACTER (len=MaxNameLength) :: CurrentModuleObject ! for ease in getting objects
CHARACTER(len=MaxNameLength), ALLOCATABLE, DIMENSION(:) :: AlphArray ! Alpha input items for object
CHARACTER(len=MaxNameLength), ALLOCATABLE, DIMENSION(:) :: cAlphaFields ! Alpha field names
CHARACTER(len=MaxNameLength), ALLOCATABLE, DIMENSION(:) :: cNumericFields ! Numeric field names
REAL(r64), ALLOCATABLE, DIMENSION(:) :: NumArray ! Numeric input items for object
LOGICAL, ALLOCATABLE, DIMENSION(:) :: lAlphaBlanks ! Logical array, alpha field input BLANK = .true.
LOGICAL, ALLOCATABLE, DIMENSION(:) :: lNumericBlanks ! Logical array, numeric field input BLANK = .true.
INTEGER :: TotalArgs=0 ! Total number of alpha and numeric arguments (max) for a
! certain object in the input file
LOGICAL :: errflag
CurrentModuleObject = 'Coil:Heating:Steam'
NumStmHeat = GetNumObjectsFound(CurrentModuleObject)
NumSteamCoils = NumStmHeat
IF (NumSteamCoils.GT.0) THEN
ALLOCATE(SteamCoil(NumSteamCoils))
ALLOCATE(CheckEquipName(NumSteamCoils))
CheckEquipName=.true.
ENDIF
CALL GetObjectDefMaxArgs(CurrentModuleObject,TotalArgs,NumAlphas,NumNums)
ALLOCATE(AlphArray(NumAlphas))
AlphArray=' '
ALLOCATE(cAlphaFields(NumAlphas))
cAlphaFields=' '
ALLOCATE(cNumericFields(NumNums))
cNumericFields=' '
ALLOCATE(NumArray(NumNums))
NumArray=0.0d0
ALLOCATE(lAlphaBlanks(NumAlphas))
lAlphaBlanks=.true.
ALLOCATE(lNumericBlanks(NumNums))
lNumericBlanks=.true.
! Get the data for steam heating coils
DO StmHeatNum = 1, NumStmHeat
CoilNum= StmHeatNum
CALL GetObjectItem(CurrentModuleObject,StmHeatNum,AlphArray, &
NumAlphas,NumArray,NumNums,IOSTAT, &
NumBlank=lNumericBlanks,AlphaBlank=lAlphaBlanks, &
AlphaFieldNames=cAlphaFields,NumericFieldNames=cNumericFields)
IsNotOK=.false.
IsBlank=.false.
CALL VerifyName(AlphArray(1),SteamCoil%Name,CoilNum-1,IsNotOK,IsBlank,TRIM(CurrentModuleObject)//' Name')
IF (IsNotOK) THEN
ErrorsFound=.true.
IF (IsBlank) AlphArray(1)='xxxxx'
ENDIF
CALL VerifyUniqueCoilName(CurrentModuleObject,AlphArray(1),errflag,TRIM(CurrentModuleObject)//' Name')
IF (errflag) THEN
ErrorsFound=.true.
ENDIF
SteamCoil(CoilNum)%Name = AlphArray(1)
SteamCoil(CoilNum)%Schedule = AlphArray(2)
IF (lAlphaBlanks(2)) THEN
SteamCoil(CoilNum)%SchedPtr = ScheduleAlwaysOn
ELSE
SteamCoil(CoilNum)%SchedPtr = GetScheduleIndex(AlphArray(2))
IF (SteamCoil(CoilNum)%SchedPtr == 0) THEN
CALL ShowSevereError(RoutineName//TRIM(CurrentModuleObject)//'="'//TRIM(AlphArray(1))//'", invalid data.')
CALL ShowContinueError(TRIM(cAlphaFields(2))//' not found='//TRIM(AlphArray(2)))
ErrorsFound=.true.
ENDIF
ENDIF
SteamCoil(CoilNum)%SteamCoilTypeA ='Heating'
SteamCoil(CoilNum)%SteamCoilType_Num = SteamCoil_AirHeating
SteamCoil(CoilNum)%Coil_PlantTypeNum = TypeOf_CoilSteamAirHeating
SteamCoil(CoilNum)%MaxSteamVolFlowRate = NumArray(1)
SteamCoil(CoilNum)%DegOfSubCooling = NumArray(2)
SteamCoil(CoilNum)%LoopSubCoolReturn = NumArray(3)
SteamCoil(CoilNum)%SteamInletNodeNum = &
GetOnlySingleNode(AlphArray(3),ErrorsFound,TRIM(CurrentModuleObject),AlphArray(1),NodeType_Steam, &
NodeConnectionType_Inlet,2,ObjectIsNotParent)
SteamCoil(CoilNum)%SteamOutletNodeNum = &
GetOnlySingleNode(AlphArray(4),ErrorsFound,TRIM(CurrentModuleObject),AlphArray(1),NodeType_Steam, &
NodeConnectionType_Outlet,2,ObjectIsNotParent)
SteamCoil(CoilNum)%AirInletNodeNum = &
GetOnlySingleNode(AlphArray(5),ErrorsFound,TRIM(CurrentModuleObject),AlphArray(1),NodeType_Air, &
NodeConnectionType_Inlet,1,ObjectIsNotParent)
SteamCoil(CoilNum)%AirOutletNodeNum = &
GetOnlySingleNode(AlphArray(6),ErrorsFound,TRIM(CurrentModuleObject),AlphArray(1),NodeType_Air, &
NodeConnectionType_Outlet,1,ObjectIsNotParent)
SELECT CASE (MakeUPPERCase(AlphArray(7)))
!TEMPERATURE SETPOINT CONTROL or ZONE LOAD CONTROLLED Coils
CASE ('TEMPERATURESETPOINTCONTROL')
SteamCoil(CoilNum)%TypeofCoil = TemperatureSetpointControl
SteamCoil(CoilNum)%TempSetPointNodeNum = &
GetOnlySingleNode(AlphArray(8),ErrorsFound,TRIM(CurrentModuleObject),AlphArray(1),NodeType_Air, &
NodeConnectionType_Sensor,1,ObjectIsNotParent)
IF (SteamCoil(CoilNum)%TempSetPointNodeNum==0) Then
CALL ShowSevereError(RoutineName//TRIM(cAlphaFields(8))//' not found for '// &
TRIM(CurrentModuleObject)//' = '//TRIM(AlphArray(1)))
CALL ShowContinueError('..required for Temperature Setpoint Controlled Coils.')
ErrorsFound=.true.
ENDIF
CASE ('ZONELOADCONTROL')
SteamCoil(CoilNum)%TypeofCoil = ZoneloadControl
IF (.NOT. lAlphaBlanks(8)) THEN
CALL ShowWarningError(RoutineName//'ZoneLoad Controlled Coil, so '//TRIM(cAlphaFields(8))//' not needed')
CALL ShowContinueError('for '//TRIM(CurrentModuleObject)//' = '//TRIM(AlphArray(1)))
SteamCoil(CoilNum)%TempSetPointNodeNum = 0
ENDIF
CASE DEFAULT
CALL ShowSevereError(RoutineName//'Invalid '//TRIM(cAlphaFields(7))//' ['//TRIM(AlphArray(7))//'] specified for '// &
TRIM(CurrentModuleObject)//' = '//TRIM(AlphArray(1)))
ErrorsFound=.true.
END SELECT
CALL TestCompSet(TRIM(CurrentModuleObject),AlphArray(1),AlphArray(3),AlphArray(4),'Steam Nodes')
CALL TestCompSet(TRIM(CurrentModuleObject),AlphArray(1),AlphArray(5),AlphArray(6),'Air Nodes')
IF (SteamIndex == 0 .and. CoilNum == 1) THEN
SteamIndex=FindRefrigerant('Steam')
IF (SteamIndex == 0) THEN
CALL ShowSevereError(RoutineName//'Steam Properties for '//TRIM(AlphArray(1))// &
' not found.')
CALL ShowContinueError('Steam Fluid Properties should have been included in the input file.')
ErrorsFound=.true.
ENDIF
ENDIF
SteamCoil(CoilNum)%FluidIndex=SteamIndex
END DO
DO CoilNum=1,NumStmHeat
!Setup the Simple Heating Coil reporting variables
CALL SetupOutputVariable('Heating Coil Heating Energy [J]', SteamCoil(CoilNum)%TotSteamHeatingCoilEnergy, &
'System','Sum',SteamCoil(CoilNum)%Name, &
ResourceTypeKey='ENERGYTRANSFER',EndUseKey='HEATINGCOILS',GroupKey='System')
CALL SetupOutputVariable('Heating Coil Heating Rate [W]', SteamCoil(CoilNum)%TotSteamHeatingCoilRate, &
'System','Average',SteamCoil(CoilNum)%Name)
CALL SetupOutputVariable('Heating Coil Steam Mass Flow Rate [Kg/s]', SteamCoil(CoilNum)%OutletSteamMassFlowRate, &
'System','Average',SteamCoil(CoilNum)%Name)
CALL SetupOutputVariable('Heating Coil Steam Inlet Temperature [C]', SteamCoil(CoilNum)%InletSteamTemp, &
'System','Average',SteamCoil(CoilNum)%Name)
CALL SetupOutputVariable('Heating Coil Steam Outlet Temperature [C]', SteamCoil(CoilNum)%OutletSteamTemp, &
'System','Average',SteamCoil(CoilNum)%Name)
CALL SetupOutputVariable('Heating Coil Steam Trap Loss Rate [W]', SteamCoil(CoilNum)%LoopLoss, &
'System','Average',SteamCoil(CoilNum)%Name)
END DO
IF (ErrorsFound) THEN
CALL ShowFatalError(RoutineName//'Errors found in getting input.')
ENDIF
DEALLOCATE(AlphArray)
DEALLOCATE(cAlphaFields)
DEALLOCATE(cNumericFields)
DEALLOCATE(NumArray)
DEALLOCATE(lAlphaBlanks)
DEALLOCATE(lNumericBlanks)
RETURN
END SUBROUTINE GetSteamCoilInput