SUBROUTINE GetFurnaceInput
! SUBROUTINE INFORMATION:
! AUTHOR Richard Liesen
! DATE WRITTEN Feb 2001
! MODIFIED Don Shirey and Rich Raustad, Mar/Oct 2001, Mar 2003
! Bereket Nigusse, April 2010 - deprecated supply air flow fraction through
! controlled zone from the input field.
! Bo Shen, March 2012, add inputs for VS WSHP,
! Bo Shen, ORNL, July 2012 - added variable-speed air source heat pump cooling and heating coils, using curve-fits
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Obtains input data for fans and coils and stores it in the Furnace data structures
! METHODOLOGY EMPLOYED:
! Uses "Get" routines to read in data.
! REFERENCES:
! USE STATEMENTS:
USE InputProcessor, ONLY: GetNumObjectsFound, GetObjectItem, VerifyName, SameString, FindItemInList, &
GetObjectDefMaxArgs
USE NodeInputManager, ONLY: GetOnlySingleNode
USE DataLoopNode, ONLY: NodeID
USE DataHeatBalance, ONLY: Zone
USE BranchNodeConnections, ONLY: SetUpCompSets, TestCompSet
USE DataAirSystems, ONLY: PrimaryAirSystem
USE DataZoneControls, ONLY: TempControlledZone, NumTempControlledZones, HumidityControlZone, &
NumHumidityControlZones, ComfortControlledZone, NumComfortControlledZones
USE WaterToAirHeatPumpSimple, ONLY: GetWtoAHPSimpleCoilCapacity=>GetCoilCapacity, &
GetWtoAHPSimpleCoilInletNode=>GetCoilInletNode, &
GetWtoAHPSimpleCoilOutletNode=>GetCoilOutletNode, &
GetWtoAHPSimpleCoilIndex=>GetCoilIndex, &
SetSimpleWSHPData, GetWtoAHPSimpleCoilAirFlow=>GetCoilAirFlowRate
USE VariableSpeedCoils, ONLY: GetCoilCapacityVariableSpeed, &
GetCoilInletNodeVariableSpeed, &
GetCoilOutletNodeVariableSpeed, &
GetCoilIndexVariableSpeed, &
GetCoilAirFlowRateVariableSpeed,&
SetVarSpeedCoilData, GetVSCoilCondenserInletNode, &
GetVSCoilMinOATCompressor
USE WaterToAirHeatPump, ONLY: GetWtoAHPCoilCapacity=>GetCoilCapacity, &
GetWtoAHPCoilInletNode=>GetCoilInletNode, &
GetWtoAHPCoilOutletNode=>GetCoilOutletNode,GetWtoAHPCoilIndex=>GetCoilIndex
USE HeatingCoils, ONLY: GetHeatingCoilCapacity=>GetCoilCapacity,GetHeatingCoilInletNode=>GetCoilInletNode, &
GetHeatingCoilOutletNode=>GetCoilOutletNode, GetHeatingCoilIndex=>GetCoilIndex, &
GetHeatingCoilTypeNum, GetHeatingCoilPLFCurveIndex
USE DXCoils, ONLY: GetDXCoilCapacity=>GetCoilCapacity,GetMinOATDXCoilCompressor=>GetMinOATCompressor, &
GetDXCoilInletNode=>GetCoilInletNode, GetDXCoilOutletNode=>GetCoilOutletNode, &
GetDXCoilCondenserInletNode=>GetCoilCondenserInletNode,GetDXCoilIndex, &
GetDXCoilTypeNum=>GetCoilTypeNum, SetDXCoolingCoilData
USE HVACHXAssistedCoolingCoil, ONLY: GetDXHXAsstdCoilCapacity=>GetCoilCapacity,GetDXHXAsstdCoilInletNode=>GetCoilInletNode, &
GetDXHXAsstdCoilOutletNode=>GetCoilOutletNode,GetHXDXCoilName,GetHXDXCoilIndex, &
GetHXAssistedCoilTypeNum=>GetCoilGroupTypeNum, GetActualDXCoilIndex
USE WaterCoils, ONLY: GetCoilWaterInletNode, GetCoilMaxWaterFlowRate, &
GetWaterCoilInletNode=>GetCoilInletNode,GetWaterCoilOutletNode=>GetCoilOutletNode
USE SteamCoils, ONLY: GetSteamCoilAirInletNode=>GetCoilAirInletNode, GetSteamCoilIndex, &
GetSteamCoilAirOutletNode=>GetCoilAirOutletNode, &
GetSteamCoilSteamInletNode=>GetCoilSteamInletNode, &
GetCoilMaxSteamFlowRate=>GetCoilMaxSteamFlowRate, GetTypeOfCoil, ZoneLoadControl
USE Fans, ONLY: GetFanDesignVolumeFlowRate,GetFanInletNode,GetFanOutletNode,GetFanIndex, &
GetFanAvailSchPtr, GetFanType
USE FluidProperties, ONLY: GetSatDensityRefrig
USE General, ONLY: RoundSigDigits, TrimSigDigits
USE DataSizing, ONLY: AutoSize
USE OutAirNodeManager, ONLY: CheckOutAirNodeNumber
USE DataIPShortCuts
USE EMSManager, ONLY: ManageEMS
USE HVACControllers, ONLY: CheckCoilWaterInletNode
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
! na
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: FurnaceNum ! The Furnace that you are currently loading input into
INTEGER :: GetObjectNum ! The index to each specific object name
INTEGER :: NumFields ! Total number of fields in object
INTEGER :: NumAlphas ! Total number of alpha fields in object
INTEGER :: MaxAlphas ! Maximum number of alpha fields in all objects
INTEGER :: NumNumbers ! Total number of numeric fields in object
INTEGER :: MaxNumbers ! Maximum number of numeric fields in all objects
INTEGER :: IOStatus ! Function call status
REAL(r64), ALLOCATABLE, DIMENSION(:) :: Numbers ! Numeric data
CHARACTER(len=MaxNameLength), ALLOCATABLE, DIMENSION(:) :: Alphas ! Alpha data
CHARACTER(Len=MaxNameLength), ALLOCATABLE, DIMENSION(:) :: cAlphaFields ! Alpha field names
CHARACTER(Len=MaxNameLength), ALLOCATABLE, DIMENSION(:) :: cNumericFields ! Numeric field names
LOGICAL, ALLOCATABLE, DIMENSION(:) :: lAlphaBlanks ! Logical array, alpha field input BLANK = .TRUE.
LOGICAL, ALLOCATABLE, DIMENSION(:) :: lNumericBlanks ! Logical array, numeric field input BLANK = .TRUE.
CHARACTER(len=MaxNameLength) :: CompSetFanInlet, CompSetFanOutlet, CompSetCoolInlet, CompSetHeatInlet, CompSetHeatOutlet
CHARACTER(len=MaxNameLength) :: CurrentModuleObject ! Object type for getting and error messages
LOGICAL :: ErrorsFound = .FALSE. ! If errors detected in input
LOGICAL :: IsNotOK ! Flag to verify name
LOGICAL :: IsBlank ! Flag for blank name
Integer :: NumHeatOnly ! Number of heat only furnaces
Integer :: NumHeatCool ! Number of heat/cool furnaces
Integer :: HeatOnlyNum ! Index to heat only furnaces
Integer :: HeatCoolNum ! Index to heat/cool furnaces
Integer :: NumUnitaryHeatOnly ! Number of heat only unitary systems
Integer :: NumUnitaryHeatCool ! Number of heat/cool unitary systems
Integer :: UnitaryHeatOnlyNum ! Index to heat only furnaces
Integer :: UnitaryHeatCoolNum ! Index to heat/cool unitary systems
Integer :: NumWaterToAirHeatPump ! Number of water-to-air heat pumps
Integer :: NumHeatPump ! Number of air-to-air or water-to-air heat pumps
Integer :: HeatPumpNum ! Index to air-to-air heat pumps
Integer :: ControlledZoneNum ! Index to controlled zones
LOGICAL :: AirNodeFound ! Used to determine if control zone is valid
LOGICAL :: AirLoopFound ! Used to determine if control zone is served by furnace air loop
INTEGER :: AirLoopNumber ! Used to determine if control zone is served by furnace air loop
INTEGER :: BranchNum ! Used to determine if control zone is served by furnace air loop
INTEGER :: CompNum ! Used to determine if control zone is served by furnace air loop
INTEGER :: TstatZoneNum ! Used to determine if control zone has a thermostat object
INTEGER :: HstatZoneNum ! Used to determine if control zone has a humidistat object
LOGICAL :: ErrFlag ! Mining function error flag
INTEGER :: FanInletNode ! Used for node checking warning messages
INTEGER :: FanOutletNode ! Used for node checking warning messages
INTEGER :: CoolingCoilInletNode ! Used for node checking warning messages
INTEGER :: CoolingCoilOutletNode ! Used for node checking warning messages
INTEGER :: HeatingCoilInletNode ! Used for node checking warning messages
INTEGER :: HeatingCoilOutletNode ! Used for node checking warning messages
INTEGER :: SupHeatCoilInletNode ! Used for node checking warning messages
INTEGER :: SupHeatCoilOutletNode ! Used for node checking warning messages
INTEGER :: ReHeatCoilInletNode ! Used for node checking warning messages
INTEGER :: ReHeatCoilOutletNode ! Used for node checking warning messages
REAL(r64) :: FanVolFlowRate ! Fan Max Flow Rate from Fan object (for comparisons to validity)
INTEGER :: FurnaceType_Num ! Integer equivalent of Furnace or UnitarySystem "type"
CHARACTER(len=MaxNameLength) :: CoolingCoilType ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: CoolingCoilName ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: HeatingCoilType ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: HeatingCoilName ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: ReheatingCoilType ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: ReheatingCoilName ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: SuppHeatCoilType ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: SuppHeatCoilName ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: FanType ! Used in mining function CALLS
CHARACTER(len=MaxNameLength) :: FanName ! Used in mining function CALLS
LOGICAL :: PrintMessage ! Used in mining function CALLS
INTEGER :: TotalZonesOnAirLoop ! number of zones attached to air loop
INTEGER :: HeatingCoilPLFCurveIndex ! index of heating coil PLF curve
INTEGER :: SteamIndex ! steam coil index
REAL(r64) :: SteamDensity ! density of steam at 100C
INTEGER :: DXCoilIndex ! Index to DX coil in HXAssited object
! Flow
MaxNumbers=0
MaxAlphas=0
CurrentModuleObject = 'AirLoopHVAC:Unitary:Furnace:HeatOnly'
NumHeatOnly = GetNumObjectsFound(CurrentModuleObject)
CALL GetObjectDefMaxArgs(CurrentModuleObject,NumFields,NumAlphas,NumNumbers)
MaxNumbers=MAX(MaxNumbers,NumNumbers)
MaxAlphas=MAX(MaxAlphas,NumAlphas)
CurrentModuleObject = 'AirLoopHVAC:Unitary:Furnace:HeatCool'
NumHeatCool = GetNumObjectsFound(CurrentModuleObject)
CALL GetObjectDefMaxArgs(CurrentModuleObject,NumFields,NumAlphas,NumNumbers)
MaxNumbers=MAX(MaxNumbers,NumNumbers)
MaxAlphas=MAX(MaxAlphas,NumAlphas)
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatOnly'
NumUnitaryHeatOnly = GetNumObjectsFound(CurrentModuleObject)
CALL GetObjectDefMaxArgs(CurrentModuleObject,NumFields,NumAlphas,NumNumbers)
MaxNumbers=MAX(MaxNumbers,NumNumbers)
MaxAlphas=MAX(MaxAlphas,NumAlphas)
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatCool'
NumUnitaryHeatCool = GetNumObjectsFound(CurrentModuleObject)
CALL GetObjectDefMaxArgs(CurrentModuleObject,NumFields,NumAlphas,NumNumbers)
MaxNumbers=MAX(MaxNumbers,NumNumbers)
MaxAlphas=MAX(MaxAlphas,NumAlphas)
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatPump:AirToAir'
NumHeatPump = GetNumObjectsFound(CurrentModuleObject)
CALL GetObjectDefMaxArgs(CurrentModuleObject,NumFields,NumAlphas,NumNumbers)
MaxNumbers=MAX(MaxNumbers,NumNumbers)
MaxAlphas=MAX(MaxAlphas,NumAlphas)
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatPump:WaterToAir'
NumWaterToAirHeatPump = GetNumObjectsFound(CurrentModuleObject)
CALL GetObjectDefMaxArgs(CurrentModuleObject,NumFields,NumAlphas,NumNumbers)
MaxNumbers=MAX(MaxNumbers,NumNumbers)
MaxAlphas=MAX(MaxAlphas,NumAlphas)
ALLOCATE(Alphas(MaxAlphas))
Alphas=' '
ALLOCATE(Numbers(MaxNumbers))
Numbers=0.0d0
ALLOCATE(cAlphaFields(MaxAlphas))
cAlphaFields=' '
ALLOCATE(cNumericFields(MaxNumbers))
cNumericFields=' '
ALLOCATE(lAlphaBlanks(MaxAlphas))
lAlphaBlanks=.TRUE.
ALLOCATE(lNumericBlanks(MaxNumbers))
lNumericBlanks=.TRUE.
NumFurnaces = NumHeatOnly + NumHeatCool + NumUnitaryHeatOnly + NumUnitaryHeatCool + NumHeatPump + NumWaterToAirHeatPump
IF (NumFurnaces.GT.0) THEN
ALLOCATE(Furnace(NumFurnaces))
ENDIF
ALLOCATE(CheckEquipName(NumFurnaces))
CheckEquipName=.true.
! Get the data for the HeatOnly Furnace
DO HeatOnlyNum = 1, NumHeatOnly + NumUnitaryHeatOnly
FanInletNode = 0
FanOutletNode = 0
FanVolFlowRate = 0.0d0
HeatingCoilInletNode = 0
HeatingCoilOutletNode = 0
! Furnace and UnitarySystem objects are both read in here.
! Will still have 2 differently named objects for the user, but read in with 1 DO loop.
IF(HeatOnlyNum .LE. NumHeatOnly) THEN
CurrentModuleObject = 'AirLoopHVAC:Unitary:Furnace:HeatOnly'
FurnaceType_Num = Furnace_HeatOnly
GetObjectNum = HeatOnlyNum
ELSE
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatOnly'
FurnaceType_Num = UnitarySys_HeatOnly
GetObjectNum = HeatOnlyNum - NumHeatOnly
END IF
FurnaceNum = HeatOnlyNum
Furnace(FurnaceNum)%FurnaceType_Num = FurnaceType_Num
CALL GetObjectItem(CurrentModuleObject,GetObjectNum,Alphas,NumAlphas,Numbers,NumNumbers,IOStatus, &
NumBlank=lNumericBlanks,AlphaBlank=lAlphaBlanks, &
AlphaFieldNames=cAlphaFields,NumericFieldNames=cNumericFields)
IsNotOK=.FALSE.
IsBlank=.FALSE.
CALL VerifyName(Alphas(1),Furnace%Name,FurnaceNum-1,IsNotOK,IsBlank,TRIM(CurrentModuleObject)//' Name')
IF (IsNotOK) THEN
ErrorsFound=.TRUE.
IF (IsBlank) Alphas(1)='xxxxx'
ENDIF
Furnace(FurnaceNum)%Name = Alphas(1)
IF (lAlphaBlanks(2)) THEN
Furnace(FurnaceNum)%SchedPtr = ScheduleAlwaysOn
ELSE
Furnace(FurnaceNum)%SchedPtr = GetScheduleIndex(Alphas(2))
IF (Furnace(FurnaceNum)%SchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(2))//' = '//TRIM(Alphas(2)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
Furnace(FurnaceNum)%FurnaceInletNodeNum = &
GetOnlySingleNode(Alphas(3),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_Inlet,1,ObjectIsParent)
Furnace(FurnaceNum)%FurnaceOutletNodeNum = &
GetOnlySingleNode(Alphas(4),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_Outlet,1,ObjectIsParent)
CALL TestCompSet(CurrentModuleObject,Alphas(1),Alphas(3),Alphas(4),'Air Nodes')
Furnace(FurnaceNum)%FanSchedPtr = GetScheduleIndex(Alphas(5))
IF (.NOT. lAlphaBlanks(5) .AND. Furnace(FurnaceNum)%FanSchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ELSEIF (lAlphaBlanks(5)) THEN
Furnace(FurnaceNum)%OpMode = CycFanCycCoil
ENDIF
!Get the Controlling Zone or Location of the Furnace Thermostat
Furnace(FurnaceNum)%ControlZoneNum = FindItemInList(Alphas(6),Zone%Name,NumOfZones)
IF (Furnace(FurnaceNum)%ControlZoneNum == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
ENDIF
TotalZonesOnAirLoop = 0
! Get the node number for the zone with the thermostat
IF (Furnace(FurnaceNum)%ControlZoneNum > 0) THEN
AirNodeFound=.FALSE.
AirLoopFound=.FALSE.
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%ActualZoneNum /= Furnace(FurnaceNum)%ControlZoneNum) CYCLE
! Find the controlled zone number for the specified thermostat location
Furnace(FurnaceNum)%NodeNumofControlledZone=ZoneEquipConfig(ControlledZoneNum)%ZoneNode
! Determine if furnace is on air loop served by the thermostat location specified
AirLoopNumber = ZoneEquipConfig(ControlledZoneNum)%AirLoopNum
IF(AirLoopNumber .GT. 0)THEN
DO BranchNum = 1, PrimaryAirSystem(AirLoopNumber)%NumBranches
DO CompNum = 1, PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%TotalComponents
IF(.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%Name, &
Furnace(FurnaceNum)%Name) .OR. &
.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%TypeOf, &
CurrentModuleObject))CYCLE
AirLoopFound=.TRUE.
EXIT
END DO
IF(AirLoopFound)EXIT
END DO
DO TstatZoneNum = 1, NumTempControlledZones
IF(TempControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
DO TstatZoneNum = 1, NumComfortControlledZones
IF(ComfortControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find an AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
END IF
EXIT
ENDDO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowSevereError('Did not find Air Node (Zone with Thermostat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
CALL ShowContinueError('Both a ZoneHVAC:EquipmentConnections object and a ZoneControl:Thermostat object' &
//' must be specified for this zone.')
ErrorsFound=.TRUE.
ENDIF
IF (.not. AirLoopFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowSevereError('Did not find correct Primary Air Loop.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6))//&
' is not served by this AirLoopHVAC equipment.')
ErrorsFound=.TRUE.
ENDIF
IF(AirLoopNumber .GT. 0)THEN
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%AirLoopNum == AirLoopNumber) THEN
TotalZonesOnAirLoop = TotalZonesOnAirLoop + 1
END IF
END DO
END IF
ENDIF
!Get fan data
FanType = Alphas(7)
FanName = Alphas(8)
ErrFlag=.FALSE.
CALL GetFanType(FanName, Furnace(FurnaceNum)%FanType_Num, ErrFlag, &
CurrentModuleObject,Alphas(1))
IF (ErrFlag) THEN
ErrorsFound=.TRUE.
END IF
IF (Furnace(FurnaceNum)%FanType_Num == FanType_SimpleOnOff .OR. &
Furnace(FurnaceNum)%FanType_Num == FanType_SimpleConstVolume)THEN
CALL ValidateComponent(FanType,FanName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from fan object
! Get the fan index
ErrFlag=.FALSE.
CALL GetFanIndex(FanName, Furnace(FurnaceNum)%FanIndex, ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
!Set the Design Fan Volume Flow Rate
ErrFlag=.FALSE.
FanVolFlowRate = GetFanDesignVolumeFlowRate(FanType,FanName,ErrFlag)
Furnace(FurnaceNum)%ActualFanVolFlowRate = FanVolFlowRate
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' ='//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Fan Inlet Node
ErrFlag=.FALSE.
FanInletNode = GetFanInletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Fan Outlet Node
ErrFlag=.FALSE.
FanOutletNode = GetFanOutletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the fan's availabitlity schedule
ErrFlag=.FALSE.
Furnace(FurnaceNum)%FanAvailSchedPtr = GetFanAvailSchPtr(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Check fan's schedule for cycling fan operation if constant volume fan is used
IF(Furnace(FurnaceNum)%FanSchedPtr .GT. 0 .AND. Furnace(FurnaceNum)%FanType_Num == FanType_SimpleConstVolume)THEN
IF (.NOT. CheckScheduleValueMinMax(Furnace(FurnaceNum)%FanSchedPtr,'>',0.0d0,'<=',1.0d0)) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('For '//TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
CALL ShowContinueError('Fan operating mode must be continuous (fan operating mode schedule values > 0).')
CALL ShowContinueError('Error found in '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
CALL ShowContinueError('...schedule values must be (>0., <=1.)')
ErrorsFound=.TRUE.
END IF
ELSE IF(lAlphaBlanks(5) .AND. Furnace(FurnaceNum)%FanType_Num /= FanType_SimpleOnOff)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
CALL ShowContinueError(TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
CALL ShowContinueError('Fan type must be Fan:OnOff when '// &
TRIM(cAlphaFields(5))//' = Blank.')
ErrorsFound=.TRUE.
END IF
ENDIF ! IF (IsNotOK) THEN
ELSE ! wrong fan type
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
ErrorsFound=.TRUE.
END IF ! IF (Furnace(FurnaceNum)%FanType_Num == FanType_SimpleOnOff .OR. &
IF (SameString(Alphas(9),'BlowThrough') ) &
Furnace(FurnaceNum)%FanPlace = BlowThru
IF (SameString(Alphas(9),'DrawThrough') ) &
Furnace(FurnaceNum)%FanPlace = DrawThru
IF (Furnace(FurnaceNum)%FanPlace .EQ.0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(9))//' = '//TRIM(Alphas(9)))
ErrorsFound = .TRUE.
END IF
!Get coil data
HeatingCoilType = Alphas(10)
HeatingCoilName = Alphas(11)
Furnace(FurnaceNum)%HeatingCoilType = HeatingCoilType
Furnace(FurnaceNum)%HeatingCoilName = HeatingCoilName
IF (SameString(HeatingCoilType,'Coil:Heating:Gas') .OR. &
SameString(HeatingCoilType,'Coil:Heating:Electric')) THEN
ErrFlag = .FALSE.
Furnace(FurnaceNum)%HeatingCoilType_Num = GetHeatingCoilTypeNum(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
! Get index to Heating Coil
ErrFlag=.FALSE.
CALL GetHeatingCoilIndex(HeatingCoilName,Furnace(FurnaceNum)%HeatingCoilIndex,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the furnace design capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = &
GetHeatingCoilCapacity(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' ='//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Heating Coil Inlet Node
ErrFlag=.FALSE.
HeatingCoilInletNode = &
GetHeatingCoilInletNode(HeatingCoilType,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirInletNode = HeatingCoilInletNode
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' ='//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Heating Coil Outlet Node
ErrFlag=.FALSE.
HeatingCoilOutletNode = &
GetHeatingCoilOutletNode(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' ='//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ENDIF
ELSEIF (SameString(HeatingCoilType,'Coil:Heating:Water')) THEN
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingWater
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
! Get the Heating Coil water Inlet or control Node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoilControlNode = GetCoilWaterInletNode('Coil:Heating:Water',HeatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil hot water max volume flow rate
ErrFlag = .FALSE.
Furnace(FurnaceNum)%MaxHeatCoilFluidFlow = GetCoilMaxWaterFlowRate('Coil:Heating:Water', &
HeatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
HeatingCoilInletNode = GetWaterCoilInletNode('Coil:Heating:Water',HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirInletNode = HeatingCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
HeatingCoilOutletNode = GetWaterCoilOutletNode('Coil:Heating:Water',HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirOutletNode = HeatingCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! check if user has also used a water coil controller, which they should not do
ErrFlag = .FALSE.
CALL CheckCoilWaterInletNode(Furnace(FurnaceNum)%CoilControlNode, ErrFlag)
IF (.NOT. ErrFlag) THEN ! then did find a controller so that is bad
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name) &
//' has a conflicting Controller:WaterCoil object' )
CALL ShowContinueError('Hot water coils are controlled directly by unitary and furnace systems.')
CALL ShowContinueError('No water coil controller should be input for the coil.')
ErrorsFound = .TRUE.
ENDIF
ENDIF
ELSEIF (SameString(HeatingCoilType,'Coil:Heating:Steam')) THEN
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingSteam
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
ErrFlag = .FALSE.
Furnace(FurnaceNum)%HeatingCoilIndex = GetSTeamCoilIndex('COIL:HEATING:STEAM',HeatingCoilName,ErrFlag)
IF (Furnace(FurnaceNum)%HeatingCoilIndex .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' illegal '//TRIM(cAlphaFields(11))//' = ' &
//TRIM(HeatingCoilName))
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam inlet node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoilControlNode = GetSteamCoilSteamInletNode('COIL:HEATING:STEAM',HeatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam max volume flow rate
Furnace(FurnaceNum)%MaxHeatCoilFluidFlow = GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%HeatingCoilIndex,ErrFlag)
IF (Furnace(FurnaceNum)%MaxHeatCoilFluidFlow .GT. 0.0d0)THEN
SteamIndex = 0 ! Function GetSatDensityRefrig will look up steam index if 0 is passed
SteamDensity=GetSatDensityRefrig("STEAM",TempSteamIn,1.0d0,SteamIndex,'GetUnitaryHeatOnly')
Furnace(FurnaceNum)%MaxHeatCoilFluidFlow = Furnace(FurnaceNum)%MaxHeatCoilFluidFlow * SteamDensity
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
HeatingCoilInletNode = &
GetSteamCoilAirInletNode(Furnace(FurnaceNum)%HeatingCoilIndex,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirInletNode = HeatingCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
HeatingCoilOutletNode = &
GetSteamCoilAirOutletNode(Furnace(FurnaceNum)%HeatingCoilIndex,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirOutletNode = HeatingCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(11))//' = '//TRIM(Alphas(11)))
ErrorsFound=.TRUE.
END IF ! IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingGas .OR. &, etc.
! Add component sets array
IF (Furnace(FurnaceNum)%FanPlace == BlowThru) THEN
CompSetFanInlet = Alphas(3)
CompSetFanOutlet = NodeID(FanOutletNode)
CompSetHeatInlet = NodeID(FanOutletNode)
CompSetHeatOutlet = Alphas(4)
! Fan inlet node name must not be the same as the furnace inlet node name
IF (FanInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatOnly)THEN
CALL ShowContinueError('When a blow through fan is specified, '//&
'the fan inlet node name must be the same as the furnace inlet node name.')
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
CALL ShowContinueError('...Furnace inlet node name = '//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ELSE
CALL ShowContinueError('When a blow through fan is specified, '//&
'the fan inlet node name must be the same as the unitary system inlet node name.')
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
CALL ShowContinueError('...Unitary System inlet node name = '//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
! Fan outlet node name must be the same as the heating coil inlet node name
IF (FanOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a blow through fan is specified, '//&
'the fan outlet node name must be the same as the heating coil inlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
! Heating coil outlet node name must be the same as the furnace outlet node name
IF (HeatingCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatOnly)THEN
CALL ShowContinueError('When a blow through fan is specified, '//&
'the heating coil outlet node name must be the same as the furnace outlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('When a blow through fan is specified, '//&
'the heating coil outlet node name must be the same as the unitary system outlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
ELSE ! draw through fan
CompSetHeatInlet = Alphas(3)
CompSetHeatOutlet = NodeID(FanInletNode)
CompSetFanInlet = NodeID(FanInletNode)
CompSetFanOutlet = Alphas(4)
! Heating coil inlet node name must not be the same as the furnace inlet node name
IF (HeatingCoilInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatOnly)THEN
CALL ShowContinueError('When a draw through fan is specified, '//&
'the heating coil inlet node name must be the same as the furnace inlet node name.')
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
CALL ShowContinueError('...Furnace inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ELSE
CALL ShowContinueError('When a draw through fan is specified, '//&
'the heating coil inlet node name must be the same as the unitary system inlet node name.')
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
CALL ShowContinueError('...UnitarySystem inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
! Heating coil outlet node name must be the same as the fan inlet node name
IF (HeatingCoilOutletNode /= FanInletNode) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a draw through fan is specified, '//&
'the heating coil outlet node name must be the same as the fan inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
ErrorsFound=.TRUE.
END IF
! Fan coil outlet node name must be the same as the furnace outlet node name
IF (FanOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatOnly)THEN
CALL ShowContinueError('When a draw through fan is specified, '//&
'the fan outlet node name must be the same as the furnace outlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('When a draw through fan is specified, '//&
'the fan outlet node name must be the same as the unitary system outlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
ENDIF
! Add fan to component sets array
CALL SetUpCompSets(CurrentModuleObject, Furnace(FurnaceNum)%Name, &
Alphas(7),Alphas(8),CompSetFanInlet,CompSetFanOutlet)
! Add heating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Furnace(FurnaceNum)%Name, &
Alphas(10),Alphas(11),CompSetHeatInlet,CompSetHeatOutlet)
! Set the furnace max outlet temperature
Furnace(FurnaceNum)%DesignMaxOutletTemp = Numbers(1)
! Set the furnace design fan volumetric flow rate
Furnace(FurnaceNum)%DesignFanVolFlowRate = Numbers(2)
! Compare the flow rates.
IF (FanVolFlowRate /= AutoSize .and. Furnace(FurnaceNum)%DesignFanVolFlowRate /= AutoSize) THEN
IF (Furnace(FurnaceNum)%DesignFanVolFlowRate > FanVolFlowRate) THEN
CALL ShowWarningError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... The '//TRIM(cNumericFields(2))//' > Max Volume Flow Rate defined '// &
'in the associated fan object, should be <=.')
CALL ShowContinueError('... Entered value = '//TRIM(RoundSigDigits(Furnace(FurnaceNum)%DesignFanVolFlowRate,4))// &
'... Fan ['//TRIM(FanType)//' = '//TRIM(FanName)// &
'] Max Value = '//TRIM(RoundSigDigits(FanVolFlowRate,4)))
CALL ShowContinueError(' The HVAC system flow rate is reset to the' &
//' fan flow rate and the simulation continues.')
Furnace(FurnaceNum)%DesignFanVolFlowRate = FanVolFlowRate
ENDIF
ENDIF
IF (Furnace(FurnaceNum)%DesignFanVolFlowRate /= AutoSize) THEN
IF (Furnace(FurnaceNum)%DesignFanVolFlowRate <= 0.0d0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... The '//TRIM(cNumericFields(2))//' <= 0.0, it must be > 0.0.')
CALL ShowContinueError('... Entered value = '//TRIM(RoundSigDigits(Furnace(FurnaceNum)%DesignFanVolFlowRate,2)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
! HeatOnly furnace has only 1 flow rate, initialize other variables used in this module
Furnace(FurnaceNum)%MaxHeatAirVolFlow = Furnace(FurnaceNum)%DesignFanVolFlowRate
Furnace(FurnaceNum)%MaxCoolAirVolFlow = Furnace(FurnaceNum)%DesignFanVolFlowRate
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow = Furnace(FurnaceNum)%DesignFanVolFlowRate
Furnace(FurnaceNum)%AirFlowControl = UseCompressorOnFlow
!Set heating convergence tolerance
Furnace(FurnaceNum)%HeatingConvergenceTolerance = 0.001d0
END DO !End of the HeatOnly Furnace Loop
! Get the data for the HeatCool Furnace or UnitarySystem
DO HeatCoolNum = 1, NumHeatCool + NumUnitaryHeatCool
FanInletNode = 0
FanOutletNode = 0
FanVolFlowRate = 0.0d0
CoolingCoilInletNode = 0
CoolingCoilOutletNode = 0
HeatingCoilInletNode = 0
HeatingCoilOutletNode = 0
ReHeatCoilInletNode = 0
ReHeatCoilOutletNode = 0
! Furnace and UnitarySystem objects are both read in here.
! Will still have 2 differently named objects for the user, but read in with 1 DO loop.
IF(HeatCoolNum .LE. NumHeatCool) THEN
CurrentModuleObject = 'AirLoopHVAC:Unitary:Furnace:HeatCool'
FurnaceType_Num = Furnace_HeatCool
GetObjectNum = HeatCoolNum
ELSE
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatCool'
FurnaceType_Num = UnitarySys_HeatCool
GetObjectNum = HeatCoolNum - NumHeatCool
END IF
FurnaceNum = HeatCoolNum + NumHeatOnly + NumUnitaryHeatOnly
Furnace(FurnaceNum)%FurnaceType_Num = FurnaceType_Num
CALL GetObjectItem(CurrentModuleObject,GetObjectNum,Alphas,NumAlphas,Numbers,NumNumbers,IOStatus, &
NumBlank=lNumericBlanks,AlphaBlank=lAlphaBlanks, &
AlphaFieldNames=cAlphaFields,NumericFieldNames=cNumericFields)
IsNotOK=.FALSE.
IsBlank=.FALSE.
CALL VerifyName(Alphas(1),Furnace%Name,FurnaceNum-1,IsNotOK,IsBlank,TRIM(CurrentModuleObject)//' Name')
IF (IsNotOK) THEN
ErrorsFound=.TRUE.
IF (IsBlank) Alphas(1)='xxxxx'
ENDIF
Furnace(FurnaceNum)%Name = Alphas(1)
IF (lAlphaBlanks(2)) THEN
Furnace(FurnaceNum)%SchedPtr = ScheduleAlwaysOn
ELSE
Furnace(FurnaceNum)%SchedPtr = GetScheduleIndex(Alphas(2))
IF (Furnace(FurnaceNum)%SchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(2))//' = '//TRIM(Alphas(2)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
Furnace(FurnaceNum)%FurnaceInletNodeNum = &
GetOnlySingleNode(Alphas(3),ErrorsFound,CurrentModuleObject,Alphas(1), &
NodeType_Air,NodeConnectionType_Inlet,1,ObjectIsParent)
Furnace(FurnaceNum)%FurnaceOutletNodeNum = &
GetOnlySingleNode(Alphas(4),ErrorsFound,CurrentModuleObject,Alphas(1), &
NodeType_Air,NodeConnectionType_Outlet,1,ObjectIsParent)
CALL TestCompSet(CurrentModuleObject,Alphas(1),Alphas(3),Alphas(4),'Air Nodes')
Furnace(FurnaceNum)%FanSchedPtr = GetScheduleIndex(Alphas(5))
IF (.NOT. lAlphaBlanks(5) .AND. Furnace(FurnaceNum)%FanSchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ELSEIF (lAlphaBlanks(5)) THEN
Furnace(FurnaceNum)%OpMode = CycFanCycCoil
ENDIF
!Get the Controlling Zone or Location of the Furnace Thermostat
Furnace(FurnaceNum)%ControlZoneNum = FindItemInList(Alphas(6),Zone%Name,NumOfZones)
IF (Furnace(FurnaceNum)%ControlZoneNum == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
ENDIF
TotalZonesOnAirLoop = 0
! Get the node number for the zone with the thermostat
IF (Furnace(FurnaceNum)%ControlZoneNum > 0) THEN
AirNodeFound=.FALSE.
AirLoopFound=.FALSE.
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%ActualZoneNum /= Furnace(FurnaceNum)%ControlZoneNum) CYCLE
! Find the controlled zone number for the specified thermostat location
Furnace(FurnaceNum)%NodeNumofControlledZone=ZoneEquipConfig(ControlledZoneNum)%ZoneNode
! Determine if system is on air loop served by the thermostat location specified
AirLoopNumber = ZoneEquipConfig(ControlledZoneNum)%AirLoopNum
IF(AirLoopNumber .GT. 0)THEN
DO BranchNum = 1, PrimaryAirSystem(AirLoopNumber)%NumBranches
DO CompNum = 1, PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%TotalComponents
IF(.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%Name, &
Alphas(1)) .OR. &
.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%TypeOf, &
CurrentModuleObject))CYCLE
AirLoopFound=.TRUE.
EXIT
END DO
IF(AirLoopFound)EXIT
END DO
DO TstatZoneNum = 1, NumTempControlledZones
IF(TempControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
DO TstatZoneNum = 1, NumComfortControlledZones
IF(ComfortControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find an AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
END IF
EXIT
ENDDO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find air node (zone with thermostat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
CALL ShowContinueError('Both a ZoneHVAC:EquipmentConnections object and a ZoneControl:Thermostat object' &
//' must be specified for this zone.')
ErrorsFound=.TRUE.
ENDIF
IF (.not. AirLoopFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowSevereError('Did not find correct AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
ENDIF
IF(AirLoopNumber .GT. 0)THEN
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%AirLoopNum == AirLoopNumber) THEN
TotalZonesOnAirLoop = TotalZonesOnAirLoop + 1
END IF
END DO
END IF
ENDIF
!Get fan data
FanType = Alphas(7)
FanName = Alphas(8)
ErrFlag=.FALSE.
CALL GetFanType(FanName, Furnace(FurnaceNum)%FanType_Num, ErrFlag, &
CurrentModuleObject,Alphas(1))
IF (ErrFlag) THEN
ErrorsFound=.TRUE.
END IF
IF (Furnace(FurnaceNum)%FanType_Num == FanType_SimpleOnOff .OR. &
Furnace(FurnaceNum)%FanType_Num == FanType_SimpleConstVolume)THEN
CALL ValidateComponent(FanType,FanName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('In Furnace='//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from fan object
! Get the fan index
ErrFlag=.FALSE.
CALL GetFanIndex(FanName, Furnace(FurnaceNum)%FanIndex, ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Design Fan Volume Flow Rate
ErrFlag=.FALSE.
FanVolFlowRate = GetFanDesignVolumeFlowRate(FanType,FanName,ErrFlag)
Furnace(FurnaceNum)%ActualFanVolFlowRate = FanVolFlowRate
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ENDIF
! Get the Fan Inlet Node
ErrFlag=.FALSE.
FanInletNode = GetFanInletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Fan Outlet Node
ErrFlag=.FALSE.
FanOutletNode = GetFanOutletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the fan's availability schedule
ErrFlag=.FALSE.
Furnace(FurnaceNum)%FanAvailSchedPtr = GetFanAvailSchPtr(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Check fan's schedule for cycling fan operation if constant volume fan is used
IF(Furnace(FurnaceNum)%FanSchedPtr .GT. 0 .AND. Furnace(FurnaceNum)%FanType_Num == FanType_SimpleConstVolume)THEN
IF (.NOT. CheckScheduleValueMinMax(Furnace(FurnaceNum)%FanSchedPtr,'>',0.0d0,'<=',1.0d0)) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('For '//TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
CALL ShowContinueError('Fan operating mode must be continuous (fan operating mode schedule values > 0).')
CALL ShowContinueError('Error found in '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
CALL ShowContinueError('...schedule values must be (>0., <=1.)')
ErrorsFound=.TRUE.
END IF
ELSE IF(lAlphaBlanks(5) .AND. Furnace(FurnaceNum)%FanType_Num /= FanType_SimpleOnOff)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
CALL ShowContinueError(TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
CALL ShowContinueError('Fan type must be Fan:OnOff when '// &
TRIM(cAlphaFields(5))//' = Blank.')
ErrorsFound=.TRUE.
END IF
ENDIF ! IF (IsNotOK) THEN
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
ErrorsFound=.TRUE.
END IF ! IF (TFurnace(FurnaceNum)%FanType_Num == FanType_SimpleOnOff .OR. &, etc.
IF (SameString(Alphas(9),'BlowThrough') ) &
Furnace(FurnaceNum)%FanPlace = BlowThru
IF (SameString(Alphas(9),'DrawThrough') ) &
Furnace(FurnaceNum)%FanPlace = DrawThru
IF (Furnace(FurnaceNum)%FanPlace .EQ.0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(9))//' = '//TRIM(Alphas(9)))
ErrorsFound = .TRUE.
END IF
!Get coil data
HeatingCoilType = Alphas(10)
HeatingCoilName = Alphas(11)
HeatingCoilPLFCurveIndex = 0
Furnace(FurnaceNum)%HeatingCoilType = HeatingCoilType
Furnace(FurnaceNum)%HeatingCoilName = HeatingCoilName
IF (SameString(HeatingCoilType,'Coil:Heating:Gas') .OR. &
SameString(HeatingCoilType,'Coil:Heating:Electric')) THEN
ErrFlag = .FALSE.
Furnace(FurnaceNum)%HeatingCoilType_Num = GetHeatingCoilTypeNum(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil
! Get heating coil index
ErrFlag=.FALSE.
CALL GetHeatingCoilIndex(HeatingCoilName,Furnace(FurnaceNum)%HeatingCoilIndex,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the design heating capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = &
GetHeatingCoilCapacity(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Heating Coil Inlet Node
ErrFlag=.FALSE.
HeatingCoilInletNode = &
GetHeatingCoilInletNode(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Heating Coil Outlet Node
ErrFlag=.FALSE.
HeatingCoilOutletNode = &
GetHeatingCoilOutletNode(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Heating Coil PLF Curve Index
ErrFlag=.FALSE.
HeatingCoilPLFCurveIndex = &
GetHeatingCoilPLFCurveIndex(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ENDIF
ELSEIF (SameString(HeatingCoilType,'Coil:Heating:Water')) THEN
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingWater
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
! Get the Heating Coil water Inlet or control Node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoilControlNode = GetCoilWaterInletNode('Coil:Heating:Water',HeatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil hot water max volume flow rate
ErrFlag = .FALSE.
Furnace(FurnaceNum)%MaxHeatCoilFluidFlow = GetCoilMaxWaterFlowRate('Coil:Heating:Water', &
HeatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
HeatingCoilInletNode = GetWaterCoilInletNode('Coil:Heating:Water',HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirInletNode = HeatingCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
HeatingCoilOutletNode = GetWaterCoilOutletNode('Coil:Heating:Water',HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirOutletNode = HeatingCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! check if user has also used a water coil controller, which they should not do
ErrFlag = .FALSE.
CALL CheckCoilWaterInletNode(Furnace(FurnaceNum)%CoilControlNode, ErrFlag)
IF (.NOT. ErrFlag) THEN ! then did find a controller so that is bad
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name) &
//' has a conflicting Controller:WaterCoil object' )
CALL ShowContinueError('Hot water coils are controlled directly by unitary and furnace systems.')
CALL ShowContinueError('No water coil controller should be input for the coil.')
ErrorsFound = .TRUE.
ENDIF
ENDIF
ELSEIF (SameString(HeatingCoilType,'Coil:Heating:Steam')) THEN
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingSteam
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
ErrFlag = .FALSE.
Furnace(FurnaceNum)%HeatingCoilIndex = GetSTeamCoilIndex('COIL:HEATING:STEAM',HeatingCoilName,ErrFlag)
IF (Furnace(FurnaceNum)%HeatingCoilIndex .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' illegal '//TRIM(cAlphaFields(11))//' = ' &
//TRIM(HeatingCoilName))
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam inlet node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoilControlNode = GetSteamCoilSteamInletNode('Coil:Heating:Steam',HeatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam max volume flow rate
Furnace(FurnaceNum)%MaxHeatCoilFluidFlow = GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%HeatingCoilIndex,ErrFlag)
IF (Furnace(FurnaceNum)%MaxHeatCoilFluidFlow .GT. 0.0d0)THEN
SteamIndex = 0 ! Function GetSatDensityRefrig will look up steam index if 0 is passed
SteamDensity=GetSatDensityRefrig("STEAM",TempSteamIn,1.0d0,SteamIndex,'GetAirLoopHVACHeatCoolInput')
Furnace(FurnaceNum)%MaxHeatCoilFluidFlow = Furnace(FurnaceNum)%MaxHeatCoilFluidFlow * SteamDensity
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
HeatingCoilInletNode = &
GetSteamCoilAirInletNode(Furnace(FurnaceNum)%HeatingCoilIndex,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirInletNode = HeatingCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
HeatingCoilOutletNode = &
GetSteamCoilAirOutletNode(Furnace(FurnaceNum)%HeatingCoilIndex,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%HWCoilAirOutletNode = HeatingCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(11))//' = '//TRIM(Alphas(11)))
ErrorsFound=.TRUE.
END IF ! IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingGas .OR. &, etc.
! Get Cooling Coil Information if available
CoolingCoilType = Alphas(12)
CoolingCoilName = Alphas(13)
! Find the type of coil. Do not print message since this may not be the correct coil type.
ErrFlag = .FALSE.
PrintMessage = .FALSE.
IF (SameString(CoolingCoilType, 'COIL:COOLING:DX:VARIABLESPEED') )THEN
Furnace(FurnaceNum)%CoolingCoilType_Num = Coil_CoolingAirToAirVariableSpeed
ELSE
Furnace(FurnaceNum)%CoolingCoilType_Num = &
GetDXCoilTypeNum(CoolingCoilType,CoolingCoilName,ErrFlag,PrintMessage)
END IF
! If coil type not found, check to see if a HX assisted cooling coil is used.
IF(Furnace(FurnaceNum)%CoolingCoilType_Num .EQ. 0)THEN
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoolingCoilType_Num = &
GetHXAssistedCoilTypeNum(CoolingCoilType,CoolingCoilName,ErrFlag,PrintMessage)
END IF
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == CoilDX_CoolingSingleSpeed)THEN
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from DX cooling coil
! Get DX cooling coil index
CALL GetDXCoilIndex(CoolingCoilName,Furnace(FurnaceNum)%CoolingCoilIndex,IsNotOK)
IF(IsNotOK)THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
END IF
! Get DX cooling coil capacity
ErrFlag = .FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetDXCoilCapacity(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Cooling Coil Nodes
ErrFlag=.FALSE.
CoolingCoilInletNode = GetDXCoilInletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
CoolingCoilOutletNode = GetDXCoilOutletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get outdoor condenser node from DX coil object
ErrFlag=.FALSE.
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) THEN
Furnace(FurnaceNum)%CondenserNodeNum = GetVSCoilCondenserInletNode(CoolingCoilName,ErrFlag)
ELSE
Furnace(FurnaceNum)%CondenserNodeNum = &
GetDXCoilCondenserInletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
END IF
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
! Push heating coil PLF curve index to DX coil
IF(HeatingCoilPLFCurveIndex .GT. 0)THEN
CALL SetDXCoolingCoilData(Furnace(FurnaceNum)%CoolingCoilIndex,ErrorsFound, &
HeatingCoilPLFCurvePTR=HeatingCoilPLFCurveIndex)
END IF
ELSEIF (Furnace(FurnaceNum)%CoolingCoilType_Num == CoilDX_CoolingHXAssisted)THEN
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heat exchanger assisted cooling coil
! Get DX heat exchanger assisted cooling coil index
CALL GetHXDXCoilIndex(CoolingCoilName,Furnace(FurnaceNum)%CoolingCoilIndex,IsNotOK)
IF(IsNotOK)THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
END IF
! Get DX cooling coil capacity
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetDXHXAsstdCoilCapacity(CoolingCoilType,CoolingCoilName,ErrFlag)
ErrFlag = .FALSE.
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Cooling Coil Nodes
ErrFlag=.FALSE.
CoolingCoilInletNode = GetDXHXAsstdCoilInletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
CoolingCoilOutletNode = GetDXHXAsstdCoilOutletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get outdoor condenser node from heat exchanger assisted DX coil object
ErrFlag=.FALSE.
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) THEN
Furnace(FurnaceNum)%CondenserNodeNum = GetVSCoilCondenserInletNode(CoolingCoilName,ErrFlag)
ELSE
Furnace(FurnaceNum)%CondenserNodeNum = &
GetDXCoilCondenserInletNode('COIL:COOLING:DX:SINGLESPEED', &
GetHXDXCoilName(CoolingCoilType,CoolingCoilName,ErrFlag), ErrFlag)
END IF
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Push heating coil PLF curve index to DX coil
IF(HeatingCoilPLFCurveIndex .GT. 0)THEN
! get the actual index to the DX cooling coil object
DXCoilIndex = GetActualDXCoilIndex(CoolingCoilType,CoolingCoilName,ErrorsFound)
Furnace(FurnaceNum)%ActualDXCoilIndexforHXAssisted = DXCoilIndex
CALL SetDXCoolingCoilData(DXCoilIndex,ErrorsFound, &
HeatingCoilPLFCurvePTR=HeatingCoilPLFCurveIndex)
END IF
ENDIF ! IF (IsNotOK) THEN
ELSE IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed )THEN
! BOS ADDED, AUG/2012, VARIIABLE SPEED DX COOLING COIL
! Furnace(FurnaceNum)%DXCoolCoilType = 'COIL:COOLING:DX:VARIABLESPEED'
! Furnace(FurnaceNum)%DXCoolCoilName = CoolingCoilName
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...specified in '//TRIM(CurrentModuleObject)//'="'//TRIM(Alphas(1))//'".')
ErrorsFound=.TRUE.
ELSE
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoolingCoilIndex = GetCoilIndexVariableSpeed(CoolingCoilType, &
CoolingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('...specified in '//TRIM(CurrentModuleObject)//'="'//TRIM(Alphas(1))//'".')
ErrorsFound=.TRUE.
END IF
CoolingCoilInletNode =GetCoilInletNodeVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
CoolingCoilOutletNode =GetCoilOutletNodeVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
Furnace(FurnaceNum)%CondenserNodeNum = GetVSCoilCondenserInletNode(CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(12))//' = '//TRIM(Alphas(12)))
ErrorsFound=.TRUE.
END IF
IF (SameString(Alphas(14),'None') .OR. SameString(Alphas(14),'Multimode') .OR. &
SameString(Alphas(14),'CoolReheat'))THEN
AirNodeFound=.FALSE.
If(SameString(Alphas(14),'Multimode'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_Multimode
Furnace(FurnaceNum)%Humidistat = .TRUE.
IF(Furnace(FurnaceNum)%CoolingCoilType_Num /= CoilDX_CoolingHXAssisted) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(14))//' = '//TRIM(Alphas(14)))
CALL ShowContinueError('Multimode control must be used with a Heat Exchanger Assisted Cooling Coil.')
IF(lAlphaBlanks(15))THEN
CALL ShowContinueError('Dehumidification control type is assumed to be None since a reheat coil has not been '// &
'specified and the simulation continues.')
Furnace(FurnaceNum)%Humidistat = .FALSE.
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
ELSE
CALL ShowContinueError('Dehumidification control type is assumed to be CoolReheat and the simulation continues.')
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_CoolReheat
END IF
END IF
END IF
IF(SameString(Alphas(14),'CoolReheat'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_CoolReheat
Furnace(FurnaceNum)%Humidistat = .TRUE.
IF(lAlphaBlanks(15))THEN
CALL ShowWarningError(TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('Dehumidification control type is assumed to be None since a reheat coil has not been '// &
'specified and the simulation continues.')
Furnace(FurnaceNum)%Humidistat = .FALSE.
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
END IF
END IF
IF(SameString(Alphas(14),'None'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
Furnace(FurnaceNum)%Humidistat = .FALSE.
END IF
IF(Furnace(FurnaceNum)%Humidistat)THEN
DO HstatZoneNum = 1, NumHumidityControlZones
IF(HumidityControlZone(HstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find Air Node (Zone with Humidistat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
ENDIF
END IF
ELSE ! invalid input
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(14))//' = '//TRIM(Alphas(14)))
Furnace(FurnaceNum)%Humidistat = .FALSE.
ErrorsFound=.TRUE.
END IF
! Check placement of cooling coil with respect to fan placement and dehumidification control type
IF(Furnace(FurnaceNum)%FanPlace == BlowThru)THEN
IF(FanOutletNode == HeatingCoilInletNode .AND. &
Furnace(FurnaceNum)%DehumidControlType_Num /= DehumidControl_CoolReheat)THEN
Furnace(FurnaceNum)%CoolingCoilUpstream = .FALSE.
END IF
ELSE
IF(HeatingCoilOutletNode == CoolingCoilInletNode .AND. &
Furnace(FurnaceNum)%DehumidControlType_Num /= DehumidControl_CoolReheat)THEN
Furnace(FurnaceNum)%CoolingCoilUpstream = .FALSE.
END IF
END IF
!Get reheat coil data if humidistat is used
ReheatingCoilType = Alphas(15)
ReheatingCoilName = Alphas(16)
Furnace(FurnaceNum)%SuppHeatCoilType = ReheatingCoilType
Furnace(FurnaceNum)%SuppHeatCoilName = ReheatingCoilName
ErrFlag = .FALSE.
IF(.NOT. lAlphaBlanks(15))THEN
IF (SameString(ReheatingCoilType,'Coil:Heating:Gas') .OR. &
SameString(ReheatingCoilType,'Coil:Heating:Electric') .OR. &
SameString(ReheatingCoilType,'Coil:Heating:Desuperheater')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = GetHeatingCoilTypeNum(ReheatingCoilType,ReheatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
CALL ValidateComponent(ReHeatingCoilType,ReHeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('In '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ELSE ! mine data from reheat coil
! Get the heating coil index
CALL GetHeatingCoilIndex(ReheatingCoilName,Furnace(FurnaceNum)%SuppHeatCoilIndex,IsNotOK)
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the design supplemental heating capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignSuppHeatingCapacity = &
GetHeatingCoilCapacity(ReHeatingCoilType,ReHeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Reheat Coil Inlet Node
ErrFlag=.FALSE.
ReheatCoilInletNode = GetHeatingCoilInletNode(ReheatingCoilType,ReheatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ENDIF
! Get the Reheat Coil Outlet Node
ErrFlag=.FALSE.
ReheatCoilOutletNode = GetHeatingCoilOutletNode(ReheatingCoilType,ReheatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ENDIF
ELSEIF (SameString(ReheatingCoilType,'Coil:Heating:Water')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = Coil_HeatingWater
CALL ValidateComponent(ReheatingCoilType,ReheatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
! Get the Heating Coil water Inlet or control Node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppCoilControlNode = GetCoilWaterInletNode('Coil:Heating:Water',ReheatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil hot water max volume flow rate
ErrFlag = .FALSE.
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = GetCoilMaxWaterFlowRate('Coil:Heating:Water', &
ReheatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil Inlet Node
ErrFlag = .FALSE.
ReheatCoilInletNode = GetWaterCoilInletNode('Coil:Heating:Water',ReheatingCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirInletNode = ReheatCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil Outlet Node
ErrFlag = .FALSE.
ReheatCoilOutletNode = GetWaterCoilOutletNode('Coil:Heating:Water',ReheatingCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirOutletNode = ReheatCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! check if user has also used a water coil controller, which they should not do
ErrFlag = .FALSE.
CALL CheckCoilWaterInletNode(Furnace(FurnaceNum)%CoilControlNode, ErrFlag)
IF (.NOT. ErrFlag) THEN ! then did find a controller so that is bad
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name) &
//' has a conflicting Controller:WaterCoil object' )
CALL ShowContinueError('Hot water coils are controlled directly by unitary and furnace systems.')
CALL ShowContinueError('No water coil controller should be input for the coil.')
ErrorsFound = .TRUE.
ENDIF
ENDIF
ELSEIF (SameString(ReheatingCoilType,'Coil:Heating:Steam')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = Coil_HeatingSteam
CALL ValidateComponent(ReheatingCoilType,ReheatingCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppHeatCoilIndex = GetSTeamCoilIndex('COIL:HEATING:STEAM',ReheatingCoilName,ErrFlag)
IF (Furnace(FurnaceNum)%SuppHeatCoilIndex .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' illegal '//TRIM(cAlphaFields(11))//' = ' &
//TRIM(ReheatingCoilName))
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam inlet node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppCoilControlNode = GetSteamCoilSteamInletNode('Coil:Heating:Steam',ReheatingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam max volume flow rate
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%SuppHeatCoilIndex,ErrFlag)
IF (Furnace(FurnaceNum)%MaxSuppCoilFluidFlow .GT. 0.0d0)THEN
SteamIndex = 0 ! Function GetSatDensityRefrig will look up steam index if 0 is passed
SteamDensity=GetSatDensityRefrig("STEAM",TempSteamIn,1.0d0,SteamIndex,'GetAirLoopHVACHeatCoolInput')
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = &
GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%SuppHeatCoilIndex,ErrFlag) * SteamDensity
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
ReheatCoilInletNode = &
GetSteamCoilAirInletNode(Furnace(FurnaceNum)%SuppHeatCoilIndex,ReheatingCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirInletNode = ReheatCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
ReheatCoilOutletNode = &
GetSteamCoilAirOutletNode(Furnace(FurnaceNum)%SuppHeatCoilIndex,ReheatingCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirOutletNode = ReheatCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
ENDIF
ELSE ! Illeagal heating coil
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(15))//' = '//TRIM(Alphas(15)))
ErrorsFound=.TRUE.
END IF ! IF (Furnace(FurnaceNum)%SuppHeatCoilType_Num == Coil_HeatingGas .OR. &, etc.
END IF ! IF(.NOT. lAlphaBlanks(15))THEN
IF(Furnace(FurnaceNum)%FanPlace .EQ. BlowThru)THEN
IF(FanInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('When a blow through fan is specified, the fan inlet node name must be '// &
'the same as the furnace inlet node name.')
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
CALL ShowContinueError('...Furnace inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ELSE
CALL ShowContinueError('When a blow through fan is specified, the fan inlet node name must be '// &
'the same as the unitary system inlet node name.')
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
CALL ShowContinueError('...UnitarySystem inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
IF(Furnace(FurnaceNum)%CoolingCoilUpstream)THEN
IF(FanOutletNode /= CoolingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a blow through fan is specified, the fan outlet node name must be '// &
'the same as the cooling coil inlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(CoolingCoilOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('The cooling coil outlet node name must be '// &
'the same as the heating coil inlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF((Furnace(FurnaceNum)%Humidistat .AND. Furnace(FurnaceNum)%DehumidControlType_Num == DehumidControl_CoolReheat) .OR. &
ReHeatCoilInletNode .GT. 0)THEN
IF(HeatingCoilOutletNode /= ReHeatCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a blow through fan is specified, the heating coil outlet node name must be '// &
'the same as the reheat coil inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Reheat coil inlet node name = '//TRIM(NodeID(ReHeatCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(ReHeatCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('The reheat coil outlet node name must be '// &
'the same as the furnace outlet node name.')
CALL ShowContinueError('...Reheat coil outlet node name = '//TRIM(NodeID(ReHeatCoilOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('The reheat coil outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Reheat coil outlet node name = '//TRIM(NodeID(ReHeatCoilOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
ELSE ! IF((Furnace(FurnaceNum)%Humidistat ...
! Heating coil outlet node name must be the same as the furnace outlet node name
IF (HeatingCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatOnly)THEN
CALL ShowContinueError('When a blow through fan is specified, '//&
'the heating coil outlet node name must be the same as the furnace outlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('When a blow through fan is specified, '//&
'the heating coil outlet node name must be the same as the unitary system outlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
END IF
ELSE ! IF(Furnace(FurnaceNum)%CoolingCoilUpstream)THEN
IF(FanOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a blow through fan is specified, the fan outlet node name must be '// &
'the same as the heating coil inlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(HeatingCoilOutletNode /= CoolingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('The heating coil outlet node name must be '// &
'the same as the cooling coil inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(CoolingCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('When a blow through fan is specified, the cooling coil outlet node name must be '// &
'the same as the furnace outlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('When a blow through fan is specified, the cooling coil outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
END IF
ELSE ! ELSE from IF(Furnace(FurnaceNum)%FanPlace .EQ. BlowThru)THEN
IF(Furnace(FurnaceNum)%CoolingCoilUpstream)THEN
IF(CoolingCoilInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('When a draw through fan is specified, the cooling coil inlet node name must be '// &
'the same as the furnace inlet node name.')
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
CALL ShowContinueError('...Furnace inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ELSE
CALL ShowContinueError('When a draw through fan is specified, the cooling coil inlet node name must be '// &
'the same as the unitary system inlet node name.')
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
CALL ShowContinueError('...UnitarySystem inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
IF(CoolingCoilOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('The cooling coil outlet node name must be '// &
'the same as the heating coil inlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(HeatingCoilOutletNode /= FanInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a draw through fan is specified, the heating coil outlet node name must be '// &
'the same as the fan inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
ErrorsFound=.TRUE.
END IF
IF((Furnace(FurnaceNum)%Humidistat .AND. Furnace(FurnaceNum)%DehumidControlType_Num == DehumidControl_CoolReheat) .OR. &
ReHeatCoilInletNode .GT. 0)THEN
IF(FanOutletNode /= ReHeatCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a draw through fan is specified, the fan outlet node name must be '// &
'the same as the reheat coil inlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Reheat coil inlet node name = '//TRIM(NodeID(ReheatCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(ReHeatCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('The reheat coil outlet node name must be '// &
'the same as the furnace outlet node name.')
CALL ShowContinueError('...Reheat coil outlet node name = '//TRIM(NodeID(ReHeatCoilOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('The reheat coil outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Reheat coil outlet node name = '//TRIM(NodeID(ReHeatCoilOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
ELSE
IF(FanOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a draw through fan is specified, the fan outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Unitary system outlet node name = '// &
TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ErrorsFound=.TRUE.
END IF
END IF
ELSE ! IF(Furnace(FurnaceNum)%CoolingCoilUpstream)THEN
IF(HeatingCoilInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('When a draw through fan is specified, the heating coil inlet node name must be '// &
'the same as the furnace inlet node name.')
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
CALL ShowContinueError('...Furnace inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ELSE
CALL ShowContinueError('When a draw through fan is specified, the heating coil inlet node name must be '// &
'the same as the unitary system inlet node name.')
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
CALL ShowContinueError('...UnitarySystem inlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
IF(HeatingCoilOutletNode /= CoolingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('The heating coil outlet node name must be '// &
'the same as the cooling coil inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(CoolingCoilOutletNode /= FanInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('When a draw through fan is specified, the cooling coil outlet node name must be '// &
'the same as the fan inlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
ErrorsFound=.TRUE.
END IF
IF(FanOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
IF(FurnaceType_Num == Furnace_HeatCool)THEN
CALL ShowContinueError('When a draw through fan is specified, the fan outlet node name must be '// &
'the same as the furnace outlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Furnace outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ELSE
CALL ShowContinueError('When a draw through fan is specified, the fan outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...UnitarySystem outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
END IF
ErrorsFound=.TRUE.
END IF
END IF
END IF ! ELSE from IF(Furnace(FurnaceNum)%FanPlace .EQ. BlowThru)THEN
! Add fan to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(7),Alphas(8),NodeID(FanInletNode),NodeID(FanOutletNode))
! Add DX cooling coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(12),Alphas(13),NodeID(CoolingCoilInletNode), NodeID(CoolingCoilOutletNode))
! Add heating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(10),Alphas(11),NodeID(HeatingCoilInletNode), NodeID(HeatingCoilOutletNode))
IF(ReheatCoilInletNode .GT. 0)THEN
! Add reheating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(15),Alphas(16),NodeID(ReheatCoilInletNode),NodeID(ReheatCoilOutletNode))
END IF
!Set the furnace max outlet temperature
Furnace(FurnaceNum)%DesignMaxOutletTemp = Numbers(1)
Furnace(FurnaceNum)%MaxCoolAirVolFlow = Numbers(2)
IF (Furnace(FurnaceNum)%MaxCoolAirVolFlow .LE. 0 .AND. Furnace(FurnaceNum)%MaxCoolAirVolFlow .NE. AutoSize) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cNumericFields(2))//' = '//TRIM(TrimSigDigits(Numbers(2),7)))
ErrorsFound = .TRUE.
END IF
Furnace(FurnaceNum)%MaxHeatAirVolFlow = Numbers(3)
IF (Furnace(FurnaceNum)%MaxHeatAirVolFlow .LE. 0 .AND. Furnace(FurnaceNum)%MaxHeatAirVolFlow .NE. AutoSize) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cNumericFields(3))//' = '//TRIM(TrimSigDigits(Numbers(3),7)))
ErrorsFound = .TRUE.
END IF
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow = Numbers(4)
IF (Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow .LT. 0 .AND.Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow .NE. AutoSize) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cNumericFields(4))//' = '//TRIM(TrimSigDigits(Numbers(4),7)))
ErrorsFound = .TRUE.
END IF
IF(Numbers(2) .NE. Autosize .AND. Numbers(3) .NE. Autosize .AND. Numbers(4) .NE. Autosize)THEN
Furnace(FurnaceNum)%DesignFanVolFlowRate = MAX(Numbers(2),Numbers(3),Numbers(4))
ELSE
Furnace(FurnaceNum)%DesignFanVolFlowRate = Autosize
END IF
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%MaxCoolAirVolFlow &
= GetCoilAirFlowRateVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow = &
MIN(Furnace(FurnaceNum)%MaxHeatAirVolFlow,Furnace(FurnaceNum)%MaxCoolAirVolFlow)
IF(Furnace(FurnaceNum)%MaxHeatAirVolFlow /= Autosize .AND. &
Furnace(FurnaceNum)%MaxCoolAirVolFlow /= Autosize)THEN
Furnace(FurnaceNum)%DesignFanVolFlowRate = &
MAX(Furnace(FurnaceNum)%MaxHeatAirVolFlow,Furnace(FurnaceNum)%MaxCoolAirVolFlow)
ELSE
Furnace(FurnaceNum)%DesignFanVolFlowRate = Autosize
END IF
END IF
IF(FanVolFlowRate .NE. AutoSize)THEN
IF(FanVolFlowRate .LT. Furnace(FurnaceNum)%MaxCoolAirVolFlow .AND. &
Furnace(FurnaceNum)%MaxCoolAirVolFlow .NE. AutoSize)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... air flow rate = '// &
TRIM(TrimSigDigits(FanVolFlowRate,7))//&
' in fan object '//TRIM(FanName)//' is less than the maximum HVAC system air flow rate in ' &
//'cooling mode.')
CALL ShowContinueError(' The '//TRIM(cNumericFields(2))//' is reset to the' &
//' fan flow rate and the simulation continues.')
Furnace(FurnaceNum)%MaxCoolAirVolFlow = FanVolFlowRate
Furnace(FurnaceNum)%DesignFanVolFlowRate = FanVolFlowRate
END IF
IF(FanVolFlowRate .LT. Furnace(FurnaceNum)%MaxHeatAirVolFlow .AND. &
Furnace(FurnaceNum)%MaxHeatAirVolFlow .NE. AutoSize)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... air flow rate = '// &
TRIM(TrimSigDigits(FanVolFlowRate,7))//&
' in fan object '//TRIM(FanName)//' is less than the maximum HVAC system air flow rate in ' &
//'heating mode.')
CALL ShowContinueError(' The '//TRIM(cNumericFields(3))//' is reset to the' &
//' fan flow rate and the simulation continues.')
Furnace(FurnaceNum)%MaxHeatAirVolFlow = FanVolFlowRate
Furnace(FurnaceNum)%DesignFanVolFlowRate = FanVolFlowRate
END IF
END IF
IF(Furnace(FurnaceNum)%FanSchedPtr .GT. 0)THEN
IF (.NOT. CheckScheduleValueMinMax(Furnace(FurnaceNum)%FanSchedPtr,'>=',0.0d0,'<=',0.0d0)) THEN
! set air flow control mode:
! UseCompressorOnFlow = operate at last cooling or heating air flow requested when compressor is off
! UseCompressorOffFlow = operate at value specified by user
! AirFlowControl only valid if fan opmode = ContFanCycComp
IF (Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow .EQ. 0.0d0) THEN
Furnace(FurnaceNum)%AirFlowControl = UseCompressorOnFlow
ELSE
Furnace(FurnaceNum)%AirFlowControl = UseCompressorOffFlow
END IF
END IF
END IF
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetCoilCapacityVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
!Set heating convergence tolerance
Furnace(FurnaceNum)%HeatingConvergenceTolerance = 0.001d0
!Set cooling convergence tolerance
Furnace(FurnaceNum)%CoolingConvergenceTolerance = 0.001d0
END DO !End of the HeatCool Furnace Loop
! Get the data for the Unitary System HeatPump AirToAir (UnitarySystem:HeatPump:AirToAir)
DO HeatPumpNum = 1, NumHeatPump
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatPump:AirToAir'
FanInletNode = 0
FanOutletNode = 0
CoolingCoilInletNode = 0
CoolingCoilOutletNode = 0
HeatingCoilInletNode = 0
HeatingCoilOutletNode = 0
SupHeatCoilInletNode = 0
SupHeatCoilOutletNode = 0
FurnaceNum= NumHeatOnly + NumHeatCool + NumUnitaryHeatOnly + NumUnitaryHeatCool + HeatPumpNum
CALL GetObjectItem(CurrentModuleObject,HeatPumpNum,Alphas,NumAlphas,Numbers,NumNumbers,IOStatus, &
NumBlank=lNumericBlanks,AlphaBlank=lAlphaBlanks, &
AlphaFieldNames=cAlphaFields,NumericFieldNames=cNumericFields)
IsNotOK=.FALSE.
IsBlank=.FALSE.
CALL VerifyName(Alphas(1),Furnace%Name,FurnaceNum-1,IsNotOK,IsBlank,TRIM(CurrentModuleObject)//' Name')
IF (IsNotOK) THEN
ErrorsFound=.TRUE.
IF (IsBlank) Alphas(1)='xxxxx'
ENDIF
Furnace(FurnaceNum)%FurnaceType_Num = UnitarySys_HeatPump_AirToAir
Furnace(FurnaceNum)%Name = Alphas(1)
IF (lAlphaBlanks(2)) THEN
Furnace(FurnaceNum)%SchedPtr = ScheduleAlwaysOn
ELSE
Furnace(FurnaceNum)%SchedPtr = GetScheduleIndex(Alphas(2))
IF (Furnace(FurnaceNum)%SchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(2))//' = '//TRIM(Alphas(2)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
Furnace(FurnaceNum)%FurnaceInletNodeNum = &
GetOnlySingleNode(Alphas(3),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_Inlet,1,ObjectIsParent)
Furnace(FurnaceNum)%FurnaceOutletNodeNum = &
GetOnlySingleNode(Alphas(4),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_Outlet,1,ObjectIsParent)
CALL TestCompSet(CurrentModuleObject,Alphas(1),Alphas(3),Alphas(4),'Air Nodes')
!Get the Controlling Zone or Location of the Furnace Thermostat
Furnace(FurnaceNum)%ControlZoneNum = FindItemInList(Alphas(5),Zone%Name,NumOfZones)
IF (Furnace(FurnaceNum)%ControlZoneNum == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ENDIF
TotalZonesOnAirLoop = 0
! Get the node number for the zone with the thermostat
IF (Furnace(FurnaceNum)%ControlZoneNum > 0) THEN
AirNodeFound=.FALSE.
AirLoopFound=.FALSE.
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%ActualZoneNum /= Furnace(FurnaceNum)%ControlZoneNum) CYCLE
! Find the controlled zone number for the specified thermostat location
Furnace(FurnaceNum)%NodeNumofControlledZone=ZoneEquipConfig(ControlledZoneNum)%ZoneNode
! Determine if furnace is on air loop served by the thermostat location specified
AirLoopNumber = ZoneEquipConfig(ControlledZoneNum)%AirLoopNum
IF(AirLoopNumber .GT. 0)THEN
DO BranchNum = 1, PrimaryAirSystem(AirLoopNumber)%NumBranches
DO CompNum = 1, PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%TotalComponents
IF(.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%Name, &
Alphas(1)) .OR. &
.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%TypeOf, &
CurrentModuleObject))CYCLE
AirLoopFound=.TRUE.
EXIT
END DO
IF(AirLoopFound)EXIT
END DO
DO TstatZoneNum = 1, NumTempControlledZones
IF(TempControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
DO TstatZoneNum = 1, NumComfortControlledZones
IF(ComfortControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find an AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
END IF
EXIT
ENDDO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find air node (zone with thermostat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
CALL ShowContinueError('Both a ZoneHVAC:EquipmentConnections object and a ZoneControl:Thermostat object' &
//' must be specified for this zone.')
ErrorsFound=.TRUE.
ENDIF
IF (.not. AirLoopFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowSevereError('Did not find correct AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ENDIF
IF(AirLoopNumber .GT. 0)THEN
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%AirLoopNum == AirLoopNumber) THEN
TotalZonesOnAirLoop = TotalZonesOnAirLoop + 1
END IF
END DO
END IF
ENDIF
!Get fan data
FanType = Alphas(6)
FanName = Alphas(7)
ErrFlag=.FALSE.
CALL GetFanType(FanName, Furnace(FurnaceNum)%FanType_Num, ErrFlag, &
CurrentModuleObject,Alphas(1))
IF (ErrFlag) THEN
ErrorsFound=.TRUE.
END IF
IF (Furnace(FurnaceNum)%FanType_Num == FanType_SimpleOnOff .OR. &
Furnace(FurnaceNum)%FanType_Num == FanType_SimpleConstVolume)THEN
CALL ValidateComponent(FanType,FanName,IsNotOK, TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from fan object
! Get the fan index
ErrFlag=.FALSE.
CALL GetFanIndex(FanName, Furnace(FurnaceNum)%FanIndex, ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the fan inlet node number
ErrFlag=.FALSE.
FanInletNode = GetFanInletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the fan outlet node number
ErrFlag=.FALSE.
FanOutletNode = GetFanOutletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the fan availability schedule
ErrFlag=.FALSE.
Furnace(FurnaceNum)%FanAvailSchedPtr = GetFanAvailSchPtr(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Design Fan Volume Flow Rate
ErrFlag=.FALSE.
FanVolFlowRate = GetFanDesignVolumeFlowRate(FanType,FanName,ErrFlag)
Furnace(FurnaceNum)%ActualFanVolFlowRate = FanVolFlowRate
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
END IF
!Get heating coil type and name data
HeatingCoilType = Alphas(8)
HeatingCoilName = Alphas(9)
ErrFlag = .FALSE.
IF (SameString(HeatingCoilType, 'COIL:HEATING:DX:VARIABLESPEED') )THEN
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingAirToAirVariableSpeed
ELSE
Furnace(FurnaceNum)%HeatingCoilType_Num = GetDXCoilTypeNum(HeatingCoilType,HeatingCoilName,ErrFlag)
END IF
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
END IF
IF (Furnace(FurnaceNum)%HeatingCoilType_Num == CoilDX_HeatingEmpirical)THEN
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from DX heating coil
CALL GetDXCoilIndex(HeatingCoilName,Furnace(FurnaceNum)%HeatingCoilIndex,IsNotOK)
IF(IsNotOK)THEN
CALL ShowContinueError('...occurs '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
END IF
! Get the Heating Coil Node Names
ErrFlag=.FALSE.
HeatingCoilInletNode = GetDXCoilInletNode(HeatingCoilType,HeatingCoilName,ErrFlag)
HeatingCoilOutletNode = GetDXCoilOutletNode(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the design heating capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = GetDXCoilCapacity(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' ='//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ELSE IF(Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingAirToAirVariableSpeed) THEN
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%HeatingCoilIndex = GetCoilIndexVariableSpeed(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilInletNode=GetCoilInletNodeVariableSpeed(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilOutletNode=GetCoilOutletNodeVariableSpeed(HeatingCoilType, HeatingCoilName,ErrFlag)
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(8))//' = '//TRIM(Alphas(8)))
ErrorsFound=.TRUE.
END IF
! Get Cooling Coil Information if available
CoolingCoilType = Alphas(10)
CoolingCoilName = Alphas(11)
IF (SameString(CoolingCoilType, 'COIL:COOLING:DX:VARIABLESPEED') )THEN
Furnace(FurnaceNum)%CoolingCoilType_Num = Coil_CoolingAirToAirVariableSpeed
END IF
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from DX cooling coil
ErrFlag = .FALSE.
PrintMessage = .FALSE.
IF(Furnace(FurnaceNum)%CoolingCoilType_Num /= Coil_CoolingAirToAirVariableSpeed) THEN
Furnace(FurnaceNum)%CoolingCoilType_Num = &
GetDXCoilTypeNum(CoolingCoilType,CoolingCoilName,ErrFlag,PrintMessage)
END IF
! If coil type not found, check to see if a HX assisted cooling coil is used.
IF(Furnace(FurnaceNum)%CoolingCoilType_Num .EQ. 0)THEN
ErrFlag = .FALSE.
PrintMessage = .FALSE.
Furnace(FurnaceNum)%CoolingCoilType_Num = &
GetHXAssistedCoilTypeNum(CoolingCoilType,CoolingCoilName,ErrFlag,PrintMessage)
END IF
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == CoilDX_CoolingSingleSpeed)THEN
! Get the cooling coil node numbers
ErrFlag=.FALSE.
CALL GetDXCoilIndex(CoolingCoilName,Furnace(FurnaceNum)%CoolingCoilIndex,ErrFlag)
CoolingCoilInletNode = GetDXCoilInletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
CoolingCoilOutletNode = GetDXCoilOutletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the DX cooling coil design capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = GetDXCoilCapacity(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ELSEIF (Furnace(FurnaceNum)%CoolingCoilType_Num == CoilDX_CoolingHXAssisted)THEN
! Get the cooling coil node numbers
ErrFlag=.FALSE.
CALL GetHXDXCoilIndex(CoolingCoilName,Furnace(FurnaceNum)%CoolingCoilIndex,ErrFlag)
CoolingCoilInletNode = GetDXHXAsstdCoilInletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
CoolingCoilOutletNode = GetDXHXAsstdCoilOutletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the heat exchanger assisted cooling coil design capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = GetDXHXAsstdCoilCapacity(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! get the actual index to the DX cooling coil object
DXCoilIndex = GetActualDXCoilIndex(CoolingCoilType,CoolingCoilName,ErrorsFound)
Furnace(FurnaceNum)%ActualDXCoilIndexforHXAssisted = DXCoilIndex
ELSE IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed )THEN
! BOS ADDED, AUG/2012, VARIIABLE SPEED DX COOLING COIL
! Furnace(FurnaceNum)%DXCoolCoilType = 'COIL:COOLING:DX:VARIABLESPEED'
! Furnace(FurnaceNum)%DXCoolCoilName = CoolingCoilName
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...specified in '//TRIM(CurrentModuleObject)//'="'//TRIM(Alphas(1))//'".')
ErrorsFound=.TRUE.
ELSE
ErrFlag = .FALSE.
Furnace(FurnaceNum)%CoolingCoilIndex = GetCoilIndexVariableSpeed(CoolingCoilType, &
CoolingCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('...specified in '//TRIM(CurrentModuleObject)//'="'//TRIM(Alphas(1))//'".')
ErrorsFound=.TRUE.
END IF
CoolingCoilInletNode =GetCoilInletNodeVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
CoolingCoilOutletNode =GetCoilOutletNodeVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
Furnace(FurnaceNum)%CondenserNodeNum = GetVSCoilCondenserInletNode(CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(10))//' = '//TRIM(Alphas(10)))
ErrorsFound=.TRUE.
END IF
ENDIF
IF(Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed .AND. &
Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingAirToAirVariableSpeed) THEN
!Furnace(FurnaceNum)%WatertoAirHPType = WatertoAir_VarSpeedEquationFit
CALL SetVarSpeedCoilData(Furnace(FurnaceNum)%CoolingCoilIndex,ErrorsFound, &
CompanionHeatingCoilNum=Furnace(FurnaceNum)%HeatingCoilIndex)
END IF
! Get supplemental heating coil information
SuppHeatCoilType = Alphas(12)
SuppHeatCoilName = Alphas(13)
Furnace(FurnaceNum)%SuppHeatCoilType = SuppHeatCoilType
Furnace(FurnaceNum)%SuppHeatCoilName = SuppHeatCoilName
ErrFlag = .FALSE.
IF (SameString(SuppHeatCoilType,'Coil:Heating:Gas') .OR. &
SameString(SuppHeatCoilType,'Coil:Heating:Electric') ) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = GetHeatingCoilTypeNum(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
IsNotOK = .FALSE.
CALL ValidateComponent(SuppHeatCoilType,SuppHeatCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('In '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ELSE ! mine data from the supplemental heating coil
CALL GetHeatingCoilIndex(SuppHeatCoilName,Furnace(FurnaceNum)%SuppHeatCoilIndex,IsNotOK)
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Supplemental Heating Coil Inlet Node Number
ErrFlag=.FALSE.
SupHeatCoilInletNode = GetHeatingCoilInletNode(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ENDIF
! Get the Supplemental Heating Coil Outlet Node Number
ErrFlag=.FALSE.
SupHeatCoilOutletNode = GetHeatingCoilOutletNode(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the supplemental heating coil design capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignSuppHeatingCapacity = &
GetHeatingCoilCapacity(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ENDIF
ELSEIF (SameString(SuppHeatCoilType,'Coil:Heating:Water')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = Coil_HeatingWater
CALL ValidateComponent(SuppHeatCoilType,SuppHeatCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
! Get the Heating Coil water Inlet or control Node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppCoilControlNode = GetCoilWaterInletNode('Coil:Heating:Water',SuppHeatCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil hot water max volume flow rate
ErrFlag = .FALSE.
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = GetCoilMaxWaterFlowRate('Coil:Heating:Water', &
SuppHeatCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil Inlet Node
ErrFlag = .FALSE.
SupHeatCoilInletNode = GetWaterCoilInletNode('Coil:Heating:Water',SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirInletNode = SupHeatCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil Outlet Node
ErrFlag = .FALSE.
SupHeatCoilOutletNode = GetWaterCoilOutletNode('Coil:Heating:Water',SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirOutletNode = SupHeatCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! check if user has also used a water coil controller, which they should not do
ErrFlag = .FALSE.
CALL CheckCoilWaterInletNode(Furnace(FurnaceNum)%CoilControlNode, ErrFlag)
IF (.NOT. ErrFlag) THEN ! then did find a controller so that is bad
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name) &
//' has a conflicting Controller:WaterCoil object' )
CALL ShowContinueError('Hot water coils are controlled directly by unitary and furnace systems.')
CALL ShowContinueError('No water coil controller should be input for the coil.')
ErrorsFound = .TRUE.
ENDIF
ENDIF
ELSEIF (SameString(SuppHeatCoilType,'Coil:Heating:Steam')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = Coil_HeatingSteam
CALL ValidateComponent(SuppHeatCoilType,SuppHeatCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppHeatCoilIndex = GetSTeamCoilIndex('COIL:HEATING:STEAM',SuppHeatCoilName,ErrFlag)
IF (Furnace(FurnaceNum)%SuppHeatCoilIndex .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' illegal '//TRIM(cAlphaFields(12))//' = ' &
//TRIM(SuppHeatCoilName))
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam inlet node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppCoilControlNode = GetSteamCoilSteamInletNode('Coil:Heating:Steam',SuppHeatCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam max volume flow rate
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%SuppHeatCoilIndex,ErrFlag)
IF (Furnace(FurnaceNum)%MaxSuppCoilFluidFlow .GT. 0.0d0)THEN
SteamIndex = 0 ! Function GetSatDensityRefrig will look up steam index if 0 is passed
SteamDensity=GetSatDensityRefrig("STEAM",TempSteamIn,1.0d0,SteamIndex,'GetAirLoopHVACHeatCoolInput')
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = &
GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%SuppHeatCoilIndex,ErrFlag) * SteamDensity
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
SupHeatCoilInletNode = &
GetSteamCoilAirInletNode(Furnace(FurnaceNum)%SuppHeatCoilIndex,SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirInletNode = SupHeatCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
SupHeatCoilOutletNode = &
GetSteamCoilAirOutletNode(Furnace(FurnaceNum)%SuppHeatCoilIndex,SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirOutletNode = SupHeatCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(12))//' = '//TRIM(Alphas(12)))
ErrorsFound=.TRUE.
END IF ! IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingGas .OR. &, etc.
IF (SameString(Alphas(14),'BlowThrough') ) &
Furnace(FurnaceNum)%FanPlace = BlowThru
IF (SameString(Alphas(14),'DrawThrough') ) &
Furnace(FurnaceNum)%FanPlace = DrawThru
IF (Furnace(FurnaceNum)%FanPlace .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(14))//' = '//TRIM(Alphas(14)))
ErrorsFound = .TRUE.
END IF
Furnace(FurnaceNum)%FanSchedPtr = GetScheduleIndex(Alphas(15))
IF (.NOT. lAlphaBlanks(15) .AND. Furnace(FurnaceNum)%FanSchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(15))//' = '//TRIM(Alphas(15)))
ErrorsFound=.TRUE.
ELSEIF (lAlphaBlanks(15)) THEN
Furnace(FurnaceNum)%OpMode = CycFanCycCoil
IF(Furnace(FurnaceNum)%FanType_Num /= FanType_SimpleOnOff)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
CALL ShowContinueError(TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
CALL ShowContinueError('Fan type must be Fan:OnOff when '// &
TRIM(cAlphaFields(15))//' = Blank.')
ErrorsFound=.TRUE.
END IF
ENDIF
IF (Furnace(FurnaceNum)%FanType_Num == FanType_SimpleConstVolume)THEN
IF(Furnace(FurnaceNum)%FanSchedPtr .GT. 0)THEN
IF (.NOT. CheckScheduleValueMinMax(Furnace(FurnaceNum)%FanSchedPtr,'>',0.0d0,'<=',1.0d0)) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('For '//TRIM(cAlphaFields(7))//' = '//TRIM(Alphas(7)))
CALL ShowContinueError('Fan operating mode must be continuous (fan operating mode schedule values > 0).')
CALL ShowContinueError('Error found in '//TRIM(cAlphaFields(15))//' = '//TRIM(Alphas(15)))
CALL ShowContinueError('...schedule values must be (>0., <=1.)')
ErrorsFound=.TRUE.
END IF
END IF
END IF
! Dehumidification Control Type
IF (SameString(Alphas(16),'None') .OR. SameString(Alphas(16),'Multimode') .OR. &
SameString(Alphas(16),'CoolReheat'))THEN
AirNodeFound=.FALSE.
If(SameString(Alphas(16),'Multimode'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_Multimode
Furnace(FurnaceNum)%Humidistat = .TRUE.
IF(Furnace(FurnaceNum)%CoolingCoilType_Num /= CoilDX_CoolingHXAssisted) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(16))//' = '//TRIM(Alphas(16)))
CALL ShowContinueError('Multimode control must be used with a Heat Exchanger Assisted Cooling Coil.')
ErrorsFound=.TRUE.
END IF
END IF
IF(SameString(Alphas(16),'CoolReheat'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_CoolReheat
Furnace(FurnaceNum)%Humidistat = .TRUE.
END IF
IF(SameString(Alphas(16),'None'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
Furnace(FurnaceNum)%Humidistat = .FALSE.
END IF
IF(Furnace(FurnaceNum)%Humidistat)THEN
DO HstatZoneNum = 1, NumHumidityControlZones
IF(HumidityControlZone(HstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find Air Node (Zone with Humidistat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ENDIF
END IF
ELSE ! invalid input or blank
IF (.NOT. lAlphaBlanks(16)) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(16))//' = '//TRIM(Alphas(16)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%Humidistat = .FALSE.
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
ENDIF
END IF
! Check node names for child components
IF (Furnace(FurnaceNum)%FanPlace == BlowThru) THEN
IF(FanInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('When a blow through fan is specified, the fan inlet node name must be '// &
'the same as the unitary system inlet node name.')
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
CALL ShowContinueError('...Unitary system inlet node name = '//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ErrorsFound=.TRUE.
END IF
IF(FanOutletNode /= CoolingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('When a blow through fan is specified, the fan outlet node name must be '// &
'the same as the cooling coil inlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(CoolingCoilOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('The cooling coil outlet node name must be '// &
'the same as the heating coil inlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(HeatingCoilOutletNode /= SupHeatCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('When a blow through fan is specified, the heating coil outlet node name must be '// &
'the same as the supplemental heating coil inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Supplemental heating coil inlet node name = '//TRIM(NodeID(SupHeatCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(SupHeatCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('The supplemental heating coil outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Supplemental heating coil outlet node name = '//TRIM(NodeID(SupHeatCoilOutletNode)))
CALL ShowContinueError('...Unitary system outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ErrorsFound=.TRUE.
END IF
ELSE
IF(CoolingCoilInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('When a draw through fan is specified, the cooling coil inlet node name must be '// &
'the same as the unitary system inlet node name.')
CALL ShowContinueError('...Cooling coil inlet node name = '//TRIM(NodeID(CoolingCoilInletNode)))
CALL ShowContinueError('...Unitary system inlet node name = '//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
ErrorsFound=.TRUE.
END IF
IF(CoolingCoilOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('The cooling coil outlet node name must be '// &
'the same as the heating coil inlet node name.')
CALL ShowContinueError('...Cooling coil outlet node name = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('...Heating coil inlet node name = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(HeatingCoilOutletNode /= FanInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('When a draw through fan is specified, the heating coil outlet node name must be '// &
'the same as the fan inlet node name.')
CALL ShowContinueError('...Heating coil outlet node name = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('...Fan inlet node name = '//TRIM(NodeID(FanInletNode)))
ErrorsFound=.TRUE.
END IF
IF(FanOutletNode /= SupHeatCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('When a draw through fan is specified, the fan outlet node name must be '// &
'the same as the supplemental heating coil inlet node name.')
CALL ShowContinueError('...Fan outlet node name = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('...Supplemental heating coil inlet node name = '//TRIM(NodeID(SupHeatCoilInletNode)))
ErrorsFound=.TRUE.
END IF
IF(SupHeatCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('The supplemental heating coil outlet node name must be '// &
'the same as the unitary system outlet node name.')
CALL ShowContinueError('...Supplemental heating coil outlet node name = '//TRIM(NodeID(SupHeatCoilOutletNode)))
CALL ShowContinueError('...Unitary system outlet node name = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ErrorsFound=.TRUE.
END IF
END IF
! Add component sets array
IF (Furnace(FurnaceNum)%FanPlace == BlowThru) THEN
CompSetFanInlet = Alphas(3)
CompSetCoolInlet = 'UNDEFINED'
ELSE
CompSetFanInlet = 'UNDEFINED'
CompSetCoolInlet = Alphas(3)
ENDIF
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(6),Alphas(7),CompSetFanInlet,'UNDEFINED')
! Add DX cooling coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(10),Alphas(11),CompSetCoolInlet,'UNDEFINED')
! Add DX heating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(8),Alphas(9),'UNDEFINED','UNDEFINED')
! Add supplemental heating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(12),Alphas(13),'UNDEFINED',Alphas(4))
Furnace(FurnaceNum)%MaxCoolAirVolFlow = Numbers(1)
IF (Furnace(FurnaceNum)%MaxCoolAirVolFlow .LE. 0 .AND. Furnace(FurnaceNum)%MaxCoolAirVolFlow .NE. AutoSize) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cNumericFields(1))//' = '//TRIM(TrimSigDigits(Numbers(1),7)))
ErrorsFound = .TRUE.
END IF
Furnace(FurnaceNum)%MaxHeatAirVolFlow = Numbers(2)
IF (Furnace(FurnaceNum)%MaxHeatAirVolFlow .LE. 0 .AND. Furnace(FurnaceNum)%MaxHeatAirVolFlow .NE. AutoSize) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cNumericFields(2))//' = '//TRIM(TrimSigDigits(Numbers(2),7)))
ErrorsFound = .TRUE.
END IF
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow = Numbers(3)
IF (Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow .LT. 0 .AND.Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow .NE. AutoSize) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cNumericFields(3))//' = '//TRIM(TrimSigDigits(Numbers(3),7)))
ErrorsFound = .TRUE.
END IF
IF(Furnace(FurnaceNum)%FanSchedPtr .GT. 0)THEN
IF (.NOT. CheckScheduleValueMinMax(Furnace(FurnaceNum)%FanSchedPtr,'>=',0.0d0,'<=',0.0d0)) THEN !Objexx Range is 0 to 0?
! set air flow control mode:
! UseCompressorOnFlow = operate at last cooling or heating air flow requested when compressor is off
! UseCompressorOffFlow = operate at value specified by user
! AirFlowControl only valid if fan opmode = ContFanCycComp
IF (Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow .EQ. 0.0d0) THEN
Furnace(FurnaceNum)%AirFlowControl = UseCompressorOnFlow
ELSE
Furnace(FurnaceNum)%AirFlowControl = UseCompressorOffFlow
END IF
END IF
END IF
IF(Numbers(1) .NE. Autosize .AND. Numbers(2) .NE. Autosize .AND. Numbers(3) .NE. Autosize)THEN
Furnace(FurnaceNum)%DesignFanVolFlowRate = MAX(Numbers(1),Numbers(2),Numbers(3))
ELSE
Furnace(FurnaceNum)%DesignFanVolFlowRate = Autosize
END IF
IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingAirToAirVariableSpeed) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%MaxHeatAirVolFlow &
= GetCoilAirFlowRateVariableSpeed(HeatingCoilType,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%MaxCoolAirVolFlow &
= GetCoilAirFlowRateVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow = &
MIN(Furnace(FurnaceNum)%MaxHeatAirVolFlow,Furnace(FurnaceNum)%MaxCoolAirVolFlow)
IF(Furnace(FurnaceNum)%MaxHeatAirVolFlow /= Autosize .AND. &
Furnace(FurnaceNum)%MaxCoolAirVolFlow /= Autosize)THEN
Furnace(FurnaceNum)%DesignFanVolFlowRate = &
MAX(Furnace(FurnaceNum)%MaxHeatAirVolFlow,Furnace(FurnaceNum)%MaxCoolAirVolFlow)
ELSE
Furnace(FurnaceNum)%DesignFanVolFlowRate = Autosize
END IF
END IF
IF(FanVolFlowRate .NE. AutoSize)THEN
IF(FanVolFlowRate .LT. Furnace(FurnaceNum)%MaxCoolAirVolFlow .AND. &
Furnace(FurnaceNum)%MaxCoolAirVolFlow .NE. AutoSize)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... air flow rate = '// &
TRIM(TrimSigDigits(FanVolFlowRate,7))//&
' in fan object '//TRIM(FanName)//' is less than the maximum HVAC system air flow rate in ' &
//'cooling mode.')
CALL ShowContinueError(' The '//TRIM(cNumericFields(1))//' is reset to the' &
//' fan flow rate and the simulation continues.')
Furnace(FurnaceNum)%MaxCoolAirVolFlow = FanVolFlowRate
Furnace(FurnaceNum)%DesignFanVolFlowRate = FanVolFlowRate
END IF
IF(FanVolFlowRate .LT. Furnace(FurnaceNum)%MaxHeatAirVolFlow .AND. &
Furnace(FurnaceNum)%MaxHeatAirVolFlow .NE. AutoSize)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... air flow rate = '// &
TRIM(TrimSigDigits(FanVolFlowRate,7))//&
' in fan object '//TRIM(FanName)//' is less than the maximum HVAC system air flow rate in ' &
//'heating mode.')
CALL ShowContinueError(' The '//TRIM(cNumericFields(2))//' is reset to the' &
//' fan flow rate and the simulation continues.')
Furnace(FurnaceNum)%MaxHeatAirVolFlow = FanVolFlowRate
Furnace(FurnaceNum)%DesignFanVolFlowRate = FanVolFlowRate
END IF
END IF
!Set heating convergence tolerance
Furnace(FurnaceNum)%HeatingConvergenceTolerance = 0.001d0
!Set minimum OAT for heat pump compressor operation
! get from coil module
ErrFlag=.FALSE.
IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingAirToAirVariableSpeed) THEN
Furnace(FurnaceNum)%MinOATCompressor = GetVSCoilMinOATCompressor(HeatingCoilName,ErrFlag)
ELSE
Furnace(FurnaceNum)%MinOATCompressor = &
GetMinOATDXCoilCompressor(HeatingCoilType,HeatingCoilName,ErrFlag)
END IF
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Mine heatpump outdoor condenser node from DX coil object
ErrFlag=.FALSE.
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == CoilDX_CoolingSingleSpeed) THEN
Furnace(FurnaceNum)%CondenserNodeNum = &
GetDXCoilCondenserInletNode(CoolingCoilType,CoolingCoilName,ErrFlag)
ELSE IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) THEN
Furnace(FurnaceNum)%CondenserNodeNum = GetVSCoilCondenserInletNode(CoolingCoilName,ErrFlag)
ELSE
Furnace(FurnaceNum)%CondenserNodeNum = &
GetDXCoilCondenserInletNode('Coil:Cooling:DX:SingleSpeed', &
GetHXDXCoilName(CoolingCoilType,CoolingCoilName,ErrFlag), &
ErrFlag)
END IF
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingAirToAirVariableSpeed) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = &
GetCoilCapacityVariableSpeed(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingAirToAirVariableSpeed) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetCoilCapacityVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
!Set cooling convergence tolerance
Furnace(FurnaceNum)%CoolingConvergenceTolerance = 0.001d0
!Set the furnace max outlet temperature
Furnace(FurnaceNum)%DesignMaxOutletTemp = Numbers(4)
!Set maximum supply air temperature for supplemental heating coil
Furnace(FurnaceNum)%MaxOATSuppHeat = Numbers(5)
END DO !End of the Unitary System HeatPump Loop
!Get the Input for the Water to Air Heat Pump (UnitarySystem:HeatPump:WaterToAir)
DO HeatPumpNum = 1, NumWatertoAirHeatPump
CurrentModuleObject = 'AirLoopHVAC:UnitaryHeatPump:WaterToAir'
FanInletNode = 0
FanOutletNode = 0
CoolingCoilInletNode = 0
CoolingCoilOutletNode = 0
HeatingCoilInletNode = 0
HeatingCoilOutletNode = 0
SupHeatCoilInletNode = 0
SupHeatCoilOutletNode = 0
FurnaceNum= NumHeatOnly + NumHeatCool + NumUnitaryHeatOnly + NumUnitaryHeatCool + NumHeatPump + HeatPumpNum
CALL GetObjectItem(CurrentModuleObject,HeatPumpNum,Alphas,NumAlphas,Numbers,NumNumbers,IOStatus, &
NumBlank=lNumericBlanks,AlphaBlank=lAlphaBlanks, &
AlphaFieldNames=cAlphaFields,NumericFieldNames=cNumericFields)
IsNotOK=.FALSE.
IsBlank=.FALSE.
CALL VerifyName(Alphas(1),Furnace%Name,FurnaceNum-1,IsNotOK,IsBlank,TRIM(CurrentModuleObject)//' Name')
IF (IsNotOK) THEN
ErrorsFound=.TRUE.
IF (IsBlank) Alphas(1)='xxxxx'
ENDIF
Furnace(FurnaceNum)%FurnaceType_Num = UnitarySys_HeatPump_WaterToAir
Furnace(FurnaceNum)%Name = Alphas(1)
IF (lAlphaBlanks(2)) THEN
Furnace(FurnaceNum)%SchedPtr = ScheduleAlwaysOn
ELSE
Furnace(FurnaceNum)%SchedPtr = GetScheduleIndex(Alphas(2))
IF (Furnace(FurnaceNum)%SchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(2))//' = '//TRIM(Alphas(2)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
Furnace(FurnaceNum)%FurnaceInletNodeNum = &
GetOnlySingleNode(Alphas(3),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_Inlet,1,ObjectIsParent)
Furnace(FurnaceNum)%FurnaceOutletNodeNum = &
GetOnlySingleNode(Alphas(4),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_Outlet,1,ObjectIsParent)
CALL TestCompSet(CurrentModuleObject,Alphas(1),Alphas(3),Alphas(4),'Air Nodes')
!Get the Controlling Zone or Location of the Furnace Thermostat
Furnace(FurnaceNum)%ControlZoneNum = FindItemInList(Alphas(5),Zone%Name,NumOfZones)
IF (Furnace(FurnaceNum)%ControlZoneNum == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ENDIF
TotalZonesOnAirLoop = 0
! Get the node number for the zone with the thermostat
IF (Furnace(FurnaceNum)%ControlZoneNum > 0) THEN
AirNodeFound=.FALSE.
AirLoopFound=.FALSE.
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%ActualZoneNum /= Furnace(FurnaceNum)%ControlZoneNum) CYCLE
! Find the controlled zone number for the specified thermostat location
Furnace(FurnaceNum)%NodeNumofControlledZone=ZoneEquipConfig(ControlledZoneNum)%ZoneNode
! Determine if furnace is on air loop served by the thermostat location specified
AirLoopNumber = ZoneEquipConfig(ControlledZoneNum)%AirLoopNum
IF(AirLoopNumber .GT. 0)THEN
DO BranchNum = 1, PrimaryAirSystem(AirLoopNumber)%NumBranches
DO CompNum = 1, PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%TotalComponents
IF(.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%Name, &
Alphas(1)) .OR. &
.NOT. SameString(PrimaryAirSystem(AirLoopNumber)%Branch(BranchNum)%Comp(CompNum)%TypeOf, &
CurrentModuleObject))CYCLE
AirLoopFound=.TRUE.
EXIT
END DO
IF(AirLoopFound)EXIT
END DO
DO TstatZoneNum = 1, NumTempControlledZones
IF(TempControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
DO TstatZoneNum = 1, NumComfortControlledZones
IF(ComfortControlledZone(TstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find an AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
END IF
EXIT
ENDDO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find air node (zone with thermostat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
CALL ShowContinueError('Both a ZoneHVAC:EquipmentConnections object and a ZoneControl:Thermostat object' &
//' must be specified for this zone.')
ErrorsFound=.TRUE.
ENDIF
IF (.not. AirLoopFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowSevereError('Did not find correct AirLoopHVAC.')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ENDIF
IF(AirLoopNumber .GT. 0)THEN
DO ControlledZoneNum = 1,NumOfZones
IF (ZoneEquipConfig(ControlledZoneNum)%AirLoopNum == AirLoopNumber) THEN
TotalZonesOnAirLoop = TotalZonesOnAirLoop + 1
END IF
END DO
END IF
ENDIF
!Get fan data
FanType = Alphas(6)
FanName = Alphas(7)
ErrFlag=.FALSE.
CALL GetFanType(FanName, Furnace(FurnaceNum)%FanType_Num, ErrFlag, &
CurrentModuleObject,Alphas(1))
IF (ErrFlag) THEN
ErrorsFound=.TRUE.
END IF
IF (Furnace(FurnaceNum)%FanType_Num == FanType_SimpleOnOff)THEN
CALL ValidateComponent(FanType,FanName,IsNotOK, TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
ErrFlag=.FALSE.
CALL GetFanIndex(FanName, Furnace(FurnaceNum)%FanIndex, ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ErrFlag=.FALSE.
FanInletNode = GetFanInletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ErrFlag=.FALSE.
FanOutletNode = GetFanOutletNode(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ErrFlag=.FALSE.
Furnace(FurnaceNum)%FanAvailSchedPtr = GetFanAvailSchPtr(FanType,FanName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
ErrorsFound=.TRUE.
END IF
!Get heating coil type and name data
IF (Alphas(8) == 'COIL:HEATING:WATERTOAIRHEATPUMP:PARAMETERESTIMATION' )THEN
HeatingCoilType = Alphas(8)
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingWaterToAirHP
HeatingCoilName = Alphas(9)
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%HeatingCoilIndex = GetWtoAHPCoilIndex(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilInletNode=GetWtoAHPCoilInletNode(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilOutletNode=GetWtoAHPCoilOutletNode(HeatingCoilType, HeatingCoilName,ErrFlag)
ENDIF
ELSEIF (Alphas(8) == 'COIL:HEATING:WATERTOAIRHEATPUMP:EQUATIONFIT' )THEN
HeatingCoilType = Alphas(8)
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingWaterToAirHPSimple
HeatingCoilName = Alphas(9)
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%HeatingCoilIndex = GetWtoAHPSimpleCoilIndex(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilInletNode=GetWtoAHPSimpleCoilInletNode(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilOutletNode=GetWtoAHPSimpleCoilOutletNode(HeatingCoilType, HeatingCoilName,ErrFlag)
ENDIF
ELSEIF (Alphas(8) == 'COIL:HEATING:WATERTOAIRHEATPUMP:VARIABLESPEEDEQUATIONFIT' )THEN
HeatingCoilType = Alphas(8)
Furnace(FurnaceNum)%HeatingCoilType_Num = Coil_HeatingWaterToAirHPVSEquationFit
HeatingCoilName = Alphas(9)
CALL ValidateComponent(HeatingCoilType,HeatingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%HeatingCoilIndex = GetCoilIndexVariableSpeed(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilInletNode=GetCoilInletNodeVariableSpeed(HeatingCoilType, HeatingCoilName,ErrFlag)
HeatingCoilOutletNode=GetCoilOutletNodeVariableSpeed(HeatingCoilType, HeatingCoilName,ErrFlag)
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(8))//' = '//TRIM(Alphas(8)))
ErrorsFound=.TRUE.
END IF
! Get Cooling Coil Information if available
IF (Alphas(10) == 'COIL:COOLING:WATERTOAIRHEATPUMP:PARAMETERESTIMATION' )THEN
CoolingCoilType = Alphas(10)
Furnace(FurnaceNum)%CoolingCoilType_Num = Coil_CoolingWaterToAirHP
CoolingCoilName = Alphas(11)
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%CoolingCoilIndex = GetWtoAHPCoilIndex(CoolingCoilType, CoolingCoilName,ErrFlag)
CoolingCoilInletNode=GetWtoAHPCoilInletNode(CoolingCoilType, &
CoolingCoilName,ErrFlag)
CoolingCoilOutletNode=GetWtoAHPCoilOutletNode(CoolingCoilType, &
CoolingCoilName,ErrFlag)
ENDIF
ELSEIF (Alphas(10) == 'COIL:COOLING:WATERTOAIRHEATPUMP:EQUATIONFIT' )THEN
CoolingCoilType = Alphas(10)
Furnace(FurnaceNum)%CoolingCoilType_Num = Coil_CoolingWaterToAirHPSimple
CoolingCoilName = Alphas(11)
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%CoolingCoilIndex = GetWtoAHPSimpleCoilIndex(CoolingCoilType, CoolingCoilName,ErrFlag)
CoolingCoilInletNode=GetWtoAHPSimpleCoilInletNode(CoolingCoilType, &
CoolingCoilName,ErrFlag)
CoolingCoilOutletNode=GetWtoAHPSimpleCoilOutletNode(CoolingCoilType, &
CoolingCoilName,ErrFlag)
ENDIF
ELSEIF (Alphas(10) == 'COIL:COOLING:WATERTOAIRHEATPUMP:VARIABLESPEEDEQUATIONFIT' )THEN
CoolingCoilType = Alphas(10)
Furnace(FurnaceNum)%CoolingCoilType_Num = Coil_CoolingWaterToAirHPVSEquationFit
CoolingCoilName = Alphas(11)
CALL ValidateComponent(CoolingCoilType,CoolingCoilName,IsNotOK, &
TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%CoolingCoilIndex = GetCoilIndexVariableSpeed(CoolingCoilType, CoolingCoilName,ErrFlag)
CoolingCoilInletNode=GetCoilInletNodeVariableSpeed(CoolingCoilType, &
CoolingCoilName,ErrFlag)
CoolingCoilOutletNode=GetCoilOutletNodeVariableSpeed(CoolingCoilType, &
CoolingCoilName,ErrFlag)
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(10))//' = '//TRIM(Alphas(10)))
ErrorsFound=.TRUE.
END IF
IF (NumAlphas >= 18) THEN
! get water flow mode info before CALL SetSimpleWSHPData
IF (SameString(Alphas(18),'Constant')) Furnace(FurnaceNum)%WaterCyclingMode = WaterConstant
IF (SameString(Alphas(18),'Cycling')) Furnace(FurnaceNum)%WaterCyclingMode = WaterCycling
IF (SameString(Alphas(18),'ConstantOnDemand')) Furnace(FurnaceNum)%WaterCyclingMode = WaterConstantOnDemand
!default to draw through if not specified in input
IF (lAlphaBlanks(18)) Furnace(FurnaceNum)%WaterCyclingMode = WaterCycling
ELSE
Furnace(FurnaceNum)%WaterCyclingMode = WaterCycling
ENDIF
IF (Furnace(FurnaceNum)%WaterCyclingMode .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' illegal '//TRIM(cAlphaFields(18))//' = '//TRIM(Alphas(18)))
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! end get water flow mode info
IF (Alphas(8) == 'COIL:HEATING:WATERTOAIRHEATPUMP:EQUATIONFIT' .AND. &
Alphas(10) == 'COIL:COOLING:WATERTOAIRHEATPUMP:EQUATIONFIT') THEN
Furnace(FurnaceNum)%WatertoAirHPType = WatertoAir_Simple
CALL SetSimpleWSHPData(Furnace(FurnaceNum)%CoolingCoilIndex,ErrorsFound,Furnace(FurnaceNum)%WaterCyclingMode, &
CompanionHeatingCoilNum=Furnace(FurnaceNum)%HeatingCoilIndex)
ELSE IF(Alphas(8) == 'COIL:HEATING:WATERTOAIRHEATPUMP:PARAMETERESTIMATION' .AND. &
Alphas(10) == 'COIL:COOLING:WATERTOAIRHEATPUMP:PARAMETERESTIMATION') THEN
Furnace(FurnaceNum)%WatertoAirHPType = WatertoAir_ParEst
ELSE IF(Alphas(8) == 'COIL:HEATING:WATERTOAIRHEATPUMP:VARIABLESPEEDEQUATIONFIT' .AND. &
Alphas(10) == 'COIL:COOLING:WATERTOAIRHEATPUMP:VARIABLESPEEDEQUATIONFIT') THEN
Furnace(FurnaceNum)%WatertoAirHPType = WatertoAir_VarSpeedEquationFit
CALL SetVarSpeedCoilData(Furnace(FurnaceNum)%CoolingCoilIndex,ErrorsFound, &
CompanionHeatingCoilNum=Furnace(FurnaceNum)%HeatingCoilIndex)
ELSE
CALL ShowContinueError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Cooling coil and heating coil should be of same general type')
ErrorsFound = .TRUE.
END IF
! Get supplemental heating coil information
SuppHeatCoilType = Alphas(12)
SuppHeatCoilName = Alphas(13)
Furnace(FurnaceNum)%SuppHeatCoilType = SuppHeatCoilType
Furnace(FurnaceNum)%SuppHeatCoilName = SuppHeatCoilName
ErrFlag = .FALSE.
IF (SameString(SuppHeatCoilType,'Coil:Heating:Gas') .OR. &
SameString(SuppHeatCoilType,'Coil:Heating:Electric') ) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = GetHeatingCoilTypeNum(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE
IsNotOK = .FALSE.
CALL ValidateComponent(SuppHeatCoilType,SuppHeatCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('In '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ELSE ! mine data from the supplemental heating coil
CALL GetHeatingCoilIndex(SuppHeatCoilName,Furnace(FurnaceNum)%SuppHeatCoilIndex,IsNotOK)
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the Supplemental Heating Coil Inlet Node Number
ErrFlag=.FALSE.
SupHeatCoilInletNode = GetHeatingCoilInletNode(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
ErrorsFound=.TRUE.
ENDIF
! Get the Supplemental Heating Coil Outlet Node Number
ErrFlag=.FALSE.
SupHeatCoilOutletNode = GetHeatingCoilOutletNode(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! Get the supplemental heating coil design capacity
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignSuppHeatingCapacity = &
GetHeatingCoilCapacity(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF ! IF (IsNotOK) THEN
ENDIF
ELSEIF (SameString(SuppHeatCoilType,'Coil:Heating:Water')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = Coil_HeatingWater
CALL ValidateComponent(SuppHeatCoilType,SuppHeatCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
! Get the Heating Coil water Inlet or control Node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppCoilControlNode = GetCoilWaterInletNode('Coil:Heating:Water',SuppHeatCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil hot water max volume flow rate
ErrFlag = .FALSE.
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = GetCoilMaxWaterFlowRate('Coil:Heating:Water', &
SuppHeatCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil Inlet Node
ErrFlag = .FALSE.
SupHeatCoilInletNode = GetWaterCoilInletNode('Coil:Heating:Water',SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirInletNode = SupHeatCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the ReHeat Coil Outlet Node
ErrFlag = .FALSE.
SupHeatCoilOutletNode = GetWaterCoilOutletNode('Coil:Heating:Water',SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirOutletNode = SupHeatCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! check if user has also used a water coil controller, which they should not do
ErrFlag = .FALSE.
CALL CheckCoilWaterInletNode(Furnace(FurnaceNum)%CoilControlNode, ErrFlag)
IF (.NOT. ErrFlag) THEN ! then did find a controller so that is bad
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name) &
//' has a conflicting Controller:WaterCoil object' )
CALL ShowContinueError('Hot water coils are controlled directly by unitary and furnace systems.')
CALL ShowContinueError('No water coil controller should be input for the coil.')
ErrorsFound = .TRUE.
ENDIF
ENDIF
ELSEIF (SameString(SuppHeatCoilType,'Coil:Heating:Steam')) THEN
Furnace(FurnaceNum)%SuppHeatCoilType_Num = Coil_HeatingSteam
CALL ValidateComponent(SuppHeatCoilType,SuppHeatCoilName,IsNotOK,TRIM(CurrentModuleObject))
IF (IsNotOK) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ELSE ! mine data from heating coil object
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppHeatCoilIndex = GetSTeamCoilIndex(SuppHeatCoilType,SuppHeatCoilName,ErrFlag)
IF (Furnace(FurnaceNum)%SuppHeatCoilIndex .EQ. 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' illegal '//TRIM(cAlphaFields(12))//' = ' &
//TRIM(SuppHeatCoilName))
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam inlet node number
ErrFlag = .FALSE.
Furnace(FurnaceNum)%SuppCoilControlNode = GetSteamCoilSteamInletNode('Coil:Heating:Steam',SuppHeatCoilName,ErrFlag)
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil steam max volume flow rate
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%SuppHeatCoilIndex,ErrFlag)
IF (Furnace(FurnaceNum)%MaxSuppCoilFluidFlow .GT. 0.0d0)THEN
SteamIndex = 0 ! Function GetSatDensityRefrig will look up steam index if 0 is passed
SteamDensity=GetSatDensityRefrig("STEAM",TempSteamIn,1.0d0,SteamIndex,'GetAirLoopHVACHeatCoolInput')
Furnace(FurnaceNum)%MaxSuppCoilFluidFlow = &
GetCoilMaxSteamFlowRate(Furnace(FurnaceNum)%SuppHeatCoilIndex,ErrFlag) * SteamDensity
END IF
! Get the Heating Coil Inlet Node
ErrFlag = .FALSE.
SupHeatCoilInletNode = &
GetSteamCoilAirInletNode(Furnace(FurnaceNum)%SuppHeatCoilIndex,SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirInletNode = SupHeatCoilInletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
! Get the Heating Coil Outlet Node
ErrFlag = .FALSE.
SupHeatCoilOutletNode = &
GetSteamCoilAirOutletNode(Furnace(FurnaceNum)%SuppHeatCoilIndex,SuppHeatCoilName,ErrFlag)
Furnace(FurnaceNum)%SuppCoilAirOutletNode = SupHeatCoilOutletNode
IF(ErrFlag)THEN
CALL ShowContinueError('Occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
ErrorsFound = .TRUE.
END IF
ENDIF
ELSE
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(12))//' = '//TRIM(Alphas(12)))
ErrorsFound=.TRUE.
END IF ! IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingGas .OR. &, etc.
IF (lAlphaBlanks(14)) THEN
Furnace(FurnaceNum)%CondenserNodeNum = 0
ELSE
Furnace(FurnaceNum)%CondenserNodeNum = &
GetOnlySingleNode(Alphas(14),ErrorsFound,TRIM(CurrentModuleObject),Alphas(1), &
NodeType_Air,NodeConnectionType_OutsideAirReference,1,ObjectIsNotParent)
! need better verification.
IF (.not. CheckOutAirNodeNumber(Furnace(FurnaceNum)%CondenserNodeNum)) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError(' Node name of outdoor dry-bulb temperature sensor not valid outdoor air node= '// &
TRIM(Alphas(14)))
CALL ShowContinueError('...does not appear in an OutdoorAir:NodeList or as an OutdoorAir:Node.')
ErrorsFound=.TRUE.
END IF
ENDIF
IF (SameString(Alphas(15),'BlowThrough')) Furnace(FurnaceNum)%FanPlace = BlowThru
IF (SameString(Alphas(15),'DrawThrough')) Furnace(FurnaceNum)%FanPlace = DrawThru
IF (Furnace(FurnaceNum)%FanPlace .EQ.0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(15))//' = '//TRIM(Alphas(15)))
ErrorsFound = .TRUE.
END IF
Furnace(FurnaceNum)%FanSchedPtr = GetScheduleIndex(Alphas(16))
IF (.NOT. lAlphaBlanks(16) .AND. Furnace(FurnaceNum)%FanSchedPtr == 0) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(16))//' = '//TRIM(Alphas(16)))
ErrorsFound=.TRUE.
ELSEIF (lAlphaBlanks(16)) THEN
Furnace(FurnaceNum)%OpMode = CycFanCycCoil
IF(Furnace(FurnaceNum)%FanType_Num /= FanType_SimpleOnOff)THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Furnace(FurnaceNum)%Name))
CALL ShowContinueError(TRIM(cAlphaFields(6))//' = '//TRIM(Alphas(6)))
CALL ShowContinueError('Fan type must be Fan:OnOff when '// &
TRIM(cAlphaFields(16))//' = Blank.')
ErrorsFound=.TRUE.
END IF
ENDIF
! add the Dehumidification Type
IF (SameString(Alphas(17),'None') .OR. SameString(Alphas(17),'CoolReheat'))THEN
AirNodeFound=.FALSE.
IF(SameString(Alphas(17),'CoolReheat'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_CoolReheat
Furnace(FurnaceNum)%Humidistat = .TRUE.
IF(lAlphaBlanks(17))THEN
CALL ShowWarningError(TRIM(CurrentModuleObject)//' "'//TRIM(Alphas(1))//'"')
CALL ShowContinueError('Dehumidification control type is assumed to be None since a supplemental reheat coil '// &
'has not been specified and the simulation continues.')
Furnace(FurnaceNum)%Humidistat = .FALSE.
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
END IF
END IF
IF(SameString(Alphas(17),'None'))THEN
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
Furnace(FurnaceNum)%Humidistat = .FALSE.
END IF
IF(Furnace(FurnaceNum)%Humidistat)THEN
DO HstatZoneNum = 1, NumHumidityControlZones
IF(HumidityControlZone(HstatZoneNum)%ActualZoneNum .NE. Furnace(FurnaceNum)%ControlZoneNum)CYCLE
AirNodeFound=.TRUE.
END DO
IF (.not. AirNodeFound) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Did not find Air Node (Zone with Humidistat).')
CALL ShowContinueError('Specified '//TRIM(cAlphaFields(5))//' = '//TRIM(Alphas(5)))
ErrorsFound=.TRUE.
ENDIF
END IF
ELSE ! invalid input or blank
IF (.NOT. lAlphaBlanks(17)) THEN
CALL ShowSevereError(TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('Illegal '//TRIM(cAlphaFields(17))//' = '//TRIM(Alphas(17)))
ErrorsFound=.TRUE.
ELSE
Furnace(FurnaceNum)%Humidistat = .FALSE.
Furnace(FurnaceNum)%DehumidControlType_Num = DehumidControl_None
ENDIF
END IF
! Add fan to component sets array
IF (Furnace(FurnaceNum)%FanPlace == BlowThru) THEN
CompSetFanInlet = Alphas(3)
CompSetCoolInlet = 'UNDEFINED'
IF (FanInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between unitary system inlet node and fan inlet node.')
CALL ShowContinueError('..For "BlowThrough" fan, the inlet node name for the HeatPump should match the '// &
'fan inlet node name.')
CALL ShowContinueError('..HeatPump Inlet Node = '//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
CALL ShowContinueError('..Fan Inlet Node = '//TRIM(NodeID(FanInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (FanOutletNode /= CoolingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between fan outlet node and cooling coil inlet node.')
CALL ShowContinueError('..For "BlowThrough" fan, the fan outlet node name must match the cooling coil '// &
'inlet node name.')
CALL ShowContinueError('..Fan outlet node = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('..Cooling coil inlet node = '//TRIM(NodeID(CoolingCoilInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (CoolingCoilOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between cooling coil outlet node and heating coil inlet node.')
CALL ShowContinueError('..The cooling coil outlet node name must match the heating coil inlet node name.')
CALL ShowContinueError('..Cooling coil outlet node = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('..Heating coil inlet node = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (HeatingCoilOutletNode /= SupHeatCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between heating coil outlet node and supplemental heating coil inlet node.')
CALL ShowContinueError('..For "BlowThrough" fan, the heating coil outlet node name must match the supplemental '// &
'heating coil inlet node name.')
CALL ShowContinueError('..Heating coil outlet node = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('..Supplemental heating coil inlet node = '//TRIM(NodeID(SupHeatCoilInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (SupHeatCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between supplemental heating coil outlet node and HeatPump outlet node.')
CALL ShowContinueError('..The supplemental heating coil outlet node name must match the '// &
'HeatPump outlet node name.')
CALL ShowContinueError('..Supplemental heating coil outlet node = '//TRIM(NodeID(SupHeatCoilOutletNode)))
CALL ShowContinueError('..HeatPump outlet node = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ErrorsFound=.TRUE.
ENDIF
ELSE
CompSetFanInlet = 'UNDEFINED'
CompSetCoolInlet = Alphas(3)
IF (CoolingCoilInletNode /= Furnace(FurnaceNum)%FurnaceInletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between unitary system inlet node and cooling coil inlet node.')
CALL ShowContinueError('..For "DrawThrough" fan, the inlet node name for the HeatPump should match'// &
' the cooling coil inlet node name.')
CALL ShowContinueError('..HeatPump inlet node = '//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceInletNodeNum)))
CALL ShowContinueError('..Cooling coil inlet node = '//TRIM(NodeID(CoolingCoilInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (CoolingCoilOutletNode /= HeatingCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between cooling coil outlet node and heating coil inlet node.')
CALL ShowContinueError('..The outlet node name for the cooling coil should match'// &
' the heating coil inlet node name.')
CALL ShowContinueError('..Cooling coil outlet node = '//TRIM(NodeID(CoolingCoilOutletNode)))
CALL ShowContinueError('..Heating coil inlet node = '//TRIM(NodeID(HeatingCoilInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (HeatingCoilOutletNode /= FanInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between heating coil outlet node and fan inlet node.')
CALL ShowContinueError('..For "DrawThrough" fan, the outlet node name for the heating coil should match'// &
' the fan inlet node name.')
CALL ShowContinueError('..Heating coil outlet node = '//TRIM(NodeID(HeatingCoilOutletNode)))
CALL ShowContinueError('..Fan inlet node = '//TRIM(NodeID(FanInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (FanOutletNode /= SupHeatCoilInletNode) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between fan outlet node and supplemental heating coil inlet node.')
CALL ShowContinueError('..For "DrawThrough" fan, the outlet node name for the fan should match the '// &
'supplemental heating coil inlet node name.')
CALL ShowContinueError('..Fan outlet node = '//TRIM(NodeID(FanOutletNode)))
CALL ShowContinueError('..Supplemental heating coil inlet node = '//TRIM(NodeID(SupHeatCoilInletNode)))
ErrorsFound=.TRUE.
ENDIF
IF (SupHeatCoilOutletNode /= Furnace(FurnaceNum)%FurnaceOutletNodeNum) THEN
CALL ShowSevereError('For '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1))//&
', Mismatch between supplemental heating coil outlet node and HeatPump outlet node.')
CALL ShowContinueError('..The supplemental heating coil outlet node name must match the '// &
'HeatPump outlet node name.')
CALL ShowContinueError('..Supplemental heating coil outlet node = '//TRIM(NodeID(SupHeatCoilOutletNode)))
CALL ShowContinueError('..HeatPump outlet node = ' &
//TRIM(NodeID(Furnace(FurnaceNum)%FurnaceOutletNodeNum)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
! (Set up validation here for the fan or cooling coil inlet?)
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(6),Alphas(7),CompSetFanInlet,'UNDEFINED')
! Add DX heating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(8),Alphas(9),'UNDEFINED','UNDEFINED')
! Add DX cooling coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(10),Alphas(11),CompSetCoolInlet,'UNDEFINED')
! Add supplemental heating coil to component sets array
CALL SetUpCompSets(CurrentModuleObject, Alphas(1), &
Alphas(12),Alphas(13),'UNDEFINED',Alphas(4))
!Set the Design Fan Volume Flow Rate
ErrFlag=.FALSE.
FanVolFlowRate = GetFanDesignVolumeFlowRate(FanType,FanName,ErrFlag)
Furnace(FurnaceNum)%ActualFanVolFlowRate = FanVolFlowRate
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
! CR8094 - simple water to air heat pump MUST operate at the same flow rate specified in the coil objects
! Furnace(FurnaceNum)%DesignFanVolFlowRate = Numbers(1)
! Furnace(FurnaceNum)%MaxHeatAirVolFlow = Furnace(FurnaceNum)%DesignFanVolFlowRate
! Furnace(FurnaceNum)%MaxCoolAirVolFlow = Furnace(FurnaceNum)%DesignFanVolFlowRate
! parameter estimate model only specifies air flow rate in parent object
IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingWaterToAirHP) THEN
Furnace(FurnaceNum)%MaxHeatAirVolFlow = Numbers(1)
Furnace(FurnaceNum)%MaxCoolAirVolFlow = Numbers(1)
! simple HP model specifies air flow rate in both the parent and child coils. Use coil air flow rates.
! simple HP model air flow rate input will not be used.
ELSEIF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingWaterToAirHPSimple) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%MaxHeatAirVolFlow = GetWtoAHPSimpleCoilAirFlow(HeatingCoilType,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%MaxCoolAirVolFlow = GetWtoAHPSimpleCoilAirFlow(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ELSEIF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingWaterToAirHPVSEquationFit) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%MaxHeatAirVolFlow = GetCoilAirFlowRateVariableSpeed(HeatingCoilType,HeatingCoilName,ErrFlag)
Furnace(FurnaceNum)%MaxCoolAirVolFlow = GetCoilAirFlowRateVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlow = &
MIN(Furnace(FurnaceNum)%MaxHeatAirVolFlow,Furnace(FurnaceNum)%MaxCoolAirVolFlow)
IF(Furnace(FurnaceNum)%MaxHeatAirVolFlow /= Autosize .AND. &
Furnace(FurnaceNum)%MaxCoolAirVolFlow /= Autosize)THEN
Furnace(FurnaceNum)%DesignFanVolFlowRate = &
MAX(Furnace(FurnaceNum)%MaxHeatAirVolFlow,Furnace(FurnaceNum)%MaxCoolAirVolFlow)
ELSE
Furnace(FurnaceNum)%DesignFanVolFlowRate = Autosize
END IF
Furnace(FurnaceNum)%AirFlowControl = UseCompressorOnFlow
IF (FanVolFlowRate /= AutoSize .and. Furnace(FurnaceNum)%DesignFanVolFlowRate /= AutoSize) THEN
IF (Furnace(FurnaceNum)%DesignFanVolFlowRate > FanVolFlowRate) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... has a Cooling or Heating Air Flow Rate > Max Fan Volume Flow Rate, should be <=.')
CALL ShowContinueError('... Entered value='//TRIM(RoundSigDigits(Furnace(FurnaceNum)%DesignFanVolFlowRate,2))// &
'... Fan ['//TRIM(FanType)//':'//TRIM(FanName)// &
'] Max Value='//TRIM(RoundSigDigits(FanVolFlowRate,2)))
ENDIF
ENDIF
IF (FanVolFlowRate /= AutoSize .and. Furnace(FurnaceNum)%DesignFanVolFlowRate /= AutoSize) THEN
IF (Furnace(FurnaceNum)%DesignFanVolFlowRate <= 0.0d0) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
CALL ShowContinueError('... has a Design Fan Flow Rate <= 0.0, it must be >0.0')
CALL ShowContinueError('... Entered value='//TRIM(RoundSigDigits(Furnace(FurnaceNum)%DesignFanVolFlowRate,2)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
!Set the heat pump heating coil capacity
! Get from coil module.
IF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingWaterToAirHP) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = &
GetWtoAHPCoilCapacity(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ELSEIF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingWaterToAirHPSimple) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = &
GetWtoAHPSimpleCoilCapacity(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ELSEIF (Furnace(FurnaceNum)%HeatingCoilType_Num == Coil_HeatingWaterToAirHPVSEquationFit) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignHeatingCapacity = &
GetCoilCapacityVariableSpeed(HeatingCoilType,HeatingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
!Set the heat pump heating coil convergence
Furnace(FurnaceNum)%HeatingConvergenceTolerance = Numbers(2)
!Set the heat pump cooling coil capacity (Total capacity)
! Get from coil module.
IF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingWaterToAirHP) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetWtoAHPCoilCapacity(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ELSEIF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingWaterToAirHPSimple) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetWtoAHPSimpleCoilCapacity(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ELSEIF (Furnace(FurnaceNum)%CoolingCoilType_Num == Coil_CoolingWaterToAirHPVSEquationFit) THEN
ErrFlag=.FALSE.
Furnace(FurnaceNum)%DesignCoolingCapacity = &
GetCoilCapacityVariableSpeed(CoolingCoilType,CoolingCoilName,ErrFlag)
IF (ErrFlag) THEN
CALL ShowContinueError('...occurs in '//TRIM(CurrentModuleObject)//' = '//TRIM(Alphas(1)))
ErrorsFound=.TRUE.
ENDIF
ENDIF
!Set the heat pump cooling coil convergence
Furnace(FurnaceNum)%CoolingConvergenceTolerance = Numbers(3)
!Set the heatpump cycling rate
Furnace(FurnaceNum)%MaxONOFFCyclesperHour = Numbers(4)
!Set the heat pump time constant
Furnace(FurnaceNum)%HPTimeConstant = Numbers(5)
!Set the heat pump on-cycle power use fraction
Furnace(FurnaceNum)%OnCyclePowerFraction = Numbers (6)
!Set the heat pump fan delay time
Furnace(FurnaceNum)%FanDelayTime = Numbers(7)
!Set the heatpump design supplemental heating capacity
! Get from coil module.
!Set the heatpump max outlet temperature
Furnace(FurnaceNum)%DesignMaxOutletTemp = Numbers(8)
!Set maximum supply air temperature for supplemental heating coil
Furnace(FurnaceNum)%MaxOATSuppHeat = Numbers(9)
END DO !End of the Unitary System WatertoAirHeatPump Loop
DEALLOCATE(Alphas)
DEALLOCATE(Numbers)
IF (ErrorsFound) THEN
CALL ShowFatalError('Errors found in getting Furnace or Unitary System input.')
ENDIF
DO HeatOnlyNum = 1, NumHeatOnly
FurnaceNum= HeatOnlyNum
! Setup Report variables for the Furnace that are not reported in the components themselves
CALL SetupOutputVariable('Unitary System Fan Part Load Ratio []',Furnace(FurnaceNum)%FanPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
IF (AnyEnergyManagementSystemInModel) THEN
CALL SetupEMSActuator('AirLoopHVAC:Unitary:Furnace:HeatOnly', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate', '[m3/s]', &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideOn, &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideValue )
ENDIF
END DO
DO UnitaryHeatOnlyNum = NumHeatOnly + 1, NumHeatOnly + NumUnitaryHeatOnly
FurnaceNum= UnitaryHeatOnlyNum
! Setup Report variables for Unitary System that are not reported in the components themselves
CALL SetupOutputVariable('Unitary System Fan Part Load Ratio []',Furnace(FurnaceNum)%FanPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
IF (AnyEnergyManagementSystemInModel) THEN
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatOnly', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate', '[m3/s]', &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideOn, &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideValue )
ENDIF
END DO
DO HeatCoolNum = NumHeatOnly + NumUnitaryHeatOnly + 1, NumHeatOnly + NumUnitaryHeatOnly + NumHeatCool
FurnaceNum= HeatCoolNum
! Setup Report variables for the Furnace that are not reported in the components themselves
CALL SetupOutputVariable('Unitary System Fan Part Load Ratio []',Furnace(FurnaceNum)%FanPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Compressor Part Load Ratio []',Furnace(FurnaceNum)%CompPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
IF (AnyEnergyManagementSystemInModel) THEN
CALL SetupEMSActuator('AirLoopHVAC:Unitary:Furnace:HeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate', '[m3/s]', &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideOn, &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideValue )
CALL SetupEMSActuator('AirLoopHVAC:Unitary:Furnace:HeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate During Cooling Operation', '[m3/s]', &
Furnace(FurnaceNum)%MaxCoolAirVolFlowEMSOverrideOn, &
Furnace(FurnaceNum)%MaxCoolAirVolFlowEMSOverrideValue )
CALL SetupEMSActuator('AirLoopHVAC:Unitary:Furnace:HeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate During Heating Operation', '[m3/s]', &
Furnace(FurnaceNum)%MaxHeatAirVolFlowEMSOverrideOn, &
Furnace(FurnaceNum)%MaxHeatAirVolFlowEMSOverrideValue )
CALL SetupEMSActuator('AirLoopHVAC:Unitary:Furnace:HeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate During No Heating or Cooling Operation', '[m3/s]', &
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlowEMSOverrideOn, &
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlowEMSOverrideValue )
ENDIF
END DO
DO UnitaryHeatCoolNum = NumHeatOnly+NumHeatCool+NumUnitaryHeatOnly+1, &
NumHeatOnly+NumHeatCool+NumUnitaryHeatOnly+NumUnitaryHeatCool
FurnaceNum= UnitaryHeatCoolNum
! Setup Report variables for Unitary System that are not reported in the components themselves
CALL SetupOutputVariable('Unitary System Fan Part Load Ratio []',Furnace(FurnaceNum)%FanPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Compressor Part Load Ratio []',Furnace(FurnaceNum)%CompPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
IF (AnyEnergyManagementSystemInModel) THEN
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate', '[m3/s]', &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideOn, &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideValue )
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate During Cooling Operation', '[m3/s]', &
Furnace(FurnaceNum)%MaxCoolAirVolFlowEMSOverrideOn, &
Furnace(FurnaceNum)%MaxCoolAirVolFlowEMSOverrideValue )
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate During Heating Operation', '[m3/s]', &
Furnace(FurnaceNum)%MaxHeatAirVolFlowEMSOverrideOn, &
Furnace(FurnaceNum)%MaxHeatAirVolFlowEMSOverrideValue )
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatCool', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate During No Heating or Cooling Operation', '[m3/s]', &
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlowEMSOverrideOn, &
Furnace(FurnaceNum)%MaxNoCoolHeatAirVolFlowEMSOverrideValue )
ENDIF
END DO
DO HeatPumpNum = NumHeatOnly+NumHeatCool+NumUnitaryHeatOnly+NumUnitaryHeatCool+1, NumFurnaces-NumWaterToAirHeatPump
FurnaceNum= HeatPumpNum
! Setup Report variables for Unitary System that are not reported in the components themselves
CALL SetupOutputVariable('Unitary System Fan Part Load Ratio []',Furnace(FurnaceNum)%FanPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Compressor Part Load Ratio []',Furnace(FurnaceNum)%CompPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Dehumidification Induced Heating Demand Rate [W]', &
Furnace(FurnaceNum)%DehumidInducedHeatingDemandRate, 'System','Average', &
Furnace(FurnaceNum)%Name)
IF (AnyEnergyManagementSystemInModel) THEN
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatPump:AirToAir', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate', '[m3/s]', &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideOn, &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideValue )
ENDIF
END DO
DO HeatPumpNum = NumHeatOnly+NumHeatCool+NumUnitaryHeatOnly+NumUnitaryHeatCool+NumHeatPump+1, NumFurnaces
FurnaceNum= HeatPumpNum
! Setup Report variables for Unitary System that are not reported in the components themselves
CALL SetupOutputVariable('Unitary System Fan Part Load Ratio []',Furnace(FurnaceNum)%FanPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Compressor Part Load Ratio []',Furnace(FurnaceNum)%CompPartLoadRatio, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Requested Sensible Cooling Rate [W]',Furnace(FurnaceNum)%CoolingCoilSensDemand, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Requested Latent Cooling Rate [W]',Furnace(FurnaceNum)%CoolingCoilLatentDemand, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Requested Heating Rate [W]',Furnace(FurnaceNum)%HeatingCoilSensDemand, &
'System','Average',Furnace(FurnaceNum)%Name)
CALL SetupOutputVariable('Unitary System Dehumidification Induced Heating Demand Rate [W]', &
Furnace(FurnaceNum)%DehumidInducedHeatingDemandRate, 'System','Average', &
Furnace(FurnaceNum)%Name)
IF (AnyEnergyManagementSystemInModel) THEN
CALL SetupEMSActuator('AirLoopHVAC:UnitaryHeatPump:WaterToAir', Furnace(FurnaceNum)%Name, &
'Autosized Supply Air Flow Rate', '[m3/s]', &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideOn, &
Furnace(FurnaceNum)%DesignFanVolFlowRateEMSOverrideValue )
ENDIF
END DO
IF (AnyEnergyManagementSystemInModel) THEN
DO FurnaceNum = 1, NumFurnaces
CALL SetupEMSInternalVariable('Unitary HVAC Design Heating Capacity', Furnace(FurnaceNum)%Name, '[W]', &
Furnace(FurnaceNum)%DesignHeatingCapacity )
CALL SetupEMSInternalVariable('Unitary HVAC Design Cooling Capacity', Furnace(FurnaceNum)%Name, '[W]', &
Furnace(FurnaceNum)%DesignCoolingCapacity )
CALL SetupEMSActuator('Unitary HVAC', Furnace(FurnaceNum)%Name, 'Sensible Load Request' , '[W]', &
Furnace(FurnaceNum)%EMSOverrideSensZoneLoadRequest, Furnace(FurnaceNum)%EMSSensibleZoneLoadValue )
CALL SetupEMSActuator('Unitary HVAC', Furnace(FurnaceNum)%Name, 'Moisture Load Request' , '[W]', &
Furnace(FurnaceNum)%EMSOverrideMoistZoneLoadRequest, Furnace(FurnaceNum)%EMSMoistureZoneLoadValue )
ENDDO
ENDIF
CALL ManageEMS(emsCallFromComponentGetInput)
RETURN
END SUBROUTINE GetFurnaceInput