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) | :: | InletNodeNum | |||
integer, | intent(in) | :: | OutletNodeNum | |||
integer, | intent(in), | optional | :: | LoopNum | ||
real(kind=r64), | intent(in), | optional | :: | OutletTemp |
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 SafeCopyPlantNode( InletNodeNum, OutletNodeNum, LoopNum, OutletTemp )
! SUBROUTINE INFORMATION:
! AUTHOR B. Griffith
! DATE WRITTEN February, 2010
! MODIFIED na
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Provide a safer alternative for Node(outlet) = Node(inlet)
! Intended just for plant
! METHODOLOGY EMPLOYED:
! Copy over state variables but not setpoints
! derived from adiabatic Pipes
!
! REFERENCES:
! na
! USE STATEMENTS:
USE DataLoopNode , ONLY : Node
USE DataPlant, ONLY : PlantLoop
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
INTEGER , INTENT(IN) :: InletNodeNum
INTEGER , INTENT(IN) :: OutletNodeNum
INTEGER , INTENT(IN) , OPTIONAL :: LoopNum
REAL(r64), INTENT(IN), OPTIONAL :: OutletTemp !set on outlet node if present and water.
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS:
! na
! DERIVED TYPE DEFINITIONS:
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
Node(OutletNodeNum)%FluidType = Node(InletNodeNum)%FluidType
Node(OutletNodeNum)%Temp = Node(InletNodeNum)%Temp
Node(OutletNodeNum)%MassFlowRate = Node(InletNodeNum)%MassFlowRate
Node(OutletNodeNum)%Quality = Node(InletNodeNum)%Quality
Node(OutletNodeNum)%Enthalpy = Node(InletNodeNum)%Enthalpy ! should have routines that keep this current with temp?
Node(OutletNodeNum)%TempMin = Node(InletNodeNum)%TempMin
Node(OutletNodeNum)%TempMax = Node(InletNodeNum)%TempMax
!DSU3 not don't do this, upstream components outlet might stomp on this components inlet
! so don't propagate hardware limits downstream. Node(OutletNodeNum)%MassFlowRateMin = Node(InletNodeNum)%MassFlowRateMin
!DSU3 not don't do this Node(OutletNodeNum)%MassFlowRateMax = Node(InletNodeNum)%MassFlowRateMax
! DSU3 hopefully these next two go away once changes are broadly implemented...
Node(OutletNodeNum)%MassFlowRateMinAvail = MAX(Node(InletNodeNum)%MassFlowRateMin, Node(InletNodeNum)%MassFlowRateMinAvail)
Node(OutletNodeNum)%MassFlowRateMaxAvail = MIN(Node(InletNodeNum)%MassFlowRateMax, Node(InletNodeNum)%MassFlowRateMaxAvail)
Node(OutletNodeNum)%HumRat = Node(InletNodeNum)%HumRat ! air only?
!Only pass pressure if we aren't doing a pressure simulation
IF (Present(LoopNum)) THEN
IF (PlantLoop(LoopNum)%PressureSimType > 1) THEN
!Don't do anything
ELSE
Node(OutletNodeNum)%Press = Node(InletNodeNum)%Press
ENDIF
ENDIF
RETURN
END SUBROUTINE SafeCopyPlantNode