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 | ||
---|---|---|---|---|---|---|
real(kind=r64), | intent(in) | :: | AvgEqOfTime | |||
real(kind=r64), | intent(in) | :: | AvgSinSolarDeclin | |||
real(kind=r64), | intent(in) | :: | AvgCosSolarDeclin |
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 CalcPerSolarBeam(AvgEqOfTime,AvgSinSolarDeclin,AvgCosSolarDeclin)
! SUBROUTINE INFORMATION:
! AUTHOR Legacy Code
! DATE WRITTEN
! MODIFIED BG, Nov 2012 - Timestep solar. DetailedSolarTimestepIntegration
! RE-ENGINEERED Lawrie, Oct 2000
! PURPOSE OF THIS SUBROUTINE:
! This subroutine manages computation of solar gain multipliers for beam radiation. These
! are calculated for a period of days depending on the input "Shadowing Calculations".
! METHODOLOGY EMPLOYED:
! na
! REFERENCES:
! BLAST/IBLAST code, original author George Walton
! USE STATEMENTS:
USE WindowComplexManager,ONLY: InitComplexWindows, UpdateComplexWindows
USE DataSystemVariables, ONLY: DetailedSkyDiffuseAlgorithm, DetailedSolarTimestepIntegration
USE DataGlobals, ONLY: TimeStepZone, HourOfDay, TimeStep
IMPLICIT NONE ! Enforce explicit typing of all variables in this routine
! SUBROUTINE ARGUMENT DEFINITIONS:
REAL(r64), INTENT(IN) :: AvgSinSolarDeclin ! Average value of Sine of Solar Declination for period
REAL(r64), INTENT(IN) :: AvgCosSolarDeclin ! Average value of Cosine of Solar Declination for period
REAL(r64), INTENT(IN) :: AvgEqOfTime ! Average value of Equation of Time for period
! SUBROUTINE PARAMETER DEFINITIONS:
! INTERFACE BLOCK SPECIFICATIONS
! na
! DERIVED TYPE DEFINITIONS
! na
! SUBROUTINE LOCAL VARIABLE DECLARATIONS:
INTEGER IHOUR ! Hour index number
INTEGER TS ! TimeStep Loop Counter
LOGICAL, SAVE :: Once=.true.
IF (Once) CALL InitComplexWindows
Once=.false.
IF (KickOffSizing .or. KickOffSimulation) RETURN ! Skip solar calcs for these Initialization steps.
#ifdef EP_Count_Calls
NumCalcPerSolBeam_Calls=NumCalcPerSolBeam_Calls+1
#endif
! Intialize some values for the appropriate period
IF (.NOT. DetailedSolarTimestepIntegration) THEN
SunLitFracHR=0.0d0
SunLitFrac=0.0d0
SunLitFracWithoutReveal=0.0d0
CTHETA=0.0d0
CosIncAngHR=0.0d0
CosIncAng=0.0d0
AOSurf=0.0d0
BackSurfaces=0
OverlapAreas=0.0d0
DO IHOUR = 1,24
SurfaceWindow%OutProjSLFracMult(IHOUR) = 1.d0
SurfaceWindow%InOutProjSLFracMult(IHOUR) = 1.d0
END DO
ELSE
SunLitFracHR(1:TotSurfaces,HourOfDay) = 0.d0
SunLitFrac(1:TotSurfaces,HourOfDay,TimeStep) = 0.d0
SunLitFracWithoutReveal(1:TotSurfaces,HourOfDay,TimeStep) = 0.d0
CTHETA(1:TotSurfaces) = 0.d0
CosIncAngHR(1:TotSurfaces,HourOfDay) = 0.d0
CosIncAng(1:TotSurfaces,HourOfDay,TimeStep) = 0.d0
AOSurf(1:TotSurfaces) = 0.d0
BackSurfaces(1:TotSurfaces,1:MaxBkSurf,HourOfDay,TimeStep) = 0
OverlapAreas(1:TotSurfaces,1:MaxBkSurf,HourOfDay,TimeStep) = 0.d0
SurfaceWindow%OutProjSLFracMult(HourOfDay) =1.0d0
SurfaceWindow%InOutProjSLFracMult(HourOfDay) =1.0d0
ENDIF
IF (.NOT. DetailedSolarTimestepIntegration) THEN
DO IHOUR = 1, 24 ! Do for all hours.
DO TS=1,NumOfTimeStepInHour
CALL FigureSunCosines(IHOUR, TS, AvgEqOfTime, AvgSinSolarDeclin, AvgCosSolarDeclin)
END DO
END DO
ELSE
CALL FigureSunCosines(HourOfDay, TimeStep, AvgEqOfTime, AvgSinSolarDeclin, AvgCosSolarDeclin)
ENDIF
!
!Initialize/update the Complex Fenestration geometry and optical properties
CALL UpdateComplexWindows
!
IF (.NOT. DetailedSolarTimestepIntegration) THEN
DO IHOUR = 1, 24 ! Do for all hours.
DO TS=1,NumOfTimeStepInHour
CALL FigureSolarBeamAtTimestep(IHOUR, TS)
END DO ! TimeStep Loop
END DO ! Hour Loop
ELSE
CALL FigureSolarBeamAtTimestep(HourOfDay, TimeStep)
ENDIF
RETURN
END SUBROUTINE CalcPerSolarBeam