Nodes of different colours represent the following:
Solid arrows point from a parent (sub)module to the submodule which is descended from it. Dashed arrows point from a module being used to the module or program unit using it. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer, | intent(in) | :: | PVTnum |
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module. Where possible, edges connecting nodes are given different colours to make them easier to distinguish in large graphs.
SUBROUTINE SizePVT(PVTnum)
! SUBROUTINE INFORMATION:
! AUTHOR Brent Griffith
! DATE WRITTEN August 2008
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! This subroutine is for sizing PVT flow rates that
! have not been specified in the input.
! METHODOLOGY EMPLOYED:
! Obtains hot water flow rate from the plant sizing array.
! REFERENCES:
! na
! USE STATEMENTS:
USE DataSizing
USE DataPlant, ONLY: PlantLoop, SupplySide, DemandSide
USE DataInterfaces, ONLY: ShowFatalError, ShowSevereError, ShowContinueError, SetupOutputVariable
USE DataHVACGlobals, ONLY: SmallWaterVolFlow, SmallAirVolFlow, Main, Cooling, Heating, Other
USE PlantUtilities, ONLY: RegisterPlantCompDesignFlow
USE ReportSizingManager, ONLY: ReportSizingOutput
USE OutputReportPredefined
USE DataAirSystems, ONLY: PrimaryAirSystem
USE DataAirLoop, ONLY: AirLoopControlInfo
USE DataEnvironment , ONLY: StdRhoAir
USE DataLoopNode , ONLY: Node
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
INTEGER, INTENT(IN) :: PVTnum
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: PltSizNum ! Plant Sizing index corresponding to CurLoopNum
LOGICAL :: ErrorsFound ! If errors detected in input
!unused1208 CHARACTER(len=MaxNameLength) :: equipName ! Name of boiler object
REAL(r64) :: DesVolFlow
REAL(r64) :: DesMassFlow
PltSizNum = 0
ErrorsFound = .FALSE.
IF (PVT(PVTnum)%WorkingFluidType == LiquidWorkingFluid) THEN
IF ( .NOT. ALLOCATED(PlantSizData)) RETURN
If ( .NOT. ALLOCATED(PlantLoop ) ) RETURN
IF (PVT(PVTnum)%WLoopNum > 0) THEN
PltSizNum = PlantLoop(PVT(PVTnum)%WLoopNum)%PlantSizNum
END IF
IF (PVT(PVTnum)%DesignVolFlowRate == AutoSize) THEN
IF (PVT(PVTnum)%WLoopSideNum == SupplySide) Then
IF (PltSizNum > 0) THEN
IF (PlantSizData(PltSizNum)%DesVolFlowRate >= SmallWaterVolFlow) THEN
DesVolFlow = PlantSizData(PltSizNum)%DesVolFlowRate
ELSE
DesVolFlow = 0.0d0
END IF
PVT(PVTnum)%DesignVolFlowRate = DesVolFlow
ELSE
CALL ShowSevereError('Autosizing of PVT solar collector design flow rate requires a Sizing:Plant object')
CALL ShowContinueError('Occurs in PVT object='//TRIM(PVT(PVTnum)%Name))
ErrorsFound = .TRUE.
END IF
ELSEIF (PVT(PVTnum)%WLoopSideNum == DemandSide) THEN
PVT(PVTnum)%DesignVolFlowRate = PVT(PVTnum)%AreaCol * SimplePVTWaterSizeFactor
ENDIF
CALL ReportSizingOutput('SolarCollector:FlatPlate:PhotovoltaicThermal', PVT(PVTnum)%Name, &
'Design Flow Rate [m3/s]', &
PVT(PVTnum)%DesignVolFlowRate)
CALL RegisterPlantCompDesignFlow( PVT(PVTnum)%PlantInletNodeNum, PVT(PVTnum)%DesignVolFlowRate )
PVT(PVTnum)%SizingInit = .FALSE.
END IF
ENDIF !plant component
IF (PVT(PVTnum)%WorkingFluidType == AirWorkingFluid) THEN
IF (PVT(PVTnum)%DesignVolFlowRate == AutoSize) THEN
IF (CurSysNum > 0) THEN
CALL CheckSysSizing('SolarCollector:FlatPlate:PhotovoltaicThermal', PVT(PVTnum)%Name)
IF (CurOASysNum > 0) THEN
DesVolFlow = FinalSysSizing(CurSysNum)%DesOutAirVolFlow
ELSE
SELECT CASE(CurDuctType)
CASE(Main)
DesVolFlow = FinalSysSizing(CurSysNum)%SysAirMinFlowRat*FinalSysSizing(CurSysNum)%DesMainVolFlow
CASE(Cooling)
DesVolFlow = FinalSysSizing(CurSysNum)%SysAirMinFlowRat*FinalSysSizing(CurSysNum)%DesCoolVolFlow
CASE(Heating)
DesVolFlow = FinalSysSizing(CurSysNum)%DesHeatVolFlow
CASE(Other)
DesVolFlow = FinalSysSizing(CurSysNum)%DesMainVolFlow
CASE DEFAULT
DesVolFlow = FinalSysSizing(CurSysNum)%DesMainVolFlow
END SELECT
END IF
DesMassFlow = StdRhoAir *DesVolFlow
PVT(PVTnum)%DesignVolFlowRate = DesVolFlow
PVT(PVTnum)%MaxMassFlowRate = DesMassFlow
CALL ReportSizingOutput('SolarCollector:FlatPlate:PhotovoltaicThermal', PVT(PVTnum)%Name, &
'Design Flow Rate [m3/s]', &
PVT(PVTnum)%DesignVolFlowRate)
PVT(PVTnum)%SizingInit = .FALSE.
ELSE IF (CurZoneEqNum > 0) THEN
! PVT is not currently for zone equipment, should not come here.
ENDIF
ENDIF
ENDIF
IF (ErrorsFound) THEN
CALL ShowFatalError('Preceding sizing errors cause program termination')
END IF
RETURN
END SUBROUTINE SizePVT