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 | ||
---|---|---|---|---|---|---|
character(len=*), | intent(in) | :: | LoopName | |||
character(len=*), | intent(in) | :: | BranchName | |||
real(kind=r64), | intent(out) | :: | BranchMaxFlow | |||
integer, | intent(out) | :: | PressCurveType | |||
integer, | intent(out) | :: | PressCurveIndex | |||
integer, | intent(inout) | :: | NumComps | |||
character(len=MaxNameLength), | intent(out), | DIMENSION(:) | :: | CompType | ||
character(len=MaxNameLength), | intent(out), | DIMENSION(:) | :: | CompName | ||
character(len=MaxNameLength), | intent(out), | DIMENSION(:) | :: | CompInletNodeNames | ||
integer, | intent(out), | DIMENSION(:) | :: | CompInletNodeNums | ||
character(len=MaxNameLength), | intent(out), | DIMENSION(:) | :: | CompOutletNodeNames | ||
integer, | intent(out), | DIMENSION(:) | :: | CompOutletNodeNums | ||
logical, | intent(inout) | :: | ErrorsFound |
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 GetBranchData(LoopName,BranchName,BranchMaxFlow,PressCurveType,PressCurveIndex,NumComps,CompType,CompName, &
CompInletNodeNames,CompInletNodeNums,CompOutletNodeNames,CompOutletNodeNums,ErrorsFound)
! SUBROUTINE INFORMATION:
! AUTHOR Linda K. Lawrie
! DATE WRITTEN October 1999
! MODIFIED October 2001, Automatic Extensibility
! September 2012, B. Griffith, removed component control types
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! This routine gets the Branch Data (internal structure) for the requested
! Branch Name and returns it in "list structure" to the calling routine.
! METHODOLOGY EMPLOYED:
! na
! REFERENCES:
! na
! USE STATEMENTS:
USE General, ONLY: TrimSigDigits
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
CHARACTER(len=*), INTENT(IN) :: LoopName ! Loop Name of this Branch
CHARACTER(len=*), INTENT(IN) :: BranchName ! Requested Branch Name
REAL(r64), INTENT(OUT) :: BranchMaxFlow ! Max Flow Rate for Branch
INTEGER, INTENT(OUT) :: PressCurveType ! Index of a pressure curve object
INTEGER, INTENT(OUT) :: PressCurveIndex ! Index of a pressure curve object
INTEGER, INTENT(INOUT) :: NumComps ! Number of Components on Branch
CHARACTER(len=MaxNameLength), INTENT(OUT), &
DIMENSION(:) :: CompType ! Component Type for each item on Branch
CHARACTER(len=MaxNameLength), INTENT(OUT), &
DIMENSION(:) :: CompName ! Component Name for each item on Branch
CHARACTER(len=MaxNameLength), INTENT(OUT), &
DIMENSION(:) :: CompInletNodeNames ! Component Inlet Node IDs for each item on Branch
INTEGER, INTENT(OUT), &
DIMENSION(:) :: CompInletNodeNums ! Component Inlet Node Numbers for each item on Branch
CHARACTER(len=MaxNameLength), INTENT(OUT), &
DIMENSION(:) :: CompOutletNodeNames ! Component Outlet Node IDs for each item on Branch
INTEGER, INTENT(OUT), &
DIMENSION(:) :: CompOutletNodeNums ! Component Outlet Node Numbers for each item on Branch
LOGICAL, INTENT(INOUT) :: ErrorsFound
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER :: Count ! Loop Counter
TYPE (ComponentData), ALLOCATABLE, SAVE, &
DIMENSION(:) :: BComponents ! Component data to be returned
INTEGER :: MinCompsAllowed
! NumComps now defined on input
ALLOCATE(BComponents(NumComps))
CALL GetInternalBranchData(LoopName,BranchName,BranchMaxFlow,PressCurveType,PressCurveIndex,NumComps,BComponents,ErrorsFound)
MinCompsAllowed=MIN(SIZE(CompType),SIZE(CompName),SIZE(CompInletNodeNames), &
SIZE(CompInletNodeNums),SIZE(CompOutletNodeNames),SIZE(CompOutletNodeNums))
IF (MinCompsAllowed < NumComps) THEN
CALL ShowSevereError('GetBranchData: Component List arrays not big enough to hold Number of Components')
CALL ShowContinueError('Input BranchName='//TRIM(BranchName)//', in Loop='//TRIM(LoopName))
CALL ShowContinueError('Max Component Array size='//TRIM(TrimSigDigits(MinCompsAllowed))// &
', but input size='//TRIM(TrimSigDigits(NumComps)))
CALL ShowFatalError('Program terminates due to preceding conditions.')
ENDIF
DO Count=1,NumComps
CompType(Count)=BComponents(Count)%CType
CompName(Count)=BComponents(Count)%Name
CompInletNodeNames(Count)=BComponents(Count)%InletNodeName
CompInletNodeNums(Count)=BComponents(Count)%InletNode
CompOutletNodeNames(Count)=BComponents(Count)%OutletNodeName
CompOutletNodeNums(Count)=BComponents(Count)%OutletNode
ENDDO
DEALLOCATE(BComponents)
RETURN
END SUBROUTINE GetBranchData