Changeset d56bfae in flexpart.git


Ignore:
Timestamp:
Feb 6, 2017, 9:25:56 AM (2 years ago)
Author:
Sabine <sabine.eckhardt@…>
Branches:
dev, release-10, univie
Children:
75a4ded
Parents:
0539b8f
Message:

scavenging moved to before advance - for testing _timeama!

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/timemanager.f90

    r278f4ed rd56bfae  
    132132  loutend=loutnext+loutaver/2
    133133
     134  !  open(127,file=path(2)(1:length(2))//'depostat.dat'
     135  !    +  ,form='unformatted')
     136  !write (*,*) 'writing deposition statistics depostat.dat!'
    134137
    135138  !**********************************************************************
     
    144147!CGZ-lifetime: set lifetime to 0
    145148 
    146   if (interpolhmix) write(*,*) 'Interpolating hmix'
    147   if (.not.usekernel) write(*,*) 'Not using the kernel'
    148 
    149149  write(*,46) float(itime)/3600,itime,numpart
    150150
     
    311311  !   if (itime.eq.loutnext) then
    312312  !   do 247 ksp=1, nspec
    313   !    247 kp=1, maxpointspec_act
     313  !   do 247 kp=1, maxpointspec_act
    314314  !47         xm(ksp,kp)=0.
    315315
     
    355355      if (mod(itime-loutstart,loutsample).eq.0) then
    356356
    357    
    358     do j=1,numpart
    359   ! RECEPTOR: dry/wet depovel
    360   !****************************
    361   ! Before the particle is moved
    362   ! the calculation of the scavenged mass shall only be done once after release
    363   ! xscav_frac1 was initialised with a negative value
    364 
    365 !      write (*,*) 'out:',j,xtra1(j),ytra1(j),prob_rec(1),xscav_frac1(j,1)
    366       if  (DRYBKDEP) then
    367        do ks=1,nspec
    368          if  ((xscav_frac1(j,ks).lt.0)) then
    369             call get_vdep_prob(itime,xtra1(j),ytra1(j),ztra1(j),prob_rec)
    370             if (DRYDEPSPEC(ks)) then        ! dry deposition
    371 !        write (*,*) 'j,..:',j,xtra1(j),ytra1(j),prob_rec(1),xscav_frac1(j,1)
    372                xscav_frac1(j,ks)=prob_rec(ks)
    373              else
    374                 xmass1(j,ks)=0
    375                 xscav_frac1(j,ks)=0.
    376              endif
    377          endif
    378         enddo
    379        endif
    380 
    381        if (WETBKDEP) then
    382        do ks=1,nspec
    383          if  ((xscav_frac1(j,ks).lt.0)) then
    384             call get_wetscav(itime,lsynctime,loutnext,j,ks,grfraction,idummy,idummy,wetscav)
    385             if (wetscav(ks).gt.0) then
    386                 xscav_frac1(j,ks)=wetscav(ks)* &
    387                        (zpoint2(npoint(j))-zpoint1(npoint(j)))*grfraction(1)
    388             else
    389                 xmass1(j,ks)=0.
    390                 xscav_frac1(j,ks)=0.
    391             endif
    392          endif
    393         enddo
    394        endif
    395 
    396   enddo
    397 
    398357  ! If we are exactly at the start or end of the concentration averaging interval,
    399358  ! give only half the weight to this sample
     
    584543        zold=ztra1(j)
    585544
     545   
     546  ! RECEPTOR: dry/wet depovel
     547  !****************************
     548  ! Before the particle is moved
     549  ! the calculation of the scavenged mass shall only be done once after release
     550  ! xscav_frac1 was initialised with a negative value
     551
     552      if  (DRYBKDEP) then
     553       do ks=1,nspec
     554         if  ((xscav_frac1(j,ks).lt.0)) then
     555            call get_vdep_prob(itime,xtra1(j),ytra1(j),ztra1(j),prob_rec)
     556            if (DRYDEPSPEC(ks)) then        ! dry deposition
     557               xscav_frac1(j,ks)=prob_rec(ks)
     558             else
     559                xmass1(j,ks)=0
     560                xscav_frac1(j,ks)=0.
     561             endif
     562         endif
     563        enddo
     564       endif
     565
     566       if (WETBKDEP) then
     567       do ks=1,nspec
     568         if  ((xscav_frac1(j,ks).lt.0)) then
     569            call get_wetscav(itime,lsynctime,loutnext,j,ks,grfraction,idummy,idummy,wetscav)
     570            if (wetscav(ks).gt.0) then
     571                xscav_frac1(j,ks)=wetscav(ks)* &
     572                       (zpoint2(npoint(j))-zpoint1(npoint(j)))*grfraction(1)
     573            else
     574                xmass1(j,ks)=0.
     575                xscav_frac1(j,ks)=0.
     576            endif
     577         endif
     578        enddo
     579       endif
    586580
    587581  ! Integrate Lagevin equation for lsynctime seconds
     
    594588        endif
    595589     
    596 !        write (*,*) ' before advanced: ',j,prob(1),xmass1(j,1),ztra1(j)
    597590        call advance(itime,npoint(j),idt(j),uap(j),ucp(j),uzp(j), &
    598591             us(j),vs(j),ws(j),nstop,xtra1(j),ytra1(j),ztra1(j),prob, &
    599592             cbt(j))
    600         if (ztra1(j).lt.30) then
    601 !        write (*,*) 'advanced: ',ztra1(j),j,xtra1(j),ytra1(j)
    602         endif
     593!        write (*,*) 'advance: ',prob(1),xmass1(j,1),ztra1(j)
    603594
    604595  ! Calculate the gross fluxes across layer interfaces
Note: See TracChangeset for help on using the changeset viewer.
hosted by ZAMG