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) | :: | WellNum |
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 CalcGroundwaterWell(WellNum)
! SUBROUTINE INFORMATION:
! AUTHOR B. Griffith
! DATE WRITTEN August 2006
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Collect the calculations used to update the modeled values
! for the groundwater wells at each system timestep
!
! METHODOLOGY EMPLOYED:
! starting simple and ignoring well storage and complex rate restrictions.
! just uses nominal pump rate and power (assuming well designed well).
! REFERENCES:
! na
! USE STATEMENTS:
USE DataGlobals, only: BeginTimeStepFlag, SecInHour
USE DataHVACGlobals, ONLY: TimeStepSys
USE DataEnvironment , only:GroundTemp_Deep
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
INTEGER, Intent(IN) :: WellNum ! Index of well
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS:
! na
! DERIVED TYPE DEFINITIONS:
! see DataWater.f90
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
REAL(r64) :: VdotDelivered
! REAL(r64) :: VdotRequest
REAL(r64) :: PumpPower
If (BeginTimeStepFlag) then
! do any updating needed
! GroundwaterWell(WellNum)%VdotRequest = 0.0
endif
VdotDelivered = 0.0d0
PumpPower = 0.0d0
If (GroundwaterWell(WellNum)%VdotRequest > 0.0d0) Then
IF (GroundwaterWell(WellNum)%VdotRequest >= GroundwaterWell(WellNum)%PumpNomVolFlowRate) Then ! run flat out
WaterStorage(GroundwaterWell(WellNum)%StorageTankID)%VdotAvailSupply(GroundwaterWell(WellNum)%StorageTankSupplyARRID) &
= GroundwaterWell(WellNum)%PumpNomVolFlowRate
WaterStorage(GroundwaterWell(WellNum)%StorageTankID)%TwaterSupply(GroundwaterWell(WellNum)%StorageTankSupplyARRID) &
= GroundTemp_Deep
VdotDelivered = GroundwaterWell(WellNum)%PumpNomVolFlowRate
PumpPower = GroundwaterWell(WellNum)%PumpNomPowerUse
endif
! the run at part load to just meet request
If (GroundwaterWell(WellNum)%VdotRequest < GroundwaterWell(WellNum)%PumpNomVolFlowRate) Then
WaterStorage(GroundwaterWell(WellNum)%StorageTankID)%VdotAvailSupply(GroundwaterWell(WellNum)%StorageTankSupplyARRID) &
= GroundwaterWell(WellNum)%VdotRequest
WaterStorage(GroundwaterWell(WellNum)%StorageTankID)%TwaterSupply(GroundwaterWell(WellNum)%StorageTankSupplyARRID) &
= GroundTemp_Deep
VdotDelivered = GroundwaterWell(WellNum)%VdotRequest
PumpPower = GroundwaterWell(WellNum)%PumpNomPowerUse * &
GroundwaterWell(WellNum)%VdotRequest / GroundwaterWell(WellNum)%PumpNomVolFlowRate
ENDIF
ENDIF
GroundwaterWell(WellNum)%VdotDelivered = VdotDelivered
GroundwaterWell(WellNum)%VolDelivered = VdotDelivered * TimeStepSys * SecInHour
GroundwaterWell(WellNum)%PumpPower = PumpPower
GroundwaterWell(WellNum)%PumpEnergy = PumpPower * TimeStepSys * SecInHour
RETURN
END SUBROUTINE CalcGroundwaterWell