[1989] | 1 | SUBROUTINE SW & |
---|
| 2 | & ( KIDIA, KFDIA , KLON , KLEV , KAER,& |
---|
| 3 | & PSCT , PCARDI, PPSOL , PALBD, PALBP , PWV, PQS,& |
---|
| 4 | & PRMU0, PCG , PCLDSW, PDP , POMEGA, POZ, PPMB,& |
---|
| 5 | & PTAU , PTAVE , PAER,& |
---|
| 6 | & PFDOWN, PFUP,& |
---|
| 7 | & PCDOWN, PCUP,& |
---|
| 8 | & PFDNN, PFDNV , PFUPN, PFUPV,& |
---|
| 9 | & PCDNN, PCDNV , PCUPN, PCUPV,& |
---|
| 10 | & PSUDU, PUVDF , PPARF, PPARCF, PDIFFS , PDIRFS, & |
---|
| 11 | & LRDUST, PPIZA_DST,PCGA_DST,PTAUREL_DST & |
---|
| 12 | & ) |
---|
| 13 | |
---|
| 14 | |
---|
| 15 | !**** *SW* - COMPUTES THE SHORTWAVE RADIATION FLUXES. |
---|
| 16 | |
---|
| 17 | ! PURPOSE. |
---|
| 18 | ! -------- |
---|
| 19 | |
---|
| 20 | ! THIS ROUTINE COMPUTES THE SHORTWAVE RADIATION FLUXES IN TWO |
---|
| 21 | ! SPECTRAL INTERVALS FOLLOWING FOUQUART AND BONNEL (1980). |
---|
| 22 | |
---|
| 23 | !** INTERFACE. |
---|
| 24 | ! ---------- |
---|
| 25 | |
---|
| 26 | ! *SW* IS CALLED FROM *RADLSW* |
---|
| 27 | |
---|
| 28 | ! IMPLICIT ARGUMENTS : |
---|
| 29 | ! -------------------- |
---|
| 30 | |
---|
| 31 | ! ==== INPUTS === |
---|
| 32 | ! ==== OUTPUTS === |
---|
| 33 | |
---|
| 34 | ! METHOD. |
---|
| 35 | ! ------- |
---|
| 36 | |
---|
| 37 | ! 1. COMPUTES ABSORBER AMOUNTS (SWU) |
---|
| 38 | ! 2. COMPUTES FLUXES IN U.V./VISIBLE SPECTRAL INTERVAL (SW1S) |
---|
| 39 | ! 3. COMPUTES FLUXES IN NEAR-INFRARED SPECTRAL INTERVAL (SWNI) |
---|
| 40 | |
---|
| 41 | ! EXTERNALS. |
---|
| 42 | ! ---------- |
---|
| 43 | |
---|
| 44 | ! *SWU*, *SW1S*, *SWNI* |
---|
| 45 | |
---|
| 46 | ! REFERENCE. |
---|
| 47 | ! ---------- |
---|
| 48 | |
---|
| 49 | ! SEE RADIATION'S PART OF THE ECMWF RESEARCH DEPARTMENT |
---|
| 50 | ! DOCUMENTATION, AND FOUQUART AND BONNEL (1980) |
---|
| 51 | |
---|
| 52 | ! AUTHOR. |
---|
| 53 | ! ------- |
---|
| 54 | ! JEAN-JACQUES MORCRETTE *ECMWF* |
---|
| 55 | |
---|
| 56 | ! MODIFICATIONS. |
---|
| 57 | ! -------------- |
---|
| 58 | ! ORIGINAL : 89-07-14 |
---|
| 59 | ! 95-01-01 J.-J. MORCRETTE Direct/Diffuse Albedo |
---|
| 60 | ! 95-12-07 J.-J. MORCRETTE Near-Infrared in nsw-1 Intervals |
---|
| 61 | ! 990128 JJMorcrette sunshine duration |
---|
| 62 | ! 99-05-25 JJMorcrette Revised aerosols |
---|
| 63 | ! 00-12-18 JJMorcrette 6 spectral intervals |
---|
| 64 | ! 02-09-01 JJMorcrette UV and PAR |
---|
| 65 | ! M.Hamrud 01-Oct-2003 CY28 Cleaning |
---|
| 66 | ! Y.Seity 04-11-18 : add two arguments for AROME extern. surface |
---|
| 67 | ! Y.Seity 05-10-10 : add add 3 optional arg. for dust SW properties |
---|
| 68 | ! JJMorcrette 20060721 PP of clear-sky PAR |
---|
| 69 | ! ------------------------------------------------------------------ |
---|
| 70 | |
---|
| 71 | USE PARKIND1 ,ONLY : JPIM ,JPRB |
---|
| 72 | USE YOMHOOK ,ONLY : LHOOK, DR_HOOK |
---|
| 73 | !USE YOERAD , ONLY : NSW |
---|
| 74 | ! NSW mis dans .def MPL 20140211 |
---|
| 75 | USE write_field_phy |
---|
[5294] | 76 | ! Temporary fix waiting for cleaner interface (or not) |
---|
| 77 | USE clesphys_mod_h, ONLY: NSW |
---|
[1989] | 78 | |
---|
| 79 | IMPLICIT NONE |
---|
| 80 | |
---|
[5294] | 81 | !!include "clesphys.h" |
---|
[1989] | 82 | |
---|
| 83 | integer, save :: icount=0 |
---|
[2010] | 84 | !$OMP THREADPRIVATE(icount) |
---|
[1989] | 85 | INTEGER(KIND=JPIM),INTENT(IN) :: KLON |
---|
| 86 | INTEGER(KIND=JPIM),INTENT(IN) :: KLEV |
---|
| 87 | INTEGER(KIND=JPIM),INTENT(IN) :: KIDIA |
---|
| 88 | INTEGER(KIND=JPIM),INTENT(IN) :: KFDIA |
---|
| 89 | INTEGER(KIND=JPIM),INTENT(IN) :: KAER |
---|
| 90 | REAL(KIND=JPRB) ,INTENT(IN) :: PSCT |
---|
| 91 | REAL(KIND=JPRB) ,INTENT(IN) :: PCARDI |
---|
| 92 | REAL(KIND=JPRB) ,INTENT(IN) :: PPSOL(KLON) |
---|
| 93 | REAL(KIND=JPRB) ,INTENT(IN) :: PALBD(KLON,NSW) |
---|
| 94 | REAL(KIND=JPRB) ,INTENT(IN) :: PALBP(KLON,NSW) |
---|
| 95 | REAL(KIND=JPRB) ,INTENT(IN) :: PWV(KLON,KLEV) |
---|
| 96 | REAL(KIND=JPRB) ,INTENT(IN) :: PQS(KLON,KLEV) |
---|
| 97 | REAL(KIND=JPRB) ,INTENT(IN) :: PRMU0(KLON) |
---|
| 98 | REAL(KIND=JPRB) ,INTENT(IN) :: PCG(KLON,NSW,KLEV) |
---|
| 99 | REAL(KIND=JPRB) ,INTENT(IN) :: PCLDSW(KLON,KLEV) |
---|
| 100 | REAL(KIND=JPRB) :: PDP(KLON,KLEV) ! Argument NOT used |
---|
| 101 | REAL(KIND=JPRB) ,INTENT(IN) :: POMEGA(KLON,NSW,KLEV) |
---|
| 102 | REAL(KIND=JPRB) ,INTENT(IN) :: POZ(KLON,KLEV) |
---|
| 103 | REAL(KIND=JPRB) ,INTENT(IN) :: PPMB(KLON,KLEV+1) |
---|
| 104 | REAL(KIND=JPRB) ,INTENT(IN) :: PTAU(KLON,NSW,KLEV) |
---|
| 105 | REAL(KIND=JPRB) ,INTENT(IN) :: PTAVE(KLON,KLEV) |
---|
| 106 | REAL(KIND=JPRB) ,INTENT(IN) :: PAER(KLON,6,KLEV) |
---|
| 107 | !++MODIFCODE |
---|
| 108 | LOGICAL ,INTENT(IN) :: LRDUST |
---|
| 109 | REAL(KIND=JPRB) ,INTENT(IN) :: PPIZA_DST(KLON,KLEV,NSW) |
---|
| 110 | REAL(KIND=JPRB) ,INTENT(IN) :: PCGA_DST(KLON,KLEV,NSW) |
---|
| 111 | REAL(KIND=JPRB) ,INTENT(IN) :: PTAUREL_DST(KLON,KLEV,NSW) |
---|
| 112 | !--MODIFCODE |
---|
| 113 | REAL(KIND=JPRB) ,INTENT(OUT) :: PFDOWN(KLON,KLEV+1) |
---|
| 114 | REAL(KIND=JPRB) ,INTENT(OUT) :: PFUP(KLON,KLEV+1) |
---|
| 115 | REAL(KIND=JPRB) ,INTENT(OUT) :: PCDOWN(KLON,KLEV+1) |
---|
| 116 | REAL(KIND=JPRB) ,INTENT(OUT) :: PCUP(KLON,KLEV+1) |
---|
| 117 | REAL(KIND=JPRB) ,INTENT(OUT) :: PFDNN(KLON) |
---|
| 118 | REAL(KIND=JPRB) ,INTENT(OUT) :: PFDNV(KLON) |
---|
| 119 | REAL(KIND=JPRB) ,INTENT(OUT) :: PFUPN(KLON) |
---|
| 120 | REAL(KIND=JPRB) ,INTENT(OUT) :: PFUPV(KLON) |
---|
| 121 | REAL(KIND=JPRB) ,INTENT(OUT) :: PCDNN(KLON) |
---|
| 122 | REAL(KIND=JPRB) ,INTENT(OUT) :: PCDNV(KLON) |
---|
| 123 | REAL(KIND=JPRB) ,INTENT(OUT) :: PCUPN(KLON) |
---|
| 124 | REAL(KIND=JPRB) ,INTENT(OUT) :: PCUPV(KLON) |
---|
| 125 | REAL(KIND=JPRB) ,INTENT(OUT) :: PSUDU(KLON) |
---|
| 126 | REAL(KIND=JPRB) ,INTENT(OUT) :: PUVDF(KLON) |
---|
| 127 | REAL(KIND=JPRB) ,INTENT(OUT) :: PPARF(KLON) |
---|
| 128 | REAL(KIND=JPRB) ,INTENT(OUT) :: PPARCF(KLON) |
---|
| 129 | REAL(KIND=JPRB) ,INTENT(OUT) :: PDIFFS(KLON,NSW) |
---|
| 130 | REAL(KIND=JPRB) ,INTENT(OUT) :: PDIRFS(KLON,NSW) |
---|
| 131 | ! ------------------------------------------------------------------ |
---|
| 132 | |
---|
| 133 | !* 0.1 ARGUMENTS |
---|
| 134 | ! --------- |
---|
| 135 | |
---|
| 136 | ! ------------------------------------------------------------------ |
---|
| 137 | |
---|
| 138 | ! ------------ |
---|
| 139 | |
---|
| 140 | REAL(KIND=JPRB) :: ZAKI(KLON,2,NSW)& |
---|
| 141 | & , ZCLD(KLON,KLEV) , ZCLEAR(KLON) & |
---|
| 142 | & , ZDSIG(KLON,KLEV) , ZFACT(KLON)& |
---|
| 143 | & , ZFD(KLON,KLEV+1) , ZCD(KLON,KLEV+1)& |
---|
| 144 | & , ZCDOWN(KLON,KLEV+1), ZCDNIR(KLON,KLEV+1), ZCDUVS(KLON,KLEV+1)& |
---|
| 145 | & , ZFDOWN(KLON,KLEV+1), ZFDNIR(KLON,KLEV+1), ZFDUVS(KLON,KLEV+1)& |
---|
| 146 | & , ZFU(KLON,KLEV+1) , ZCU(KLON,KLEV+1)& |
---|
| 147 | & , ZCUP(KLON,KLEV+1) , ZCUNIR(KLON,KLEV+1), ZCUUVS(KLON,KLEV+1)& |
---|
| 148 | & , ZFUP(KLON,KLEV+1) , ZFUNIR(KLON,KLEV+1), ZFUUVS(KLON,KLEV+1)& |
---|
| 149 | & , ZRMU(KLON) , ZSEC(KLON) & |
---|
| 150 | & , ZSUDU1(KLON) , ZSUDU2(KLON) & |
---|
| 151 | & , ZSUDU1T(KLON) , ZSUDU2T(KLON) & |
---|
| 152 | & , ZUD(KLON,5,KLEV+1) ,ZDIFF(KLON,KLEV) ,ZDIRF(KLON,KLEV) & |
---|
| 153 | & , ZDIFF2(KLON,KLEV) , ZDIRF2(KLON,KLEV) |
---|
| 154 | |
---|
| 155 | INTEGER(KIND=JPIM) :: JK, JL, JNU, INUVS, INUIR |
---|
| 156 | |
---|
| 157 | REAL(KIND=JPRB) :: ZHOOK_HANDLE |
---|
| 158 | LOGICAL :: LLDEBUG |
---|
| 159 | character*1 str1 |
---|
| 160 | |
---|
| 161 | #include "sw1s.intfb.h" |
---|
| 162 | #include "swni.intfb.h" |
---|
| 163 | #include "swu.intfb.h" |
---|
| 164 | |
---|
| 165 | ! ------------------------------------------------------------------ |
---|
| 166 | |
---|
| 167 | !* 1. ABSORBER AMOUNTS AND OTHER USEFUL QUANTITIES |
---|
| 168 | ! -------------------------------------------- |
---|
| 169 | |
---|
| 170 | IF (LHOOK) CALL DR_HOOK('SW',0,ZHOOK_HANDLE) |
---|
| 171 | LLDEBUG=.FALSE. |
---|
| 172 | CALL SWU ( KIDIA,KFDIA ,KLON ,KLEV,& |
---|
| 173 | & PSCT ,PCARDI,PCLDSW,PPMB ,PPSOL,& |
---|
| 174 | & PRMU0,PTAVE ,PWV,& |
---|
| 175 | & ZAKI ,ZCLD ,ZCLEAR,ZDSIG,ZFACT,ZRMU,ZSEC,ZUD ) |
---|
| 176 | |
---|
| 177 | ! ------------------------------------------------------------------ |
---|
| 178 | !* 2. INTERVAL (0.185/0.25-0.68 MICRON): U.V. AND VISIBLE |
---|
| 179 | ! --------------------------------------------------- |
---|
| 180 | IF (NSW <= 4) THEN |
---|
| 181 | INUVS=1 |
---|
| 182 | INUIR=2 |
---|
| 183 | ELSEIF (NSW == 6) THEN |
---|
| 184 | INUVS=1 |
---|
| 185 | INUIR=4 |
---|
| 186 | ENDIF |
---|
| 187 | |
---|
| 188 | DO JK = 1 , KLEV+1 |
---|
| 189 | DO JL = KIDIA,KFDIA |
---|
| 190 | ZFD(JL,JK) =0.0_JPRB |
---|
| 191 | ZFU(JL,JK) =0.0_JPRB |
---|
| 192 | ZCD(JL,JK) =0.0_JPRB |
---|
| 193 | ZCU(JL,JK) =0.0_JPRB |
---|
| 194 | ENDDO |
---|
| 195 | ENDDO |
---|
| 196 | DO JL = KIDIA,KFDIA |
---|
| 197 | ZSUDU1T(JL)=0.0_JPRB |
---|
| 198 | PUVDF(JL) =0.0_JPRB |
---|
| 199 | PPARF(JL) =0.0_JPRB |
---|
| 200 | PPARCF(JL) =0.0_JPRB |
---|
| 201 | ENDDO |
---|
| 202 | |
---|
| 203 | IF(LLDEBUG) THEN |
---|
| 204 | call writefield_phy('sw_zsec',ZSEC,1) |
---|
| 205 | call writefield_phy('sw_zrmu',ZRMU,1) |
---|
| 206 | call writefield_phy('sw_prmu0',PRMU0,1) |
---|
| 207 | call writefield_phy('sw_zfact',ZFACT,1) |
---|
| 208 | ENDIF |
---|
| 209 | |
---|
| 210 | icount=icount+1 |
---|
| 211 | DO JNU = INUVS , INUIR-1 |
---|
| 212 | !++MODIFCODE |
---|
| 213 | CALL SW1S & |
---|
| 214 | &( KIDIA , KFDIA, KLON , KLEV , KAER , JNU & |
---|
| 215 | &, PAER , PALBD , PALBP, PCG , ZCLD , ZCLEAR & |
---|
| 216 | &, ZDSIG, POMEGA, POZ , ZRMU , ZSEC , PTAU , ZUD & |
---|
| 217 | &, ZFDUVS,ZFUUVS, ZCDUVS,ZCUUVS, ZSUDU1, ZDIFF,ZDIRF & |
---|
| 218 | &, LRDUST,PPIZA_DST(:,:,JNU) & ! SSA for this wavelength |
---|
| 219 | &, PCGA_DST(:,:,JNU) & ! GCA for this wavelengt |
---|
| 220 | &, PTAUREL_DST(:,:,JNU) ) ! TAUREL for this wavelength |
---|
| 221 | !--MODIFCODE |
---|
| 222 | IF(LLDEBUG) THEN |
---|
| 223 | ! Ecriture des champs avec un indicage du fichier par l'intervalle spectral |
---|
| 224 | write(str1,'(i1)') jnu |
---|
| 225 | call writefield_phy("sw_zcduvs"//str1,zcduvs,klev+1) |
---|
| 226 | ENDIF |
---|
| 227 | |
---|
| 228 | |
---|
| 229 | DO JL=KIDIA,KFDIA |
---|
| 230 | PDIFFS(JL,JNU)=ZDIFF(JL,1)*ZFACT(JL) |
---|
| 231 | PDIRFS(JL,JNU)=ZDIRF(JL,1)*ZFACT(JL) |
---|
| 232 | ENDDO |
---|
| 233 | DO JK = 1 , KLEV+1 |
---|
| 234 | DO JL = KIDIA,KFDIA |
---|
| 235 | ZFD(JL,JK)=ZFD(JL,JK)+ZFDUVS(JL,JK) |
---|
| 236 | ZFU(JL,JK)=ZFU(JL,JK)+ZFUUVS(JL,JK) |
---|
| 237 | ZCD(JL,JK)=ZCD(JL,JK)+ZCDUVS(JL,JK) |
---|
| 238 | ZCU(JL,JK)=ZCU(JL,JK)+ZCUUVS(JL,JK) |
---|
| 239 | ENDDO |
---|
| 240 | ENDDO |
---|
| 241 | DO JL = KIDIA,KFDIA |
---|
| 242 | ZSUDU1T(JL)=ZSUDU1T(JL)+ZSUDU1(JL) |
---|
| 243 | ENDDO |
---|
| 244 | |
---|
| 245 | IF (NSW == 6) THEN |
---|
| 246 | IF (JNU <= 2) THEN |
---|
| 247 | DO JL = KIDIA,KFDIA |
---|
| 248 | PUVDF(JL)=PUVDF(JL)+ZFDUVS(JL,1) |
---|
| 249 | ENDDO |
---|
| 250 | ELSEIF (JNU == 3) THEN |
---|
| 251 | DO JL=KIDIA,KFDIA |
---|
| 252 | PPARF(JL)=PPARF(JL)+ZFDUVS(JL,1) |
---|
| 253 | PPARCF(JL)=PPARCF(JL)+ZCDUVS(JL,1) |
---|
| 254 | ENDDO |
---|
| 255 | ENDIF |
---|
| 256 | ENDIF |
---|
| 257 | ENDDO |
---|
| 258 | |
---|
| 259 | !if (icount==5) stop'on arrete dans sw.F90 au bout de 5 appels' |
---|
| 260 | ! ------------------------------------------------------------------ |
---|
| 261 | |
---|
| 262 | !* 3. INTERVAL (0.68-4.00 MICRON): NEAR-INFRARED |
---|
| 263 | ! ------------------------------------------ |
---|
| 264 | |
---|
| 265 | DO JK = 1 , KLEV+1 |
---|
| 266 | DO JL = KIDIA,KFDIA |
---|
| 267 | ZFDOWN(JL,JK)=0.0_JPRB |
---|
| 268 | ZFUP (JL,JK)=0.0_JPRB |
---|
| 269 | ZCDOWN(JL,JK)=0.0_JPRB |
---|
| 270 | ZCUP (JL,JK)=0.0_JPRB |
---|
| 271 | ZSUDU2T(JL) =0.0_JPRB |
---|
| 272 | ENDDO |
---|
| 273 | ENDDO |
---|
| 274 | |
---|
| 275 | DO JNU = INUIR , NSW |
---|
| 276 | !++MODIFCODE |
---|
| 277 | CALL SWNI & |
---|
| 278 | &( KIDIA ,KFDIA , KLON , KLEV , KAER , JNU & |
---|
| 279 | &, PAER ,ZAKI , PALBD, PALBP, PCG , ZCLD, ZCLEAR & |
---|
| 280 | &, ZDSIG ,POMEGA, POZ , ZRMU , ZSEC , PTAU, ZUD & |
---|
| 281 | &, PWV ,PQS & |
---|
| 282 | &, ZFDNIR,ZFUNIR,ZCDNIR,ZCUNIR,ZSUDU2,ZDIFF2,ZDIRF2 & |
---|
| 283 | &, LRDUST,PPIZA_DST(:,:,JNU) & |
---|
| 284 | &, PCGA_DST(:,:,JNU) & |
---|
| 285 | &, PTAUREL_DST(:,:,JNU) & |
---|
| 286 | &) |
---|
| 287 | !--MODIFCODE |
---|
| 288 | |
---|
| 289 | IF(LLDEBUG) THEN |
---|
| 290 | ! Ecriture des champs avec un indicage du fichier par l'intervalle spectral |
---|
| 291 | write(str1,'(i1)') jnu |
---|
| 292 | call writefield_phy("sw_zcdnir"//str1,zcdnir,klev+1) |
---|
| 293 | ENDIF |
---|
| 294 | |
---|
| 295 | DO JL=KIDIA,KFDIA |
---|
| 296 | PDIFFS(JL,JNU)=ZDIFF2(JL,1)*ZFACT(JL) |
---|
| 297 | PDIRFS(JL,JNU)=ZDIRF2(JL,1)*ZFACT(JL) |
---|
| 298 | ENDDO |
---|
| 299 | DO JK = 1 , KLEV+1 |
---|
| 300 | DO JL = KIDIA,KFDIA |
---|
| 301 | ZFDOWN(JL,JK)=ZFDOWN(JL,JK)+ZFDNIR(JL,JK) |
---|
| 302 | ZFUP (JL,JK)=ZFUP (JL,JK)+ZFUNIR(JL,JK) |
---|
| 303 | ZCDOWN(JL,JK)=ZCDOWN(JL,JK)+ZCDNIR(JL,JK) |
---|
| 304 | ZCUP (JL,JK)=ZCUP (JL,JK)+ZCUNIR(JL,JK) |
---|
| 305 | ENDDO |
---|
| 306 | ENDDO |
---|
| 307 | DO JL = KIDIA,KFDIA |
---|
| 308 | ZSUDU2T(JL)=ZSUDU2T(JL)+ZSUDU2(JL) |
---|
| 309 | ENDDO |
---|
| 310 | ENDDO |
---|
| 311 | |
---|
| 312 | ! ------------------------------------------------------------------ |
---|
| 313 | |
---|
| 314 | !* 4. FILL THE DIAGNOSTIC ARRAYS |
---|
| 315 | ! -------------------------- |
---|
| 316 | |
---|
| 317 | DO JL = KIDIA,KFDIA |
---|
| 318 | PFDNN(JL)=ZFDOWN(JL,1)*ZFACT(JL) |
---|
| 319 | PFDNV(JL)=ZFD(JL,1)*ZFACT(JL) |
---|
| 320 | PFUPN(JL)=ZFUP(JL,KLEV+1)*ZFACT(JL) |
---|
| 321 | PFUPV(JL)=ZFU(JL,KLEV+1)*ZFACT(JL) |
---|
| 322 | |
---|
| 323 | PCDNN(JL)=ZCDOWN(JL,1)*ZFACT(JL) |
---|
| 324 | PCDNV(JL)=ZCD(JL,1)*ZFACT(JL) |
---|
| 325 | PCUPN(JL)=ZCUP(JL,KLEV+1)*ZFACT(JL) |
---|
| 326 | PCUPV(JL)=ZCU(JL,KLEV+1)*ZFACT(JL) |
---|
| 327 | |
---|
| 328 | PSUDU(JL)=(ZSUDU1T(JL)+ZSUDU2T(JL))*ZFACT(JL) |
---|
| 329 | PUVDF(JL)=PUVDF(JL)*ZFACT(JL) |
---|
| 330 | PPARF(JL)=PPARF(JL)*ZFACT(JL) |
---|
| 331 | PPARCF(JL)=PPARCF(JL)*ZFACT(JL) |
---|
| 332 | ENDDO |
---|
| 333 | |
---|
| 334 | !WRITE(*,'("---> Dans SW:")') |
---|
| 335 | !WRITE(*,'("ZFUP ",10E12.5)') (ZFUP(1,JK),JK=1,KLEV+1) |
---|
| 336 | !WRITE(*,'("ZFU ",10E12.5)') (ZFU(1,JK),JK=1,KLEV+1) |
---|
| 337 | !WRITE(*,'("ZFUNIR",10E12.5)') (ZFUNIR(1,JK),JK=1,KLEV+1) |
---|
| 338 | !WRITE(*,'("ZFACT ",E12.5)') ZFACT(1) |
---|
| 339 | |
---|
| 340 | DO JK = 1 , KLEV+1 |
---|
| 341 | DO JL = KIDIA,KFDIA |
---|
| 342 | PFUP(JL,JK) = (ZFUP(JL,JK) + ZFU(JL,JK)) * ZFACT(JL) |
---|
| 343 | PFDOWN(JL,JK) = (ZFDOWN(JL,JK) + ZFD(JL,JK)) * ZFACT(JL) |
---|
| 344 | PCUP(JL,JK) = (ZCUP(JL,JK) + ZCU(JL,JK)) * ZFACT(JL) |
---|
| 345 | PCDOWN(JL,JK) = (ZCDOWN(JL,JK) + ZCD(JL,JK)) * ZFACT(JL) |
---|
| 346 | ENDDO |
---|
| 347 | ENDDO |
---|
| 348 | IF(LLDEBUG) THEN |
---|
| 349 | call writefield_phy('sw_pcdown',PCDOWN,KLEV+1) |
---|
| 350 | ENDIF |
---|
| 351 | |
---|
| 352 | ! ------------------------------------------------------------------ |
---|
| 353 | |
---|
| 354 | IF (LHOOK) CALL DR_HOOK('SW',1,ZHOOK_HANDLE) |
---|
| 355 | END SUBROUTINE SW |
---|