Changeset 4715


Ignore:
Timestamp:
Oct 5, 2023, 4:14:22 PM (8 months ago)
Author:
Laurent Fairhead
Message:

Final (hopefully) commit from the newmicro replayisation workshop. The final USE statements that were
still included in the cloud_optics_prop routine were moved to the call_cloud_optics_prop routine that
sets up the interface between LMDZ and the parametrization.
LF for LR, MCD, AI, EV, JBM

Location:
LMDZ6/trunk/libf
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/trunk/libf/phylmd/lmdz_cloud_optics_prop.F90

    r4707 r4715  
    2929  USE lmdz_cloud_optics_prop_ini , ONLY : zepsec, novlp, iflag_ice_thermo, ok_new_lscp
    3030 
    31   USE icefrac_lsc_mod ! computes ice fraction (JBM 3/14)
    32   USE lmdz_lscp_tools, only: icefrac_lscp
    3331
    3432
     
    112110  REAL, INTENT(OUT) :: icc3dcon(klon, klev)! cloud fraction for liquid part only, convective clouds [-]
    113111  REAL, INTENT(OUT) :: icc3dstra(klon, klev)! cloud fraction for ice part only, stratiform clouds [-]
    114   REAL, INTENT(OUT) :: icefrac_optics(klon, klev)! ice fraction in clouds seen by radiation [-]
     112  REAL, INTENT(INOUT) :: icefrac_optics(klon, klev)! ice fraction in clouds seen by radiation [-]
    115113
    116114  ! Local variables
     
    196194
    197195
    198       IF (ok_new_lscp) THEN
    199           CALL icefrac_lscp(klon,temp(:,k),iflag_ice_thermo,distcltop(:,k),temp_cltop(:,k),icefrac_optics(:,k),dzfice(:,k))
    200       ELSE
    201           CALL icefrac_lsc(klon,temp(:,k),pplay(:,k)/paprs(:,1),icefrac_optics(:,k))
    202       ENDIF
     196!!$      IF (ok_new_lscp) THEN
     197!!$          CALL icefrac_lscp(klon,temp(:,k),iflag_ice_thermo,distcltop(:,k),temp_cltop(:,k),icefrac_optics(:,k),dzfice(:,k))
     198!!$      ELSE
     199!!$          CALL icefrac_lsc(klon,temp(:,k),pplay(:,k)/paprs(:,1),icefrac_optics(:,k))
     200!!$      ENDIF
    203201
    204202      DO i = 1, klon
  • LMDZ6/trunk/libf/phylmd/nuage.F90

    r4664 r4715  
    120120        ENDIF
    121121
    122         IF ((.NOT. ptconv(i,k)) .AND. ok_new_lscp .AND. ok_icefra_lscp) THEN
    123         ! EV: take the ice fraction directly from the lscp code
    124         ! consistent only for non convective grid points
    125         ! critical for mixed phase clouds
    126             DO i=1,klon
    127             zfice(i)=picefra(i,k)
    128             ENDDO
     122    IF (ok_new_lscp .AND. ok_icefra_lscp) THEN
     123    ! EV: take the ice fraction directly from the lscp code
     124    ! consistent only for non convective grid points
     125    ! critical for mixed phase clouds
     126        DO i=1,klon
     127        IF (.NOT. ptconv(i,k)) THEN
     128           zfice(i)=picefra(i,k)
    129129        ENDIF
     130        ENDDO
     131    ENDIF
    130132
    131133
  • LMDZ6/trunk/libf/phylmd/physiq_mod.F90

    r4707 r4715  
    7878    USE wxios, ONLY: g_ctx, wxios_set_context
    7979    USE lmdz_lscp, ONLY : lscp
    80     USE lmdz_cloud_optics_prop, ONLY : cloud_optics_prop
     80    USE lmdz_call_cloud_optics_prop, ONLY : call_cloud_optics_prop
    8181    USE lmdz_lscp_old, ONLY : fisrtilp
    8282    USE lmdz_wake_ini, ONLY : wake_ini
     
    18441844                             RCPD, RLSTT, RLVTT, RLMLT, &
    18451845                             RVTMP2, RTT,RD,RG)
     1846       ! Test de coherence sur oc_cdnc utilisé uniquement par cloud_optics_prop
     1847       IF (ok_newmicro) then
     1848          IF (iflag_rrtm.EQ.1) THEN
     1849#ifdef CPP_RRTM
     1850             IF (ok_cdnc.AND.NRADLP.NE.3) THEN
     1851             abort_message='RRTM choix incoherent NRADLP doit etre egal a 3 ' &
     1852                  // 'pour ok_cdnc'
     1853             CALL abort_physic(modname,abort_message,1)
     1854             ENDIF
     1855#else
     1856
     1857             abort_message='You should compile with -rrtm if running with '//'iflag_rrtm=1'
     1858             CALL abort_physic(modname,abort_message,1)
     1859#endif
     1860          ENDIF
     1861       ENDIF   
    18461862       CALL cloud_optics_prop_ini(klon, prt_level, lunout, flag_aerosol, &
    18471863                                  & ok_cdnc, bl95_b0, &
     
    43874403       ENDIF
    43884404
    4389        IF (ok_newmicro) then
    4390 ! AI          IF (iflag_rrtm.NE.0) THEN
    4391           IF (iflag_rrtm.EQ.1) THEN
    4392 #ifdef CPP_RRTM
    4393              IF (ok_cdnc.AND.NRADLP.NE.3) THEN
    4394              abort_message='RRTM choix incoherent NRADLP doit etre egal a 3 ' &
    4395                   // 'pour ok_cdnc'
    4396              CALL abort_physic(modname,abort_message,1)
    4397              ENDIF
    4398 #else
    4399 
    4400              abort_message='You should compile with -rrtm if running with '//'iflag_rrtm=1'
    4401              CALL abort_physic(modname,abort_message,1)
    4402 #endif
    4403           ENDIF
    4404           CALL cloud_optics_prop(klon, klev, &
     4405       !Rajout appel a interface calcul proprietes optiques des nuages
     4406       CALL call_cloud_optics_prop(klon, klev, ok_newmicro, &
    44054407               paprs, pplay, t_seri, radocond, picefra, cldfra, &
    44064408               cldtau, cldemi, cldh, cldl, cldm, cldt, cldq, &
    4407                flwp, fiwp, flwc, fiwc, &
     4409               flwp, fiwp, flwc, fiwc, ok_aie, &
    44084410               mass_solu_aero, mass_solu_aero_pi, &
    44094411               cldtaupi, distcltop, temp_cltop, re, fl, ref_liq, ref_ice, &
     
    44114413               reffclwc, cldnvi, lcc3d, lcc3dcon, lcc3dstra, icc3dcon, icc3dstra,  &
    44124414               zfice, dNovrN, ptconv, rnebcon, clwcon)
    4413        ELSE
    4414           CALL nuage (paprs, pplay, &
    4415                t_seri, radocond, picefra, cldfra, cldtau, cldemi, &
    4416                cldh, cldl, cldm, cldt, cldq, &
    4417                ok_aie, &
    4418                mass_solu_aero, mass_solu_aero_pi, &
    4419                bl95_b0, bl95_b1, distcltop, temp_cltop, &
    4420                cldtaupi, re, fl)
    4421        ENDIF
     4415
    44224416       !
    44234417       !IM betaCRF
  • LMDZ6/trunk/libf/phylmdiso/physiq_mod.F90

    r4707 r4715  
    7878    USE wxios, ONLY: g_ctx, wxios_set_context
    7979    USE lmdz_lscp, ONLY : lscp
    80     USE lmdz_cloud_optics_prop, ONLY : cloud_optics_prop
     80    USE lmdz_call_cloud_optics_prop, ONLY : call_cloud_optics_prop
    8181    USE lmdz_lscp_old, ONLY : fisrtilp
    8282    USE lmdz_wake_ini, ONLY : wake_ini
     
    19321932                             RCPD, RLSTT, RLVTT, RLMLT, &
    19331933                             RVTMP2, RTT,RD,RG)
     1934       ! Test de coherence sur oc_cdnc utilisé uniquement par cloud_optics_prop
     1935       IF (ok_newmicro) then
     1936          IF (iflag_rrtm.EQ.1) THEN
     1937#ifdef CPP_RRTM
     1938             IF (ok_cdnc.AND.NRADLP.NE.3) THEN
     1939             abort_message='RRTM choix incoherent NRADLP doit etre egal a 3 ' &
     1940                  // 'pour ok_cdnc'
     1941             CALL abort_physic(modname,abort_message,1)
     1942             ENDIF
     1943#else
     1944
     1945             abort_message='You should compile with -rrtm if running with '//'iflag_rrtm=1'
     1946             CALL abort_physic(modname,abort_message,1)
     1947#endif
     1948          ENDIF
     1949       ENDIF   
    19341950       CALL cloud_optics_prop_ini(klon, prt_level, lunout, flag_aerosol, &
    19351951                                  & ok_cdnc, bl95_b0, &
     
    55775593       ENDIF
    55785594
    5579        IF (ok_newmicro) then
    5580 ! AI          IF (iflag_rrtm.NE.0) THEN
    5581           IF (iflag_rrtm.EQ.1) THEN
    5582 #ifdef CPP_RRTM
    5583              IF (ok_cdnc.AND.NRADLP.NE.3) THEN
    5584              abort_message='RRTM choix incoherent NRADLP doit etre egal a 3 ' &
    5585                   // 'pour ok_cdnc'
    5586              CALL abort_physic(modname,abort_message,1)
    5587              ENDIF
    5588 #else
    5589 
    5590              abort_message='You should compile with -rrtm if running with '//'iflag_rrtm=1'
    5591              CALL abort_physic(modname,abort_message,1)
    5592 #endif
    5593           ENDIF
    5594           CALL cloud_optics_prop(klon, klev, &
     5595       !Rajout appel a interface calcul proprietes optiques des nuages
     5596       CALL call_cloud_optics_prop(klon, klev, ok_newmicro, &
    55955597               paprs, pplay, t_seri, radocond, picefra, cldfra, &
    55965598               cldtau, cldemi, cldh, cldl, cldm, cldt, cldq, &
    5597                flwp, fiwp, flwc, fiwc, &
     5599               flwp, fiwp, flwc, fiwc, ok_aie, &
    55985600               mass_solu_aero, mass_solu_aero_pi, &
    55995601               cldtaupi, distcltop, temp_cltop, re, fl, ref_liq, ref_ice, &
     
    56015603               reffclwc, cldnvi, lcc3d, lcc3dcon, lcc3dstra, icc3dcon, icc3dstra,  &
    56025604               zfice, dNovrN, ptconv, rnebcon, clwcon)
    5603        ELSE
    5604           CALL nuage (paprs, pplay, &
    5605                t_seri, radocond, picefra, cldfra, cldtau, cldemi, &
    5606                cldh, cldl, cldm, cldt, cldq, &
    5607                ok_aie, &
    5608                mass_solu_aero, mass_solu_aero_pi, &
    5609                bl95_b0, bl95_b1, distcltop, temp_cltop, &
    5610                cldtaupi, re, fl)
    5611        ENDIF
     5605
    56125606       !
    56135607       !IM betaCRF
Note: See TracChangeset for help on using the changeset viewer.