Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=r64) | :: | X(:) | ||||
real(kind=r64), | intent(inout) | :: | AP(:) | |||
real(kind=r64), | intent(in) | :: | AE(:) | |||
real(kind=r64), | intent(in) | :: | AW(:) | |||
real(kind=r64), | intent(in) | :: | BP(:) | |||
integer | :: | N |
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 AUTOTDMA(X,AP,AE,AW,BP, N)
!
! SUBROUTINE INFORMATION:
! AUTHOR JOHN L. WRIGHT
! DATE WRITTEN unknown
! MODIFIED na
!
! RE-ENGINEERED na
! PURPOSE OF THIS SUBROUTINE:
! Matrix solver manager routine
!
! METHODOLOGY EMPLOYED:
! 1-D TDMA solver.
!
! REFERENCES:
! na
!
! USE STATEMENTS:
! na
!
!
IMPLICIT NONE
! SUBROUTINE ARGUMENT DEFINITIONS:
REAL(r64), INTENT( INOUT) :: AP(:)
REAL(r64), INTENT( IN) :: AE(:),AW(:),BP(:)
!
! SUBROUTINE PARAMETER DEFINITIONS:
! na
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
REAL(r64) :: X(:)
INTEGER :: N
! Flow
! Call TDMA for forward (i.e., west-to-east and back) calculation
! or TDMA_R for reverse (i.e., east-to-west and back) calculation
! TDMA won't tolerate RHOSFxx(1)=0 (i.e., ap(1)=0)
! but TDMA_R won't tolerate RHOSBxx(N-1)=0 (i.e., ap(n)=0)
! where n-1 refers to the outdoor layer (glazing or shading layer)
! This if-statement will catch the situation where RHOSFxx(1)=0.
! i.e., AP(1)=0.
IF (AP(1) .LT. AP(N)) THEN
CALL TDMA_R(X,AP,AE,AW,BP,N)
ELSE
! This "fix" (on the next line) is only used as a last resort
! The if-statement will catch the very unusual situation where both
! RHOSBxx(N-1)=0. AND RHOSFxx(1)=0.
IF (AP(1) .LT. 0.0001d0) AP(1)=0.0001d0
CALL TDMA(X,AP,AE,AW,BP,N)
ENDIF
RETURN
END SUBROUTINE AUTOTDMA