Ignore:
Timestamp:
Sep 28, 2017, 3:43:23 PM (7 years ago)
Author:
jvatant
Message:

Added the surface methane tank and put it in start files
--JVO

Location:
trunk/LMDZ.TITAN/libf/phytitan
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.TITAN/libf/phytitan/phyetat0_mod.F90

    r1722 r1789  
    88                     ngrid,nlayer,fichnom,tab0,Lmodif,nsoil,nq, &
    99                     day_ini,time,tsurf,tsoil, &
    10                      emis,q2,qsurf)
     10                     emis,q2,qsurf,tankCH4)
    1111
    1212! to use  'getin_p'
     
    4444  real,intent(out) :: q2(ngrid,nlayer+1) !
    4545  real,intent(out) :: qsurf(ngrid,nq) ! tracers on surface
     46  real,intent(out) :: tankCH4(ngrid)  ! depth of CH4 tank
    4647
    4748!======================================================================
     
    217218write(*,*) "phyetat0: Surface emissivity <emis> range:", &
    218219             minval(emis), maxval(emis)
     220
     221! Depth of methane tank (added by JVO 2017)
     222 if (startphy_file) then
     223   call get_field("tankCH4",tankCH4,found,indextime)
     224   if (.not.found) then
     225     write(*,*) "phyetat0: Failed loading <tankCH4>"
     226     !  call abort
     227     tankCH4(:)=2.
     228   endif
     229 else
     230   tankCH4(:)=2.
     231 endif ! of if (startphy_file)
     232 write(*,*) "phyetat0: Depth of methane tank <tankCH4> range:", &
     233              minval(tankCH4), maxval(tankCH4)
    219234
    220235! pbl wind variance
  • trunk/LMDZ.TITAN/libf/phytitan/phyredem.F90

    r1647 r1789  
    135135
    136136subroutine physdem1(filename,nsoil,ngrid,nlay,nq, &
    137                     phystep,time,tsurf,tsoil,emis,q2,qsurf)
     137                    phystep,time,tsurf,tsoil,emis,q2,qsurf,tankCH4)
    138138  ! write time-dependent variable to restart file
    139139  use iostart, only : open_restartphy, close_restartphy, &
     
    155155  real,intent(in) :: q2(ngrid,nlay+1)
    156156  real,intent(in) :: qsurf(ngrid,nq)
     157  real,intent(in) :: tankCH4(ngrid)
    157158
    158159  integer :: iq
     
    176177  ! Planetary Boundary Layer
    177178  call put_field("q2","pbl wind variance",q2)
     179
     180  ! Methane tank depth
     181  call put_field("tankCH4","Depth of methane tank",tankCH4)
    178182 
    179183! tracers
  • trunk/LMDZ.TITAN/libf/phytitan/physiq_mod.F90

    r1788 r1789  
    375375!$OMP THREADPRIVATE(dycchi,qysat,nomqy)
    376376
     377      real,dimension(:),allocatable,save :: tankCH4 ! Depth of surface methane tank
     378!$OMP THREADPRIVATE(tankCH4)
     379
    377380!-----------------------------------------------------------------------------
    378381     
     
    402405        ALLOCATE(qsurf(ngrid,nq)) 
    403406        ALLOCATE(q2(ngrid,nlayer+1))
     407        ALLOCATE(tankCH4(ngrid))
    404408        ALLOCATE(ztprevious(ngrid,nlayer))
    405409        ALLOCATE(zuprevious(ngrid,nlayer))
     
    448452!        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    449453         call phyetat0(startphy_file,ngrid,nlayer,"startfi.nc",0,0,nsoilmx,nq,      &
    450                        day_ini,time_phys,tsurf,tsoil,emis,q2,qsurf)                       
     454                       day_ini,time_phys,tsurf,tsoil,emis,q2,qsurf,tankCH4)                       
    451455         if (.not.startphy_file) then
    452456           ! additionnal "academic" initialization of physics
     
    12411245            call physdem1("restartfi.nc",nsoilmx,ngrid,nlayer,nq, &
    12421246                          ptimestep,ztime_fin,                    &
    1243                           tsurf,tsoil,emis,q2,qsurf_hist)
     1247                          tsurf,tsoil,emis,q2,qsurf_hist,tankCH4)
    12441248         endif
    12451249         
Note: See TracChangeset for help on using the changeset viewer.