GCC Code Coverage Report
Directory: ./ Exec Total Coverage
File: phylmd/rrtm/rrtm_cmbgb8.F90 Lines: 46 46 100.0 %
Date: 2023-06-30 12:51:15 Branches: 30 32 93.8 %

Line Branch Exec Source
1
!***************************************************************************
2
1
SUBROUTINE RRTM_CMBGB8
3
!***************************************************************************
4
5
!     BAND 8:  1080-1180 cm-1 (low (i.e.>~300mb) - H2O; high - O3)
6
!***************************************************************************
7
8
! Parameters
9
USE PARKIND1  ,ONLY : JPIM     ,JPRB
10
USE YOMHOOK   ,ONLY : LHOOK,   DR_HOOK
11
12
USE YOERRTO8 , ONLY : KAO     ,KBO     ,SELFREFO   ,FRACREFAO  ,&
13
 & FRACREFBO, ABSCO2AO,ABSCO2BO,ABSN2OAO   ,ABSN2OBO   ,&
14
 & CFC12O   , CFC22ADJO
15
USE YOERRTA8 , ONLY : KA      ,KB      ,SELFREF    ,FRACREFA   ,&
16
 & FRACREFB , ABSCO2A ,ABSCO2B ,ABSN2OA    ,ABSN2OB    ,&
17
 & CFC12    , CFC22ADJ
18
USE YOERRTRWT, ONLY : FREFA    ,FREFB    ,RWGT
19
USE YOERRTFTR, ONLY : NGC      ,NGS      ,NGN
20
21
IMPLICIT NONE
22
23
INTEGER(KIND=JPIM) :: IGC, IPR, IPRSM, JP, JT
24
25
REAL(KIND=JPRB) :: Z_SUMF1, Z_SUMF2, Z_SUMK, Z_SUMK1, Z_SUMK2, Z_SUMK3, Z_SUMK4, Z_SUMK5, Z_SUMK6
26
REAL(KIND=JPRB) :: ZHOOK_HANDLE
27
28
1
IF (LHOOK) CALL DR_HOOK('RRTM_CMBGB8',0,ZHOOK_HANDLE)
29
6
DO JT = 1,5
30
41
  DO JP = 1,7
31
    IPRSM = 0
32
320
    DO IGC = 1,NGC(8)
33
      Z_SUMK = 0.0_JPRB
34
840
      DO IPR = 1, NGN(NGS(7)+IGC)
35
560
        IPRSM = IPRSM + 1
36
840
        Z_SUMK = Z_SUMK + KAO(JT,JP,IPRSM)*RWGT(IPRSM+112)
37
      ENDDO
38
315
      KA(JT,JP,IGC) = Z_SUMK
39
    ENDDO
40
  ENDDO
41
ENDDO
42
6
DO JT = 1,5
43
271
  DO JP = 7,59
44
    IPRSM = 0
45
2390
    DO IGC = 1,NGC(8)
46
      Z_SUMK = 0.0_JPRB
47
6360
      DO IPR = 1, NGN(NGS(7)+IGC)
48
4240
        IPRSM = IPRSM + 1
49
6360
        Z_SUMK = Z_SUMK + KBO(JT,JP,IPRSM)*RWGT(IPRSM+112)
50
      ENDDO
51
2385
      KB(JT,JP,IGC) = Z_SUMK
52
    ENDDO
53
  ENDDO
54
ENDDO
55
56
11
DO JT = 1,10
57
  IPRSM = 0
58
91
  DO IGC = 1,NGC(8)
59
    Z_SUMK = 0.0_JPRB
60
240
    DO IPR = 1, NGN(NGS(7)+IGC)
61
160
      IPRSM = IPRSM + 1
62
240
      Z_SUMK = Z_SUMK + SELFREFO(JT,IPRSM)*RWGT(IPRSM+112)
63
    ENDDO
64
90
    SELFREF(JT,IGC) = Z_SUMK
65
  ENDDO
66
ENDDO
67
68
IPRSM = 0
69
9
DO IGC = 1,NGC(8)
70
  Z_SUMF1= 0.0_JPRB
71
  Z_SUMF2= 0.0_JPRB
72
  Z_SUMK1= 0.0_JPRB
73
  Z_SUMK2= 0.0_JPRB
74
  Z_SUMK3= 0.0_JPRB
75
  Z_SUMK4= 0.0_JPRB
76
  Z_SUMK5= 0.0_JPRB
77
  Z_SUMK6= 0.0_JPRB
78
24
  DO IPR = 1, NGN(NGS(7)+IGC)
79
16
    IPRSM = IPRSM + 1
80
16
    Z_SUMF1= Z_SUMF1+ FRACREFAO(IPRSM)
81
16
    Z_SUMF2= Z_SUMF2+ FRACREFBO(IPRSM)
82
16
    Z_SUMK1= Z_SUMK1+ ABSCO2AO(IPRSM)*RWGT(IPRSM+112)
83
16
    Z_SUMK2= Z_SUMK2+ ABSCO2BO(IPRSM)*RWGT(IPRSM+112)
84
16
    Z_SUMK3= Z_SUMK3+ ABSN2OAO(IPRSM)*RWGT(IPRSM+112)
85
16
    Z_SUMK4= Z_SUMK4+ ABSN2OBO(IPRSM)*RWGT(IPRSM+112)
86
16
    Z_SUMK5= Z_SUMK5+ CFC12O(IPRSM)*RWGT(IPRSM+112)
87
24
    Z_SUMK6= Z_SUMK6+ CFC22ADJO(IPRSM)*RWGT(IPRSM+112)
88
  ENDDO
89
8
  FRACREFA(IGC) = Z_SUMF1
90
8
  FRACREFB(IGC) = Z_SUMF2
91
8
  ABSCO2A(IGC) = Z_SUMK1
92
8
  ABSCO2B(IGC) = Z_SUMK2
93
8
  ABSN2OA(IGC) = Z_SUMK3
94
8
  ABSN2OB(IGC) = Z_SUMK4
95
8
  CFC12(IGC) = Z_SUMK5
96
9
  CFC22ADJ(IGC) = Z_SUMK6
97
ENDDO
98
99
9
DO IGC = 1,NGC(8)
100
8
  FREFA(NGS(7)+IGC,1) = FRACREFA(IGC)
101
9
  FREFB(NGS(7)+IGC,1) = FRACREFB(IGC)
102
ENDDO
103
104
1
IF (LHOOK) CALL DR_HOOK('RRTM_CMBGB8',1,ZHOOK_HANDLE)
105
1
END SUBROUTINE RRTM_CMBGB8