Ignore:
Timestamp:
Jun 10, 2024, 11:53:45 AM (6 months ago)
Author:
tbertrand
Message:

LMDZ.PLUTO
Fixing a bug in physiq.F when calling callcorrk_pluto (the old version of callcorrk for pluto)
TB

Location:
trunk/LMDZ.PLUTO/libf/phypluto
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.PLUTO/libf/phypluto/callcorrk.F90

    r3329 r3361  
    856856
    857857      plevrad(1) = 0.
    858 !      plevrad(2) = 0.   !! JL18 enabling this line puts the radiative top at p=0 which was the idea before, but does not seem to perform best after all.
     858      !!plevrad(2) = 0.   !! JL18 enabling this line puts the radiative top at p=0 which was the idea before, but does not seem to perform best after all.
    859859
    860860      tlevrad(1) = tlevrad(2)
  • trunk/LMDZ.PLUTO/libf/phypluto/callcorrk_pluto_mod.F90

    r3353 r3361  
    265265         Cmk= 0.01 * 1.0 / (g * mugaz * 1.672621e-27) ! q_main=1.0 assumed
    266266
    267          epsi_ch4=mmol(igcm_ch4_gas)/mmol(igcm_n2)
     267         if (methane) then
     268           epsi_ch4=mmol(igcm_ch4_gas)/mmol(igcm_n2)
     269         endif
    268270
    269271         ! If fixed profile of CH4 gas
     
    280282
    281283!=======================================================================
    282 
    283284!     L_NSPECTV is the number of Visual(or Solar) spectral intervals
    284285!     how much light we get
     
    653654         ELSE                          ! during the night, fluxes = 0
    654655            nfluxtopv=0.0
     656            fmnetv_nu(:,:)=0.0
     657            nfluxtopv_nu(:)=0.0
    655658            DO l=1,L_NLAYRAD
    656659               fmnetv(l)=0.0
     
    712715               end do
    713716         END DO
    714 
    715717         ! values at top of atmosphere
    716718         dpp = g/(cpp*scalep*(plevrad(3)-plevrad(1)))
  • trunk/LMDZ.PLUTO/libf/phypluto/callkeys_mod.F90

    r3353 r3361  
    8383      logical,save :: convergeps,conservn2,condensn2,no_n2frost
    8484!$OMP THREADPRIVATE(convergeps,conservn2,condensn2,no_n2frost)
    85       logical,save :: globmean1d,kmix_proffix
    86 !$OMP THREADPRIVATE(globmean1d,kmix_proffix)
     85      logical,save :: kmix_proffix
     86!$OMP THREADPRIVATE(kmix_proffix)
    8787      logical,save :: ch4fix,vmrch4_proffix
    8888!$OMP THREADPRIVATE(ch4fix,vmrch4_proffix)
  • trunk/LMDZ.PLUTO/libf/phypluto/gfluxi.F

    r3184 r3361  
    8686!-----------------------------------------------------------------------
    8787         if (W0(L).eq.1.D0) then
    88             W0(L) = 0.99999D0
     88               W0(L) = 0.99999D0
    8989         endif
    9090         
  • trunk/LMDZ.PLUTO/libf/phypluto/physiq_mod.F90

    r3356 r3361  
    981981                               firstcall,lastcall)
    982982                  albedo_equivalent(1:ngrid)=albedo(1:ngrid,1)
     983                  fluxrad_sky(1:ngrid)=emis(1:ngrid)*fluxsurf_lw(1:ngrid)+       &
     984                               fluxsurf_sw(1:ngrid)*(1.-albedo(1:ngrid,1))
    983985               else
    984986                call callcorrk(ngrid,nlayer,pq,nq,qsurf,  &
     
    991993                              tau_col,cloudfrac,totcloudfrac,                     &
    992994                              .false.,firstcall,lastcall)
     995                  ! Radiative flux from the sky absorbed by the surface (W.m-2).
     996                  GSR=0.0
     997                  fluxrad_sky(1:ngrid)=emis(1:ngrid)*fluxsurf_lw(1:ngrid)+        &
     998                              fluxsurfabs_sw(1:ngrid)
    993999               endif ! oldplutocorrk
    9941000                !GG (feb2021): Option to "artificially" decrease the raditive time scale in
     
    10101016                ! AF24: removed CLFvarying Option
    10111017
    1012                ! Radiative flux from the sky absorbed by the surface (W.m-2).
    1013                GSR=0.0
    1014                fluxrad_sky(1:ngrid)=emis(1:ngrid)*fluxsurf_lw(1:ngrid)+fluxsurfabs_sw(1:ngrid)
    10151018
    10161019                            !if(noradsurf)then ! no lower surface; SW flux just disappears
     
    21662169
    21672170         call writediagfi(ngrid,"ALB","Surface albedo"," ",2,albedo_equivalent)
    2168          !call writediagfi(ngrid,"ALB_1st","First Band Surface albedo"," ",2,albedo(:,1))
     2171         call writediagfi(ngrid,"ALB_1st","First Band Surface albedo"," ",2,albedo(:,1))
    21692172         call writediagfi(ngrid,"ISR","incoming stellar rad.","W m-2",2,fluxtop_dn)
    21702173         call writediagfi(ngrid,"ASR","absorbed stellar rad.","W m-2",2,fluxabs_sw)
  • trunk/LMDZ.PLUTO/libf/phypluto/sfluxi_pluto_mod.F

    r3329 r3361  
    1414      use radcommon_h, only: planckir, tlimit,sigma, gweight
    1515      use comcstfi_mod, only: pi
    16       use gfluxi_mod, only: gfluxi
     16      use gfluxi_old_mod, only: gfluxi_old
    1717
    1818
     
    136136C         WITHIN EACH INTERVAL AT THE MIDPOINT WAVENUMBER
    137137
    138           CALL GFLUXI(NLEVRAD,TLEV,NW,DWNI(NW),DTAUI(1,NW,NG),
     138          CALL GFLUXI_OLD(NLEVRAD,TLEV,NW,DWNI(NW),DTAUI(1,NW,NG),
    139139     *                TAUCUMI(1,NW,NG),
    140140     *                WBARI(1,NW,NG),COSBI(1,NW,NG),UBARI,RSFI,BTOP,
     
    193193
    194194
    195        CALL GFLUXI(NLEVRAD,TLEV,NW,DWNI(NW),DTAUI(1,NW,NG),
     195       CALL GFLUXI_OLD(NLEVRAD,TLEV,NW,DWNI(NW),DTAUI(1,NW,NG),
    196196     *                TAUCUMI(1,NW,NG),
    197197     *                WBARI(1,NW,NG),COSBI(1,NW,NG),UBARI,RSFI,BTOP,
  • trunk/LMDZ.PLUTO/libf/phypluto/sfluxv_pluto_mod.F

    r3329 r3361  
    1212      use radinc_h, only: L_NLAYRAD, L_NLEVRAD
    1313      use radcommon_h, only: tlimit, gweight
    14       use gfluxv_mod, only: gfluxv
     14      use gfluxv_old_mod, only: gfluxv_old
    1515
    1616      implicit none
     
    100100
    101101
    102           CALL GFLUXV(DTAUV(1,NW,NG),TAUV(1,NW,NG),TAUCUMV(1,NW,NG),
     102          CALL GFLUXV_OLD(DTAUV(1,NW,NG),TAUV(1,NW,NG),TAUCUMV(1,NW,NG),
    103103     *                WBARV(1,NW,NG),COSBV(1,NW,NG),UBAR0,F0PI,RSFV,
    104104     *                BTOP,BSURF,FMUPV,FMDV,DIFFV,FLUXUP,FLUXDN)
     
    155155C       RETURN FLUXES FOR A GIVEN NT
    156156
    157         CALL GFLUXV(DTAUV(1,NW,NG),TAUV(1,NW,NG),TAUCUMV(1,NW,NG),
     157        CALL GFLUXV_OLD(DTAUV(1,NW,NG),TAUV(1,NW,NG),TAUCUMV(1,NW,NG),
    158158     *              WBARV(1,NW,NG),COSBV(1,NW,NG),UBAR0,F0PI,RSFV,
    159159     *              BTOP,BSURF,FMUPV,FMDV,DIFFV,FLUXUP,FLUXDN)
  • trunk/LMDZ.PLUTO/libf/phypluto/surfprop.F90

    r3329 r3361  
    460460           enddo
    461461        ENDDO
    462         print*, emin
    463         print*, tidat(1,:)
    464         print*, mlayer(:)
    465462
    466463      ELSE
Note: See TracChangeset for help on using the changeset viewer.