source: branches/petra/src/com_mod.f90 @ 36

Last change on this file since 36 was 36, checked in by pesei, 7 years ago

Implement switch for incremental deposition, see ticket:113 and many small changes, see changelog.txt

  • Property svn:executable set to *
File size: 31.2 KB
Line 
1!**********************************************************************
2! Copyright 1998-2015                                                 *
3! Andreas Stohl, Petra Seibert, A. Frank, Gerhard Wotawa,             *
4! Caroline Forster, Sabine Eckhardt, John Burkhart, Harald Sodemann   *
5!                                                                     *
6! This file is part of FLEXPART.                                      *
7!                                                                     *
8! FLEXPART is free software: you can redistribute it and/or modify    *
9! it under the terms of the GNU General Public License as published by*
10! the Free Software Foundation, either version 3 of the License, or   *
11! (at your option) any later version.                                 *
12!                                                                     *
13! FLEXPART is distributed in the hope that it will be useful,         *
14! but WITHOUT ANY WARRANTY; without even the implied warranty of      *
15! MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the       *
16! GNU General Public License for more details.                        *
17!                                                                     *
18! You should have received a copy of the GNU General Public License   *
19! along with FLEXPART.  If not, see <http://www.gnu.org/licenses/>.   *
20!**********************************************************************
21
22module com_mod
23
24!*******************************************************************************
25!        Include file for particle diffusion model FLEXPART                    *
26!        This file contains a global common block used by FLEXPART             *
27!                                                                              *
28!        Author: A. Stohl                                                      *
29!                                                                              *
30!        June 1996                                                             *
31!                                                                              *
32!        Modifications: 15 August 2013 IP,
33!        2/2015 PS, add incremental deposition switch
34!                                                                              *
35!*******************************************************************************
36
37  use par_mod, only: dp, numpath, maxnests, maxageclass, maxspec, ni, &
38       numclass, nymax, nxmax, maxcolumn, maxwf, nzmax, nxmaxn, nymaxn, &
39       maxreceptor, maxpart, maxrand, nwzmax, nuvzmax
40
41  implicit none
42
43  !****************************************************************
44  ! Variables defining where FLEXPART input/output files are stored
45  !****************************************************************
46
47  character :: path(numpath+2*maxnests)*120
48  integer :: length(numpath+2*maxnests)
49  character(len=256) :: pathfile, flexversion, arg1, arg2
50 
51  ! path                    path names needed for trajectory model
52  ! length                  length of path names needed for trajectory model
53  ! pathfile                file where pathnames are stored
54  ! flexversion             version of flexpart
55  ! arg                     input arguments from launch at command line
56
57  !********************************************************
58  ! Variables defining the general model run specifications
59  !********************************************************
60
61  integer :: ibdate,ibtime,iedate,ietime
62  real(kind=dp) :: bdate,edate
63
64
65  ! ibdate                  beginning date (YYYYMMDD)
66  ! ibtime                  beginning time (HHMISS)
67  ! iedate                  ending date (YYYYMMDD)
68  ! ietime                  ending time (HHMISS)
69  ! bdate                   beginning date of simulation (julian date)
70  ! edate                   ending date of simulation (julian date)
71
72
73  integer :: ldirect,ideltas
74
75  ! ldirect                 1 for forward, -1 for backward simulation
76  ! ideltas                 length of trajectory loop from beginning to
77  !                    ending date (s)
78
79  integer :: loutstep,loutaver,loutsample,method,lsynctime
80  real :: outstep
81
82  ! loutstep [s]            gridded concentration output every loutstep seconds
83  ! loutaver [s]            concentration output is an average over [s] seconds
84  ! loutsample [s]          sampling interval of gridded concentration output
85  ! lsynctime [s]           synchronisation time of all particles
86  ! method                  indicator which dispersion method is to be used
87  ! outstep = real(abs(loutstep))
88
89  real :: ctl,fine
90  integer :: ifine,iout,ipout,ipin,iflux,mdomainfill
91  integer :: mquasilag,nested_output,ind_source,ind_receptor
92  integer :: ind_rel,ind_samp,ioutputforeachrelease,linit_cond,surf_only
93  logical :: turbswitch, ldep_incr
94
95  ! ctl      factor, by which time step must be smaller than Lagrangian time scale
96  ! ifine    reduction factor for time step used for vertical wind
97  !     Langevin equation for the vertical wind component
98  ! ioutputforeachrelease Should each release be a seperate output field?
99  ! iflux    flux calculation options: 1 calculation of fluxes, 2 no fluxes
100  ! iout     output options: 1 conc. output (ng/m3), 2 mixing ratio (pptv), 3 both
101  ! ipout    particle dump options: 0 no, 1 every output interval, 2 only at end
102  ! ipin     read in particle positions from dumped file from a previous run
103  ! fine     real(ifine)
104  ! mdomainfill 0: normal run
105  !        1: particles are initialized according to atmospheric mass distribution
106  ! ind_source switches between different units for concentrations at the source
107  !  NOTE that in backward simulations the release of computational particles
108  !  takes place at the "receptor" and the sampling of particles at the "source".
109  !     1= mass units
110  !     2= mass mixing ratio units
111  ! ind_receptor switches between different units for FLEXPART concentration at the receptor
112  !     1= mass units
113  !     2= mass mixing ratio units
114  ! linit_cond  switch on the output of sensitivity to initial conditions for backward runs
115  !     0=no, 1=mass unit, 2=mass mixing ratio unit
116  ! mquasilag 0: normal run
117  !      1: Particle position output is produced in a condensed format and particles are numbered
118  ! surf_only   switch output in grid_time files for surface only or full vertical resolution
119  !      0=no (full vertical resolution), 1=yes (surface only)
120  ! nested_output: 0 no, 1 yes
121  ! turbswitch              determines how the Markov chain is formulated
122  ! ldep_incr: .true. incremental deposition, .false. accumulated deposition
123
124  ! ind_rel and ind_samp  are used within the code to change between mass and mass-mix (see readcommand.f)
125
126
127  integer :: mintime,itsplit
128
129  ! mintime                 minimum time step to be used by FLEXPART
130  ! itsplit                 time constant for splitting particles
131
132  integer :: lsubgrid,lconvection,lagespectra
133
134  ! lsubgrid     1 if subgrid topography parameterization switched on, 2 if not
135  ! lconvection  1 if convection parameterization switched on, 0 if not
136  ! lagespectra  1 if age spectra calculation switched on, 2 if not
137
138  integer :: lnetcdfout
139  ! lnetcdfout   1 for netcdf grid output, 0 if not. Set in COMMAND (namelist input)
140
141  integer :: nageclass,lage(maxageclass)
142
143  ! nageclass               number of ageclasses for the age spectra calculation
144  ! lage [s]                ageclasses for the age spectra calculation
145
146
147  logical :: gdomainfill
148
149  ! gdomainfill             .T., if domain-filling is global, .F. if not
150
151
152
153  !*********************************************************************
154  ! Variables defining the release locations, released species and their
155  ! properties, etc.
156  !*********************************************************************
157
158  !change Sabine Eckhardt, only save the first 1000 identifier for releasepoints
159  character :: compoint(1001)*45
160  integer :: numpoint
161  !SE, now dynamically allocated:
162  ! ireleasestart(maxpoint),ireleaseend(maxpoint)
163  !      real xpoint1(maxpoint),ypoint1(maxpoint)
164  !real xpoint2(maxpoint),ypoint2(maxpoint)
165  !real zpoint1(maxpoint),zpoint2(maxpoint)
166  !integer*2 kindz(maxpoint)
167  integer :: specnum(maxspec)
168  !real xmass(maxpoint,maxspec)
169  real :: decay(maxspec)
170  real :: weta(maxspec),wetb(maxspec)
171! NIK: 31.01.2013- parameters for in-cloud scavening
172  real :: weta_in(maxspec), wetb_in(maxspec), wetc_in(maxspec), wetd_in(maxspec)
173  real :: reldiff(maxspec),henry(maxspec),f0(maxspec)
174  real :: density(maxspec),dquer(maxspec),dsigma(maxspec)
175  real :: vsetaver(maxspec),cunningham(maxspec),weightmolar(maxspec)
176  real :: vset(maxspec,ni),schmi(maxspec,ni),fract(maxspec,ni)
177  real :: ri(5,numclass),rac(5,numclass),rcl(maxspec,5,numclass)
178  real :: rgs(maxspec,5,numclass),rlu(maxspec,5,numclass)
179  real :: rm(maxspec),dryvel(maxspec),kao(maxspec),ohreact(maxspec)
180  ! SE  it is possible to associate a species with a second one to make transfer from gas to aerosol
181  integer :: spec_ass(maxspec)
182
183  real :: area_hour(maxspec,24),point_hour(maxspec,24)
184  real :: area_dow(maxspec,7),point_dow(maxspec,7)
185
186  !integer npart(maxpoint)
187  integer :: nspec,maxpointspec_act
188  character(len=10) :: species(maxspec)
189
190
191  ! compoint                comment, also "name" of each starting point
192  ! numpoint                actual number of trajectory starting/ending points
193  ! ireleasestart,ireleaseend [s] starting and ending time of each release
194  ! xmass                   total mass emitted
195  ! xpoint1,ypoint1         lower left coordinates of release area
196  ! xpoint2,ypoint2         upper right coordinates of release area
197  ! zpoint1,zpoint2         min./max. z-coordinates of release points
198  ! kindz                   1: zpoint is in m agl, 2: zpoint is in m asl
199  ! npart                   number of particles per release point
200  ! nspec                   number of different species allowed for one release
201  ! maxpointspec_act        number of releaspoints for which a different output shall be created
202  ! species                 name of species
203  ! decay                   decay constant of radionuclide
204
205  ! WET DEPOSITION
206  ! weta, wetb              parameters for determining below-cloud wet scavenging coefficients
207  ! weta_in, wetb_in       parameters for determining in-cloud wet scavenging coefficients
208  ! wetc_in, wetd_in       parameters for determining in-cloud wet scavenging coefficients
209
210  ! GAS DEPOSITION
211  ! reldiff                 diffusivitiy of species relative to diff. of H2O
212  ! henry [M/atm]           Henry constant
213  ! f0                      reactivity relative to that of O3
214  ! ri [s/m]                stomatal resistance
215  ! rcl [s/m]               lower canopy resistance
216  ! rgs [s/m]               ground resistance
217  ! rlu [s/m]               leaf cuticular resistance
218  ! rm [s/m]                mesophyll resistance
219  ! dryvel [m/s]            constant dry deposition velocity
220
221  ! PARTICLE DEPOSITION
222  ! density [kg/m3]         density of particles
223  ! dquer [m]               mean diameter of particles
224  ! dsigma                  dsigma=10 or dsigma=0.1 means that 68% of the
225  !                    mass are between 0.1*dquer and 10*dquer
226
227  ! fract                   mass fraction of each diameter interval
228  ! vset [m/s]              gravitational settling velocity in ni intervals
229  ! cunningham              Cunningham slip correction (strictly valid only near surface)
230  ! vsetaver [m/s]          average gravitational settling velocity
231  ! schmi                   Schmidt number**2/3 of each diameter interval
232  ! weightmolar [g/mol]     molecular weight
233
234  ! TIME VARIATION OF EMISSION
235  ! area_hour, point_hour   daily variation of emission strengths for area and point sources
236  ! area_dow, point_dow     day-of-week variation of emission strengths for area and point sources
237
238
239
240  !**********************************************************
241  ! Variables used for domain-filling trajectory calculations
242  !**********************************************************
243
244  integer :: nx_we(2),ny_sn(2)
245  integer :: numcolumn
246  integer :: numcolumn_we(2,0:nymax-1),numcolumn_sn(2,0:nxmax-1)
247  real :: zcolumn_we(2,0:nymax-1,maxcolumn)
248  real :: zcolumn_sn(2,0:nxmax-1,maxcolumn)
249  real :: xmassperparticle
250  real :: acc_mass_we(2,0:nymax-1,maxcolumn)
251  real :: acc_mass_sn(2,0:nxmax-1,maxcolumn)
252
253  ! nx_we(2)                x indices of western and eastern boundary of domain-filling
254  ! ny_sn(2)                y indices of southern and northern boundary of domain-filling
255  ! numcolumn_we            number of particles to be released within one column
256  !                    at the western and eastern boundary surfaces
257  ! numcolumn_sn            same as numcolumn_we, but for southern and northern domain boundary
258  ! numcolumn               maximum number of particles to be released within a single
259  !                    column
260  ! zcolumn_we              altitudes where particles are to be released
261  !                    at the western and eastern boundary surfaces
262  ! zcolumn_sn              same as zcolumn_we, but for southern and northern domain boundary
263  ! xmassperparticle        air mass per particle in the domain-filling traj. option
264  ! acc_mass_we             mass that has accumulated at the western and eastern boundary;
265  !                    if it exceeds xmassperparticle, a particle is released and
266  !                    acc_mass_we is reduced accordingly
267  ! acc_mass_sn             same as acc_mass_we, but for southern and northern domain boundary
268
269
270
271  !******************************************************************************
272  ! Variables associated with the ECMWF meteorological input data ("wind fields")
273  !******************************************************************************
274
275  integer :: numbwf,wftime(maxwf),lwindinterv
276  character(len=255) :: wfname(maxwf),wfspec(maxwf)
277
278  ! lwindinterv [s]         Interval between wind fields currently in memory
279  ! numbwf                  actual number of wind fields
280  ! wftime(maxwf) [s]       times relative to beginning time of wind fields
281  ! wfname(maxwf)           file names of wind fields
282  ! wfspec(maxwf)           specifications of wind field file, e.g. if on hard
283  !                    disc or on tape
284
285  integer :: memtime(2),memind(2)
286
287  ! memtime [s]             validation times of wind fields in memory
288  ! memind                  pointer to wind field, in order to avoid shuffling
289  !                    of wind fields
290
291
292
293  !****************************************************************************
294  ! Variables defining actual size and geographical location of the wind fields
295  !****************************************************************************
296
297  integer :: nx,ny,nxmin1,nymin1,nxfield,nuvz,nwz,nz,nmixz,nlev_ec
298  real :: dx,dy,xlon0,ylat0,dxconst,dyconst,height(nzmax)
299
300  ! nx,ny,nz                actual dimensions of wind fields in x,y and z
301  !                    direction, respectively
302  ! nxmin1,nymin1           nx-1, ny-1, respectively
303  ! nuvz,nwz                vertical dimension of original ECMWF data
304  ! nxfield                 same as nx for limited area fields,
305  !                    but for global fields nx=nxfield+1
306  ! nmixz                   number of levels up to maximum PBL height (3500 m)
307
308  ! nuvz is used for u,v components
309  ! nwz is used for w components (staggered grid)
310  ! nz is used for the levels in transformed coordinates (terrain-following Cartesian
311  ! coordinates)
312
313  ! nlev_ec  number of levels ECMWF model
314  ! dx                      grid distance in x direction
315  ! dy                      grid distance in y direction
316  ! dxconst,dyconst         auxiliary variables for utransform,vtransform
317  ! height                  heights of all levels
318  ! xlon0                   geographical longitude and
319  ! ylat0                   geographical latitude of lower left grid point
320
321
322
323  !*************************************************
324  ! Variables used for vertical model discretization
325  !*************************************************
326
327  real :: akm(nwzmax),bkm(nwzmax)
328  real :: akz(nuvzmax),bkz(nuvzmax)
329  real :: aknew(nzmax),bknew(nzmax)
330
331  ! akm,bkm: coeffizients which regulate vertical discretization of ecmwf model
332  !     (at the border of model layers)
333  ! akz,bkz: model discretization coeffizients at the centre of the layers
334  ! aknew,bknew model discretization coeffizients at the interpolated levels
335
336
337
338  ! Fixed fields, unchangeable with time
339  !*************************************
340
341  real :: oro(0:nxmax-1,0:nymax-1)
342  real :: excessoro(0:nxmax-1,0:nymax-1)
343  real :: lsm(0:nxmax-1,0:nymax-1)
344  real :: xlanduse(0:nxmax-1,0:nymax-1,numclass)
345
346  ! oro [m]              orography of the ECMWF model
347  ! excessoro            excess orography mother domain
348  ! lsm                  land sea mask of the ECMWF model
349  ! xlanduse [0-1]       area fractions in percent
350
351  ! 3d fields
352  !**********
353
354  real :: uu(0:nxmax-1,0:nymax-1,nzmax,2)
355  real :: vv(0:nxmax-1,0:nymax-1,nzmax,2)
356  real :: uupol(0:nxmax-1,0:nymax-1,nzmax,2)
357  real :: vvpol(0:nxmax-1,0:nymax-1,nzmax,2)
358  real :: ww(0:nxmax-1,0:nymax-1,nzmax,2)
359  real :: tt(0:nxmax-1,0:nymax-1,nzmax,2)
360  real :: qv(0:nxmax-1,0:nymax-1,nzmax,2)
361  real :: pv(0:nxmax-1,0:nymax-1,nzmax,2)
362  real :: rho(0:nxmax-1,0:nymax-1,nzmax,2)
363  real :: drhodz(0:nxmax-1,0:nymax-1,nzmax,2)
364  real :: tth(0:nxmax-1,0:nymax-1,nuvzmax,2)
365  real :: qvh(0:nxmax-1,0:nymax-1,nuvzmax,2)
366  real :: pplev(0:nxmax-1,0:nymax-1,nuvzmax,2)
367  integer(kind=1) :: clouds(0:nxmax-1,0:nymax-1,nzmax,2)
368  integer :: cloudsh(0:nxmax-1,0:nymax-1,2)
369
370
371  ! uu,vv,ww [m/2]       wind components in x,y and z direction
372  ! uupol,vvpol [m/s]    wind components in polar stereographic projection
373  ! tt [K]               temperature data
374  ! qv                   specific humidity data
375  ! pv (pvu)             potential vorticity
376  ! rho [kg/m3]          air density
377  ! drhodz [kg/m2]       vertical air density gradient
378  ! tth,qvh              tth,qvh on original eta levels
379  ! clouds:   no cloud, no precipitation   0
380  !      cloud, no precipitation      1
381  !      rainout  conv/lsp dominated  2/3
382  !      washout  conv/lsp dominated  4/5
383
384  ! pplev for the GFS version
385
386  ! 2d fields
387  !**********
388
389  real :: ps(0:nxmax-1,0:nymax-1,1,2)
390  real :: sd(0:nxmax-1,0:nymax-1,1,2)
391  real :: msl(0:nxmax-1,0:nymax-1,1,2)
392  real :: tcc(0:nxmax-1,0:nymax-1,1,2)
393  real :: u10(0:nxmax-1,0:nymax-1,1,2)
394  real :: v10(0:nxmax-1,0:nymax-1,1,2)
395  real :: tt2(0:nxmax-1,0:nymax-1,1,2)
396  real :: td2(0:nxmax-1,0:nymax-1,1,2)
397  real :: lsprec(0:nxmax-1,0:nymax-1,1,2)
398  real :: convprec(0:nxmax-1,0:nymax-1,1,2)
399  real :: sshf(0:nxmax-1,0:nymax-1,1,2)
400  real :: ssr(0:nxmax-1,0:nymax-1,1,2)
401  real :: surfstr(0:nxmax-1,0:nymax-1,1,2)
402  real :: ustar(0:nxmax-1,0:nymax-1,1,2)
403  real :: wstar(0:nxmax-1,0:nymax-1,1,2)
404  real :: hmix(0:nxmax-1,0:nymax-1,1,2)
405  real :: tropopause(0:nxmax-1,0:nymax-1,1,2)
406  real :: oli(0:nxmax-1,0:nymax-1,1,2)
407  real :: diffk(0:nxmax-1,0:nymax-1,1,2)
408
409  ! ps                   surface pressure
410  ! sd                   snow depth
411  ! msl                  mean sea level pressure
412  ! tcc                  total cloud cover
413  ! u10                  10 meter u
414  ! v10                  10 meter v
415  ! tt2                  2 meter temperature
416  ! td2                  2 meter dew point
417  ! lsprec [mm/h]        large scale total precipitation
418  ! convprec [mm/h]      convective precipitation
419  ! sshf                 surface sensible heat flux
420  ! ssr                  surface solar radiation
421  ! surfstr              surface stress
422  ! ustar [m/s]          friction velocity
423  ! wstar [m/s]          convective velocity scale
424  ! hmix  [m]            mixing height
425  ! tropopause [m]       altitude of thermal tropopause
426  ! oli [m]              inverse Obukhov length (1/L)
427  ! diffk [m2/s]         diffusion coefficient at reference height
428
429
430  real :: vdep(0:nxmax-1,0:nymax-1,maxspec,2)
431
432  ! vdep [m/s]           deposition velocities
433
434
435  !********************************************************************
436  ! Variables associated with the ECMWF input data (nested wind fields)
437  !********************************************************************
438
439  ! NOTE: all nested variables have the same name as the variables used
440  ! for the mother domain, except with a 'n' appended at the end
441  !********************************************************************
442
443  integer :: numbnests
444
445  ! numbnests    number of nested grids
446
447  character(len=255) :: wfnamen(maxnests,maxwf)
448  character(len=18) :: wfspecn(maxnests,maxwf)
449
450  ! wfnamen      nested wind field names
451  ! wfspecn      specifications of wind field file, e.g. if on hard
452  !         disc or on tape
453
454
455  !*********************************************************************
456  ! Variables characterizing size and location of the nested wind fields
457  !*********************************************************************
458
459  integer :: nxn(maxnests),nyn(maxnests)
460  real :: dxn(maxnests),dyn(maxnests),xlon0n(maxnests),ylat0n(maxnests)
461
462  ! nxn,nyn      actual dimensions of nested wind fields in x and y direction
463  ! dxn,dyn      grid distances in x,y direction for the nested grids
464  ! xlon0n       geographical longitude of lower left grid point of nested wind fields
465  ! ylat0n       geographical latitude of lower left grid point of nested wind fields
466
467
468  ! Nested fields, unchangeable with time
469  !**************************************
470
471  real :: oron(0:nxmaxn-1,0:nymaxn-1,maxnests)
472  real :: excessoron(0:nxmaxn-1,0:nymaxn-1,maxnests)
473  real :: lsmn(0:nxmaxn-1,0:nymaxn-1,maxnests)
474  real :: xlandusen(0:nxmaxn-1,0:nymaxn-1,numclass,maxnests)
475
476
477  ! 3d nested fields
478  !*****************
479
480  real :: uun(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
481  real :: vvn(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
482  real :: wwn(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
483  real :: ttn(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
484  real :: qvn(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
485  real :: pvn(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
486  integer(kind=1) :: cloudsn(0:nxmaxn-1,0:nymaxn-1,0:nzmax,2,maxnests)
487  integer :: cloudsnh(0:nxmaxn-1,0:nymaxn-1,2,maxnests)
488  real :: rhon(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
489  real :: drhodzn(0:nxmaxn-1,0:nymaxn-1,nzmax,2,maxnests)
490  real :: tthn(0:nxmaxn-1,0:nymaxn-1,nuvzmax,2,maxnests)
491  real :: qvhn(0:nxmaxn-1,0:nymaxn-1,nuvzmax,2,maxnests)
492
493  ! 2d nested fields
494  !*****************
495
496  real :: psn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
497  real :: sdn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
498  real :: msln(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
499  real :: tccn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
500  real :: u10n(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
501  real :: v10n(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
502  real :: tt2n(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
503  real :: td2n(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
504  real :: lsprecn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
505  real :: convprecn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
506  real :: sshfn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
507  real :: ssrn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
508  real :: surfstrn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
509  real :: ustarn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
510  real :: wstarn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
511  real :: hmixn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
512  real :: tropopausen(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
513  real :: olin(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
514  real :: diffkn(0:nxmaxn-1,0:nymaxn-1,1,2,maxnests)
515  real :: vdepn(0:nxmaxn-1,0:nymaxn-1,maxspec,2,maxnests)
516
517
518  !*************************************************
519  ! Certain auxiliary variables needed for the nests
520  !*************************************************
521
522  real :: xresoln(0:maxnests),yresoln(0:maxnests)
523
524  ! xresoln, yresoln   Factors by which the resolutions in the nests
525  !               are enhanced compared to mother grid
526
527  real :: xln(maxnests),yln(maxnests),xrn(maxnests),yrn(maxnests)
528
529  ! xln,yln,xrn,yrn    Corner points of nested grids in grid coordinates
530  !               of mother grid
531
532
533  !******************************************************
534  ! Variables defining the polar stereographic projection
535  !******************************************************
536
537  logical :: xglobal,sglobal,nglobal
538  real :: switchnorthg,switchsouthg
539
540  !xglobal             T for global fields, F for limited area fields
541  !sglobal             T if domain extends towards south pole
542  !nglobal             T if domain extends towards north pole
543  !switchnorthg,switchsouthg   same as parameters switchnorth,
544  !                    switchsouth, but in grid units
545
546  real :: southpolemap(9),northpolemap(9)
547
548  !southpolemap,northpolemap   define stereographic projections
549  !                    at the two poles
550
551
552  !******************
553  ! Landuse inventory
554  ! Sabine Eckhardt Dec 06: change to new landuse inventary - 11 classes, 1200 x 600 global
555  !******************
556
557  integer(kind=1) :: landinvent(1200,600,6)
558  real :: z0(numclass)
559
560  ! landinvent         landuse inventory (numclass=11 classes)
561  ! z0                  roughness length for the landuse classes
562
563
564
565  !**************************************************************************
566  ! Variables characterizing the output grid and containing the model results
567  !**************************************************************************
568
569  integer :: numxgrid,numygrid,numzgrid
570  real :: dxout,dyout,outlon0,outlat0,xoutshift,youtshift
571  integer :: numxgridn,numygridn
572  real :: dxoutn,dyoutn,outlon0n,outlat0n,xoutshiftn,youtshiftn
573  !real outheight(maxzgrid),outheighthalf(maxzgrid)
574  logical :: dep,drydep,drydepspec(maxspec),wetdep,ohrea,assspec
575
576  ! numxgrid,numygrid       number of grid points in x,y-direction
577  ! numxgridn,numygridn     number of grid points in x,y-direction for nested output grid
578  ! numzgrid                number of vertical levels of output grid
579  ! dxout,dyout             grid distance of output grid
580  ! dxoutn,dyoutn           grid distance of nested output grid
581  ! outlon0,outlat0         lower left corner of output grid
582  ! outlon0n,outlat0n       lower left corner of nested output grid
583  ! xoutshift,youtshift     xlon0-outlon0, ylat0-outlat0
584  ! xoutshiftn,youtshiftn   xlon0-outlon0n, ylat0-outlat0n
585  ! outheight [m]           upper levels of the output grid
586  ! outheighthalf [m]       half (middle) levels of the output grid cells
587  ! dep                     .true., if either dry or wet depos. is switched on
588  ! drydep                  .true., if dry deposition is switched on
589  ! drydepspec              .true., if dry deposition is switched on for that species
590  ! wetdep                  .true., if wet deposition is switched on
591  ! ohrea                   .true., if oh reaction is switched on
592  ! assspec                 .true., if there are two species asscoiated
593  !                    (i.e. transfer of mass between these two occurs
594
595
596
597  !  if output for each releasepoint shall be created maxpointspec=number of releasepoints
598  !  else maxpointspec is 1 -> moved to unc_mod
599  !  the OUTGRID is moved to the module outg_mod
600  !******************************************************************************
601
602  !real gridunc(0:maxxgrid-1,0:maxygrid-1,maxzgrid,maxspec,
603  !    +             maxpointspec_act,nclassunc,maxageclass)
604  !real griduncn(0:maxxgridn-1,0:maxygridn-1,maxzgrid,maxspec,
605  !    +              maxpointspec_act,nclassunc,maxageclass)
606  !real wetgridunc(0:maxxgrid-1,0:maxygrid-1,maxspec,
607  !    +                maxpointspec_act,nclassunc,maxageclass)
608  !real wetgriduncn(0:maxxgridn-1,0:maxygridn-1,maxspec,
609  !    +ct                 maxpointspec,nclassunc,maxageclass)
610  !real drygridunc(0:maxxgrid-1,0:maxygrid-1,maxspec,maxpointspec,
611  !    +                nclassunc,maxageclass)
612  !real drygriduncn(0:maxxgridn-1,0:maxygridn-1,maxspec,
613  !    +                 maxpointspec,nclassunc,maxageclass)
614
615  !real oroout(0:maxxgrid-1,0:maxygrid-1)
616  !real orooutn(0:maxxgridn-1,0:maxygridn-1)
617  !     real area(0:maxxgrid-1,0:maxygrid-1)
618  !real arean(0:maxxgridn-1,0:maxygridn-1)
619  !real volume(0:maxxgrid-1,0:maxygrid-1,maxzgrid)
620  !real volumen(0:maxxgridn-1,0:maxygridn-1,maxzgrid)
621
622  !real areaeast(0:maxxgrid-1,0:maxygrid-1,maxzgrid)
623  !real areanorth(0:maxxgrid-1,0:maxygrid-1,maxzgrid)
624
625
626  ! gridunc,griduncn        uncertainty of outputted concentrations
627  ! wetgridunc,wetgriduncn  uncertainty of accumulated wet deposited mass on output grid
628  ! drygridunc,drygriduncn  uncertainty of accumulated dry deposited mass on output grid
629  ! oroout,orooutn [m]      height of model topography at output grid
630  ! area,arean [m2]         area of each grid cell
631  ! volume,volumen [m3]     volume of each grid cell
632  ! ... field names with n at the end indicate a nested output grid
633
634
635  !***********************************
636  ! Variables defining receptor points
637  !***********************************
638
639  real :: xreceptor(maxreceptor),yreceptor(maxreceptor)
640  real :: receptorarea(maxreceptor)
641  real :: creceptor(maxreceptor,maxspec)
642  character(len=16) :: receptorname(maxreceptor)
643  integer :: numreceptor
644
645  ! xreceptor,yreceptor     receptor position
646  ! creceptor               concentrations at receptor points
647  ! receptorarea            area of 1*1 grid cell at receptor point
648
649
650
651  !***************************************
652  ! Variables characterizing each particle
653  !***************************************
654
655  integer :: numpart,itra1(maxpart)
656  integer :: npoint(maxpart),nclass(maxpart)
657  integer :: idt(maxpart),itramem(maxpart),itrasplit(maxpart)
658  integer :: numparticlecount
659
660  real(kind=dp) :: xtra1(maxpart),ytra1(maxpart)
661  real :: ztra1(maxpart),xmass1(maxpart,maxspec)
662
663  ! numpart                 actual number of particles in memory
664  ! itra1 (maxpart) [s]     temporal positions of the particles
665  ! npoint(maxpart)         indicates the release point of each particle
666  ! nclass (maxpart)        one of nclassunc classes to which the particle is attributed
667  ! itramem (maxpart) [s]   memorized release times of the particles
668  ! itrasplit (maxpart) [s] next time when particle is to be split into two
669  ! idt(maxpart) [s]        time step to be used for next integration
670  ! numparticlecount        counts the total number of particles that have been released
671  ! xtra1,ytra1,ztra1       spatial positions of the particles
672  ! xmass1 [kg]             particle masses
673
674
675
676  !*******************************************************
677  ! Info table on available chemical species/radionuclides
678  !*******************************************************
679
680  !character*10 specname(maxtable)
681  !real decaytime(maxtable),wetscava(maxtable),wetscavb(maxtable)
682  !real drydiff(maxtable),dryhenry(maxtable),dryactiv(maxtable)
683  !real partrho(maxtable),partmean(maxtable),partsig(maxtable)
684  !real dryvelo(maxtable),weightmol(maxtable),ohreact(maxtable)
685
686  ! specname            Name of chemical species/radionuclide
687  ! decaytime           Half time of radionuclides
688  ! wetscava, wetscavb  Parameters for calculating scavenging coefficients
689  ! drydiff             diffusivitiy of species relative to diff. of H2O
690  ! dryhenry [M/atm]    Henry constant
691  ! dryactiv            reactivity relative to that of O3
692  ! partrho [kg/m3]     density of particles
693  ! partmean [m]        mean diameter of particles
694  ! partsig [m]         mean stand. deviation of particle diameter
695  ! dryvelo [cm/s]      constant dry deposition velocity
696  ! weightmol [g/mol]   molecular weight
697  ! ohreact             OH reaction rate
698
699
700  !********************
701  ! Random number field
702  !********************
703
704  real :: rannumb(maxrand)
705
706  ! rannumb                 field of normally distributed random numbers
707
708  !********************
709  ! Verbosity, testing flags, namelist I/O
710  !********************   
711  integer :: verbosity=0
712  integer :: info_flag=0
713  integer :: count_clock, count_clock0,  count_rate, count_max
714  real    :: tins
715  logical :: nmlout=.true.
716   
717
718end module com_mod
Note: See TracBrowser for help on using the repository browser.
hosted by ZAMG