Ignore:
Timestamp:
Feb 23, 2021, 4:01:34 PM (4 years ago)
Author:
lmdz-users
Message:

Modifications to code to introduce a new vertical axis on llm+1 levels so that fluxes can
be output on their proper levels as per the CMIP6 DataRequest?
LF

Location:
LMDZ6/branches/IPSL-CM6A-MR
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • LMDZ6/branches/IPSL-CM6A-MR/DefLists/context_lmdz.xml

    r3721 r3853  
    6363    <axis id="time_year" unit="day" />
    6464    <axis id="presnivs" standard_name="Vertical levels" unit="Pa"/>
     65    <axis id="presinter" standard_name="Pressure at interface of vertical levels" unit="Pa"/>
    6566    <axis id="Ahyb" standard_name="Ahyb comp of Hyb Cord" unit="Pa"/>
    6667    <axis id="Bhyb" standard_name="Bhyb comp of Hyb Cord" unit=""/>
     
    114115     </grid>
    115116
     117     <grid id="grid_glo_presinter">
     118        <domain domain_ref="dom_glo" />
     119        <axis axis_ref="presinter" />
     120     </grid>
     121     <grid id="grid_out_presinter">
     122        <domain domain_ref="dom_out" />
     123        <axis axis_ref="presinter" />
     124     </grid>
     125
    116126     <grid id="grid_glo_plev">
    117127        <domain domain_ref="dom_glo" />
  • LMDZ6/branches/IPSL-CM6A-MR/libf/dyn3d_common/comvert_mod.F90

    r2602 r3853  
    1010
    1111PUBLIC :: ap,bp,presnivs,dpres,sig,ds,pa,preff,nivsigs,nivsig, &
    12           aps,bps,scaleheight,pseudoalt,disvert_type, pressure_exner
     12          aps,bps,scaleheight,pseudoalt,disvert_type, pressure_exner, &
     13          presinter
    1314
    1415REAL ap(llm+1) ! hybrid pressure contribution at interlayers
    1516REAL bp (llm+1) ! hybrid sigma contribution at interlayer
    1617REAL presnivs(llm) ! (reference) pressure at mid-layers
     18REAL presinter(llm+1) ! (reference) pressure at interlayers
    1719REAL dpres(llm)
    1820REAL sig(llm+1)
  • LMDZ6/branches/IPSL-CM6A-MR/libf/dyn3d_common/disvert.F90

    r2786 r3853  
    1111  use assert_m, only: assert
    1212  USE comvert_mod, ONLY: ap, bp, aps, bps, nivsigs, nivsig, dpres, presnivs, &
    13                          pseudoalt, pa, preff, scaleheight
     13                         pseudoalt, pa, preff, scaleheight, presinter
    1414  USE logic_mod, ONLY: ok_strato
    1515
     
    3535! dpres(llm)                 !--- PRESSURE DIFFERENCE FOR EACH LAYER
    3636! presnivs(llm)              !--- PRESSURE AT EACH MID-LAYER
     37! presinter(llm+1)           !--- PRESSURE AT EACH INTERFACE
    3738! scaleheight                !--- VERTICAL SCALE HEIGHT            (Earth: 8kms)
    3839! nivsig(llm+1)              !--- SIGMA INDEX OF EACH LAYER INTERFACE
     
    355356          max(ap(l+1)+bp(l+1)*preff, 1.e-10))
    356357  ENDDO
     358  DO l=1, llmp1
     359     presinter(l)= ( ap(l)+bp(l)*preff)
     360     write(lunout, *)'PRESINTER(', l, ')=', presinter(l)
     361  ENDDO
    357362
    358363  write(lunout, *) trim(modname),': PRESNIVS '
  • LMDZ6/branches/IPSL-CM6A-MR/libf/dynphy_lonlat/inigeomphy_mod.F90

    r3435 r3853  
    2525  USE nrtype, ONLY: pi
    2626  USE comvert_mod, ONLY: preff, ap, bp, aps, bps, presnivs, &
    27                          scaleheight, pseudoalt
     27                         scaleheight, pseudoalt, presinter
    2828  USE vertical_layers_mod, ONLY: init_vertical_layers
    2929  IMPLICIT NONE
     
    224224  ! copy over preff , ap(), bp(), etc
    225225  CALL init_vertical_layers(nlayer,preff,scaleheight, &
    226                             ap,bp,aps,bps,presnivs,pseudoalt)
     226                            ap,bp,aps,bps,presnivs,presinter,pseudoalt)
    227227
    228228!$OMP END PARALLEL
  • LMDZ6/branches/IPSL-CM6A-MR/libf/phy_common/vertical_layers_mod.F90

    r2786 r3853  
    1515   REAL,SAVE,ALLOCATABLE :: presnivs(:) ! reference pressure at mid-layer (Pa),
    1616                                        ! based on preff, ap and bp
     17   REAL,SAVE,ALLOCATABLE :: presinter(:) ! reference pressure at interface (Pa),
     18                                        ! based on preff, ap and bp
    1719   REAL,SAVE,ALLOCATABLE :: pseudoalt(:) ! pseudo-altitude of model layers (km),
    1820                                         ! based on preff and scaleheight
    1921   
    20 !$OMP THREADPRIVATE(preff,scaleheight,ap,bp,aps,bps,presnivs,pseudoalt)
     22!$OMP THREADPRIVATE(preff,scaleheight,ap,bp,aps,bps,presnivs,presinter,pseudoalt)
    2123
    2224
     
    2426
    2527  SUBROUTINE init_vertical_layers(nlayer,preff_,scaleheight_,ap_,bp_,&
    26                                  aps_,bps_,presnivs_, pseudoalt_)
     28                                 aps_,bps_,presnivs_, presinter_, pseudoalt_)
    2729    IMPLICIT NONE
    2830    INTEGER,INTENT(IN) :: nlayer ! number of atmospheric layers
     
    3436    REAL,INTENT(IN)    :: bps_(nlayer) ! hybrid coordinate at mid-layer
    3537    REAL,INTENT(IN)    :: presnivs_(nlayer) ! Appproximative pressure of atm. layers (Pa)
     38    REAL,INTENT(IN)    :: presinter_(nlayer+1) ! Appproximative pressure of atm. layers (Pa)
    3639    REAL,INTENT(IN)    :: pseudoalt_(nlayer) ! pseudo-altitude of atm. layers (km)
    3740 
     
    4144    ALLOCATE(bps(nlayer))
    4245    ALLOCATE(presnivs(nlayer))
     46    ALLOCATE(presinter(nlayer+1))
    4347    ALLOCATE(pseudoalt(nlayer))
    4448 
     
    5054    bps(:) = bps_(:)
    5155    presnivs(:) = presnivs_(:)
     56    presinter(:) = presinter_(:)
    5257    pseudoalt(:) = pseudoalt_(:)
    5358
  • LMDZ6/branches/IPSL-CM6A-MR/libf/phylmd/iophy.F90

    r3488 r3853  
    12271227
    12281228    nlev=SIZE(field,2)
    1229     IF (nlev.EQ.klev+1) THEN
    1230         nlevx=klev
    1231     ELSE
    1232         nlevx=nlev
    1233     ENDIF
     1229    nlevx=nlev
     1230!    IF (nlev.EQ.klev+1) THEN
     1231!        nlevx=klev
     1232!    ELSE
     1233!        nlevx=nlev
     1234!    ENDIF
    12341235
    12351236    IF (SIZE(field,1) == klon) then
  • LMDZ6/branches/IPSL-CM6A-MR/libf/phylmd/phys_output_mod.F90

    r3666 r3853  
    4444    USE mod_grid_phy_lmdz, only: klon_glo,nbp_lon,nbp_lat
    4545    USE print_control_mod, ONLY: prt_level,lunout
    46     USE vertical_layers_mod, ONLY: ap,bp,preff,presnivs, aps, bps, pseudoalt
     46    USE vertical_layers_mod, ONLY: ap,bp,preff,presnivs, aps, bps, pseudoalt, presinter
    4747    USE time_phylmdz_mod, ONLY: day_ini, itau_phy, start_time, annee_ref, day_ref
    4848#ifdef CPP_XIOS
     
    348348    CALL wxios_add_vaxis("presnivs", &
    349349            levmax(iff) - levmin(iff) + 1, presnivs(levmin(iff):levmax(iff)))
     350    CALL wxios_add_vaxis("presinter", &
     351            klev + 1, presinter(1:klev+1))
    350352    CALL wxios_add_vaxis("Ahyb", &
    351353            levmax(iff) - levmin(iff) + 1, aps(levmin(iff):levmax(iff)), positif='down', &
Note: See TracChangeset for help on using the changeset viewer.