diff --git a/src/MNH/deallocate_model1.f90 b/src/MNH/deallocate_model1.f90 index 3b0b4673893c19604b474aa94d5979f9d97c7b50..f73c628c8730c1f457010036351ef1b7263477b3 100644 --- a/src/MNH/deallocate_model1.f90 +++ b/src/MNH/deallocate_model1.f90 @@ -198,6 +198,10 @@ IF ( ASSOCIATED(XCLDFR) .AND. KCALL==2 ) THEN DEALLOCATE(XCLDFR) END IF ! +IF ( ASSOCIATED(XICEFR) .AND. KCALL==2 ) THEN + DEALLOCATE(XICEFR) +END IF +! IF ( ASSOCIATED(XRAINFR) .AND. KCALL==2 ) THEN DEALLOCATE(XRAINFR) END IF diff --git a/src/MNH/ini_lesn.f90 b/src/MNH/ini_lesn.f90 index 45d7b9f9ac85e947fda34a09e56fe335c79d1d1c..674ba4bc0a3d548e47aced752e96208f88ef11c6 100644 --- a/src/MNH/ini_lesn.f90 +++ b/src/MNH/ini_lesn.f90 @@ -546,6 +546,11 @@ IF (LUSERI ) THEN ELSE ALLOCATE(XLES_MEAN_Ri (0,0,0)) END IF +IF (LUSERI .AND. CCLOUD=='LIMA') THEN + ALLOCATE(XLES_MEAN_If (NLES_K,NLES_TIMES,NLES_MASKS)) +ELSE + ALLOCATE(XLES_MEAN_If (0,0,0)) +END IF IF (LUSERS ) THEN ALLOCATE(XLES_MEAN_Rs (NLES_K,NLES_TIMES,NLES_MASKS)) ELSE @@ -650,6 +655,7 @@ IF (LUSERC ) XLES_MEAN_INDCf = XUNDEF IF (LUSERC ) XLES_MEAN_INDCf2 = XUNDEF IF (LUSERR ) XLES_MEAN_Rr = XUNDEF IF (LUSERI ) XLES_MEAN_Ri = XUNDEF +IF (LUSERI .AND. CCLOUD=='LIMA') XLES_MEAN_If = XUNDEF IF (LUSERS ) XLES_MEAN_Rs = XUNDEF IF (LUSERG ) XLES_MEAN_Rg = XUNDEF IF (LUSERH ) XLES_MEAN_Rh = XUNDEF diff --git a/src/MNH/ini_modeln.f90 b/src/MNH/ini_modeln.f90 index 718f11ce615bb12340a0c91c7d2b514630be805a..1341b29f9488a37e2ddd3cd64ca3c6a692b82322 100644 --- a/src/MNH/ini_modeln.f90 +++ b/src/MNH/ini_modeln.f90 @@ -959,9 +959,11 @@ END IF ! IF (NRR>1) THEN ALLOCATE(XCLDFR(IIU,IJU,IKU)); XCLDFR (:, :, :) = 0. + ALLOCATE(XICEFR(IIU,IJU,IKU)); XICEFR (:, :, :) = 0. ALLOCATE(XRAINFR(IIU,IJU,IKU)); XRAINFR(:, :, :) = 0. ELSE ALLOCATE(XCLDFR(0,0,0)) + ALLOCATE(XICEFR(0,0,0)) ALLOCATE(XRAINFR(0,0,0)) END IF ! @@ -1906,7 +1908,7 @@ CALL MPPDB_CHECK3D(XUT,"INI_MODEL_N-before read_field::XUT",PRECISION) CALL READ_FIELD(KMI,TPINIFILE,IIU,IJU,IKU, & CGETTKET,CGETRVT,CGETRCT,CGETRRT,CGETRIT,CGETCIT,CGETZWS, & CGETRST,CGETRGT,CGETRHT,CGETSVT,CGETSRCT,CGETSIGS,CGETCLDFR, & - CGETBL_DEPTH,CGETSBL_DEPTH,CGETPHC,CGETPHR, & + CGETICEFR, CGETBL_DEPTH,CGETSBL_DEPTH,CGETPHC,CGETPHR, & CUVW_ADV_SCHEME, CTEMP_SCHEME, & NSIZELBX_ll, NSIZELBXU_ll, NSIZELBY_ll, NSIZELBYV_ll, & NSIZELBXTKE_ll,NSIZELBYTKE_ll, & @@ -1914,8 +1916,8 @@ CALL READ_FIELD(KMI,TPINIFILE,IIU,IJU,IKU, & XUM,XVM,XWM,XDUM,XDVM,XDWM, & XUT,XVT,XWT,XTHT,XPABST,XTKET,XRTKEMS, & XRT,XSVT,XZWS,XCIT,XDRYMASST,XDRYMASSS, & - XSIGS,XSRCT,XCLDFR,XBL_DEPTH,XSBL_DEPTH,XWTHVMF,XPHC,XPHR, & - XLSUM,XLSVM,XLSWM,XLSTHM,XLSRVM,XLSZWSM, & + XSIGS,XSRCT,XCLDFR,XICEFR, XBL_DEPTH,XSBL_DEPTH,XWTHVMF, & + XPHC,XPHR, XLSUM,XLSVM,XLSWM,XLSTHM,XLSRVM,XLSZWSM, & XLBXUM,XLBXVM,XLBXWM,XLBXTHM,XLBXTKEM, & XLBXRM,XLBXSVM, & XLBYUM,XLBYVM,XLBYWM,XLBYTHM,XLBYTKEM, & diff --git a/src/MNH/lesn.f90 b/src/MNH/lesn.f90 index 129929246495bee84d57526e482a17fc9b4e52b7..09added3a275554efd6522a63b01f5c95812b355 100644 --- a/src/MNH/lesn.f90 +++ b/src/MNH/lesn.f90 @@ -107,6 +107,7 @@ REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZEW REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZINDCLD !indice cloud si rc>0 REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZINDCLD2 !indice cloud rc>1E-5 REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZCLDFR_LES! CLDFR on LES vertical grid +REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZICEFR_LES! ICEFR on LES vertical grid REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZRAINFR_LES! RAINFR on LES vertical grid REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZMASSF ! massflux=rho*w REAL, DIMENSION(:,:,:), ALLOCATABLE :: ZREHU ! relative humidity @@ -349,6 +350,11 @@ ELSE ALLOCATE(ZRI_LES (0,0,0)) ALLOCATE(ZIWP_LES(0,0)) END IF +IF (LUSERI .AND. CCLOUD=='LIMA') THEN + ALLOCATE(ZICEFR_LES(IIU,IJU,NLES_K)) +ELSE + ALLOCATE(ZICEFR_LES(0,0,0)) +END IF IF (LUSERS) THEN ALLOCATE(ZRS_LES (IIU,IJU,NLES_K)) ALLOCATE(ZSWP_LES(IIU,IJU)) @@ -598,6 +604,7 @@ IF (LUSERI) THEN END DO CALL LES_MEAN_ll ( ZIWP_LES, LLES_CURRENT_CART_MASK(:,:,1), & XLES_IWP(NLES_CURRENT_TCOUNT) ) + IF (CCLOUD=='LIMA') CALL LES_VER_INT( XICEFR(:,:,:) ,ZICEFR_LES ) END IF IF (LUSERS) THEN IRR = IRR + 1 @@ -812,6 +819,8 @@ END IF IF (LUSERI) & CALL LES_MEAN_ll ( ZRI_LES, LLES_CURRENT_CART_MASK, & XLES_MEAN_Ri(:,NLES_CURRENT_TCOUNT,1) ) + IF (CCLOUD=='LIMA') CALL LES_MEAN_ll ( ZICEFR_LES, LLES_CURRENT_CART_MASK, & + XLES_MEAN_If(:,NLES_CURRENT_TCOUNT,1) ) ! IF (LUSERS) & CALL LES_MEAN_ll ( ZRS_LES, LLES_CURRENT_CART_MASK, & @@ -1046,6 +1055,7 @@ DEALLOCATE(ZINDCLD2 ) DEALLOCATE(ZINDCLD2D ) DEALLOCATE(ZINDCLD2D2) DEALLOCATE(ZCLDFR_LES) +DEALLOCATE(ZICEFR_LES) DEALLOCATE(ZRAINFR_LES) DEALLOCATE(ZMASSF ) DEALLOCATE(ZTEMP ) diff --git a/src/MNH/lima_adjust_split.f90 b/src/MNH/lima_adjust_split.f90 index 6f7dbb738c7ebbe213c1145f31eba74964ecf3c4..a74787d35ffee725eb6e7eb106db590e63047e9e 100644 --- a/src/MNH/lima_adjust_split.f90 +++ b/src/MNH/lima_adjust_split.f90 @@ -14,7 +14,7 @@ INTERFACE PRHODREF, PRHODJ, PEXNREF, PPABSM, PSIGS, PMFCONV, & PPABST, PZZ, PDTHRAD, PW_NU, & PRT, PRS, PSVT, PSVS, & - PTHS, PSRCS, PCLDFR, PRC_MF, PCF_MF ) + PTHS, PSRCS, PCLDFR, PICEFR, PRC_MF, PCF_MF ) ! USE MODD_IO, ONLY: TFILEDATA USE MODD_NSV, only: NSV_LIMA_BEG @@ -58,6 +58,7 @@ REAL, DIMENSION(:,:,:), INTENT(OUT) :: PSRCS ! Second-order flux ! s'rc'/2Sigma_s2 at time t+1 ! multiplied by Lambda_3 REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PCLDFR ! Cloud fraction +REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PICEFR ! Cloud fraction REAL, DIMENSION(:,:,:), INTENT(IN) :: PRC_MF! Convective Mass Flux liquid mixing ratio REAL, DIMENSION(:,:,:), INTENT(IN) :: PCF_MF! Convective Mass Flux Cloud fraction ! @@ -73,7 +74,7 @@ END MODULE MODI_LIMA_ADJUST_SPLIT PRHODREF, PRHODJ, PEXNREF, PPABSM, PSIGS, PMFCONV, & PPABST, PZZ, PDTHRAD, PW_NU, & PRT, PRS, PSVT, PSVS, & - PTHS, PSRCS, PCLDFR, PRC_MF, PCF_MF ) + PTHS, PSRCS, PCLDFR, PICEFR, PRC_MF, PCF_MF ) ! ########################################################################### ! !!**** *MIMA_ADJUST* - compute the fast microphysical sources @@ -217,6 +218,7 @@ REAL, DIMENSION(:,:,:), INTENT(OUT) :: PSRCS ! Second-order flux ! s'rc'/2Sigma_s2 at time t+1 ! multiplied by Lambda_3 REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PCLDFR ! Cloud fraction +REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PICEFR ! Cloud fraction REAL, DIMENSION(:,:,:), INTENT(IN) :: PRC_MF! Convective Mass Flux liquid mixing ratio REAL, DIMENSION(:,:,:), INTENT(IN) :: PCF_MF! Convective Mass Flux Cloud fraction ! @@ -715,6 +717,8 @@ IF ( OSUBG_COND ) THEN PCCS=0. PCLDFR=0. END WHERE + PICEFR(:,:,:)=0. + WHERE(PICEFR(:,:,:)<1.E-10 .AND. PRIT(:,:,:)>XRTMIN(4) .AND. PCIT(:,:,:)>XCTMIN(4)) PICEFR(:,:,:)=1. PRVS(:,:,:) = PRVS(:,:,:) - ZW1(:,:,:) PRCS(:,:,:) = PRCS(:,:,:) + ZW1(:,:,:) diff --git a/src/MNH/modd_fieldn.f90 b/src/MNH/modd_fieldn.f90 index 2e28feeae0e88d68dc7de3d6d189917ddcc66dfa..49cd8d3e5860b3a96468052aabae09bc6f79be44 100644 --- a/src/MNH/modd_fieldn.f90 +++ b/src/MNH/modd_fieldn.f90 @@ -165,6 +165,7 @@ REAL, DIMENSION(:,:,:), POINTER :: XHLI_HRI=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XHLI_HCF=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XSIGS=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XCLDFR=>NULL() +REAL, DIMENSION(:,:,:), POINTER :: XICEFR=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XRAINFR=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XCIT=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XTHM=>NULL() diff --git a/src/MNH/modd_getn.f90 b/src/MNH/modd_getn.f90 index f6531c4f82818662547b4332cfd7e6e2559a28f2..5978b7c2f6aafcf4f7a061d8938fab84360284f3 100644 --- a/src/MNH/modd_getn.f90 +++ b/src/MNH/modd_getn.f90 @@ -86,6 +86,8 @@ TYPE GET_t ! and SRC related to the subgrid condensation CHARACTER (LEN=4) :: CGETCLDFR ! Get indicator for the ! CLouD FRaction + CHARACTER (LEN=4) :: CGETICEFR ! Get indicator for the + ! CLouD FRaction CHARACTER (LEN=4) :: CGETSRCT ! Get indicator for SRCM ! and SRCT related to the subgrid condensation CHARACTER (LEN=4) :: CGETHL ! Get indicator for HighLow cloud @@ -123,6 +125,7 @@ CHARACTER (LEN=4), POINTER :: CGETLSUM=>NULL(), CGETLSVM=>NULL(), CGETLSWM=>NULL CHARACTER (LEN=4), POINTER :: CGETLSTHM=>NULL(), CGETLSRVM=>NULL() CHARACTER (LEN=4), POINTER :: CGETSIGS=>NULL(),CGETSRC=>NULL() CHARACTER (LEN=4), POINTER :: CGETCLDFR=>NULL() +CHARACTER (LEN=4), POINTER :: CGETICEFR=>NULL() CHARACTER (LEN=4), POINTER :: CGETSRCT=>NULL() CHARACTER (LEN=4), POINTER :: CGETHL=>NULL() CHARACTER (LEN=4), POINTER :: CGETCIT=>NULL() @@ -178,6 +181,7 @@ CGETLSRVM=>GET_MODEL(KTO)%CGETLSRVM CGETSIGS=>GET_MODEL(KTO)%CGETSIGS CGETSRC=>GET_MODEL(KTO)%CGETSRC CGETCLDFR=>GET_MODEL(KTO)%CGETCLDFR +CGETICEFR=>GET_MODEL(KTO)%CGETICEFR CGETSRCT=>GET_MODEL(KTO)%CGETSRCT CGETHL=>GET_MODEL(KTO)%CGETHL CGETCIT=>GET_MODEL(KTO)%CGETCIT diff --git a/src/MNH/modd_lesn.f90 b/src/MNH/modd_lesn.f90 index 28db43c4d13ba4f85754ace59ad988145b5f1c75..ac78ef503a2edbb805192fd505df5d174686b7ad 100644 --- a/src/MNH/modd_lesn.f90 +++ b/src/MNH/modd_lesn.f90 @@ -113,6 +113,7 @@ TYPE LES_t REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Qs=>NULL() ! saturated spec h REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Rc=>NULL() ! <Rc> REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Cf=>NULL() ! <CLDFR> + REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_If=>NULL() ! <CLDFR> REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_INDCf=>NULL() ! <Cf> tq rc>0 (0 OU 1) REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_INDCf2=>NULL() ! <Cf> tq rc>1E-5 (0 OU 1) REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_RF=>NULL() ! <RAINFR> @@ -686,6 +687,7 @@ REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Rehu=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Qs=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Rc=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_Cf=>NULL() +REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_If=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_INDCf=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_INDCf2=>NULL() REAL, DIMENSION(:,:,:), POINTER :: XLES_MEAN_RF=>NULL() @@ -1110,6 +1112,7 @@ LES_MODEL(KFROM)%XLES_MEAN_Rehu=>XLES_MEAN_Rehu LES_MODEL(KFROM)%XLES_MEAN_Qs=>XLES_MEAN_Qs LES_MODEL(KFROM)%XLES_MEAN_Rc=>XLES_MEAN_Rc LES_MODEL(KFROM)%XLES_MEAN_Cf=>XLES_MEAN_Cf +LES_MODEL(KFROM)%XLES_MEAN_If=>XLES_MEAN_If LES_MODEL(KFROM)%XLES_MEAN_INDCf=>XLES_MEAN_INDCf LES_MODEL(KFROM)%XLES_MEAN_INDCf2=>XLES_MEAN_INDCf2 LES_MODEL(KFROM)%XLES_MEAN_RF=>XLES_MEAN_RF @@ -1535,6 +1538,7 @@ XLES_MEAN_Rehu=>LES_MODEL(KTO)%XLES_MEAN_Rehu XLES_MEAN_Qs=>LES_MODEL(KTO)%XLES_MEAN_Qs XLES_MEAN_Rc=>LES_MODEL(KTO)%XLES_MEAN_Rc XLES_MEAN_Cf=>LES_MODEL(KTO)%XLES_MEAN_Cf +XLES_MEAN_If=>LES_MODEL(KTO)%XLES_MEAN_If XLES_MEAN_INDCf=>LES_MODEL(KTO)%XLES_MEAN_INDCf XLES_MEAN_INDCf2=>LES_MODEL(KTO)%XLES_MEAN_INDCf2 XLES_MEAN_RF=>LES_MODEL(KTO)%XLES_MEAN_RF diff --git a/src/MNH/modeln.f90 b/src/MNH/modeln.f90 index 6ba8d83984325d8138102903d0428b07887e3a3d..63245233c3d962a4a861c2da5de99cd296319113 100644 --- a/src/MNH/modeln.f90 +++ b/src/MNH/modeln.f90 @@ -1807,7 +1807,7 @@ IF ((LDUST).OR.(LSALT)) THEN ! GCLD=.TRUE. IF (GCLD .AND. NRR.LE.3 ) THEN - IF( MAXVAL(XCLDFR(:,:,:)).LE. 1.E-10 .AND. GCLOUD_ONLY ) THEN + IF( MAX(MAXVAL(XCLDFR(:,:,:)),MAXVAL(XICEFR(:,:,:))).LE. 1.E-10 .AND. GCLOUD_ONLY ) THEN GCLD = .FALSE. ! only the cloudy verticals would be ! refreshed but there is no clouds END IF @@ -1895,7 +1895,7 @@ IF (CCLOUD /= 'NONE' .AND. CELEC == 'NONE') THEN ZPABST, XTHT,XRT,XSIGS,VSIGQSAT,XMFCONV,XTHM,XRCM, & XPABSM, XWT_ACT_NUC,XDTHRAD, XRTHS, XRRS, & XSVT, XRSVS, & - XSRCT, XCLDFR,XCIT, & + XSRCT, XCLDFR,XICEFR, XCIT, & LSEDIC,KACTIT, KSEDC, KSEDI, KRAIN, KWARM, KHHONI, & LCONVHG, XCF_MF,XRC_MF, XRI_MF, & XINPRC,ZINPRC3D,XINPRR, XINPRR3D, XEVAP3D, & @@ -1914,7 +1914,7 @@ IF (CCLOUD /= 'NONE' .AND. CELEC == 'NONE') THEN ZPABST, XTHT,XRT,XSIGS,VSIGQSAT,XMFCONV,XTHM,XRCM, & XPABSM, XWT_ACT_NUC,XDTHRAD, XRTHS, XRRS, & XSVT, XRSVS, & - XSRCT, XCLDFR,XCIT, & + XSRCT, XCLDFR, XICEFR, XCIT, & LSEDIC,KACTIT, KSEDC, KSEDI, KRAIN, KWARM, KHHONI, & LCONVHG, XCF_MF,XRC_MF, XRI_MF, & XINPRC,ZINPRC3D,XINPRR, XINPRR3D, XEVAP3D, & @@ -2130,7 +2130,7 @@ IF (LPROFILER) & CALL PROFILER_n(XTSTEP, & XXHAT, XYHAT, XZZ,XRHODREF, & XUT, XVT, XWT, XTHT, XRT, XSVT, XTKET, XTSRAD, XPABST, & - XAER, XCLDFR, XCIT,PSEA=ZSEA(:,:)) + XAER, MAX(XCLDFR,XICEFR), XCIT,PSEA=ZSEA(:,:)) ! ! CALL SECOND_MNH2(ZTIME2) diff --git a/src/MNH/phys_paramn.f90 b/src/MNH/phys_paramn.f90 index be5d47e97df870f165baa47c3b3efb1d37f95961..ef08a0077d4ee244a144c6cf400e1545f9c71316 100644 --- a/src/MNH/phys_paramn.f90 +++ b/src/MNH/phys_paramn.f90 @@ -624,7 +624,7 @@ IF (CRAD /='NONE') THEN ! IF (CRAD =='ECMW' .OR. CRAD =='ECRA') THEN IF (GRAD .AND. NRR.LE.3 ) THEN - IF( MAXVAL(XCLDFR(:,:,:)).LE. 1.E-10 .AND. OCLOUD_ONLY ) THEN + IF( MAX(MAXVAL(XCLDFR(:,:,:)),MAXVAL(XICEFR(:,:,:))).LE. 1.E-10 .AND. OCLOUD_ONLY ) THEN GRAD = .FALSE. ! only the cloudy verticals would be ! refreshed but there is no clouds END IF @@ -739,7 +739,7 @@ CALL SUNPOS_n ( XZENITH, ZCOSZEN, ZSINZEN, ZAZIMSOL ) COPWLW, COPILW, XFUDG, & NDLON, NFLEV, NRAD_DIAG, NFLUX, NRAD, NAER, NSWB_OLD, NSWB_MNH, NLWB_MNH, & NSTATM, NRAD_COLNBR, ZCOSZEN, XSEA, XCORSOL, & - XDIR_ALB, XSCA_ALB, XEMIS, XCLDFR, XCCO2, XTSRAD, XSTATM, XTHT, XRT, & + XDIR_ALB, XSCA_ALB, XEMIS, MAX(XCLDFR,XICEFR), XCCO2, XTSRAD, XSTATM, XTHT, XRT, & XPABST, XOZON, XAER,XDST_WL, XAER_CLIM, XSVT, & XDTHRAD, XFLALWD, XDIRFLASWD, XSCAFLASWD, XRHODREF, XZZ , & XRADEFF, XSWU, XSWD, XLWU, XLWD, XDTHRADSW, XDTHRADLW ) diff --git a/src/MNH/read_exsegn.f90 b/src/MNH/read_exsegn.f90 index 9db15fc163ad08c775913431fff5c97226d3839e..6876f2f46d87e93b9a180522e17cc1f9d92f43b1 100644 --- a/src/MNH/read_exsegn.f90 +++ b/src/MNH/read_exsegn.f90 @@ -1606,6 +1606,20 @@ ELSE END IF END IF ! +IF (LUSERI.AND. (.NOT.OUSERI)) THEN + WRITE(UNIT=ILUOUT,FMT=9001) KMI + WRITE(UNIT=ILUOUT,FMT=*) 'THE ICE CLOUD FRACTION WILL BE INITIALIZED ACCORDING' + WRITE(UNIT=ILUOUT,FMT=*) 'TO CLOUD MIXING RATIO VALUE OR SET TO 0' + CGETICEFR = 'INIT' +ELSE + IF ( LUSERI ) THEN + CGETICEFR = 'READ' + IF ( (CCONF=='START') .AND. CPROGRAM /= 'DIAG') CGETICEFR='INIT' + ELSE + CGETICEFR = 'SKIP' + END IF +END IF +! IF(CTURBLEN=='RM17' .OR. CTURBLEN=='ADAP') THEN XCEDIS=0.34 ELSE diff --git a/src/MNH/read_field.f90 b/src/MNH/read_field.f90 index f7ccb114e6c605c3aad6f3585688b88e4f2b6b8b..d83171513705eb2621407b89d55801859dcf9749 100644 --- a/src/MNH/read_field.f90 +++ b/src/MNH/read_field.f90 @@ -11,7 +11,7 @@ INTERFACE ! SUBROUTINE READ_FIELD(KOCEMI,TPINIFILE,KIU,KJU,KKU, & HGETTKET,HGETRVT,HGETRCT,HGETRRT,HGETRIT,HGETCIT,HGETZWS, & - HGETRST,HGETRGT,HGETRHT,HGETSVT,HGETSRCT,HGETSIGS,HGETCLDFR, & + HGETRST,HGETRGT,HGETRHT,HGETSVT,HGETSRCT,HGETSIGS,HGETCLDFR,HGETICEFR, & HGETBL_DEPTH,HGETSBL_DEPTH,HGETPHC,HGETPHR,HUVW_ADV_SCHEME, & HTEMP_SCHEME,KSIZELBX_ll,KSIZELBXU_ll,KSIZELBY_ll,KSIZELBYV_ll, & KSIZELBXTKE_ll,KSIZELBYTKE_ll, & @@ -19,7 +19,7 @@ INTERFACE PUM,PVM,PWM,PDUM,PDVM,PDWM, & PUT,PVT,PWT,PTHT,PPABST,PTKET,PRTKEMS, & PRT,PSVT,PZWS,PCIT,PDRYMASST,PDRYMASSS, & - PSIGS,PSRCT,PCLDFR,PBL_DEPTH,PSBL_DEPTH,PWTHVMF,PPHC,PPHR, & + PSIGS,PSRCT,PCLDFR,PICEFR,PBL_DEPTH,PSBL_DEPTH,PWTHVMF,PPHC,PPHR, & PLSUM,PLSVM,PLSWM,PLSTHM,PLSRVM, PLSZWSM, & PLBXUM,PLBXVM,PLBXWM,PLBXTHM,PLBXTKEM,PLBXRM,PLBXSVM, & PLBYUM,PLBYVM,PLBYWM,PLBYTHM,PLBYTKEM,PLBYRM,PLBYSVM, & @@ -46,7 +46,7 @@ CHARACTER (LEN=*), INTENT(IN) :: HGETTKET, & HGETRVT,HGETRCT,HGETRRT, & HGETRIT,HGETRST,HGETRGT,HGETRHT, & HGETCIT,HGETSRCT, HGETZWS, & - HGETSIGS,HGETCLDFR,HGETBL_DEPTH, & + HGETSIGS,HGETCLDFR,HGETICEFR,HGETBL_DEPTH, & HGETSBL_DEPTH,HGETPHC,HGETPHR CHARACTER (LEN=*), DIMENSION(:),INTENT(IN) :: HGETSVT ! @@ -85,6 +85,7 @@ REAL, INTENT(OUT) :: PDRYMASSS ! d Md(t) / dt REAL, DIMENSION(:,:,:), INTENT(OUT) :: PSIGS ! =sqrt(<s's'>) for the ! Subgrid Condensation REAL, DIMENSION(:,:,:), INTENT(OUT) :: PCLDFR ! cloud fraction +REAL, DIMENSION(:,:,:), INTENT(OUT) :: PICEFR ! cloud fraction REAL, DIMENSION(:,:,:), INTENT(OUT) :: PPHC ! pH value in cloud water REAL, DIMENSION(:,:,:), INTENT(OUT) :: PPHR ! pH value in rainwater ! Larger Scale fields @@ -135,7 +136,7 @@ END MODULE MODI_READ_FIELD ! ######################################################################## SUBROUTINE READ_FIELD(KOCEMI,TPINIFILE,KIU,KJU,KKU, & HGETTKET,HGETRVT,HGETRCT,HGETRRT,HGETRIT,HGETCIT,HGETZWS, & - HGETRST,HGETRGT,HGETRHT,HGETSVT,HGETSRCT,HGETSIGS,HGETCLDFR, & + HGETRST,HGETRGT,HGETRHT,HGETSVT,HGETSRCT,HGETSIGS,HGETCLDFR,HGETICEFR, & HGETBL_DEPTH,HGETSBL_DEPTH,HGETPHC,HGETPHR,HUVW_ADV_SCHEME, & HTEMP_SCHEME,KSIZELBX_ll,KSIZELBXU_ll,KSIZELBY_ll,KSIZELBYV_ll, & KSIZELBXTKE_ll,KSIZELBYTKE_ll, & @@ -143,7 +144,7 @@ END MODULE MODI_READ_FIELD PUM,PVM,PWM,PDUM,PDVM,PDWM, & PUT,PVT,PWT,PTHT,PPABST,PTKET,PRTKEMS, & PRT,PSVT,PZWS,PCIT,PDRYMASST,PDRYMASSS, & - PSIGS,PSRCT,PCLDFR,PBL_DEPTH,PSBL_DEPTH,PWTHVMF,PPHC,PPHR, & + PSIGS,PSRCT,PCLDFR,PICEFR,PBL_DEPTH,PSBL_DEPTH,PWTHVMF,PPHC,PPHR, & PLSUM,PLSVM,PLSWM,PLSTHM,PLSRVM,PLSZWSM, & PLBXUM,PLBXVM,PLBXWM,PLBXTHM,PLBXTKEM,PLBXRM,PLBXSVM, & PLBYUM,PLBYVM,PLBYWM,PLBYTHM,PLBYTKEM,PLBYRM,PLBYSVM, & @@ -325,7 +326,7 @@ CHARACTER (LEN=*), INTENT(IN) :: HGETTKET, & HGETRVT,HGETRCT,HGETRRT, & HGETRIT,HGETRST,HGETRGT,HGETRHT, & HGETCIT,HGETSRCT,HGETZWS, & - HGETSIGS,HGETCLDFR,HGETBL_DEPTH, & + HGETSIGS,HGETCLDFR,HGETICEFR,HGETBL_DEPTH, & HGETSBL_DEPTH,HGETPHC,HGETPHR CHARACTER (LEN=*), DIMENSION(:),INTENT(IN) :: HGETSVT ! @@ -366,6 +367,7 @@ REAL, INTENT(OUT) :: PDRYMASSS ! d Md(t) / dt REAL, DIMENSION(:,:,:), INTENT(OUT) :: PSIGS ! =sqrt(<s's'>) for the ! Subgrid Condensation REAL, DIMENSION(:,:,:), INTENT(OUT) :: PCLDFR ! cloud fraction +REAL, DIMENSION(:,:,:), INTENT(OUT) :: PICEFR ! cloud fraction REAL, DIMENSION(:,:,:), INTENT(OUT) :: PPHC ! pH value in cloud water REAL, DIMENSION(:,:,:), INTENT(OUT) :: PPHR ! pH value in rainwater ! @@ -1520,6 +1522,22 @@ IF(HGETCLDFR=='INIT' .OR. IRESP /= 0) THEN ENDIF ENDIF ! +IRESP=0 +IF(HGETICEFR=='READ') THEN ! cloud fraction + CALL IO_Field_read(TPINIFILE,'ICEFR',PICEFR,IRESP) +ENDIF +IF(HGETCLDFR=='INIT' .OR. IRESP /= 0) THEN + IF(SIZE(PRT,4) > 3) THEN + WHERE(PRT(:,:,:,4) > 1.E-30) + PICEFR(:,:,:) = 1. + ELSEWHERE + PICEFR(:,:,:) = 0. + ENDWHERE + ELSE + PICEFR(:,:,:) = 0. + ENDIF +ENDIF +! !* boundary layer depth ! IF (HGETBL_DEPTH=='READ') THEN diff --git a/src/MNH/resolved_cloud.f90 b/src/MNH/resolved_cloud.f90 index 30616e6c57314d97e5f5e032bf5f4b6e77d89c87..53cff879c3ef2c52e9c38b2fb58faa8b72d6f1ec 100644 --- a/src/MNH/resolved_cloud.f90 +++ b/src/MNH/resolved_cloud.f90 @@ -14,7 +14,7 @@ INTERFACE PTSTEP, PZZ, PRHODJ, PRHODREF, PEXNREF, & PPABST, PTHT, PRT, PSIGS, PSIGQSAT, PMFCONV, & PTHM, PRCM, PPABSM, & - PW_ACT,PDTHRAD, PTHS, PRS, PSVT, PSVS, PSRCS, PCLDFR,& + PW_ACT,PDTHRAD, PTHS, PRS, PSVT, PSVS, PSRCS, PCLDFR, PICEFR,& PCIT, OSEDIC, OACTIT, OSEDC, OSEDI, & ORAIN, OWARM, OHHONI, OCONVHG, & PCF_MF,PRC_MF, PRI_MF, & @@ -83,6 +83,7 @@ REAL, DIMENSION(:,:,:), INTENT(OUT) :: PSRCS ! Second-order flux ! s'rc'/2Sigma_s2 at time t+1 ! multiplied by Lambda_3 REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PCLDFR! Cloud fraction +REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PICEFR! Cloud fraction REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PCIT ! Pristine ice number ! concentration at time t LOGICAL, INTENT(IN) :: OSEDIC! Switch to activate the @@ -152,7 +153,7 @@ END MODULE MODI_RESOLVED_CLOUD PTSTEP, PZZ, PRHODJ, PRHODREF, PEXNREF, & PPABST, PTHT, PRT, PSIGS, PSIGQSAT, PMFCONV, & PTHM, PRCM, PPABSM, & - PW_ACT,PDTHRAD, PTHS, PRS, PSVT, PSVS, PSRCS, PCLDFR,& + PW_ACT,PDTHRAD, PTHS, PRS, PSVT, PSVS, PSRCS, PCLDFR,PICEFR,& PCIT, OSEDIC, OACTIT, OSEDC, OSEDI, & ORAIN, OWARM, OHHONI, OCONVHG, & PCF_MF,PRC_MF, PRI_MF, & @@ -382,6 +383,7 @@ REAL, DIMENSION(:,:,:), INTENT(OUT) :: PSRCS ! Second-order flux ! s'rc'/2Sigma_s2 at time t+1 ! multiplied by Lambda_3 REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PCLDFR! Cloud fraction +REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PICEFR! Cloud fraction REAL, DIMENSION(:,:,:), INTENT(INOUT) :: PCIT ! Pristine ice number ! concentration at time t LOGICAL, INTENT(IN) :: OSEDIC! Switch to activate the @@ -939,7 +941,7 @@ SELECT CASE ( HCLOUD ) PSVT(:,:,:,NSV_LIMA_BEG:NSV_LIMA_END), PW_ACT, & PTHS, PRS, PSVS(:,:,:,NSV_LIMA_BEG:NSV_LIMA_END), & PINPRC, PINDEP, PINPRR, ZINPRI, PINPRS, PINPRG, PINPRH, & - PEVAP3D, PCLDFR, ZICEFR, ZPRCFR ) + PEVAP3D, PCLDFR, PICEFR, ZPRCFR ) ELSE IF (OWARM) CALL LIMA_WARM(OACTIT, OSEDC, ORAIN, KSPLITR, PTSTEP, KMI, & @@ -981,7 +983,7 @@ SELECT CASE ( HCLOUD ) PDTHRAD, PW_ACT, & PRT, PRS, PSVT(:,:,:,NSV_LIMA_BEG:NSV_LIMA_END), & PSVS(:,:,:,NSV_LIMA_BEG:NSV_LIMA_END), & - PTHS, PSRCS, PCLDFR, PRC_MF, PCF_MF ) + PTHS, PSRCS, PCLDFR, PICEFR, PRC_MF, PCF_MF ) ELSE CALL LIMA_ADJUST(KRR, KMI, TPFILE, & OSUBG_COND, PTSTEP, & diff --git a/src/MNH/write_lesn.f90 b/src/MNH/write_lesn.f90 index e4adb2045bd0fc24bbcf5f685c34fd7051a53ba7..de2902c056081d6dee7dbf836b8d7f61e5ff4dd3 100644 --- a/src/MNH/write_lesn.f90 +++ b/src/MNH/write_lesn.f90 @@ -87,6 +87,7 @@ use modd_grid_n, only: xdxhat, xdyhat use modd_nsv, only: nsv use modd_les use modd_les_n +use modd_param_n, only: ccloud use modd_param_c2r2, only: ldepoc use modd_param_ice, only: ldeposc use modd_parameters, only: XUNDEF @@ -355,6 +356,8 @@ if ( luserr ) & call Les_diachro_write( tpdiafile, XLES_MEAN_RF, 'MEAN_RF', 'Mean RF Profile', '1', ymasks ) if ( luseri ) & call Les_diachro_write( tpdiafile, XLES_MEAN_Ri, 'MEAN_RI', 'Mean Ri Profile', 'kg kg-1', ymasks ) +if ( luseri .and. ccloud=='lima') & +call Les_diachro_write( tpdiafile, XLES_MEAN_If, 'MEAN_IF', 'Mean If Profile', '1', ymasks ) if ( lusers ) & call Les_diachro_write( tpdiafile, XLES_MEAN_Rs, 'MEAN_RS', 'Mean Rs Profile', 'kg kg-1', ymasks ) if ( luserg ) & diff --git a/src/MNH/write_lfifm1_for_diag.f90 b/src/MNH/write_lfifm1_for_diag.f90 index 0a16f3078ac75dfbe27e09ebcd0088176eb15fbe..967b74d5da18fc6a2131f3406a9425d62043a326 100644 --- a/src/MNH/write_lfifm1_for_diag.f90 +++ b/src/MNH/write_lfifm1_for_diag.f90 @@ -3953,7 +3953,7 @@ IF (LLIDAR) THEN ZTMP4(:,:,:,3)=XSVT(:,:,:,NSV_LIMA_NR) ZTMP4(:,:,:,4)=XSVT(:,:,:,NSV_LIMA_NI) ! - CALL LIDAR(CCLOUD, YVIEW, XALT_LIDAR, XWVL_LIDAR, XZZ, XRHODREF, XCLDFR,& + CALL LIDAR(CCLOUD, YVIEW, XALT_LIDAR, XWVL_LIDAR, XZZ, XRHODREF, MAX(XCLDFR,XICEFR),& XRT, ZWORK31, ZWORK32, & PCT=ZTMP4, & PDSTC=ZTMP1, & @@ -3982,7 +3982,7 @@ IF (LLIDAR) THEN ZTMP4(:,:,:,3)=XSVT(:,:,:,NSV_LIMA_NR) ZTMP4(:,:,:,4)=XSVT(:,:,:,NSV_LIMA_NI) ! - CALL LIDAR(CCLOUD, YVIEW, XALT_LIDAR, XWVL_LIDAR, XZZ, XRHODREF, XCLDFR,& + CALL LIDAR(CCLOUD, YVIEW, XALT_LIDAR, XWVL_LIDAR, XZZ, XRHODREF, MAX(XCLDFR,XICEFR),& XRT, ZWORK31, ZWORK32, & PCT=ZTMP4) END SELECT diff --git a/src/MNH/write_lfifm1_for_diag_supp.f90 b/src/MNH/write_lfifm1_for_diag_supp.f90 index 1bb11e435afd44755eff957d81908fa904554cb6..0175e2c28a7b797264a2578763d00077218aadcd 100644 --- a/src/MNH/write_lfifm1_for_diag_supp.f90 +++ b/src/MNH/write_lfifm1_for_diag_supp.f90 @@ -519,6 +519,7 @@ IF (LCLD_COV .AND. LUSERC) THEN CALL IO_Field_write(TPFILE,TZFIELD,ZWORK22) ! CALL IO_Field_write(TPFILE,'CLDFR',XCLDFR) + CALL IO_Field_write(TPFILE,'ICEFR',XICEFR) ! ! Visibility ! @@ -808,7 +809,7 @@ IF (LEN_TRIM(CRAD_SAT) /= 0 .AND. NRR /=0) THEN CALL RADTR_SATEL( TDTCUR%nyear, TDTCUR%nmonth, TDTCUR%nday, TDTCUR%xtime, & NDLON, NFLEV, NSTATM, NRAD_COLNBR, XEMIS(:,:,1), & XCCO2, XTSRAD, XSTATM, XTHT, XRT, XPABST, XZZ, & - XSIGS, XMFCONV, XCLDFR, LUSERI, LSIGMAS, & + XSIGS, XMFCONV, MAX(XCLDFR,XICEFR), LUSERI, LSIGMAS, & LSUBG_COND, LRAD_SUBG_COND, ZIRBT, ZWVBT, & INDGEO(JI), VSIGQSAT ) ! @@ -848,15 +849,15 @@ IF (NRTTOVINFO(1,1) /= NUNDEF) THEN ! PRINT*,'YOU ASK FOR BRIGHTNESS TEMPERATURE COMPUTED BY THE RTTOV CODE' #ifdef MNH_RTTOV_8 CALL CALL_RTTOV8(NDLON, NFLEV, NSTATM, XEMIS(:,:,1), XTSRAD, XSTATM, XTHT, XRT, & - XPABST, XZZ, XMFCONV, XCLDFR, XUT(:,:,IKB), XVT(:,:,IKB), & + XPABST, XZZ, XMFCONV, MAX(XCLDFR,XICEFR), XUT(:,:,IKB), XVT(:,:,IKB), & LUSERI, NRTTOVINFO, TPFILE ) #elif MNH_RTTOV_11 CALL CALL_RTTOV11(NDLON, NFLEV, XEMIS(:,:,1), XTSRAD, XTHT, XRT, & - XPABST, XZZ, XMFCONV, XCLDFR, XUT(:,:,IKB), XVT(:,:,IKB), & + XPABST, XZZ, XMFCONV, MAX(XCLDFR,XICEFR), XUT(:,:,IKB), XVT(:,:,IKB), & LUSERI, NRTTOVINFO, TPFILE ) #elif MNH_RTTOV_13 CALL CALL_RTTOV13(NDLON, NFLEV, XEMIS(:,:,1), XTSRAD, XTHT, XRT, & - XPABST, XZZ, XMFCONV, XCLDFR, XUT(:,:,IKB), XVT(:,:,IKB), & + XPABST, XZZ, XMFCONV, MAX(XCLDFR,XICEFR), XUT(:,:,IKB), XVT(:,:,IKB), & LUSERI, NRTTOVINFO, TPFILE ) #else PRINT *, "RTTOV LIBRARY NOT AVAILABLE = ###CALL_RTTOV####" diff --git a/src/MNH/write_lfin.f90 b/src/MNH/write_lfin.f90 index e9bab27c0a30fccb9d0b8fbb61d500a8fa9e84a9..bf995535edfc2ccea499fc360c92d749beb4ca19 100644 --- a/src/MNH/write_lfin.f90 +++ b/src/MNH/write_lfin.f90 @@ -1673,6 +1673,7 @@ ENDIF ! IF (NRR > 1 .AND. CPROGRAM == 'MESONH') THEN CALL IO_Field_write(TPFILE,'CLDFR',XCLDFR) + CALL IO_Field_write(TPFILE,'ICEFR',XICEFR) CALL IO_Field_write(TPFILE,'RAINFR',XRAINFR) END IF !