Changeset 3572 for trunk/LMDZ.PLUTO/libf


Ignore:
Timestamp:
Jan 13, 2025, 2:52:33 PM (2 weeks ago)
Author:
debatzbr
Message:

Remove generic_aerosols and generic_condensation, along with their related variables (useless). RENAME THE VARIABLE AEROHAZE TO OPTICHAZE.

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

Legend:

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

    r3275 r3572  
    66
    77      Subroutine aeropacity(ngrid,nlayer,nq,pplay,pplev,pt, pq, &
    8          aerosol,reffrad,nueffrad, QREFvis3d,QREFir3d,tau_col, &
    9          cloudfrac,totcloudfrac,clearsky)
     8         aerosol,reffrad,nueffrad, QREFvis3d,QREFir3d,tau_col)
    109
    1110       use radinc_h, only : L_TAUMAX,naerkind
    12        use aerosol_mod, only: iaero_haze, i_haze, iaero_generic, &
    13                               noaero
     11       use aerosol_mod, only: iaero_haze, i_haze
    1412       USE tracer_h, only: noms,rho_n2,rho_ice,rho_q,mmol
    1513       use comcstfi_mod, only: g, pi, mugaz, avocado
    1614       use geometry_mod, only: latitude
    17        use callkeys_mod, only: aerofixn2,kastprof,cloudlvl,     &
    18                 pres_bottom_tropo,pres_top_tropo,obs_tau_col_tropo,     &
    19                 pres_bottom_strato,pres_top_strato,obs_tau_col_strato,  &
    20                 nlayaero, aeronlay_tauref, aeronlay_choice,             &
    21                 aeronlay_pbot, aeronlay_ptop, aeronlay_sclhght,         &
    22                 aerogeneric
    23         use generic_tracer_index_mod, only: generic_tracer_index
     15       use callkeys_mod, only: kastprof
    2416       implicit none
    2517
     
    7062      REAL,INTENT(IN) :: QREFir3d(ngrid,nlayer,naerkind)
    7163      REAL,INTENT(OUT):: tau_col(ngrid) !column integrated visible optical depth
    72       ! BENJAMIN MODIFS
    73       real,intent(in) :: cloudfrac(ngrid,nlayer) ! cloud fraction
    74       real,intent(out) :: totcloudfrac(ngrid) ! total cloud fraction
    75       logical,intent(in) :: clearsky
    7664
    7765      real aerosol0, obs_tau_col_aurora, pm
     
    9684      integer igen_ice,igen_gas ! to store the index of generic tracer
    9785      logical dummy_bool ! dummy boolean just in case we need one
    98       ! integer i_rgcs_ice(aerogeneric)
    9986      !  for venus clouds
    10087      real      :: p_bot,p_top,h_bot,h_top,mode_dens,h_lay
     
    11299          endif
    113100        enddo
    114 
    115         if (noaero) then
    116           print*, "No active aerosols found in aeropacity"
    117         else
    118           print*, "If you would like to use aerosols, make sure any old"
    119           print*, "start files are updated in newstart using the option"
    120           print*, "q=0"
    121           write(*,*) "Active aerosols found in aeropacity:"
    122         endif
    123101
    124102        firstcall=.false.
  • trunk/LMDZ.PLUTO/libf/phypluto/aerosol_mod.F90

    r3353 r3572  
    1010      integer, save :: iaero_haze = 0
    1111      integer, save :: i_haze = 0
    12       logical, save, protected :: noaero = .false.
    13 !$OMP THREADPRIVATE(iaero_haze,i_haze,noaero)
    14 
    15 ! two-layer simple aerosol model
    16       integer, save, protected :: iaero_back2lay = 0
    17 ! N-layer aerosol model (replaces the 2-layer and hard-coded clouds)
    18       integer,dimension(:), allocatable, save, protected :: iaero_nlay
    19 !$OMP THREADPRIVATE(iaero_back2lay,iaero_nlay)
    20 
    21 ! Generic aerosols
    22       integer, dimension(:), allocatable, save, protected :: iaero_generic
    23       integer, dimension(:), allocatable, save, protected :: i_rgcs_ice
    24 !$OMP THREADPRIVATE(iaero_generic,i_rgcs_ice)
     12!$OMP THREADPRIVATE(iaero_haze,i_haze)
    2513
    2614!==================================================================
  • trunk/LMDZ.PLUTO/libf/phypluto/callcorrk.F90

    r3547 r3572  
    1313          OLR_nu,OSR_nu,GSR_nu,                                &
    1414          int_dtaui,int_dtauv,                                 &
    15           tau_col,cloudfrac,totcloudfrac,                      &
    16           clearsky,firstcall,lastcall)
     15          tau_col,firstcall,lastcall)
    1716
    1817      use mod_phys_lmdz_para, only : is_master
     
    3029      use aeropacity_mod, only: aeropacity
    3130      use aeroptproperties_mod, only: aeroptproperties
    32       use tracer_h, only: constants_epsi_generic,igcm_ch4_gas,igcm_n2,mmol
     31      use tracer_h, only: igcm_ch4_gas,igcm_n2,mmol
    3332      use comcstfi_mod, only: pi, mugaz, cpp, r, g
    34       use callkeys_mod, only: varactive,diurnal,tracer,varfixed,satval, &
     33      use callkeys_mod, only: diurnal,tracer,varfixed,satval, &
    3534                              diagdtau,kastprof,strictboundcorrk,specOLR, &
    3635                              tplanckmin,tplanckmax,global1d, &
    37                               generic_condensation,aerohaze,haze_radproffix,&
     36                              optichaze,haze_radproffix,&
    3837                              methane,carbox,cooling,nlte,strobel,&
    3938                              ch4fix,vmrch4_proffix,vmrch4fix
     
    4342      use sfluxv_mod, only: sfluxv
    4443      use recombin_corrk_mod, only: corrk_recombin, call_recombin
    45       use generic_cloud_common_h, only: Psat_generic, epsi_generic
    46       use generic_tracer_index_mod, only: generic_tracer_index
    4744      use planetwide_mod, only: planetwide_maxval, planetwide_minval
    4845      use radcommon_h, only: wavev,wavei
     
    8885      REAL,INTENT(IN) :: dist_star                 ! Distance star-planet (AU).
    8986      REAL,INTENT(IN) :: muvar(ngrid,nlayer+1)
    90       REAL,INTENT(IN) :: cloudfrac(ngrid,nlayer)   ! Fraction of clouds (%).
    91       logical,intent(in) :: clearsky
    9287      logical,intent(in) :: firstcall              ! Signals first call to physics.
    9388      logical,intent(in) :: lastcall               ! Signals last call to physics.
     
    108103      REAL,INTENT(OUT) :: tau_col(ngrid)                 ! Diagnostic from aeropacity.
    109104      REAL,INTENT(OUT) :: albedo_equivalent(ngrid)       ! Spectrally Integrated Albedo. For Diagnostic. By MT2015
    110       REAL,INTENT(OUT) :: totcloudfrac(ngrid)            ! Column Fraction of clouds (%).
    111105      REAL,INTENT(OUT) :: int_dtaui(ngrid,nlayer,L_NSPECTI) ! VI optical thickness of layers within narrowbands for diags ().
    112106      REAL,INTENT(OUT) :: int_dtauv(ngrid,nlayer,L_NSPECTV) ! IR optical thickness of layers within narrowbands for diags ().
     
    200194      character(len=10),parameter :: subname="callcorrk"
    201195
    202       ! For fixed water vapour profiles.
    203       integer i_var
    204       real RH
    205       real*8 pq_temp(nlayer)
    206 ! real(KIND=r8) :: pq_temp(nlayer) ! better F90 way.. DOESNT PORT TO F77!!!
    207       real psat,qsat
    208 
    209196      logical OLRz
    210197      real*8 NFLUXGNDV_nu(L_NSPECTV)
     
    235222
    236223      integer ok ! status (returned by NetCDF functions)
    237 
    238       integer igcm_generic_gas, igcm_generic_ice! index of the vap and ice of generic_tracer
    239       logical call_ice_gas_generic ! to call only one time the ice/vap pair of a tracer
    240       real, save :: metallicity ! metallicity of planet --- is not used here, but necessary to call function Psat_generic
    241 !$OMP THREADPRIVATE(metallicity)
    242       REAL, SAVE :: qvap_deep   ! deep mixing ratio of water vapor when simulating bottom less planets
    243 !$OMP THREADPRIVATE(qvap_deep)
    244224
    245225      REAL :: maxvalue,minvalue
     
    453433         endif
    454434
    455 
    456          if(varfixed .and. (generic_condensation .or. methane .or. carbox))then
    457             write(*,*) "Deep generic tracer vapor mixing ratio ? (no effect if negative) "
    458             qvap_deep=-1. ! default value
    459             call getin_p("qvap_deep",qvap_deep)
    460             write(*,*) " qvap_deep = ",qvap_deep
    461 
    462             metallicity=0.0 ! default value --- is not used here but necessary to call function Psat_generic
    463             call getin_p("metallicity",metallicity) ! --- is not used here but necessary to call function Psat_generic
    464          endif
    465 
    466435      end if ! of if (firstcall)
    467436
     
    485454!     Effective radius and variance of the aerosols
    486455!--------------------------------------------------
    487       if (aerohaze) then
     456      if (optichaze) then
    488457         do iaer=1,naerkind
    489458            if ((iaer.eq.iaero_haze)) then
     
    511480      end do
    512481
    513       if (aerohaze) then
     482      if (optichaze) then
    514483
    515484         ! Get 3D aerosol optical properties.
     
    522491         call aeropacity(ngrid,nlayer,nq,pplay,pplev, pt,pq,aerosol,      &
    523492            reffrad,nueffrad,QREFvis3d,QREFir3d,                             &
    524             tau_col,cloudfrac,totcloudfrac,clearsky)
     493            tau_col)
    525494      endif
    526495
     
    578547
    579548      ! AF24: for now only consider one aerosol (=haze)
    580       if (aerohaze) then
     549      if (optichaze) then
    581550        do iaer=1,naerkind
    582551            ! Shortwave.
     
    685654            end do ! L_LEVELS
    686655        end do ! naerkind
    687       end if ! aerohaze
     656      end if ! optichaze
    688657
    689658!-----------------------------------------------------------------------
    690659!     Aerosol optical depths
    691660!-----------------------------------------------------------------------
    692       if (aerohaze) then
     661      if (optichaze) then
    693662        do iaer=1,naerkind     ! a bug was here
    694663            do k=0,nlayer-1
     
    711680      else
    712681         tauaero(:,:)=0
    713       end if ! aerohaze
     682      end if ! optichaze
    714683
    715684         ! Albedo and Emissivity.
     
    721690         acosz=mu0(ig) ! Cosine of sun incident angle : 3D simulations or local 1D simulations using latitude.
    722691
    723 
    724692      !-----------------------------------------------------------------------
    725       !  GCS (Generic Condensable Specie) Vapor
    726       !  If you have GCS tracers and they are : variable & radiatively active
    727       !
    728       !  NC22
     693      !  Methane Vapor
    729694      !-----------------------------------------------------------------------
    730 
    731       if (generic_condensation .or. methane .or. carbox) then
    732 
    733         ! IF (methane) then
    734 
    735         !    do l=1,nlayer
    736         !        qvar(2*l)   = vmrch4(ig,nlayer+1-l)/100.*    &
    737         !                             mmol(igcm_ch4_gas)/mmol(igcm_n2)
    738         !        qvar(2*l+1) = ((vmrch4(ig,nlayer+1-l)+vmrch4(ig, &
    739         !                     max(nlayer-l,1)))/2.)/100.* &
    740         !                     mmol(igcm_ch4_gas)/mmol(igcm_n2)
    741         !    end do
    742         !    qvar(1)=qvar(2)
    743 
    744         ! ELSE
    745 
    746          ! For now, only one GCS tracer can be both variable and radiatively active
    747          ! If you set two GCS tracers, that are variable and radiatively active,
    748          ! the last one in tracer.def will be chosen as the one that will be vadiatively active
    749 
    750          do iq=1,nq
    751 
    752             call generic_tracer_index(nq,iq,igcm_generic_gas,igcm_generic_ice,call_ice_gas_generic)
    753 
    754             if (call_ice_gas_generic) then ! to call only one time the ice/vap pair of a tracer
    755 
    756                if(varactive)then
    757 
    758                   i_var=igcm_generic_gas
    759                   do l=1,nlayer
    760                      qvar(2*l)   = pq(ig,nlayer+1-l,i_var)
    761                      qvar(2*l+1) = pq(ig,nlayer+1-l,i_var)
    762                      !JL13index            qvar(2*l+1) = (pq(ig,nlayer+1-l,i_var)+pq(ig,max(nlayer-l,1),i_var))/2
    763                      !JL13index            ! Average approximation as for temperature...
    764                   end do
    765                   qvar(1)=qvar(2)
    766 
    767                elseif(varfixed .and. (qvap_deep .ge. 0))then
    768 
    769                   do l=1,nlayer ! Here we will assign fixed water vapour profiles globally.
    770 
    771                      call Psat_generic(pt(ig,l),pplay(ig,l),metallicity,psat,qsat)
    772 
    773                      if (qsat .lt. qvap_deep) then
    774                         pq_temp(l) = qsat      ! fully saturated everywhere
    775                      else
    776                         pq_temp(l) = qvap_deep
    777                      end if
    778 
    779                   end do
    780 
    781                   do l=1,nlayer
    782                      qvar(2*l)   = pq_temp(nlayer+1-l)
    783                      qvar(2*l+1) = (pq_temp(nlayer+1-l)+pq_temp(max(nlayer-l,1)))/2
    784                   end do
    785 
    786                   qvar(1)=qvar(2)
    787 
    788                else
    789                   do k=1,L_LEVELS
    790                      qvar(k) = 1.0D-7
    791                   end do
    792                end if ! varactive/varfixed
    793 
    794             endif
    795 
    796          end do ! do iq=1,nq loop on tracers
    797 
    798       end if ! if (generic_condensation)
    799 
    800       !-----------------------------------------------------------------------
    801       !  No Water vapor and No GCS (Generic Condensable Specie) vapor
    802       !-----------------------------------------------------------------------
    803 
    804       if (.not. (generic_condensation .or. methane .or. carbox)) then
     695      if (methane) then
     696         do l=1,nlayer
     697            qvar(2*l) = vmrch4(ig,nlayer+1-l)/100.*    &
     698                        mmol(igcm_ch4_gas)/mmol(igcm_n2)
     699            qvar(2*l+1) = ((vmrch4(ig,nlayer+1-l)+vmrch4(ig, &
     700                           max(nlayer-l,1)))/2.)/100.* &
     701                           mmol(igcm_ch4_gas)/mmol(igcm_n2)
     702         end do
     703         qvar(1)=qvar(2)
     704     
     705      else
    805706         do k=1,L_LEVELS
    806707            qvar(k) = 1.0D-7
    807708         end do
    808       end if ! if (.not. generic_condensation)
    809 
    810 
    811       if(.not.kastprof)then
    812          ! IMPORTANT: Now convert from kg/kg to mol/mol.
    813          do k=1,L_LEVELS
    814             if (generic_condensation .or. methane .or. carbox) then
    815                do iq=1,nq
    816                   call generic_tracer_index(nq,iq,igcm_generic_gas,igcm_generic_ice,call_ice_gas_generic)
    817                   if (call_ice_gas_generic) then ! to call only one time the ice/vap pair of a tracer
    818                     if(.not. varactive .or. i_var.eq.iq)then
    819 
    820                         epsi_generic=constants_epsi_generic(iq)
    821 
    822                         qvar(k) = qvar(k)/(epsi_generic+qvar(k)*(1.-epsi_generic))
    823                     endif
    824 
    825                   endif
    826                end do ! do iq=1,nq loop on tracers
    827             endif
    828          end do
    829       end if
     709      end if ! end methane
    830710
    831711!-----------------------------------------------------------------------
     
    834714
    835715      DO l=1,nlayer
    836          muvarrad(2*l)   = muvar(ig,nlayer+2-l)
    837              muvarrad(2*l+1) = (muvar(ig,nlayer+2-l)+muvar(ig,max(nlayer+1-l,1)))/2
     716         muvarrad(2*l)   = muvar(ig,nlayer+2-l)   
     717         muvarrad(2*l+1) = (muvar(ig,nlayer+2-l)+muvar(ig,max(nlayer+1-l,1)))/2
    838718      END DO
    839719
  • trunk/LMDZ.PLUTO/libf/phypluto/callcorrk_pluto_mod.F90

    r3504 r3572  
    1010          dtlw,dtsw,fluxsurf_lw,    &
    1111          fluxsurf_sw,fluxtop_lw,fluxtop_sw,fluxtop_dn, &
    12           reffrad,tau_col,ptime,pday,cloudfrac,totcloudfrac,   &
    13           clearsky,firstcall,lastcall)
     12          reffrad,tau_col,ptime,pday,firstcall,lastcall)
    1413
    1514      use radinc_h
     
    2524      use tracer_h, only: igcm_n2,igcm_ch4_gas,igcm_ch4_ice,rho_ch4_ice,lw_ch4,&
    2625                          mmol
    27       use callkeys_mod, only: aerohaze,ch4fix,cooling,methane,nlte,&
     26      use callkeys_mod, only: optichaze,ch4fix,cooling,methane,nlte,&
    2827                              strobel,vmrch4_proffix,specOLR,vmrch4fix,&
    2928                              haze_radproffix
     
    6867      REAL zzlay(ngrid,nlayer)            ! altitude at the middle of the layers
    6968      REAL pplev(ngrid,nlayer+1)          ! pres. level at GCM layer boundaries
    70       REAL cloudfrac(ngrid,nlayer)   ! Fraction of clouds (%).
    71       logical clearsky
    7269
    7370      REAL pt(ngrid,nlayer)               ! air temperature (K)
     
    104101      REAL fluxtop_sw(ngrid)    ! outgoing LW flux to space (W/m2)
    105102      REAL fluxtop_dn(ngrid)    ! incident top of atmosphere SW flux (W/m2)
    106       REAL totcloudfrac(ngrid)            ! Column Fraction of clouds (%).
    107103
    108104!-----------------------------------------------------------------------
     
    239235
    240236         ! Radiative Hazes
    241          if (aerohaze) then
     237         if (optichaze) then
    242238
    243239           ! AF24: TODO check duplicate suaer_corrk called from physiq_mod
    244           !  print*,'aerohaze: starting suaer_corrk'
     240          !  print*,'optichaze: starting suaer_corrk'
    245241          !  call suaer_corrk       ! set up aerosol optical properties
    246242          !  print*,'ending suaer_corrk'
     
    297293!     Get 3D aerosol optical properties.
    298294      ! ici on selectionne les proprietes opt correspondant a reffrad
    299       if (aerohaze) then
     295      if (optichaze) then
    300296        !--------------------------------------------------
    301297        ! Effective radius and variance of the aerosols if profil non
    302         ! uniform. Called only if aerohaze=true.
     298        ! uniform. Called only if optichaze=true.
    303299        !--------------------------------------------------
    304300
     
    311307        call aeropacity(ngrid,nlayer,nq,pplay,pplev, pt,pq,aerosol,      &
    312308            reffrad,nueffrad,QREFvis3d,QREFir3d,                             &
    313             tau_col,cloudfrac,totcloudfrac,clearsky)
     309            tau_col)
    314310      endif
    315311
     
    360356!     Aerosol optical properties Qext, Qscat and g on each band
    361357!     The transformation in the vertical is the same as for temperature
    362          if (aerohaze) then
     358         if (optichaze) then
    363359!     shortwave
    364360            do iaer=1,naerkind
     
    464460            end do ! naerkind
    465461
    466          endif ! aerohaze
     462         endif ! optichaze
    467463
    468464!-----------------------------------------------------------------------
    469465!     Aerosol optical depths
    470          IF (aerohaze) THEN
     466         IF (optichaze) THEN
    471467          do iaer=1,naerkind     ! heritage generic
    472468            do k=0,nlayer-1
  • trunk/LMDZ.PLUTO/libf/phypluto/callkeys_mod.F90

    r3557 r3572  
    3737      logical,save :: varfixed
    3838      logical,save :: sedimentation
    39       logical,save :: generic_condensation
    40 !$OMP THREADPRIVATE(varactive,varfixed,sedimentation,generic_condensation)
    41       logical,save :: aeron2, aeroh2o, aeroh2so4, aeroback2lay
    42 !$OMP THREADPRIVATE(aeron2, aeroh2o, aeroh2so4, aeroback2lay)
    43       logical,save :: aeronh3, aeronlay, aeroaurora
    44 !$OMP THREADPRIVATE(aeronh3,aeronlay,aeroaurora)
    45 
    46       logical,save :: aerofixn2
    47 !$OMP THREADPRIVATE(aerofixn2)
    48       integer,save :: aerogeneric ! number of aerosols of "generic" kind
    49 !$OMP THREADPRIVATE(aerogeneric)
     39!$OMP THREADPRIVATE(varactive,varfixed,sedimentation)
     40
    5041      logical,save :: nosurf
    5142!$OMP THREADPRIVATE(nosurf)
     
    6253      logical,save :: haze,haze_proffix,haze_radproffix
    6354!$OMP THREADPRIVATE(haze,haze_proffix,haze_radproffix)
    64       logical,save :: fasthaze,changeti,changetid,aerohaze,fractal
    65 !$OMP THREADPRIVATE(fasthaze,changeti,changetid,aerohaze,fractal)
     55      logical,save :: fasthaze,changeti,changetid,optichaze,fractal
     56!$OMP THREADPRIVATE(fasthaze,changeti,changetid,optichaze,fractal)
    6657      logical,save :: fast,metcloud,monoxcloud,glaflow,triton,paleo
    6758!$OMP THREADPRIVATE(fast,metcloud,monoxcloud,glaflow,triton,paleo)
     
    224215      integer,save :: versH2H2cia
    225216      character(64),save :: H2orthopara_mixture
    226       integer,save :: nlayaero
    227 !$OMP THREADPRIVATE(iddist,iaervar,iradia,startype,versH2H2cia,H2orthopara_mixture,nlayaero)
    228       integer,dimension(:),allocatable,save :: aeronlay_choice
    229 !$OMP THREADPRIVATE(aeronlay_choice)
    230 
    231       character(64),save :: optprop_back2lay_vis
    232       character(64),save :: optprop_back2lay_ir
    233       character(64),dimension(:),allocatable,save :: optprop_aeronlay_vis
    234       character(64),dimension(:),allocatable,save :: optprop_aeronlay_ir
    235 !$OMP THREADPRIVATE(optprop_back2lay_vis,optprop_back2lay_ir,optprop_aeronlay_vis,optprop_aeronlay_ir)
     217!$OMP THREADPRIVATE(iddist,iaervar,iradia,startype,versH2H2cia,H2orthopara_mixture)
    236218
    237219      real,save :: tplanckmin
     
    246228      real,save :: Tstrat
    247229      real,save :: tplanet
    248       real,save :: obs_tau_col_tropo
    249       real,save :: obs_tau_col_strato
    250 !$OMP THREADPRIVATE(Tstrat,tplanet,obs_tau_col_tropo,obs_tau_col_strato)
    251       real,save :: pres_bottom_tropo
    252       real,save :: pres_top_tropo
    253       real,save :: pres_bottom_strato
    254       real,save :: pres_top_strato
    255 !$OMP THREADPRIVATE(pres_bottom_tropo,pres_top_tropo,pres_bottom_strato,pres_top_strato)
    256       real,save :: size_tropo
    257       real,save :: size_strato
     230!$OMP THREADPRIVATE(Tstrat,tplanet)
    258231      real,save :: satval
    259232      real,save :: n2mixratio
    260 !$OMP THREADPRIVATE(size_tropo,size_strato,satval,n2mixratio)
    261       real,save :: size_nh3_cloud
    262       real,save :: pres_nh3_cloud
    263       real,save :: tau_nh3_cloud
    264 !$OMP THREADPRIVATE(size_nh3_cloud, pres_nh3_cloud, tau_nh3_cloud)
    265       real,dimension(:),allocatable,save :: aeronlay_tauref
    266       real,dimension(:),allocatable,save :: aeronlay_lamref
    267       real,dimension(:),allocatable,save :: aeronlay_ptop
    268       real,dimension(:),allocatable,save :: aeronlay_pbot
    269       real,dimension(:),allocatable,save :: aeronlay_sclhght
    270       real,dimension(:),allocatable,save :: aeronlay_size
    271       real,dimension(:),allocatable,save :: aeronlay_nueff
    272 !$OMP THREADPRIVATE(aeronlay_tauref,aeronlay_lamref,aeronlay_ptop,aeronlay_pbot,aeronlay_sclhght,aeronlay_size,aeronlay_nueff)
     233!$OMP THREADPRIVATE(satval,n2mixratio)
    273234      real,save :: n2supsat
    274235      real,save :: pceil
     
    279240      real,save :: Tsaldiff
    280241      real,save :: tau_relax
    281       real,save :: cloudlvl
    282242      real,save :: icetstep
    283243      real,save :: intheat
    284 !$OMP THREADPRIVATE(Tsaldiff,tau_relax,cloudlvl,icetstep,intheat)
     244!$OMP THREADPRIVATE(Tsaldiff,tau_relax,icetstep,intheat)
    285245      real,save :: surfalbedo
    286246      real,save :: surfemis
  • trunk/LMDZ.PLUTO/libf/phypluto/comm_wrf.F90

    r3184 r3572  
    1818  REAL,SAVE,ALLOCATABLE :: comm_RICE(:,:)
    1919  REAL,SAVE,ALLOCATABLE :: comm_GEOP(:,:)
    20   REAL,SAVE,ALLOCATABLE :: comm_CLOUDFRAC(:,:)
    21   REAL,SAVE,ALLOCATABLE :: comm_TOTCLOUDFRAC(:)
    2220  REAL,SAVE,ALLOCATABLE :: comm_RH(:,:)
    2321  REAL,SAVE,ALLOCATABLE :: comm_DQICE(:,:)
     
    5654  allocate(comm_RICE(ngrid,nlayer))
    5755  allocate(comm_GEOP(ngrid,nlayer))
    58   allocate(comm_CLOUDFRAC(ngrid,nlayer))
    59   allocate(comm_TOTCLOUDFRAC(ngrid))
    6056  allocate(comm_RH(ngrid,nlayer))
    6157  allocate(comm_DQICE(ngrid,nlayer))
     
    9288  deallocate(comm_RICE)
    9389  deallocate(comm_GEOP)
    94   deallocate(comm_CLOUDFRAC)
    95   deallocate(comm_TOTCLOUDFRAC)
    9690  deallocate(comm_RH)
    9791  deallocate(comm_DQICE)
  • trunk/LMDZ.PLUTO/libf/phypluto/dyn1d/kcm1d.F90

    r3184 r3572  
    7575
    7676  ! not used
    77   real cloudfrac(1,llm)
    78   real totcloudfrac(1)
    7977  real tau_col(1)
    8078
     
    104102
    105103  pi=2.E+0*asin(1.E+0)
    106 
    107   cloudfrac(1,:)  = 0.0
    108   totcloudfrac(1)  = 0.0
    109 
    110104
    111105  nlayer=llm
     
    385379          fluxabs_sw,fluxtop_dn,OLR_nu,OSR_nu,GSR_nu,     &
    386380          int_dtaui,int_dtauv,                            &
    387           tau_col,cloudfrac,totcloudfrac,                 &
    388           .false.,firstcall,lastcall)
     381          tau_col,firstcall,lastcall)
    389382
    390383     !write(*,*) 'BASE 3'
     
    396389     !     fluxsurfabs_sw,'T',fluxtop_lw,'U',                      &
    397390     !     fluxabs_sw,'V',fluxtop_dn,'W',OLR_nu,'X',OSR_nu,'Y',tau_col,'Z',    &
    398      !     cloudfrac,'A1',totcloudfrac,'A2',.false.,'A3',firstcall,'A4',lastcall
     391     !     .false.,'A3',firstcall,'A4',lastcall
    399392
    400393
     
    437430       fluxtop_lw, fluxabs_sw,fluxtop_dn,OLR_nu,OSR_nu,GSR_nu, &
    438431       int_dtaui,int_dtauv,                                    &
    439        tau_col,cloudfrac,totcloudfrac,                         &
    440        .false.,firstcall,lastcall)
     432       tau_col,firstcall,lastcall)
    441433
    442434
     
    449441     !     fluxsurfabs_sw,'T',fluxtop_lw,'U',                      &
    450442     !     fluxabs_sw,'V',fluxtop_dn,'W',OLR_nu,'X',OSR_nu,'Y',tau_col,'Z',    &
    451      !     cloudfrac,'A1',totcloudfrac,'A2',.false.,'A3',firstcall,'A4',lastcall
     443     !     .false.,'A3',firstcall,'A4',lastcall
    452444
    453445
  • trunk/LMDZ.PLUTO/libf/phypluto/inifis_mod.F90

    r3557 r3572  
    776776     if (is_master)write(*,*)trim(rname)//&
    777777     "Radiatively active haze ?"
    778      aerohaze=.false. ! default value
    779      call getin_p("aerohaze",aerohaze)
    780      if (is_master)write(*,*)trim(rname)//&
    781      "aerohaze = ",aerohaze
     778     optichaze=.false. ! default value
     779     call getin_p("optichaze",optichaze)
     780     if (is_master)write(*,*)trim(rname)//&
     781     "optichaze = ",optichaze
    782782
    783783     if (is_master)write(*,*)trim(rname)//&
     
    11981198
    11991199!=================================
    1200 ! TWOLAY scheme and NH3 cloudare left for retrocompatibility only,
    1201 ! You should now use N-LAYER scheme (see below).
    1202 
    1203      if (is_master) write(*,*)trim(rname)//&
    1204        ": Radiatively active two-layer aerosols?"
    1205      aeroback2lay=.false.     ! default value
    1206      call getin_p("aeroback2lay",aeroback2lay)
    1207      if (is_master) write(*,*)trim(rname)//": aeroback2lay = ",aeroback2lay
    1208 
    1209      if (aeroback2lay.and.is_master) then
    1210        print*,'Warning : The TWOLAY AEROSOL scheme is deprecated and buggy...'
    1211        print*,'You should use the generic n-layer scheme (see aeronlay).'
    1212      endif
    1213 
    1214      if (is_master) write(*,*)trim(rname)//": Radiatively active ammonia cloud?"
    1215      aeronh3=.false.     ! default value
    1216      call getin_p("aeronh3",aeronh3)
    1217      if (is_master) write(*,*)trim(rname)//": aeronh3 = ",aeronh3
    1218 
    1219      if (aeronh3.and.is_master) then
    1220        print*,'Warning : You are using specific NH3 cloud scheme ...'
    1221        print*,'You should use the generic n-layer scheme (see aeronlay).'
    1222      endif
    1223 
    1224      if (is_master) write(*,*)trim(rname)//&
    1225        ": TWOLAY AEROSOL: total optical depth "//&
    1226        "in the tropospheric layer (visible)"
    1227      obs_tau_col_tropo=8.D0
    1228      call getin_p("obs_tau_col_tropo",obs_tau_col_tropo)
    1229      if (is_master) write(*,*)trim(rname)//&
    1230        ": obs_tau_col_tropo = ",obs_tau_col_tropo
    1231 
    1232      if (is_master) write(*,*)trim(rname)//&
    1233        ": TWOLAY AEROSOL: total optical depth "//&
    1234        "in the stratospheric layer (visible)"
    1235      obs_tau_col_strato=0.08D0
    1236      call getin_p("obs_tau_col_strato",obs_tau_col_strato)
    1237      if (is_master) write(*,*)trim(rname)//&
    1238        ": obs_tau_col_strato = ",obs_tau_col_strato
    1239 
    1240      if (is_master) write(*,*)trim(rname)//&
    1241        ": TWOLAY AEROSOL: optprop_back2lay_vis?"
    1242      optprop_back2lay_vis = 'optprop_saturn_vis_n20.dat'
    1243      call getin_p("optprop_back2lay_vis",optprop_back2lay_vis)
    1244      if (is_master) write(*,*)trim(rname)//&
    1245        ": optprop_back2lay_vis = ",trim(optprop_back2lay_vis)
    1246 
    1247      if (is_master) write(*,*)trim(rname)//&
    1248        ": TWOLAY AEROSOL: optprop_back2lay_ir?"
    1249      optprop_back2lay_ir = 'optprop_saturn_ir_n20.dat'
    1250      call getin_p("optprop_back2lay_ir",optprop_back2lay_ir)
    1251      if (is_master) write(*,*)trim(rname)//&
    1252        ": optprop_back2lay_ir = ",trim(optprop_back2lay_ir)
    1253 
    1254      if (is_master) write(*,*)trim(rname)//&
    1255        ": TWOLAY AEROSOL: pres_bottom_tropo? in pa"
    1256      pres_bottom_tropo=66000.0
    1257      call getin_p("pres_bottom_tropo",pres_bottom_tropo)
    1258      if (is_master) write(*,*)trim(rname)//&
    1259        ": pres_bottom_tropo = ",pres_bottom_tropo
    1260 
    1261      if (is_master) write(*,*)trim(rname)//&
    1262        ": TWOLAY AEROSOL: pres_top_tropo? in pa"
    1263      pres_top_tropo=18000.0
    1264      call getin_p("pres_top_tropo",pres_top_tropo)
    1265      if (is_master) write(*,*)trim(rname)//&
    1266        ": pres_top_tropo = ",pres_top_tropo
    1267 
    1268      if (is_master) write(*,*)trim(rname)//&
    1269        ": TWOLAY AEROSOL: pres_bottom_strato? in pa"
    1270      pres_bottom_strato=2000.0
    1271      call getin_p("pres_bottom_strato",pres_bottom_strato)
    1272      if (is_master) write(*,*)trim(rname)//&
    1273        ": pres_bottom_strato = ",pres_bottom_strato
    1274 
    1275      ! Sanity check
    1276      if (pres_bottom_strato .gt. pres_top_tropo) then
    1277        if(is_master) then
    1278        print*,'Error : TWOLAY AEROSOL, Please ensure that in callphys.def'
    1279        print*,'you have pres_top_tropo > pres_bottom_strato !'
    1280        endif
    1281        call abort_physic(rname," pres_top_tropo > pres_bottom_strato!",1)
    1282      endif
    1283 
    1284      if (is_master) write(*,*)trim(rname)//&
    1285        ": TWOLAY AEROSOL: pres_top_strato? in pa"
    1286      pres_top_strato=100.0
    1287      call getin_p("pres_top_strato",pres_top_strato)
    1288      if (is_master) write(*,*)trim(rname)//&
    1289        ": pres_top_strato = ",pres_top_strato
    1290 
    1291      if (is_master) write(*,*)trim(rname)//&
    1292        ": TWOLAY AEROSOL: particle size in the ", &
    1293        "tropospheric layer, in meters"
    1294      size_tropo=2.e-6
    1295      call getin_p("size_tropo",size_tropo)
    1296      if (is_master) write(*,*)trim(rname)//": size_tropo = ",size_tropo
    1297 
    1298      if (is_master) write(*,*)trim(rname)//&
    1299        ": TWOLAY AEROSOL: particle size in the ", &
    1300        "stratospheric layer, in meters"
    1301      size_strato=1.e-7
    1302      call getin_p("size_strato",size_strato)
    1303      if (is_master) write(*,*)trim(rname)//": size_strato = ",size_strato
    1304 
    1305      if (is_master) write(*,*)trim(rname)//&
    1306        ": NH3 (thin) cloud: total optical depth"
    1307      tau_nh3_cloud=7.D0
    1308      call getin_p("tau_nh3_cloud",tau_nh3_cloud)
    1309      if (is_master) write(*,*)trim(rname)//": tau_nh3_cloud = ",tau_nh3_cloud
    1310 
    1311      if (is_master) write(*,*)trim(rname)//": NH3 (thin) cloud pressure level"
    1312      pres_nh3_cloud=7.D0
    1313      call getin_p("pres_nh3_cloud",pres_nh3_cloud)
    1314      if (is_master) write(*,*)trim(rname)//": pres_nh3_cloud = ",pres_nh3_cloud
    1315 
    1316      if (is_master) write(*,*)trim(rname)//": NH3 (thin) cloud: particle sizes"
    1317      size_nh3_cloud=3.e-6
    1318      call getin_p("size_nh3_cloud",size_nh3_cloud)
    1319      if (is_master) write(*,*)trim(rname)//": size_nh3_cloud = ",size_nh3_cloud
    1320 
    1321 !=================================
    1322 ! Generic N-LAYER aerosol scheme
    1323 
    1324      if (is_master) write(*,*)trim(rname)//&
    1325        ": Radiatively active generic n-layer aerosols?"
    1326      aeronlay=.false.     ! default value
    1327      call getin_p("aeronlay",aeronlay)
    1328      if (is_master) write(*,*)trim(rname)//": aeronlay = ",aeronlay
    1329 
    1330      if (is_master) write(*,*)trim(rname)//&
    1331        ": Number of generic aerosols layers?"
    1332      nlayaero=1     ! default value
    1333      call getin_p("nlayaero",nlayaero)
    1334      ! Avoid to allocate arrays of size 0
    1335      if (aeronlay .and. nlayaero.lt.1) then
    1336        if (is_master) then
    1337        print*, " You are trying to set no generic aerosols..."
    1338        print*, " Set aeronlay=.false. instead ! I abort."
    1339        endif
    1340        call abort_physic(rname,"no generic aerosols...",1)
    1341      endif
    1342      if (.not. aeronlay) nlayaero=1
    1343      if (is_master) write(*,*)trim(rname)//": nlayaero = ",nlayaero
    1344 
    1345      ! This is necessary, we just set the number of aerosol layers
    1346      IF(.NOT.ALLOCATED(aeronlay_tauref))      ALLOCATE(aeronlay_tauref(nlayaero))
    1347      IF(.NOT.ALLOCATED(aeronlay_lamref))      ALLOCATE(aeronlay_lamref(nlayaero))
    1348      IF(.NOT.ALLOCATED(aeronlay_choice))      ALLOCATE(aeronlay_choice(nlayaero))
    1349      IF(.NOT.ALLOCATED(aeronlay_pbot))        ALLOCATE(aeronlay_pbot(nlayaero))
    1350      IF(.NOT.ALLOCATED(aeronlay_ptop))        ALLOCATE(aeronlay_ptop(nlayaero))
    1351      IF(.NOT.ALLOCATED(aeronlay_sclhght))     ALLOCATE(aeronlay_sclhght(nlayaero))
    1352      IF(.NOT.ALLOCATED(aeronlay_size))        ALLOCATE(aeronlay_size(nlayaero))
    1353      IF(.NOT.ALLOCATED(aeronlay_nueff))       ALLOCATE(aeronlay_nueff(nlayaero))
    1354      IF(.NOT.ALLOCATED(optprop_aeronlay_ir))  ALLOCATE(optprop_aeronlay_ir(nlayaero))
    1355      IF(.NOT.ALLOCATED(optprop_aeronlay_vis)) ALLOCATE(optprop_aeronlay_vis(nlayaero))
    1356 
    1357      if (is_master) write(*,*)trim(rname)//&
    1358        ": Generic n-layer aerosols: Optical depth at reference wavelenght"
    1359      aeronlay_tauref=1.0E-1
    1360      call getin_p("aeronlay_tauref",aeronlay_tauref)
    1361      if (is_master) write(*,*)trim(rname)//&
    1362        ": aeronlay_tauref = ",aeronlay_tauref
    1363 
    1364      if (is_master) write(*,*)trim(rname)//&
    1365        ": Generic n-layer aerosols: Reference wavelenght for optical depths (m)"
    1366      aeronlay_lamref=0.6E-6
    1367      call getin_p("aeronlay_lamref",aeronlay_lamref)
    1368      if (is_master) write(*,*)trim(rname)//&
    1369        ": aeronlay_lamref = ",aeronlay_lamref
    1370 
    1371      if (is_master) then
    1372        write(*,*)trim(rname)//&
    1373        ": Generic n-layer aerosols: Vertical profile choice : "
    1374        write(*,*)trim(rname)//&
    1375        "             (1) Tau btwn ptop and pbot follows atm. scale height"
    1376        write(*,*)trim(rname)//&
    1377        "         or  (2) Tau above pbot follows its own scale height"
    1378      endif
    1379      aeronlay_choice=1
    1380      call getin_p("aeronlay_choice",aeronlay_choice)
    1381      if (is_master) write(*,*)trim(rname)//&
    1382        ": aeronlay_choice = ",aeronlay_choice
    1383 
    1384      if (is_master) write(*,*)trim(rname)//&
    1385        ": Generic n-layer aerosols: bottom pressures (Pa)"
    1386      aeronlay_pbot=2000.0
    1387      call getin_p("aeronlay_pbot",aeronlay_pbot)
    1388      if (is_master) write(*,*)trim(rname)//": aeronlay_pbot = ",aeronlay_pbot
    1389 
    1390      if (is_master) write(*,*)trim(rname)//&
    1391        ": Generic n-layer aerosols: (if choice=1) Top pressures (Pa) "
    1392      aeronlay_ptop=300000.0
    1393      call getin_p("aeronlay_ptop",aeronlay_ptop)
    1394      if (is_master) write(*,*)trim(rname)//": aeronlay_ptop = ",aeronlay_ptop
    1395 
    1396      if (is_master) write(*,*)trim(rname)//&
    1397        ": Generic n-layer aerosols: (if choice=2) Scale height / atm. scale height"
    1398      aeronlay_sclhght=0.2
    1399      call getin_p("aeronlay_sclhght",aeronlay_sclhght)
    1400      if (is_master) write(*,*)trim(rname)//&
    1401        ": aeronlay_sclhght = ",aeronlay_sclhght
    1402 
    1403      if (is_master) write(*,*)trim(rname)//&
    1404        ": Generic n-layer aerosols: particles effective radii (m)"
    1405      aeronlay_size=1.e-6
    1406      call getin_p("aeronlay_size",aeronlay_size)
    1407      if (is_master) write(*,*)trim(rname)//": aeronlay_size = ",aeronlay_size
    1408 
    1409      if (is_master) write(*,*)trim(rname)//&
    1410        ": Generic n-layer aerosols: particles radii effective variance"
    1411      aeronlay_nueff=0.1
    1412      call getin_p("aeronlay_nueff",aeronlay_nueff)
    1413      if (is_master) write(*,*)trim(rname)//": aeronlay_nueff = ",aeronlay_nueff
    1414 
    1415      if (is_master) write(*,*)trim(rname)//&
    1416        ": Generic n-layer aerosols: VIS optical properties file"
    1417      optprop_aeronlay_vis = 'optprop_saturn_vis_n20.dat'
    1418      call getin_p("optprop_aeronlay_vis",optprop_aeronlay_vis)
    1419      if (is_master) write(*,*)trim(rname)//&
    1420        ": optprop_aeronlay_vis = ",optprop_aeronlay_vis
    1421 
    1422      if (is_master) write(*,*)trim(rname)//&
    1423      ": Generic n-layer aerosols: IR optical properties file"
    1424      optprop_aeronlay_ir = 'optprop_saturn_ir_n20.dat'
    1425      call getin_p("optprop_aeronlay_ir",optprop_aeronlay_ir)
    1426      if (is_master) write(*,*)trim(rname)//&
    1427        ": optprop_aeronlay_ir = ",optprop_aeronlay_ir
    1428 
    1429 
    1430 !=================================
    14311200
    14321201     if (is_master) write(*,*)trim(rname)//&
     
    14601229     call getin_p("sedimentation",sedimentation)
    14611230     if (is_master) write(*,*)trim(rname)//": sedimentation = ",sedimentation
    1462 
    1463      if (is_master) write(*,*)trim(rname)//": Generic Condensation of tracers ?"
    1464      generic_condensation=.false. !default value
    1465      call getin_p("generic_condensation",generic_condensation)
    1466      if (is_master) write(*,*)trim(rname)//": generic_condensation = ",generic_condensation
    14671231
    14681232     if (is_master) write(*,*)trim(rname)//": Spectral Dependant albedo ?"
     
    15331297         call abort_physic(rname, 'if paleo is set, fast must be true', 1)
    15341298     endif
    1535      if ((haze_proffix.or.haze_radproffix).and..not.aerohaze) then
    1536          call abort_physic(rname, 'for now, haze/rad proffix only works w aerohaze=T', 1)
     1299     if ((haze_proffix.or.haze_radproffix).and..not.optichaze) then
     1300         call abort_physic(rname, 'for now, haze/rad_proffix only works with optichaze=T', 1)
    15371301     endif
    15381302      if (carbox.and.condcosurf.and.no_n2frost) then
  • trunk/LMDZ.PLUTO/libf/phypluto/initracer.F90

    r3557 r3572  
    33      use surfdat_h, ONLY: dryness
    44      USE tracer_h
    5       USE callkeys_mod, only: aerohaze,nb_monomer,haze,fractal,fasthaze,rad_haze,callmufi
     5      USE callkeys_mod, only: optichaze,nb_monomer,haze,fractal,fasthaze,rad_haze,callmufi
    66      USE recombin_corrk_mod, ONLY: ini_recombin
    77      USE mod_phys_lmdz_para, only: is_master, bcast
    8       use generic_cloud_common_h
    98      use aerosol_mod, only: iaero_haze,i_haze
    109      IMPLICIT NONE
     
    130129       IF (.NOT. allocated(constants_Tref)) allocate(constants_Tref(nq))
    131130       IF (.NOT. allocated(constants_Pref)) allocate(constants_Pref(nq))
    132        IF (.NOT. allocated(constants_epsi_generic)) allocate(constants_epsi_generic(nq))
    133131       IF (.NOT. allocated(constants_RLVTT_generic)) allocate(constants_RLVTT_generic(nq))
    134        IF (.NOT. allocated(constants_metallicity_coeff)) allocate(constants_metallicity_coeff(nq))
    135132       IF (.NOT. allocated(constants_RCPV_generic)) allocate(constants_RCPV_generic(nq))
    136133
     
    160157       constants_Tref(:)=0
    161158       constants_Pref(:)=0
    162        constants_epsi_generic(:)=0
    163159       constants_RLVTT_generic(:)=0
    164        constants_metallicity_coeff(:)=0
    165160       constants_RCPV_generic(:)=0
    166161
     
    418413                ! constants_Tref(iq)=Tref
    419414                ! constants_Pref(iq)=Pref
    420                 ! constants_epsi_generic(iq)=epsi_generic
    421415                ! constants_RLVTT_generic(iq)=RLVTT_generic
    422                 ! constants_metallicity_coeff(iq)=metallicity_coeff
    423416                ! constants_RCPV_generic(iq)=RCPV_generic
    424417        else
     
    477470
    478471        ia=0
    479         if (aerohaze) then
    480            ia=ia+1
    481            iaero_haze=ia
    482            write(*,*) '--- number of haze aerosol = ', iaero_haze
    483 
    484            block=0  ! Only one type of haze is active : the first one set in traceur.def
    485            do iq=1,nq
    486              tracername=noms(iq)
    487              write(*,*) "--> tracername ",iq,'/',nq,' = ',tracername
    488              if (tracername(1:4).eq."haze".and.block.eq.0) then
    489                i_haze=iq
    490                block=1
    491                write(*,*) "i_haze=",i_haze
    492                write(*,*) "Careful: if you set many haze traceurs in &
     472        if (optichaze) then
     473          ia=ia+1
     474          iaero_haze=ia
     475          write(*,*) '--- number of haze aerosol = ', iaero_haze
     476
     477          block=0  ! Only one type of haze is active : the first one set in traceur.def
     478          do iq=1,nq
     479            tracername=noms(iq)
     480            write(*,*) "--> tracername ",iq,'/',nq,' = ',tracername
     481            if (tracername(1:4).eq."haze".and.block.eq.0) then
     482              i_haze=iq
     483              block=1
     484              write(*,*) "i_haze=",i_haze
     485              write(*,*) "Careful: if you set many haze traceurs in &
    493486                traceur.def,only ",tracername," will be radiatively active &
    494487                (first one in traceur.def)"
    495              endif
    496            enddo
    497         endif ! end aerohaze
    498       endif ! end haze
     488            endif
     489          enddo
     490        endif ! end optichaze
     491      endif ! end callmufi or haze
    499492
    500493!     Output for records:
  • trunk/LMDZ.PLUTO/libf/phypluto/phyetat0_mod.F90

    r3506 r3572  
    1414                     day_ini,time,tsurf,tsoil, &
    1515                     emis,q2,qsurf,therm_inertia)
    16                     !  ,cloudfrac,totcloudfrac,hice, &
     16                    !  ,hice, &
    1717                    !  rnat,pctsrf_sic)
    1818                    !  ,tslab,tsea_ice,sea_ice) !AF24
  • trunk/LMDZ.PLUTO/libf/phypluto/phys_state_var_mod.F90

    r3539 r3572  
    7575      real,allocatable,dimension(:),save :: tau_col ! Total Aerosol Optical Depth.
    7676!$OMP THREADPRIVATE(tau_col)
    77 
    78       real,allocatable,dimension(:,:),save :: cloudfrac  ! Fraction of clouds (%).
    79       real,allocatable,dimension(:),save :: totcloudfrac ! Column fraction of clouds (%).
    80 !$OMP THREADPRIVATE(cloudfrac,totcloudfrac)
    81 
    8277
    8378      real,allocatable,dimension(:,:,:),save :: nueffrad ! Aerosol effective radius variance. By RW
     
    139134        ALLOCATE(ztprevious(klon,klev))
    140135        ALLOCATE(zuprevious(klon,klev))
    141         ALLOCATE(cloudfrac(klon,klev))
    142         ALLOCATE(totcloudfrac(klon))
    143136        ALLOCATE(reffrad(klon,klev,naerkind))
    144137        ALLOCATE(nueffrad(klon,klev,naerkind))
     
    216209        DEALLOCATE(ztprevious)
    217210        DEALLOCATE(zuprevious)
    218         DEALLOCATE(cloudfrac)
    219         DEALLOCATE(totcloudfrac)
    220211        DEALLOCATE(reffrad)
    221212        DEALLOCATE(nueffrad)
  • trunk/LMDZ.PLUTO/libf/phypluto/physiq_mod.F90

    r3558 r3572  
    1818      use ioipsl_getin_p_mod, only: getin_p
    1919      use radinc_h, only : L_NSPECTI,L_NSPECTV,naerkind, corrkdir, banddir
    20       use generic_cloud_common_h, only : epsi_generic, Psat_generic
    2120      use gases_h, only: gnom, gfrac
    2221      use radcommon_h, only: sigma, glat, grav, BWNV, WNOI, DWNI, DWNV, WNOV
    2322      use suaer_corrk_mod, only: suaer_corrk
    2423      use radii_mod, only: su_aer_radii,haze_reffrad_fix
    25       use aerosol_mod, only: iaero_haze, i_haze, haze_prof
     24      use aerosol_mod, only: i_haze, haze_prof
    2625      use surfdat_h, only: phisfi, zmea, zstd, zsig, zgam, zthe, &
    2726                           dryness
     
    3635                          igcm_co_gas,igcm_co_ice,igcm_prec_haze,lw_n2,lw_ch4,lw_co,&
    3736                          alpha_lift, alpha_devil, qextrhor, &
    38                           nesp, is_chim, is_condensable,constants_epsi_generic
     37                          nesp, is_chim, is_condensable
    3938      use time_phylmdz_mod, only: ecritphy, iphysiq, nday
    4039      use phyetat0_mod, only: phyetat0,tab_cntrl_mod
     
    5049                              callrad, callsoil, nosurf,                      &
    5150                              callconduct,callmolvis,callmoldiff,             &
    52                               aerohaze, corrk, diagdtau,                      &
     51                              corrk, diagdtau,                                &
    5352                              diurnal, enertest, fat1au,                      &
    5453                              icetstep, intheat, iradia, kastprof,            &
     
    5958                              carbox, methane,condmetsurf,condcosurf,         &
    6059                              oldplutovdifc,oldplutocorrk,oldplutosedim,      &
    61                               aerohaze,haze_proffix,haze_radproffix,          &
     60                              optichaze,haze_proffix,haze_radproffix,         &
    6261                              source_haze, tsurfmax, albmin_ch4,              &
    63                               season, sedimentation,generic_condensation,     &
     62                              season, sedimentation,                          &
    6463                              specOLR,                                        &
    6564                              startphy_file, testradtimes,                    &
     
    6766                              global1d, szangle,                              &
    6867                              callmufi
    69       use generic_tracer_index_mod, only: generic_tracer_index
    7068      use check_fields_mod, only: check_physics_fields
    7169      use conc_mod, only: rnew, cpnew, ini_conc_mod
     
    7876      use turb_mod, only : q2,sensibFlux,turb_resolved
    7977      use mass_redistribution_mod, only: mass_redistribution
    80       use condensation_generic_mod, only: condensation_generic
    8178      use datafile_mod, only: datadir
    8279      USE vertical_layers_mod, ONLY: ap,bp,aps,bps,presnivs,pseudoalt
     
    295292      real omega(ngrid,nlayer)            ! omega velocity (Pa/s, >0 when downward)
    296293
    297       integer i,l,ig,ierr,iq,nw,isoil,iesp, igcm_generic_gas, igcm_generic_ice
    298       logical call_ice_gas_generic ! to call only one time the ice/vap pair of a tracer
     294      integer i,l,ig,ierr,iq,nw,isoil,iesp
    299295
    300296      real zls                       ! Solar longitude (radians).
     
    316312      ! For Atmospheric Temperatures : (K/s)
    317313      real dtlscale(ngrid,nlayer)                             ! Largescale routine.
    318       real dt_generic_condensation(ngrid,nlayer)              ! condensation_generic routine.
    319314      real zdtc(ngrid,nlayer)                                 ! Condense_n2 routine.
    320315      real zdtdif(ngrid,nlayer)                               ! Turbdiff/vdifc routines.
     
    338333      real zdqsed(ngrid,nlayer,nq)    ! Callsedim routine.
    339334      real zdqmr(ngrid,nlayer,nq)     ! Mass_redistribution routine.
    340       real dqvaplscale_generic(ngrid,nlayer,nq) ! condensation_generic routine.
    341       real dqcldlscale_generic(ngrid,nlayer,nq) ! condensation_generic routine.
    342335      REAL,allocatable,save :: zdqchim(:,:,:) ! Calchim_asis routine
    343336      REAL,allocatable,save :: zdqschim(:,:)  ! Calchim_asis routine
     
    466459      real dItot, dItot_tmp, dVtot, dVtot_tmp
    467460      real dWtot, dWtot_tmp, dWtots, dWtots_tmp
    468       real psat_tmp ! AF24: to remove?
    469 
    470       real qsat_generic(ngrid,nlayer,nq) ! generic condensable tracers (GCS) specific concentration at saturation (kg/kg_of_air).
    471       real RH_generic(ngrid,nlayer,nq)   ! generic condensable tracers (GCS) Relative humidity.
    472       real rneb_generic(ngrid,nlayer,nq) ! GCS cloud fraction (generic condensation).
    473       real psat_tmp_generic
    474       real, save :: metallicity ! metallicity of planet --- is not used here, but necessary to call function Psat_generic
    475 !$OMP THREADPRIVATE(metallicity)
    476 
    477       real reffrad_generic_zeros_for_wrf(ngrid,nlayer) !  !!! this is temporary, it is only a list of zeros, it will be replaced when a generic aerosol will be implemented
    478461
    479462      real nconsMAX, vdifcncons(ngrid), cadjncons(ngrid) ! Vdfic water conservation test. By RW
     
    650633         endif
    651634
    652 !        Set metallicity for GCS
    653 !        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    654          metallicity=0.0 ! default value --- is not used here but necessary to call function Psat_generic
    655          call getin_p("metallicity",metallicity) ! --- is not used here but necessary to call function Psat_generic
    656 
    657635         if (ngrid.ne.1) then ! Note : no need to create a restart file in 1d.
    658636            call physdem0("restartfi.nc",longitude,latitude,nsoilmx,ngrid,nlayer,nq, &
     
    677655            call setspv ! Basic visible properties.
    678656            call sugas_corrk       ! Set up gaseous absorption properties.
    679             if (aerohaze) then
     657            if (optichaze) then
    680658               call suaer_corrk       ! Set up aerosol optical properties.
    681659            endif
     
    754732
    755733!     Get Lyman alpha flux at specific Ls
    756       if (haze) then
     734      if (callmufi.or.haze) then
    757735         call lymalpha(zls,zfluxuv)
    758736         print*, 'Haze lyman-alpha zls,zfluxuv=',zls,zfluxuv
     
    10401018                  call abort
    10411019               endif
    1042                ! if(water) then !AF24: removed
    1043 
    1044                if(generic_condensation) then
    1045                   do iq=1,nq
    1046 
    1047                      call generic_tracer_index(nq,iq,igcm_generic_gas,igcm_generic_ice,call_ice_gas_generic)
    1048 
    1049                      if (call_ice_gas_generic) then ! to call only one time the ice/vap pair of a tracer
    1050 
    1051                         epsi_generic=constants_epsi_generic(iq)
    1052 
    1053                         muvar(1:ngrid,1:nlayer)=mugaz/(1.e0+(1.e0/epsi_generic-1.e0)*pq(1:ngrid,1:nlayer,igcm_generic_gas))
    1054                         muvar(1:ngrid,nlayer+1)=mugaz/(1.e0+(1.e0/epsi_generic-1.e0)*pq(1:ngrid,nlayer,igcm_generic_gas))
    1055 
    1056                      endif
    1057                   end do ! do iq=1,nq loop on tracers
    1058                ! take into account generic condensable specie (GCS) effect on mean molecular weight
    1059 
    1060                else
    1061                   muvar(1:ngrid,1:nlayer+1)=mugaz
    1062                endif
    1063 
    1064                ! if(ok_slab_ocean) then !AF24: removed
    10651020
    10661021               ! standard callcorrk
     
    10711026                               zdtlw,zdtsw,fluxsurf_lw,fluxsurf_sw,fluxtop_lw,   &
    10721027                               fluxabs_sw,fluxtop_dn,reffrad,tau_col,ptime,pday, &
    1073                                cloudfrac,totcloudfrac,.false.,                   &
    10741028                               firstcall,lastcall)
    10751029                  albedo_equivalent(1:ngrid)=albedo(1:ngrid,1)
     
    10771031                               fluxsurf_sw(1:ngrid)*(1.-albedo(1:ngrid,1))
    10781032               else
     1033                muvar(1:ngrid,1:nlayer+1)=mugaz
    10791034                call callcorrk(ngrid,nlayer,pq,nq,qsurf,  &
    10801035                              albedo,albedo_equivalent,emis,mu0,pplev,pplay,pt,   &
     
    10841039                              fluxabs_sw,fluxtop_dn,OLR_nu,OSR_nu,GSR_nu,         &
    10851040                              int_dtaui,int_dtauv,                                &
    1086                               tau_col,cloudfrac,totcloudfrac,                     &
    1087                               .false.,firstcall,lastcall)
     1041                              tau_col,firstcall,lastcall)
    10881042                  ! Radiative flux from the sky absorbed by the surface (W.m-2).
    10891043                  GSR=0.0
     
    12271181                          taux,tauy)
    12281182
    1229          else ! if (oldplutovdifc) .and. (UseTurbDiff)
     1183         else ! if .not. (oldplutovdifc) .and. (UseTurbDiff)
    12301184
    12311185            zdh(1:ngrid,1:nlayer)=pdt(1:ngrid,1:nlayer)/zpopsk(1:ngrid,1:nlayer)
     
    15481502         !   VI.1. Microphysics / Aerosol particles
    15491503         ! ----------------------------------------
    1550          ! Production for microphysics
    1551          IF (callmufi .and. call_haze_prod_pCH4) THEN
    1552             zdqphot_prec(:,:)   = 0.
    1553             zdqphot_ch4(:,:)    = 0.
    1554             pdqmufi_prod(:,:,:) = 0.
    1555 
    1556             call hazecloud(ngrid,nlayer,nq,ptimestep,                             &
    1557                            pplay,pplev,pq,pdq,dist_star,mu0,zfluxuv,pdqmufi_prod, &
    1558                            zdqphot_prec,zdqphot_ch4,zdqconv_prec,declin)
    1559          ENDIF ! end callmufi .and. .and.call_haze_prod_pCH4
    1560 
    15611504         ! Call of microphysics
    15621505         IF (callmufi) THEN
     1506
     1507            ! Production for microphysics
     1508            IF (call_haze_prod_pCH4) THEN
     1509               zdqphot_prec(:,:)   = 0.
     1510               zdqphot_ch4(:,:)    = 0.
     1511               pdqmufi_prod(:,:,:) = 0.
     1512               call hazecloud(ngrid,nlayer,nq,ptimestep,                             &
     1513                              pplay,pplev,pq,pdq,dist_star,mu0,zfluxuv,pdqmufi_prod, &
     1514                              zdqphot_prec,zdqphot_ch4,zdqconv_prec,declin)
     1515            ENDIF ! end call_haze_prod_pCH4
    15631516
    15641517            pdqmufi(:,:,:) = 0.
     
    15671520   
    15681521            pdq(:,:,:) = pdq(:,:,:) + pdqmufi(:,:,:)
     1522         
     1523         ELSE
     1524            IF (haze) THEN
     1525               zdqphot_prec(:,:) = 0.
     1526               zdqphot_ch4(:,:)  = 0.
     1527               zdqhaze(:,:,:)    = 0.
     1528               ! Forcing to a fixed haze profile if haze_proffix
     1529               if (haze_proffix.and.i_haze.gt.0.) then
     1530                  call haze_prof(ngrid,nlayer,zzlay,pplay,pt,  &
     1531                                 reffrad,profmmr)
     1532                  zdqhaze(:,:,i_haze)=(profmmr(:,:)-pq(:,:,igcm_haze))/ptimestep
     1533               else
     1534                  call hazecloud(ngrid,nlayer,nq,ptimestep,            &
     1535                     pplay,pplev,pq,pdq,dist_star,mu0,zfluxuv,zdqhaze, &
     1536                     zdqphot_prec,zdqphot_ch4,zdqconv_prec,declin)
     1537               endif
     1538               pdq(:,:,:) = pdq(:,:,:) + zdqhaze(:,:,:) ! Should be updated
     1539            ENDIF ! end haze
     1540
     1541            IF (fast.and.fasthaze) THEN
     1542               call prodhaze(ngrid,nlayer,nq,ptimestep,pplev,pq,pdq,dist_star, &
     1543                        mu0,declin,zdqprodhaze,zdqsprodhaze,gradflux,fluxbot,   &
     1544                        fluxlym_sol_bot,fluxlym_ipm_bot,flym_sol,flym_ipm)
     1545               DO ig=1,ngrid
     1546                  pdq(ig,1,igcm_ch4_gas)=pdq(ig,1,igcm_ch4_gas)+  &
     1547                                                zdqprodhaze(ig,igcm_ch4_gas)
     1548                  pdq(ig,1,igcm_prec_haze)=pdq(ig,1,igcm_prec_haze)+ &
     1549                                             zdqprodhaze(ig,igcm_prec_haze)
     1550                  pdq(ig,1,igcm_haze)=abs(pdq(ig,1,igcm_haze)+ &
     1551                                             zdqprodhaze(ig,igcm_haze))
     1552                  qsurf(ig,igcm_haze)= qsurf(ig,igcm_haze)+ &
     1553                                                zdqsprodhaze(ig)*ptimestep
     1554               ENDDO
     1555            ENDIF ! end fast.and.fasthaze
     1556
     1557            ! Sedimentation.
     1558            if (sedimentation) then
     1559               zdqsed(1:ngrid,1:nlayer,1:nq) = 0.0
     1560               zdqssed(1:ngrid,1:nq)  = 0.0
     1561               if (oldplutosedim)then
     1562                  call callsedim_pluto(ngrid,nlayer,ptimestep,    &
     1563                           pplev,zzlev,pt,pdt,rice_ch4,rice_co, &
     1564                           pq,pdq,zdqsed,zdqssed,nq,pphi)
     1565               else
     1566                  call callsedim(ngrid,nlayer,ptimestep,       &
     1567                           pplev,zzlev,pt,pdt,pq,pdq,        &
     1568                           zdqsed,zdqssed,nq,pphi)
     1569               endif
     1570               ! Whether it falls as rain or snow depends only on the surface temperature
     1571               pdq(1:ngrid,1:nlayer,1:nq) = pdq(1:ngrid,1:nlayer,1:nq) + zdqsed(1:ngrid,1:nlayer,1:nq)
     1572               dqsurf(1:ngrid,1:nq) = dqsurf(1:ngrid,1:nq) + zdqssed(1:ngrid,1:nq)
     1573            end if ! end of 'sedimentation'
     1574
    15691575         ENDIF ! end callmufi
    1570 
    1571          IF (haze) THEN
    1572             zdqphot_prec(:,:) = 0.
    1573             zdqphot_ch4(:,:)  = 0.
    1574             zdqhaze(:,:,:)    = 0.
    1575            
    1576             ! Forcing to a fixed haze profile if haze_proffix
    1577             if (haze_proffix.and.i_haze.gt.0.) then
    1578                call haze_prof(ngrid,nlayer,zzlay,pplay,pt,  &
    1579                               reffrad,profmmr)
    1580                zdqhaze(:,:,i_haze)=(profmmr(:,:)-pq(:,:,igcm_haze))/ptimestep
    1581             else
    1582                call hazecloud(ngrid,nlayer,nq,ptimestep,            &
    1583                   pplay,pplev,pq,pdq,dist_star,mu0,zfluxuv,zdqhaze, &
    1584                   zdqphot_prec,zdqphot_ch4,zdqconv_prec,declin)
    1585             endif
    1586 
    1587             pdq(:,:,:) = pdq(:,:,:) + zdqhaze(:,:,:) ! Should be updated
    1588          ENDIF ! end haze
    1589 
    1590          IF (fast.and.fasthaze) THEN
    1591             call prodhaze(ngrid,nlayer,nq,ptimestep,pplev,pq,pdq,dist_star, &
    1592                      mu0,declin,zdqprodhaze,zdqsprodhaze,gradflux,fluxbot,   &
    1593                      fluxlym_sol_bot,fluxlym_ipm_bot,flym_sol,flym_ipm)
    1594 
    1595             DO ig=1,ngrid
    1596                pdq(ig,1,igcm_ch4_gas)=pdq(ig,1,igcm_ch4_gas)+  &
    1597                                              zdqprodhaze(ig,igcm_ch4_gas)
    1598                pdq(ig,1,igcm_prec_haze)=pdq(ig,1,igcm_prec_haze)+ &
    1599                                           zdqprodhaze(ig,igcm_prec_haze)
    1600                pdq(ig,1,igcm_haze)=abs(pdq(ig,1,igcm_haze)+ &
    1601                                           zdqprodhaze(ig,igcm_haze))
    1602                qsurf(ig,igcm_haze)= qsurf(ig,igcm_haze)+ &
    1603                                              zdqsprodhaze(ig)*ptimestep
    1604             ENDDO
    1605          ENDIF ! end fast.and.fasthaze
    1606 
    1607          ! Generic Condensation
    1608          if (generic_condensation) then
    1609             call condensation_generic(ngrid,nlayer,nq,ptimestep,pplev,pplay,   &
    1610                                           pt,pq,pdt,pdq,dt_generic_condensation, &
    1611                                           dqvaplscale_generic,dqcldlscale_generic,rneb_generic)
    1612             pdt(1:ngrid,1:nlayer) = pdt(1:ngrid,1:nlayer)+dt_generic_condensation(1:ngrid,1:nlayer)
    1613             pdq(1:ngrid,1:nlayer,1:nq) = pdq(1:ngrid,1:nlayer,1:nq)+dqvaplscale_generic(1:ngrid,1:nlayer,1:nq)
    1614             pdq(1:ngrid,1:nlayer,1:nq) = pdq(1:ngrid,1:nlayer,1:nq)+dqcldlscale_generic(1:ngrid,1:nlayer,1:nq)
    1615 
    1616             if(enertest)then
    1617                do ig=1,ngrid
    1618                   genericconddE(ig) = cpp*SUM(mass(:,:)*dt_generic_condensation(:,:))
    1619                enddo
    1620 
    1621                call planetwide_sumval(cpp*massarea(:,:)*dt_generic_condensation(:,:)/totarea_planet,dEtot)
    1622 
    1623                if (is_master) print*,'In generic condensation atmospheric energy change =',dEtot,' W m-2'
    1624             end if
    1625 
    1626                ! Let's loop on tracers
    1627                cloudfrac(:,:)=0.0
    1628                do iq=1,nq
    1629                   call generic_tracer_index(nq,iq,igcm_generic_gas,igcm_generic_ice,call_ice_gas_generic)
    1630                   if (call_ice_gas_generic) then ! to call only one time the ice/vap pair of a tracer
    1631                      do l = 1, nlayer
    1632                         do ig=1,ngrid
    1633                            cloudfrac(ig,l)=rneb_generic(ig,l,iq)
    1634                         enddo
    1635                      enddo
    1636                   endif
    1637             end do ! do iq=1,nq loop on tracers
    1638             ! endif ! .not. water
    1639 
    1640          endif !generic_condensation
    1641 
    1642          ! Sedimentation.
    1643          if (sedimentation) then
    1644 
    1645             zdqsed(1:ngrid,1:nlayer,1:nq) = 0.0
    1646             zdqssed(1:ngrid,1:nq)  = 0.0
    1647 
    1648             if (oldplutosedim)then
    1649                call callsedim_pluto(ngrid,nlayer,ptimestep,    &
    1650                           pplev,zzlev,pt,pdt,rice_ch4,rice_co, &
    1651                           pq,pdq,zdqsed,zdqssed,nq,pphi)
    1652 
    1653             else
    1654                call callsedim(ngrid,nlayer,ptimestep,       &
    1655                           pplev,zzlev,pt,pdt,pq,pdq,        &
    1656                           zdqsed,zdqssed,nq,pphi)
    1657             endif
    1658 
    1659             ! Whether it falls as rain or snow depends only on the surface temperature
    1660             pdq(1:ngrid,1:nlayer,1:nq) = pdq(1:ngrid,1:nlayer,1:nq) + zdqsed(1:ngrid,1:nlayer,1:nq)
    1661             dqsurf(1:ngrid,1:nq) = dqsurf(1:ngrid,1:nq) + zdqssed(1:ngrid,1:nq)
    1662 
    1663          end if ! end of 'sedimentation'
    16641576
    16651577  ! ---------------
     
    19991911      endif ! end of 'tracer'
    20001912
    2001 
    2002 
    2003       ! Calculate RH_generic (Generic Relative Humidity) for diagnostic.
    2004       if(generic_condensation)then
    2005          RH_generic(:,:,:)=0.0
    2006          do iq=1,nq
    2007 
    2008             call generic_tracer_index(nq,iq,igcm_generic_gas,igcm_generic_ice,call_ice_gas_generic)
    2009 
    2010             if (call_ice_gas_generic) then ! to call only one time the ice/vap pair of a tracer
    2011 
    2012                do l = 1, nlayer
    2013                   do ig=1,ngrid
    2014                      call Psat_generic(zt(ig,l),pplay(ig,l),metallicity,psat_tmp_generic,qsat_generic(ig,l,iq))
    2015                      RH_generic(ig,l,iq) = zq(ig,l,igcm_generic_gas) / qsat_generic(ig,l,iq)
    2016                   enddo
    2017                enddo
    2018 
    2019             end if
    2020 
    2021          end do ! iq=1,nq
    2022 
    2023       endif ! end of 'generic_condensation'
    2024 
    2025 
    20261913      if (methane) then
    20271914         IF (fast) then ! zq is the mixing ratio supposingly mixed in all atmosphere
     
    20641951      zrho_haze(:,:)=0.
    20651952      zdqrho_photprec(:,:)=0.
    2066       IF (haze.and.aerohaze) then
     1953      IF (haze.and.optichaze) then
    20671954         DO ig=1,ngrid
    20681955            DO l=1,nlayer
     
    23122199            call write_output("dEzradlw","radiative heating","w.m^-2",dEzradlw)
    23132200         endif
    2314 
    2315          if (generic_condensation) then
    2316             call write_output("genericconddE","heat from generic condensation","W m-2",genericconddE)
    2317             call write_output("dt_generic_condensation","heating from generic condensation","K s-1",dt_generic_condensation)
    2318          endif
    2319 
    23202201      endif ! end of 'enertest'
    23212202
     
    24482329            endif
    24492330
    2450            if (aerohaze) then
     2331           if (optichaze) then
    24512332              call write_output("tau_col",&
    24522333                 "Total aerosol optical depth","opacity",tau_col)
  • trunk/LMDZ.PLUTO/libf/phypluto/radii_mod.F90

    r3353 r3572  
    2929      use radinc_h, only: naerkind
    3030      use datafile_mod, only: hazerad_file
    31       use aerosol_mod, only: iaero_haze, i_haze, &
    32                               iaero_generic, i_rgcs_ice
    33       use callkeys_mod, only: nlayaero, aeronlay_size, &
    34                               aeronlay_nueff,aerogeneric
     31      use aerosol_mod, only: iaero_haze, i_haze
    3532      use tracer_h, only: radius, nqtot, is_rgcs, nmono
    3633      Implicit none
  • trunk/LMDZ.PLUTO/libf/phypluto/suaer_corrk.F90

    r3504 r3572  
    1616      use radcommon_h, only: radiustab,nsize,tstellar
    1717      use radcommon_h, only: qrefvis,qrefir,omegarefir !,omegarefvis
    18       use aerosol_mod, only: noaero,iaero_haze
    19       use callkeys_mod, only: tplanet, optprop_back2lay_vis, optprop_back2lay_ir, &
    20                               optprop_aeronlay_vis, optprop_aeronlay_ir,          &
    21                               aeronlay_lamref, nlayaero,aerogeneric
     18      use aerosol_mod, only: iaero_haze
     19      use callkeys_mod, only: tplanet
    2220      use tracer_h, only: noms
    2321
     
    130128      ! allocate file_id, as naerkind is a variable
    131129      allocate(file_id(naerkind,2))
    132 
    133       ! if (noaero) then
    134       !   print*, 'naerkind= 0'
    135       !   naerkind=0
    136       ! endif
    137 
    138130
    139131      do iaer=1,naerkind
  • trunk/LMDZ.PLUTO/libf/phypluto/tracer_h.F90

    r3557 r3572  
    6262       real, save, allocatable :: constants_Tref(:)                 ! Ref temperature for Clausis-Clapeyron (K)
    6363       real, save, allocatable :: constants_Pref(:)                 ! Reference pressure for Clausius Clapeyron (Pa)
    64        real, save, allocatable :: constants_epsi_generic(:)         ! fractionnal molecular mass (m/mugaz)
    6564       real, save, allocatable :: constants_RLVTT_generic(:)        ! Latent heat of vaporization (J/kg)
    66        real, save, allocatable :: constants_metallicity_coeff(:)    ! Coefficient to take into account the metallicity
    6765       real, save, allocatable :: constants_RCPV_generic(:)         ! specific heat capacity of the tracer vapor at Tref
    6866!$OMP THREADPRIVATE(constants_mass,constants_delta_gasH,constants_Tref)
    69 !$OMP THREADPRIVATE(constants_Pref,constants_epsi_generic)
    70 !$OMP THREADPRIVATE(constants_RLVTT_generic,constants_metallicity_coeff,constants_RCPV_generic)
     67!$OMP THREADPRIVATE(constants_Pref)
     68!$OMP THREADPRIVATE(constants_RLVTT_generic,constants_RCPV_generic)
    7169
    7270! tracer indexes: these are initialized in initracer and should be 0 if the
Note: See TracChangeset for help on using the changeset viewer.