Ignore:
Timestamp:
Jun 8, 2017, 1:03:06 AM (8 years ago)
Author:
jvatant
Message:

Cleaning of the radiative code + coherence between optci and optcv :

+ Get rid of the actually dummy and confusing extra level L_LEVELS+1 for aerosols
+ Harmonisation between optci and optcv
+ Get rid of tauref (called nowhere) and csqtly of ini_radcommon subroutine

JVO

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.GENERIC/libf/phystd/callcorrk.F90

    r1714 r1715  
    123123      REAL*8 taucumi(L_LEVELS,L_NSPECTI,L_NGAUSS)
    124124
    125       REAL*8 tauaero(L_LEVELS+1,naerkind)
     125      REAL*8 tauaero(L_LEVELS,naerkind)
    126126      REAL*8 nfluxtopv,nfluxtopi,nfluxtop,fluxtopvdn
    127127      REAL*8 nfluxoutv_nu(L_NSPECTV)                 ! Outgoing band-resolved VI flux at TOA (W/m2).
     
    189189
    190190        ! test on allocated necessary because of CLFvarying (two calls to callcorrk in physiq)
    191         if(.not.allocated(QXVAER)) allocate(QXVAER(L_LEVELS+1,L_NSPECTV,naerkind))
    192         if(.not.allocated(QSVAER)) allocate(QSVAER(L_LEVELS+1,L_NSPECTV,naerkind))
    193         if(.not.allocated(GVAER)) allocate(GVAER(L_LEVELS+1,L_NSPECTV,naerkind))
    194         if(.not.allocated(QXIAER)) allocate(QXIAER(L_LEVELS+1,L_NSPECTI,naerkind))
    195         if(.not.allocated(QSIAER)) allocate(QSIAER(L_LEVELS+1,L_NSPECTI,naerkind))
    196         if(.not.allocated(GIAER)) allocate(GIAER(L_LEVELS+1,L_NSPECTI,naerkind))
     191        if(.not.allocated(QXVAER)) allocate(QXVAER(L_LEVELS,L_NSPECTV,naerkind))
     192        if(.not.allocated(QSVAER)) allocate(QSVAER(L_LEVELS,L_NSPECTV,naerkind))
     193        if(.not.allocated(GVAER)) allocate(GVAER(L_LEVELS,L_NSPECTV,naerkind))
     194        if(.not.allocated(QXIAER)) allocate(QXIAER(L_LEVELS,L_NSPECTI,naerkind))
     195        if(.not.allocated(QSIAER)) allocate(QSIAER(L_LEVELS,L_NSPECTI,naerkind))
     196        if(.not.allocated(GIAER)) allocate(GIAER(L_LEVELS,L_NSPECTI,naerkind))
    197197
    198198         !!! ALLOCATED instances are necessary because of CLFvarying (strategy to call callcorrk twice in physiq...)
     
    323323     end do !iaer=1,naerkind.
    324324
     325
    325326      ! How much light do we get ?
    326327      do nw=1,L_NSPECTV
     
    439440            ! Test / Correct for freaky s. s. albedo values.
    440441            do iaer=1,naerkind
    441                do k=1,L_LEVELS+1
     442               do k=1,L_LEVELS
    442443
    443444                  do nw=1,L_NSPECTV
     
    482483            ! boundary conditions
    483484            tauaero(1,iaer)          = tauaero(2,iaer)
    484             tauaero(L_LEVELS+1,iaer) = tauaero(L_LEVELS,iaer)
    485485            !tauaero(1,iaer)          = 0.
    486             !tauaero(L_LEVELS+1,iaer) = 0.
    487486           
    488487         end do ! naerkind
     
    574573
    575574      if(kastprof)then
    576      
    577          if(.not.global1d)then ! garde-fou/safeguard added by MT (to be removed in the future)
    578             write(*,*) 'You have to fix mu0, '
    579             write(*,*) 'the cosinus of the solar angle'
    580             stop
    581          endif
    582          
     575
    583576         ! Initial values equivalent to mugaz.
    584577         DO l=1,nlayer
Note: See TracChangeset for help on using the changeset viewer.