Changeset 5633 for LMDZ6/trunk


Ignore:
Timestamp:
Apr 28, 2025, 2:46:35 PM (6 weeks ago)
Author:
evignon
Message:

small changes related to mixed phase clouds treatment
Etienne and Lea

Location:
LMDZ6/trunk/libf/phylmd
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/trunk/libf/phylmd/lmdz_lscp_main.f90

    r5614 r5633  
    289289  REAL, DIMENSION(klon) :: zdqsdT_raw
    290290  REAL, DIMENSION(klon) :: gammasat,dgammasatdt                   ! coefficient to make cold condensation at the correct RH and derivative wrt T
    291   REAL, DIMENSION(klon) :: Tbef,Tbefth,qlibef,DT                  ! temperature, humidity and temp. variation during condensation iteration
     291  REAL, DIMENSION(klon) :: Tbef,Tbefth,Tbefthm1,qlibef,DT                  ! temperature, humidity and temp. variation during condensation iteration
    292292  REAL :: num,denom
    293293  REAL :: cste
     
    536536    ENDIF ! (ok_poprecip)
    537537   
    538     ! Calculation of qsat, L/Cp*dqsat/dT and ncoreczq counter
     538    ! Calculation of qsat,L/cp*dqsat/dT and ncoreczq counter
    539539    !-------------------------------------------------------
    540540
     
    653653        qlibef(:)=0.
    654654        Tbefth(:)=tla(:,k)*pspsk(:,k)
     655        IF (k .GT. 1) THEN
     656         Tbefthm1(:)=tla(:,k-1)*pspsk(:,k-1)
     657        ELSE
     658         Tbefthm1(:)=Tbefth(:)       
     659        ENDIF
    655660        zqth=qta(:,k)
    656661
     
    817822                        invtau_e(i) = 0.
    818823                     ENDDO
    819                      CALL icefrac_lscp_turb(klon, dtime, pticefracturb, Tbef, zp, paprs(:,k), paprs(:,k+1), wls(:,k), zqi_ini, ziflcld, qincloud, &
    820                      zcf, tke(:,k), tke_dissip(:,k), sursat_e, invtau_e, zqliq, zqvapcl, zqice, zficeenv, dzficeenv,                   &
    821                      cldfraliq(:,k),sigma2_icefracturb(:,k),mean_icefracturb(:,k))                     
     824                     CALL icefrac_lscp_turb(klon, dtime, pticefracturb, Tbef, zp, paprs(:,k), paprs(:,k+1), wls(:,k), zqi_ini,   &
     825                     ziflcld, znebprecipcld, qincloud, zcf, tke(:,k), tke_dissip(:,k), sursat_e, invtau_e, zqliq, zqvapcl, zqice, &
     826                     zficeenv, dzficeenv, cldfraliq(:,k),sigma2_icefracturb(:,k),mean_icefracturb(:,k))                     
    822827                     DO i=1,klon
    823828                        IF (pticefracturb(i)) THEN
     
    846851                        invtau_e(i)=gamma_mixth*MAX(entr_therm(i,k)-detr_therm(i,k),0.)*RD*Tbef(i)/zp(i)
    847852                     ENDDO
    848                      CALL icefrac_lscp_turb(klon, dtime, pticefracturb, Tbefth, zp, paprs(:,k), paprs(:,k+1), wth(:,k), zqi_ini, zeroklon, qincloud, &
    849                      zcf, zeroklon, zeroklon, sursat_e, invtau_e, zqliqth, zqvapclth, zqiceth, zficeth, dzficeth,                      &
    850                      cldfraliqth(:,k), sigma2_icefracturbth(:,k), mean_icefracturbth(:,k))
     853                     CALL icefrac_lscp_turb(klon, dtime, pticefracturb, Tbefth, zp, paprs(:,k), paprs(:,k+1), wth(:,k), zqi_ini, &
     854                     zeroklon, znebprecipcld, qincloud, zcf, zeroklon, zeroklon, sursat_e, invtau_e, zqliqth, zqvapclth, zqiceth, &
     855                     zficeth, dzficeth,cldfraliqth(:,k), sigma2_icefracturbth(:,k), mean_icefracturbth(:,k))
    851856                     !Environment
    852857                     DO i=1,klon
    853858                        qincloud(i)=zqn(i)/(1.-fraca(i,k))
    854859                        zcf(i)=MIN(MAX(rneb(i,k)-rnebth(i,k), 0.),1.)*(1.-fraca(i,k))
    855                         sursat_e(i)=cloudth_sth(i,k)/zqsith(i)
    856                         invtau_e(i)=gamma_mixth*MAX(detr_therm(i,k)-entr_therm(i,k),0.)*RD*Tbef(i)/zp(i)
     860                        IF (k .GT. 1) THEN
     861                           ! evaluate the mixing sursaturation using saturation deficit at level below
     862                           sursat_e(i)=cloudth_sth(i,k-1)/(zqsith(i)+zdqsith(i)*RCPD/RLSTT*(Tbefthm1(i)-Tbefth(i)))
     863                           invtau_e(i)=gamma_mixth*MAX(detr_therm(i,k)-entr_therm(i,k),0.)*RD*Tbef(i)/zp(i)
     864                        ELSE
     865                           sursat_e(i)=0.
     866                           invtau_e(i)=0.
     867                        ENDIF
    857868                     ENDDO
    858                      CALL icefrac_lscp_turb(klon, dtime, pticefracturb, Tbef, zp, paprs(:,k), paprs(:,k+1), wls(:,k), zqi_ini, ziflcld, qincloud, &
    859                      zcf, tke(:,k), tke_dissip(:,k), sursat_e, invtau_e, zqliq, zqvapcl, zqice, zfice, dzfice,                      &
    860                      cldfraliq(:,k),sigma2_icefracturb(:,k), mean_icefracturb(:,k))
     869                     CALL icefrac_lscp_turb(klon, dtime, pticefracturb, Tbef, zp, paprs(:,k), paprs(:,k+1), wls(:,k), zqi_ini,   &
     870                     ziflcld, znebprecipcld, qincloud, zcf, tke(:,k), tke_dissip(:,k), sursat_e, invtau_e, zqliq, zqvapcl, zqice, &
     871                     zfice, dzfice, cldfraliq(:,k),sigma2_icefracturb(:,k), mean_icefracturb(:,k))
    861872 
    862873                    ! adjust zfice to account for condensates in thermals'fraction
  • LMDZ6/trunk/libf/phylmd/lmdz_lscp_tools.f90

    r5614 r5633  
    241241
    242242
    243 SUBROUTINE ICEFRAC_LSCP_TURB(klon, dtime, pticefracturb, temp, pplay, paprsdn, paprsup, wvel, qice_ini, snowcld, qtot_incl, cldfra, tke,   &
     243SUBROUTINE ICEFRAC_LSCP_TURB(klon, dtime, pticefracturb, temp, pplay, paprsdn, paprsup, wvel, qice_ini, snowcld, snowfracld, qtot_incl, cldfra, tke,   &
    244244                             tke_dissip, sursat_e, invtau_e, qliq, qvap_cld, qice, icefrac, dicefracdT, cldfraliq, sigma2_icefracturb, mean_icefracturb)
    245245!+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
     
    256256   USE lmdz_lscp_ini, ONLY : seuil_neb, temp_nowater
    257257   USE lmdz_lscp_ini, ONLY : naero5, gamma_snwretro, gamma_taud, capa_crystal, rho_ice
    258    USE lmdz_lscp_ini, ONLY : eps
     258   USE lmdz_lscp_ini, ONLY : eps, snow_fallspeed
    259259
    260260   IMPLICIT NONE
     
    275275   REAL,      INTENT(IN),       DIMENSION(klon)    :: qice_ini            !--initial specific ice content gridbox-mean     [kg/kg]
    276276   REAL,      INTENT(IN),       DIMENSION(klon)    :: snowcld             !--in-cloud snowfall flux                        [kg/m2/s]
     277   REAL,      INTENT(IN),       DIMENSION(klon)    :: snowfracld          !--cloudy precip fraction                        [-]
    277278   REAL,      INTENT(IN),       DIMENSION(klon)    :: sursat_e            !--environment supersaturation                   [-]
    278279   REAL,      INTENT(IN),       DIMENSION(klon)    :: invtau_e            !--inverse time-scale of mixing with environment [s-1]
     
    371372        ELSE
    372373
    373            qiceini_incl  = qice_ini(i) / cldfra1D + gamma_snwretro * snowcld(i) * RG * dtime / ( paprsdn(i) - paprsup(i) ) / cldfra1D
    374            ! assuming snowfall velocity = 1 m/s:
    375            !qiceini_incl  = qice_ini(i) / cldfra1D + gamma_snwretro * snowcld(i) / pplay(i) * RD * temp(i) / 1. / cldfra1D
     374           ! gamma_snwretro controls the contribution of snowflakes to the negative feedback
     375           ! note that for reasons related to inetarctions with the condensation iteration in lscp_main
     376           ! we consider here the mean snowflake concentration in the mesh (not the in-cloud concentration)
     377           ! when poprecip is active, it will be worth testing considering the incloud fraction, dividing
     378           ! by snowfracld     
     379           ! qiceini_incl  = qice_ini(i) / cldfra1D + &
     380           !              gamma_snwretro * snowcld(i) * RG * dtime / ( paprsdn(i) - paprsup(i) )
     381           ! assuming constant snowfall velocity
     382           qiceini_incl  = qice_ini(i) / cldfra1D + gamma_snwretro * snowcld(i) / pplay(i) * RD * temp(i) / snow_fallspeed
    376383
    377384           !--1. No preexisting ice and no mixing with environment: if vertical motion, fully liquid
     
    445452              ai = RG / RD / temp(i) * ( RD * RLSTT / RCPD / RV / temp(i) - 1. )
    446453              sursat_equ    = (ai * wvel(i) + sursat_e(i)*invtau_e(i)) / (invtau_phaserelax + invtau_e(i))
    447               sursat_equ    = MAX(-1., MIN(sursat_equ , 1.))
    448454              ! as sursaturation is by definition lower than -1 and
    449455              ! because local supersaturation > 1 are never found in the atmosphere
     
    490496
    491497                 liqfra_max = MAX(0., (MIN (1.,( qtot_incl(i) - (qice_ini(i) / cldfra1D) - qsati(i) * (1 + sursat_iceext ) ) / ( qsatl(i) - qsati(i) ) ) ) )
    492                  sigma2_pdf = MIN(1., 1./2. * ( ai**2 ) *  2./3. * tke(i) * tau_dissipturb / (invtau_phaserelax + invtau_e(i)))
     498                 sigma2_pdf = 1./2. * ( ai**2 ) *  2./3. * tke(i) * tau_dissipturb / (invtau_phaserelax + invtau_e(i))
    493499                 ! sursat ranges between -1 and 1, so we prevent sigma2 so exceed 1
    494500                 cldfraliq(i) = 0.5 * (1. - erf( ( sursat_iceliq - sursat_equ) / (SQRT(2.* sigma2_pdf) ) ) )
Note: See TracChangeset for help on using the changeset viewer.