Changeset 6078 for LMDZ6/trunk/libf


Ignore:
Timestamp:
Feb 16, 2026, 6:01:58 PM (4 days ago)
Author:
evignon
Message:

harmonisation des lectures de z0 dans les .def afin de pouvoir forcer les cas 1D au format standard
en z0m et z0h sur tout type de sous-surface

Location:
LMDZ6/trunk/libf
Files:
9 edited

Legend:

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

    r5980 r6078  
    205205  LOGICAL               :: LPRECIP
    206206  LOGICAL               :: LPWG
    207   real, dimension(1) :: z0m_1d, z_0h_1d, sqrt_zdu2_1d, zgeop1_rg_1d  ! Pour COARE CNRM
     207  real, dimension(1) :: z0m_1d, z0h_1d, sqrt_zdu2_1d, zgeop1_rg_1d  ! Pour COARE CNRM
    208208  CHARACTER(len=80) :: abort_message
    209209  CHARACTER(len=20) :: modname = 'pbl_surface_newfrac'                                                                     ! convert scalar to 1D for call
     
    317317       IF ((choix_bulk > 1 .AND. choix_bulk < 4) .AND. (nsrf .eq. is_oce)) THEN
    318318         IF(choix_bulk .eq. 2) THEN
    319            mixte = .false.
     319            mixte = .false.
    320320         ELSE
    321321            mixte = .true.
     
    330330         cdm(i)=cdmm(i)
    331331         cdh(i)=cdhh(i)
    332          write(*,*) "clc_core cd ch",cdmm(i),cdhh(i)
    333332
    334333!------------------                 Pour ECUME                 --------------------
    335        ELSE IF ((choix_bulk .eq. 4) .and. (nsrf .eq. is_oce)) THEN
     334       ELSE IF (choix_bulk .eq. 4) THEN
    336335         OPRECIP = .false.
    337336         OPWEBB  = .false.
    338337         OPERTFLUX = .false.
    339          IF (nsrf .eq. is_oce) THEN
    340            PSSS = 0.0
    341          ENDIF
     338         PSSS = 0.0
    342339!         call ini_csts
    343340!!$gpum nocall
     
    357354         cdh(i)=cdhh(i)
    358355   
    359          write(*,*) "ecume cd ch",cdmm(i),cdhh(i)
    360 
    361356!------------------                 Pour COARE CNRM                 --------------------
    362        ELSE IF ((choix_bulk .eq. 5) .and. (nsrf .eq. is_oce)) THEN
     357       ELSE IF (choix_bulk .eq. 5) THEN
    363358         LPRECIP = .false.
    364359         LPWG    = .false.
    365 !ym         call ini_csts
    366 
    367            z0m_1d = z0m
    368            z_0h_1d = z0h
    369            sqrt_zdu2_1d = sqrt(zdu2)
    370            zgeop1_rg_1d=zgeop1(i)/RG
     360         z0m_1d = z0m
     361         z0h_1d = z0h
     362         sqrt_zdu2_1d = sqrt(zdu2)
     363         zgeop1_rg_1d=zgeop1(i)/RG
    371364
    372365!!$gpum nocall
     
    383376         cdm(i)=cdmm(i)
    384377         cdh(i)=cdhh(i)
    385          write(*,*) "coare CNRM cd ch",cdmm(i),cdhh(i)
    386378
    387379!------------------                 Pour COARE Maison                 --------------------
    388        ELSE IF ((choix_bulk .eq. 1) .and. (nsrf .eq. is_oce)) THEN
     380       ELSE IF (choix_bulk .eq. 1) THEN
    389381         IF ( pblh(i) .eq. 0. ) THEN
    390382           pblh(i) = 1500.
    391383         ENDIF
    392          write(*,*) "debug size",size(coeffs)
    393384
    394385!!$gpum nocall
     
    408399         cdm(i)=cdmm(i)
    409400         cdh(i)=cdhh(i)
    410          write(*,*) "coare cd ch",cdmm(i),cdhh(i)
    411401       ELSE
    412402!------------------                 Pour La param LMDZ (ocean)              --------------------
     
    469459! Traitement particulier des cas oceaniques
    470460! on applique Miller et al 1992 en l'absence de gustiness
    471            IF (nsrf == is_oce) THEN
    472461!            cdh(i)=f_cdrag_oce*cdhn(i)*FH(i)
    473462             IF (iflag_gusts==0) THEN
     
    477466             cdmm(i)=MIN(cdmm(i),cdmmax)
    478467             cdhh(i)=MIN(cdhh(i),cdhmax)
    479 !             write(*,*) "LMDZ cd ch",cdmm(i),cdhh(i)
    480            END IF
    481468         ELSE                         
    482469
     
    527514! Calcul des drags
    528515           
    529            cdmm(i)=cdmn(i)*FM(i)
    530            cdhh(i)=f_cdrag_ter*cdhn(i)*FH(i)
    531            
    532516           IF (choix_bulk == 0) THEN
    533517             cdm(i)=cdmn(i)*FM(i)
    534518             cdh(i)=f_cdrag_ter*cdhn(i)*FH(i)
    535519           ENDIF
    536 
    537            IF (nsrf.EQ.is_oce) THEN
    538              cdhh(i)=f_cdrag_oce*cdhn(i)*FH(i)
    539              cdmm(i)=MIN(cdmm(i),cdmmax)
    540              cdhh(i)=MIN(cdhh(i),cdhmax)
    541            ENDIF
     520           
     521           cdmm(i)=cdmn(i)*FM(i)
     522           cdhh(i)=f_cdrag_oce*cdhn(i)*FH(i)
     523           cdmm(i)=MIN(cdmm(i),cdmmax)
     524           cdhh(i)=MIN(cdhh(i),cdhmax)
     525
    542526           IF (ok_cdrag_iter) THEN
    543527             rugos_itm(i,1) = rugos_itm(i,2)
     
    546530                              +  0.11*14e-6 / SQRT(cdmm(i) * zdu2)
    547531
    548 !---------- Version SEPARATION DES Z0 ----------------------
    549              IF (iflag_z0_oce==0) THEN
     532             ! Version SEPARATION DES Z0
     533             IF (iflag_z0_oce==1) THEN
     534               rugos_ith(i,2) = 0.40*14e-6 / SQRT(cdmm(i) * zdu2)
     535             ELSE
    550536               rugos_ith(i,2) = rugos_itm(i,2)
    551              ELSE IF (iflag_z0_oce==1) THEN
    552                rugos_ith(i,2) = 0.40*14e-6 / SQRT(cdmm(i) * zdu2)
    553537             ENDIF
    554            ENDIF
    555          ENDIF
     538
     539           ENDIF ! ok_cdrad_iter
     540
     541         ENDIF ! zri LT 0
     542
    556543         IF (ok_cdrag_iter) THEN
    557544           rugos_itm(i,2) = MAX(1.5e-05,rugos_itm(i,2))
    558545           rugos_ith(i,2) = MAX(1.5e-05,rugos_ith(i,2))
    559546         ENDIF
     547
    560548       ENDDO
     549
    561550       IF (nsrf.EQ.is_oce) THEN
    562551         cdm(i)=MIN(cdmm(i),cdmmax)
     
    565554       z0m(i) = rugos_itm(i,2)
    566555       z0h(i) = rugos_ith(i,2)
     556
     557!=============================
    567558     ELSE ! (nsrf == is_oce)
     559!=============================
    568560       zri(i) = zgeop1(i)*(ztvd-ztsolv)/(zdu2*ztvd)
    569561       IF (iri_in.EQ.1) THEN
     
    667659         cdh(i)=f_cdrag_ter*cdhn(i)*FH(i)
    668660       ENDIF
     661
    669662     ENDIF ! fin du if (nsrf == is_oce)
     663
    670664  END DO   !  Fin de la boucle sur l'horizontal
    671665
  • LMDZ6/trunk/libf/phylmd/clesphys_mod_h.f90

    r6059 r6078  
    1616          , f_cdrag_ter, f_cdrag_oce, f_rugoro, z0min, tau_gl              &
    1717          , min_wind_speed, f_gust_wk, f_gust_bl, f_qsat_oce, f_z0qh_oce   &
    18           , z0m_seaice, z0h_seaice, z0m_landice, ratio_z0hz0m_landice  &
     18          , z0m_seaice, z0h_seaice, z0m_landice, z0h_landice           &
     19          , z0m_ocean, z0h_ocean, z0m_land, z0h_land, iflag_z0_ter     &
    1920          , freq_outNMC, freq_calNMC                                   &
    2021          , lonmin_ins, lonmax_ins, latmin_ins, latmax_ins             &
     
    110111  REAL min_wind_speed, f_gust_wk, f_gust_bl, f_qsat_oce, f_z0qh_oce
    111112  REAL z0m_seaice, z0h_seaice
    112   REAL z0m_landice, ratio_z0hz0m_landice
    113   INTEGER iflag_gusts, iflag_z0_oce
     113  REAL z0m_landice, z0h_landice
     114  REAL z0m_ocean, z0h_ocean
     115  REAL z0m_land, z0h_land
     116  INTEGER iflag_gusts, iflag_z0_oce, iflag_z0_ter
    114117
    115118  ! Rugoro
     
    178181  !$OMP      , f_cdrag_ter, f_cdrag_oce, f_rugoro, z0min, tau_gl              &
    179182  !$OMP      , min_wind_speed, f_gust_wk, f_gust_bl, f_qsat_oce, f_z0qh_oce   &
    180   !$OMP      , z0m_seaice, z0h_seaice, z0m_landice, ratio_z0hz0m_landice  &
     183  !$OMP      , z0m_seaice, z0h_seaice, z0m_landice, z0h_landice           &
     184  !$OMP      , z0m_ocean, z0h_ocean, z0m_land, z0h_land, iflag_z0_ter     &
    181185  !$OMP      , freq_outNMC, freq_calNMC                                   &
    182186  !$OMP      , lonmin_ins, lonmax_ins, latmin_ins, latmax_ins             &
  • LMDZ6/trunk/libf/phylmd/conf_phys_m.f90

    r6075 r6078  
    129129    REAL, SAVE          :: f_rugoro_omp   , z0min_omp
    130130    REAL, SAVE          :: z0m_seaice_omp,z0h_seaice_omp
    131     REAL, SAVE          :: z0m_landice_omp,ratio_z0hz0m_landice_omp
     131    REAL, SAVE          :: z0m_landice_omp,z0h_landice_omp
     132    REAL, SAVE          :: z0m_ocean_omp, z0h_ocean_omp
     133    REAL, SAVE          :: z0m_land_omp, z0h_land_omp
     134    REAL                :: ratio_z0hz0m_land, ratio_z0hz0m_ocean, ratio_z0hz0m_landice, ratio_z0hz0m_seaice
    132135    REAL, SAVE          :: min_wind_speed_omp,f_gust_wk_omp,f_gust_bl_omp,f_qsat_oce_omp, f_z0qh_oce_omp
    133     INTEGER, SAVE       :: iflag_gusts_omp,iflag_z0_oce_omp
     136    INTEGER, SAVE       :: iflag_gusts_omp,iflag_z0_oce_omp, iflag_z0_ter_omp
    134137
    135138    REAL :: seuil_inversion
     
    10041007    !Config Desc = fraction of shortwave penetrating into the ice
    10051008    !Config Def  = 0.3
    1006     !Config Help = pour le modele de glace de mer
     1009    !Config Help = pour le modale de glace de mer
    10071010    si_pen_frac_omp = 0.3
    10081011    CALL getin('si_pen_frac', si_pen_frac_omp)
     
    19321935    iflag_z0_oce_omp=0
    19331936    CALL getin('iflag_z0_oce',iflag_z0_oce_omp)
     1937
     1938    iflag_z0_ter_omp=0
     1939    CALL getin('iflag_z0_ter',iflag_z0_ter_omp)
     1940
    19341941    !
    19351942    iflag_gusts_omp=0
     
    19391946    CALL getin('min_wind_speed',min_wind_speed_omp)
    19401947
    1941     z0m_seaice_omp = 0.002 ; CALL getin('z0m_seaice',z0m_seaice_omp)
    1942     z0h_seaice_omp = 0.002 ; CALL getin('z0h_seaice',z0h_seaice_omp)
    1943 
    1944 
    1945     z0m_landice_omp = 0.001 ; CALL getin('z0m_landice',z0m_landice_omp)
    1946     ratio_z0hz0m_landice_omp = 1. ; CALL getin('ratio_z0hz0m_landice',ratio_z0hz0m_landice_omp)
    1947 
    19481948    f_rugoro_omp = 0.
    19491949    CALL getin('f_rugoro',f_rugoro_omp)
     
    19521952    CALL getin('z0min',z0min_omp)
    19531953
    1954     ! PARAMETERS FOR SNOW AND ICE MELTING
     1954
     1955
     1956    z0m_seaice_omp = 0.002
     1957    CALL getin('z0m_seaice',z0m_seaice_omp)
     1958    ratio_z0hz0m_seaice =  1.
     1959    CALL getin('ratio_z0hz0m_seaice',ratio_z0hz0m_seaice)
     1960    z0h_seaice_omp = z0m_seaice_omp * ratio_z0hz0m_seaice
     1961    CALL getin('z0h_seaice',z0h_seaice_omp)
     1962
     1963    z0m_landice_omp = 0.001
     1964    CALL getin('z0m_landice',z0m_landice_omp)
     1965    ratio_z0hz0m_landice =  1.
     1966    CALL getin('ratio_z0hz0m_landice',ratio_z0hz0m_landice)
     1967    z0h_landice_omp = z0m_landice_omp * ratio_z0hz0m_landice
     1968    CALL getin('z0h_landice',z0h_landice_omp)
     1969
     1970    z0m_ocean_omp = z0min_omp
     1971    CALL getin('z0m_ocean',z0m_ocean_omp)
     1972    ratio_z0hz0m_ocean =  1.
     1973    CALL getin('ratio_z0hz0m_ocean',ratio_z0hz0m_ocean)
     1974    z0h_ocean_omp = z0m_ocean_omp * ratio_z0hz0m_ocean
     1975    CALL getin('z0h_ocean',z0h_ocean_omp)
     1976
     1977    z0m_land_omp = z0min_omp
     1978    CALL getin('z0m_land',z0m_land_omp)
     1979    ratio_z0hz0m_land =  1.
     1980    CALL getin('ratio_z0hz0m_land',ratio_z0hz0m_land)
     1981    z0h_land_omp = z0m_land_omp * ratio_z0hz0m_land
     1982    CALL getin('z0h_land',z0h_land_omp)
     1983
     1984
     1985      ! PARAMETERS FOR SNOW AND ICE MELTING
    19551986    chasno_tun_omp=0.15
    19561987    CALL getin('chasno_tun',chasno_tun_omp)
     
    23792410    iflag_gusts=iflag_gusts_omp
    23802411    iflag_z0_oce=iflag_z0_oce_omp
     2412    iflag_z0_ter=iflag_z0_ter_omp
    23812413
    23822414    z0m_seaice=z0m_seaice_omp
    23832415    z0h_seaice=z0h_seaice_omp
    23842416    z0m_landice=z0m_landice_omp
    2385     ratio_z0hz0m_landice=ratio_z0hz0m_landice_omp
     2417    z0h_landice=z0h_landice_omp
     2418    z0m_ocean=z0m_ocean_omp
     2419    z0h_ocean=z0h_ocean_omp
     2420    z0m_land=z0m_land_omp
     2421    z0h_land=z0h_land_omp
    23862422
    23872423    chasno_tun=chasno_tun_omp
     
    26822718    WRITE(lunout,*) ' f_rugoro = ',f_rugoro
    26832719    WRITE(lunout,*) ' z0min = ',z0min
     2720    WRITE(lunout,*) ' z0m_landice = ',z0m_landice
     2721    WRITE(lunout,*) ' z0h_landice = ',z0h_landice
     2722    WRITE(lunout,*) ' z0m_seaice = ',z0m_seaice
     2723    WRITE(lunout,*) ' z0h_seaice = ',z0h_seaice
     2724    WRITE(lunout,*) ' z0m_ocean = ',z0m_ocean
     2725    WRITE(lunout,*) ' z0h_ocean = ',z0h_ocean
     2726    WRITE(lunout,*) ' z0m_land = ',z0m_land
     2727    WRITE(lunout,*) ' z0h_land = ',z0h_land
    26842728    WRITE(lunout,*) ' tmax_fonte_cv = ', tmax_fonte_cv
    26852729    WRITE(lunout,*) ' iflag_wake = ', iflag_wake
  • LMDZ6/trunk/libf/phylmd/surf_land_mod.F90

    r5982 r6078  
    7676
    7777    USE dimpft_mod_h, ONLY: nvm_lmdz
    78     USE clesphys_mod_h, ONLY : nsw, ok_bs
     78    USE clesphys_mod_h, ONLY : nsw, ok_bs, z0m_land, z0h_land, iflag_z0_ter
    7979    USE yomcst_mod_h, ONLY: RCPD, RKAPPA
    8080    USE print_control_mod, ONLY: lunout
     
    336336#endif           
    337337     &       )
    338         z0h(1:knon)=z0m(1:knon) ! En attendant mieux
     338
     339
     340      z0h(1:knon)=z0m(1:knon) ! En attendant mieux
    339341
    340342      ENDIF ! iflag_hetero_surf
    341343
     344    ! possibility to impose z0m et z0h over land
     345
     346
    342347    ENDIF ! ok_veget
    343348
    344         ! blowing snow not treated yet over land
    345         fluxbs(:)=0.
     349    IF (iflag_z0_ter==-1) THEN
     350      DO i = 1, knon
     351          z0m(i) = z0m_land
     352          z0h(i) = z0h_land
     353      ENDDO
     354    ENDIF
     355
     356    ! blowing snow not treated yet over land
     357    fluxbs(:)=0.
    346358
    347359
  • LMDZ6/trunk/libf/phylmd/surf_landice_mod.F90

    r6053 r6078  
    470470if (z0m_landice .GT. 0.) then
    471471    z0m(1:knon) = z0m_landice
    472     z0h(1:knon) = z0m_landice*ratio_z0hz0m_landice
     472    z0h(1:knon) = z0h_landice
    473473else
    474474    ! parameterization of z0=f(T) following measurements in Adelie Land by Amory et al 2017
  • LMDZ6/trunk/libf/phylmd/surf_ocean_mod.F90

    r6070 r6078  
    4646#endif
    4747#endif
    48     USE clesphys_mod_h, ONLY: nsw, ok_bs, f_z0qh_oce, iflag_albedo, iflag_cycle_diurne, fmagic, pmagic, iflag_z0_oce, z0min
     48    USE clesphys_mod_h, ONLY: nsw, ok_bs, f_z0qh_oce, iflag_albedo, iflag_cycle_diurne, fmagic, pmagic
     49    USE clesphys_mod_h, ONLY:  iflag_z0_oce, z0m_ocean, z0h_ocean
    4950    USE yomcst_mod_h, ONLY: rd, retv, rg, rlvtt
    5051    USE limit_read_mod, ONLY: limit_read_rug_alb
     
    369370
    370371    !******************************************************************************
    371     ! Calculate the rugosity
     372    ! Calculate the roughness lengths
    372373    !******************************************************************************
    373374    IF (iflag_z0_oce==0) THEN
     
    390391    ELSE IF (iflag_z0_oce==-1) THEN
    391392       DO i = 1, knon
    392           z0m(i) = z0min
    393           z0h(i) = z0min
     393          z0m(i) = z0m_ocean
     394          z0h(i) = z0h_ocean
    394395       ENDDO
    395396    ELSE
  • LMDZ6/trunk/libf/phylmdiso/surf_land_mod.F90

    r5943 r6078  
    346346    ENDIF ! ok_veget
    347347
    348         ! blowing snow not treated yet over land
    349         fluxbs(:)=0.
     348    IF (iflag_z0_ter==-1) THEN
     349      DO i = 1, knon
     350          z0m(i) = z0m_land
     351          z0h(i) = z0h_land
     352      ENDDO
     353    ENDIF
     354
     355    ! blowing snow not treated yet over land
     356    fluxbs(:)=0.
     357
    350358
    351359
  • LMDZ6/trunk/libf/phylmdiso/surf_landice_mod.F90

    r6028 r6078  
    433433if (z0m_landice .GT. 0.) then
    434434    z0m(1:knon) = z0m_landice
    435     z0h(1:knon) = z0m_landice*ratio_z0hz0m_landice
     435    z0h(1:knon) = z0h_landice
    436436else
    437437    ! parameterization of z0=f(T) following measurements in Adelie Land by Amory et al 2017
  • LMDZ6/trunk/libf/phylmdiso/surf_ocean_mod.F90

    r5943 r6078  
    383383    ELSE IF (iflag_z0_oce==-1) THEN
    384384       DO i = 1, knon
    385           z0m(i) = z0min
    386           z0h(i) = z0min
     385          z0m(i) = z0m_ocean
     386          z0h(i) = z0h_ocean
    387387       ENDDO
    388388    ELSE
Note: See TracChangeset for help on using the changeset viewer.