EPA-600/7-79-XXX
November 1979
DEVELOPMENT OF MESOSCALE AIR QUALITY
SIMULATION MODELS
VOLUME 5. USER'S GUIDE TO THE
MESOFILE POSTPROCESSING PACKAGE
Joseph S. Scire, John E. Beebe,
Carl W. Benkley, and Arthur Bass
Environmental Research & Technology, Inc,
696 Virginia Road
Concord, MA 01742
NOAA Contract No. 03-6-02-35254
Project Officer
Herbert J. Viebrook
Meteorology Laboratory
National Oceanic and Atmospheric Administration
Research Triangle Park, NC 27711
OFFICE OF RESEARCH AND DEVELOPMENT
ENVIRONMENTAL PROTECTION AGENCY
WASHINGTON, DC 20460
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
DISCLAIMER
Publication of this report does not signify that the contents
necessarily reflect the views and policies of the U.S. Environmental
Protection Agency, nor does mention of trade names or commercial
products constitute endorsement or recommendation for use.
111
-------An error occurred while trying to OCR this image.
-------OCR error (C:\Conversion\JobRoot\00000AXJ\tiff\2000XGV8.tif): Unspecified error
-------
E NVIRONMENTAL RESEARCH & TECHNOLOGY INC
LIST OF TABLES
Table Page
1-1 Components of the MESOFILE File Management Package 5
1-2 Logical Unit File Structure 8
2-1 Form of MESOFILE Card Inputs and Subroutine
Identifiers 10
2-2 Card Inputs to Subroutine ECHO 16
2-3 Card Inputs to Subroutine DEFN 18
2-4 Card Inputs to Subroutine FIND 20
2-5 Card Inputs to Subroutine SEEK 22
2-6 Card Inputs to Subroutine AVRG 24
2-7 Card Inputs to the Line Printer Plotting Routine 27
2-8 Card Inputs to Subroutine ADD1 29
2-9 Card Inputs to Subroutine ADD2 31
2-10 Statistical Measures Calculated by Subroutine STAT 34
2-11 Card Inputs to Subroutine STAT 40
3-1 Card Inputs to MESOPLOT—'SAME1 NAMELIST 49
3-2 Card Inputs to MESOPLOT—'DIFF' NAMELIST 50
3-3 Card Inputs to MESOPLOT—'DATE' NAMELIST 51
4-1 Card Inputs to PLOTVEC—' SAME' NAMELIST 55
4-2 Card Inputs to PLOTVEC—"DIFF* NAMELIST 56
IX
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
1. INTRODUCTION
1.1 Background
As a result of the national commitment to the greatly expanded
use of indigenous coal reserves to meet growing energy generation
demands, several regions of the country (and in particular the Four
Corners region of the southwestern United States) will see increased
region-wide development of coal-fired steam electric power plants,
and/or coal gasification and oil shale recovery facilities. As man-
dated by federal statutes and regulations reflecting the strong
nationwide support for environmental protection, additional
fossil-fuel based energy resource development (ERD) will only be
permitted where consistent with the maintenance of human health,
welfare, and environmental quality. Suitable MESOSCALE air quality
modeling tools are needed to assess the impacts of different energy
development scenarios on regional air quality. To meet this need in
the public interest, the National Oceanic and Atmospheric Administra-
tion (NOAA) has sponsored a study by Environmental Research &
Technology, Inc. (ERT) to develop, compare, evaluate, and exercise a
number of alternative approaches to regional-scale ambient air quality
modeling in the Four Corners area, with the objective to provide a
suite of air quality simulation models that are both technically sound
and computationally practical for assessing regional-scale impacts of
energy development scenarios, specifically in the Four Corners area,
and more generally as well.
Three different regional-scale air quality transport-diffusion
models have been developed to address various features of point-source
plume dispersion of the mesoscale—e.g., dispersion at ranges of 100
to 1,000 kilometers (km) . These models are described, compared and
documented in companion volumes 1-4 in this series of documents
entitled "Development of Mesoscale Air Quality Simulation Models"
(Bass et al. 1979; Benkley and Bass 1979a, b, and c; Morris et al.
1979).
The three models are:
• MESOPLUME, a variable-trajectory Gaussian "plume-segment"
model;
• MESOPUFF, a variable-trajectory Gaussian "puff" super-
position model; and
• MESOGRID, an Eulerian grid model based on the method of
moments.
The three models share, where possible, the identical modules for
plume rise, plume decay and deposition, plume growth with distance or
travel time, and treatment of plume fumigation by entrainment within
the growing mixed layer.
To facilitate exact comparisons of these regional-scale
dispersion models for specified sets of model parameters and meteoro-
logical conditions, an efficient, easy-to-use "mesoscale modeling
system" has been designed. This system, schematically depicted in
Figure 1-1, is a fully integrated set of independent components com-
prising meteorological preprocessing, transport-diffusion, and post-
processing functions.
-------
ENVIRONMENTAL RESEARCH STECHNOLOGY INC
MESOSCALE
METEOROLOGY
MESOPAC
MESOSCALE
TRANSPORT-
DIFFUSION
MODELS
MESOPLUME
MESOPUFF
1
MESOGRID
ANALYSIS
MESOFILE
Figure 1-1 Integrated MESOSCALE Modeling System
o
0)
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
The mesoscale meteorology preprocessor, called MESOPAC, provides
the necessary meteorological input for any of the three mesoscale
transport-diffusion models (MESOPLUME, MESOPUFF, or MESOGRID). Each
of these models in turn identically communicates its results to the
postprocessing system, MESOFILE, responsible for file management,
display, and statistical analysis of all model output fields. This
document describes and illustrates the use of the MESOFILE system and
suggests other areas of application that go well beyond the uses put
to MESOFILE in the present contractual effort.
1.2 Overview of MESOFILE
The MESOscale FILE management and analysis system (MESOFILE)
shown in Figure 1-2, is a flexible post-processing package, designed
especially for interface with the regional-scale models. It consists
of file management, file merging and manipulation, statistical
analysis, and graphical display components (see Table 1-1). The file
management package records, catalogues, and archives all the relevant
output from the MESOPUFF, MESOPLUME, and MESOGRID regional scale
diffusion models. The concentration field output of any of the meso-
scale diffusion models can be routed to either the line printer or to
direct-access disk storage for subsequent processing.
The direct-access storage system allows for automatic storage and
cataloging of all the output data fields from the diffusion models
through the file management subroutine (FILMAN). Subroutine FILMAN
will produce, for each run for which output has been requested for
disposal to disk, a record of the date of the run, the run charac-
teristics, the disk file location it assigns automatically to all the
concentration data output, and the values of all the input parameters
for the run. The MESOFILE program allows this information to be
retrieved for all the previous runs made on a particular set of disk
files.
In addition, the MESOFILE user can arbitrarily specify the time
averaging interval for the model concentration fields to allow
statistical analyses to be defined over any multiple of the basic
(hourly) time step. Computer core resource limitations require that
the diffusion models operate only with a limited number of sources
within a given run (ten sources for the plume and puff models; fifty
sources for the grid model). MESOFILE can be used to sum the concen-
tration fields obtained from separate runs made with subsets of the
total source inventory to obtain an assessment of the impact of the
full source inventory. Two-dimensional fields of mean winds, mixing
heights, Pasquill-Gifford-Turner (PGT) stability classes, as well as
ambient air concentrations can be coutour plotted with the MESOPLOT
and PLOTVEC programs (see Sections 3 and 4). Figure 1-3 illustrates
some of the kinds of graphical displays produced by the MESOPLOT and
PLOTVEC routines.
BACKUP01 and ZER050 are additional file management programs that
are useful in operating the file management system. Because the
location of the output of each model run is recorded by the file
management system, an abnormally terminated run must be erased from
the run log before more model runs can be made. This is accomplished
-------
ENVIRONMENTAL RESEARCH 8, TECHNOLOGY INC
• FLEXIBLE TIME AVERAGING OF
CONCENTRATION FIELDS
• STATISTICAL ANALYSES
GRAPHICAL DISPLAYS
• CATALOGING AND ARCHIVING
Figure 1-2 File Management and Analysis (MESOFILE)
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 1-1
COMPONENTS OF THE MESOFILE FILE MANAGEMENT PACKAGE
Name
Purpose
FILMAN (subroutine records and catalogues model output and run
resident in the meso- log data
scale diffusion models)
MESOFILE
MESOPLOT
PLOTVEC
BACKUP01
ZER050
performs file merging and manipulation
operation and statistical analysis; prints
run data recorded on disk by subroutine
FILMAN
produces line printer and Calcomp contour
plots of concentration, mixing height, and
Pasquill-Gifford-Turner stability fields
produces Calcomp vector plots of the
MESOPAC wind field output and Calcomp and
line printer plots of the corresponding
isotach fields
decrements the file pointer to remove the
last model run from the run log stored on
disk (removes a "bad1 run from the system)
reinitializes the file pointer to remove
all previous model runs from the run log
stored on disk
-------
ENV RONMENTAL RESEARCH & TECHNOLOGY INC
12 , 10
« t 4 2
Wind Vectors
Wind Isotacns (m/s)
Mixing Height Field
Concentration Isopleths
Figure 1-3 Examples of MESOFILE Graphical Displays
-------
ENVIRONMENTAL RESEARCH STECHNOLOGY INC
by the BACKUP01 program (see Section 5). The direct access disk files
are currently sized to accommodate up to 25 model runs. After the
disk files are full, the model output may be spooled to tape, and the
run log can be reinitialized allowing this disk space to be reused for
up to 25 additional model runs. The ZER050 program is used for this
purpose (also see Section 5). It should be emphasized that when a run
log has been altered, either by BACKUP01 or ZER050, the concentration
output data stored on the direct access disk files corresponding to
the run or runs removed from the run log are no longer accessible by
the file management system.
1.3 Direct-Access Disk Storage System
The direct-access disk storage system used by the mesoscale
modeling package has the logical unit file structure shown in
Table 1-2. Direct-access Files 13, 15, 21, 22, 23, and 24 are used by
the diffusion models; File 25 is used by the MESOFILE post-processor.
The file characteristics (see Table 1-2) are currently fixed within
the diffusion models and MESOFILE package by Fortran "Define File"
statements in the code and may require specific modification for
adaptation to the user's host system.
Library File 13 contains a single-record description for each
model run and is sized to accommodate a maximum of 25 independent
model runs. A printout of the library file can be produced by
MESOFILE's ECHO subroutine (see Section 2.2.1).
NAMELIST File 15 contains a one-record detailed description of
the parameters used for each model run. Each record in this file
contains a duplicate of the corresponding File 13 record for the run
and the NAMELIST parameters used to make the run.
Concentration Files 21 and 22 contain the S02 and SO^
gridded concentration fields for each model output time step. An
identifying header record (identical to the format used for File 15)
precedes the concentration fields. Files 21 and 22 are sized to
accommodate a maximum of 1,800 records each; therefore, for example,
the results of 10 independent model simulations, each of 179-hour
duration with hourly output, will fit exactly within the 1,800 records
allotted. The run number and pointer files (23 and 24), which are
transparent to the user, preserve information between runs necessary
to maintain proper archival sequencing of run outputs.
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 1-2
LOGICAL UNIT FILE STRUCTURE
Device Logical
Unit Number
13
15
21
22
23
24
25
File Name
Library
NAMELIST
SC-2 Concentration
so;;
Concentration
Run Number
Pointer
MESOFILE Output
Record Structure
25 records,
14 words/record
25 records,
800 words/record
1,800 records,
1,610 words/record
1,800 records,
1,610 words/record
1 record,
2 words
1 record,
4 words
100 records,
1,610 words/record
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
2. DETAILED MESOFILE DESCRIPTION
2.1 MESOFILE Overview
The MESOFILE program consists of a set of modular subroutines
that the user explicitly invokes by card (or card-image) inputs to
construct the desired sequence of post-processing operations. The
modular nature of MESOFILE provides powerful flexibility. It is
possible to perform a wide variety of post-processing operations in a
sequence specifically designed to meet the user's particular needs.
These features of modularity and flexibility, however, require a
greater degree of user interface than a simple "black box"
post-processing program. The MESOFILE card inputs required for the
most common applications of the program are presented as examples in
Section 2.3.
The main program of MESOFILE reads the user's card inputs and
calls the appropriate subroutines. There are eight subroutines
available to perform a variety of file management and post-processing
functions. Other second-level subroutines, transparent to the user,
are invoked as appropriate by the user-called subroutines. Table 2-1
contains a description of the basic form of the card inputs to
MESOFILE, as well as a list of the subroutines and their functions
that are available to the user. Each subroutine requested by the user
(with subroutine identifier cards) is called, in order, as it appears
in the inputs. There are, however, some restrictions on the order in
which subroutines may be called. For example, the pollutant of
interest must be specified before the concentration data can be
located; therefore, the subroutine identified in Table 2-1 as
belonging to calling order Group A must precede those in Group B.
Likewise, because data must be located before they can be processed,
the subroutines in Group B must be called before the subroutines in
Group C. At the end of the run, subroutine DECODE is automatically
called as part of the normal termination of MESOFILE. DECODE gives a
useful summary of all the subroutines called, the values of the input
parameters, the input/output options, and the locations (record
numbers) of the MESOFILE disk output (on File 25) for this MESOFILE
run.
As indicated in Table 2-1, following a title card and the
subroutine identifier card is the NAMELIST card containing the
necessary input data. In FORTRAN NAMELIST formatted inputs, the first
character of each input record must be a blank, followed by an & and
the NAMELIST name. The input data, separated by commas, must appear
between the NAMELIST name and an &END. All the NAMELIST names in
MESOFILE are either "SAME" (in subroutines called by the user via
subroutine identifier cards) or "DIFF (in the line printer plotting
subroutines).
The following section contains a detailed description of the
functions, the required inputs, and the output options of each
MESOFILE subroutine. Annotated sample inputs follow each subroutine
description to demonstrate each of the options available to the user.
Sample inputs for the most common applications of MESOFILE are
presented in Section 2.3.
-------
ENVIRONMENTAL RESEARCH 4 TECHNOLOGY INC
TABLE 2-1
FORM OF MESOFILE CARD INPUTS AND SUBROUTINE IDENTIFIERS
MESOFILE CARD INPUTS
• TITLE CARD
Up to 64 characters (columns 1-64) (followed by one set of cards as
specified below for each subroutine requested by the user)
• SUBROUTINE IDENTIFIER CARD
Contains 4-letter subroutine identifier (in Columns 1-4)
• NAMELIST INPUT CARD #1
Read by the subroutine called
• NAMELIST INPUT CARD #2
Read by the line printer plotting routine (needed only if line
printer plots are produced and contour levels other than the
default contour levels are used).
SUBROUTINE
IDENTIFIER
• ECHO
• DEFN
• FIND
• SEEK
• AVRG
• ADD1
• ADD 2
• STAT
CALLING
ORDER
GROUP
A
B
B
C
C
C
C
SUBROUTINE FUNCTION (Also see detailed
subroutine descriptions - Section 2.2
Access and Prints File Management Data
Defines Pollutant, Grid Size, and Routes Output
Locates First Order Model Output
Locates Higher Order MESOFILE Output
Averages Arrays
Sums Arrays "Vertically"
Sums Arrays "Horizontally"
Calculates Statistics
10
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
2.2 MESOFILE Components
2.2.1 Subroutine ECHO
Each time a run is made of MESOPLUME, MESOPUFF, or MESOGRID in
which output of concentration data to disk is requested, the file
management subroutine FILMAN (contained in each of the models) stores
the following information in Library File 13:
run number,
date of the run,
date of the simulated period,
number of output concentration arrays,
averaging time,
save frequency,
record numbers of the output fields, and
indicator signifying whether the run terminated normally.
The values of all the NAMELIST input parameters used in the run
are stored in NAMELIST File 15. The system keeps a log of every model
run made and records the values of all the input parameters used in
each run. The only exception is that model runs having no disk output
requested do not call the FILMAN subroutine; these runs are not
included in the run log and NAMELIST files. The data stored in
Files 13 and 15 are retrieved by subroutine ECHO, which will output
the entire contents of either file on request. A sample echo of the
File 13 library is shown in Figure 2-1. The following parameters are
used to describe each model run.
• INUMB - the model run number that is automatically
assigned by the direct access disk output
subroutine (FILMAN).
• DATFLD - the date (day, month, year) of execution of the
model (not the day (or days) simulated).
• MODEL - the mesoscale dispersion model run.
• YR/DAY/HR - the starting year, Julian day, and hour of the
simulated period. (Note that the first gridded
concentration field is not output until ISAVEF *
DTIME hours of simulation time have elapsed,
where DTIME is the basic time step of the model
in hours and ISAVEF is the concentration array
disk output frequency, in terms of DTIME.
• NGRIDS - the total number of concentration arrays output
to disk for each pollutant during the model
simulation (NGRIDS = NADVTS/ISAVEF, where NADVTS
is the length of the simulation in terms of the
basic time step, DTIME).
• AVG - the concentration array averaging frequency in
hours.
• SAVE - the concentration array disk output frequency,
in hours.
• ISAFE - the direct access disk file record number of the
duplicate File 15 NAMELIST information.
11
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
> M 1*1 9 U"l kP •£
nj Aj -\j nj r\j r\} r\i
ru AJ 'M nj nj r\i r\i
X
f-i
CO
f-i
bO
.—i
0>
tu
I
o
o
u
03
o oooooooooooo
OS
t/3
---
"~
O
J-l
12
-------
ENVIRONMENTAL RESEARCH* TECHNOLOGY INC
• IBEGIN - the direct access disk file record number of the
first of the NGRIDS number of concentration
arrays output to File 21 (for 802) and File 22
(for SO^).
• ISTOP - the direct access disk file record number of the
last of the NGRIDS number of concentration
arrays output to File 21 (for S02) and File 22
(for S0£).
• ICHECK - the run termination status indication;
ICHECK = 1 indicates the model simulation run
terminated normally; ICHECK = 0 indicates it
terminated abnormally.
Because the file management system records the location of the
output of each run, an abnormally terminated run must be erased from
the library file before subsequent model runs to be stored on disk are
made (see BACKUP01, Section 5). The disk space occupied by this "bad"
output is released for reuse by running the BACKUP01 program.
Figure 2-2 displays the contents of NAMELIST File 15 as output by
subroutine ECHO. In this example, thirteen sets of namelist
parameters—one set for each model run—are stored in File 15. (The
user cannot specify which NAMELIST set is desired; the entire contents
of File 15 is printed if NFILE =15). Table 2-2 summarizes the card
input options. The following are sample card inputs.
• Sample Input—Example 1A
TITLE CARD
ECHO
&SAME NFILE=13,&END
• Sample Input—Example IB
TITLE CARD
ECHO
&SAME NFILE=13,&END
ECHO
&SAME NFILE=15,&END
The number of the file to be dumped appears between the NAMELIST
name (&SAME) and an &END. The call to subroutine ECHO in Example 1A
will produce a listing of the run library; in Example IB, a listing of
both the run library and the NAMELIST parameters for each run will be
produced.
2.2.2 Subroutine DEFN
Subroutine DEFN allows the user to specify for a particular
MESOFILE run:
• the concentration grid size,
• the pollutant of interest (S02 or S0£), and
• the starting record of the disk output on the MESOFILE disk
file (File 25).
13
-------
ENVIRONMENTAL RESEARCH ^.TECHNOLOGY INC
-5 y O O •— >-
» r* I t O ».*.»»».»***».*.»»
** O UJ UJ X
O * * O) •.
o m fO «
o <\* "- c o
o o M • ooooooooooooooooo
• O » X *. BOOOOOOOOOOOOOOOO
tmtr- n oooooooooooooooo
J> « 4 *. OOOOOOOOOOOOOOOO
H >• 9 -J OOOOOOOOOOOOOOOO
cr — BD •• oo»oo»«**««*»*«»*»*
« ». » fc m ».^»;>^^—. ^^^^^^^.^-^^^
t— — K) —I O •
CO O O O I O -*
•4 III UJ ... Oh*. •.-«--•.•.<•.*.»•.•.».*
"^ UJ UJ W I-H o
fc O O «3 Kt O -
-o o r*i co 0* o
f\j o • • oooooooooooooooo
3C ocrcr x cr • ^-oooooooooooooooo
Q ^r-(?- Qt »• OOOOOOOOOOOOOOOO
I tn9oooooooooooooo
UJ O OOOOOOOOOOOOOOOO
X -J » OOO>7**'**>>***>>**
II «. fc U * » — * . .«o— .-«—• — « — .-.-•-*—i-*-t-*-*
Q>£vrtPsl U.O tT •
ooao^ ni -< v
I— Ik _l UJ 0»*bbh>*>>>>^k«»^.*.k.
(O UJ •* *G O
< W CO 3 —• O »
*~t m fo z o o
• Wo < o o o
onto •>• o • o oooooooooooooo
ooo r*i o eo ooooooooooooooooo
ru H ^> o — — oooooooooooecooo
»* a. ^o* • H oooooooooooooooo
4 -* II »— 00*00 ••••*•••*•••••
co * • M _j — (r>i.»-*.3>.« — — «,-.,*.-,.* — «-*,*-*„
•~) I -W UJ X •
11-13 > M O <^
a: j) - » a. ..*o-»-.-»-*~*..*.-.»-.»*
« nt ft uj o
II f- l/l •« O O <•
CO CO O O X « O
*- ^ O OlS»- O»
O » Of\JO> tO t- OOOOOOOOOOOOOOOO
2 OOCT •• Q. II * -\IOOOOOOOOOOOOOOOO
-• r\IOCT< UJ U. OOOOOOOOOOOOOOOO
OH «ocr _i M oooooooooooooooo
oa. o« » cooooooooooooooooo
o»— —i f«n IP ooo)o •?•*»•• •»•**••*•
oco . . . u o . •*l-t.«o-^-*-^-«-* — -H — -«-^ — — — «
• •* I X » X *
O W 4 UJ UJ **"
OM •••. CO r\J ..........«».**.......»*.•.•.».•.*..
O •> X Kl
O — f*. < O M
f « X O UJ
It O » O O O J
CS O^,OK1 U. U. • O • OOOOOOOOOOOOOOOO
•* t- OOOO* UJ ^ ITI OLJOOOOOOOOOOOOOO
•- x oooo1 co to •» m fc ouJoooooooooooooo
— _l —• O O (7- UJ < 1 OOOOOOOOOOOOOOOO
UJ "OOT O ^> O II OOOOOOOOOOOOOO
•^ o —• r*. _i _j u ocooooooooooooooo
xrx «*.. m 9 <_; o....^.^«^ — ^.-C^^^^.^.^^^!-C
oj >- i i o z o i
to o t- o _j
4 «. fc » ** X O»»l>K>i>>»>>*>«iKB> O1 » •
U. «. 'V •— -O
< Jj O'U-O'*. •< OO-^OOOOOOOOSOOO
a. x. ooa-y _> 00^=00000000000
—J U. M OO(7»J- M II II .U II O-2-3OOOOOOOOOOOO
" *^ — OJOJ»J- O 13 ^ _J — OOOOOO33OOOOO3O
M " £ • o > T _) £ i: — LL. *: coooooooooooooo
•^ -I OTJilJ t— < >~i O Z <: •333'OOC:I33C''=OOOS3
•-< Jj ^"•Ojl a. J3 I 1^ —> — o^^>=io>7 ••••*••••••»••
i: ~3 k... 5: _z tj u-» JT v:*!...-,.^--.^ — «^«-.—.-^^4^^,_
-2 -II I I - - » £ X *
_) = or 03-cj- P-. ^
> o \l^- ...... o o o J-* - «.K^k..K<.^..kh.^>K.»k«
i— ~ \fi r t~~ 3- 3- —
It O < fO -D 3 O" II
U-Ot^X ^^. j-^.
U. O NH a» Or^ 3~.Z
—I • ITJ CT1 — CO ~- • 3- C:O^-5OO3COOOCOOOO3O
* "•* t7"OOO _J OO-3OODOOO3OOOOO33
—luJ 1:11 K- <«3^o •— —• -O "yn >3: — n (_>j o 3 poioooo^ooooooo
ujl >—uj QUJ x oooj QQ: u.»- u."-1 ou. a. o aa: xi o ooooooooooooooo
±ID3^T3-IX DJ ^^3-O*-73OU.J.OJ._ICJT>OC)'-Xar3^33 .0 .3 *
a>
r—I
•H
tu
^
LO
f—*
a;
+J
c
o
u
nj
ex
o
o
u
PU
CO
CN!
i
CM
M
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
OOOOOOOOOOOOOOOOOOO OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
0000000000000000000*0 OOOQOOOQOOOOOOOOOOOOOOOOOOOOOOGOOO
OOOOOOOOOOOOOOOOOOOX OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
1QOOOQOOO9OO
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
oooooooooocooooooooo
OOOOOOOOOOOOOOOOOOOO
oooooooooooooooooooo
OOOOOOOOOOOOOOOOOOOO
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
OOOOOOOOOOOQOOOQOQOCOOOQOOOQOOOOOOO
oooooooooooooooooooocoeoooooooooooo
OOOOOOOOOOOOOOOO^OOO OOOO OC3O3OOOOO >O
' O 3 O O O
O O O O O
' 3 -i O O 3
3 S O 3 3
, c- 3 O O O
OOOOOOO 3OOOOOOOOOOOO
OOOOOOOOOOOOOOOOOOOO
OOOOOOOOOOOOOOOOOOOC
oooooooooooooooooooo
O3OOOOOO33OOOOOO33OO
OOOOOOOOOOOOOOOOOOOO
OOOO3O3OO
OOOOOOOOOOO
OOO3O 3O
OOOOOOO
OOOOOOOOOO 3 3OO So OO-3OOOOOOOOOOOC3OOO
OOOOOOSOOOCOOOOoOOCOOSCiOOOOOOCiOOOO
OOOOOOCOOOOOOO SOOOOOO OOOOOOOOOOOOO
OO^3OOO33OOOOS30O33003OOOOS.3OOOO3O
ooooooaoooooooooooooooocooocooocoo
OOOOOOOO 30=>00 3=>000 33OOOOOOCJOOOOO 33
OOOOOOOOOOOOOOOCOOOOOOOOOOOOOOOO-OO
CD
3
c
c
O
0>
f-l
3
15
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-2
CARD INPUTS TO SUBROUTINE ECHO
SUBROUTINE ECHO
NAMELIST TITLE - SAME
Parameter
NFILE
Type Definition
INTEGER Logical unit number of the file
to be printed (NFILE = 13 for
library lines; NFILE = 15 the
NAMELIST parameters).
Default
13
16
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
The concentration array size, IMAX * JMAX, (see Table 2-3), must,
of course, be the same as the array size specified in the mesoscale
model run used to generate the concentration data. The default values
for the concentration array size in MESOFILE are the same as the
default values in the MESOPLUME, MESOPUFF, and MESOGRID models, i.e.,
26 x 26. Most of the model runs generate both SC>2 and S0£
concentration data; MESOFILE, however, operates on only one pollutant
at a time, assumed to be S(>2 unless the user specifies S0£.
All MESOFILE disk output (concentration fields, difference
fields, etc.) is written to the MESOFILE output File 25. Each output
field requires one record of disk space on File 25. The user must
specify the record where the disk output is to start for a particular
MESOFILE run. The first output array is written at this record; the
second output array is written at the next record, etc. Each time an
array is written to disk, the disk file pointer is incremented by
one. A particular MESOFILE run, for example, may write n
concentration arrays on Records 1 through n; the user may wish to save
this output, and, on a subsequent MESOFILE run, the output may be
directed to begin at record n+1.
The starting record number for MESOFILE disk output is not
supplied with a default value; this prevents accidental overwriting of
previously stored data. The user must specify this parameter if the
MESOFILE run is to generate any disk output. The concentration array
size and pollutant are used in block data; subroutine DEFN must
therefore be called only if:
• any disk output is generated in the MESOFILE run,
• the concentration array size is different from the default
26 x 26, or
• the pollutant of interest is not S02-
Table 2-3 contains a description of the card inputs to subroutine
DEFN. The following are sample card inputs.
• Sample Input—Example 2A
TITLE CARD
DEFN
&SAME IMAX=40,JMAX=40,IOUT=1,&END
• Sample Input—Example 2B
TITLE CARD
DEFN
&SAME IPOL=2,IOUT=20,&END
The call to subroutine DEFN in Example 2A sets the concentration
array size to 40 x 40. The disk file output pointer, IOUT, is given a
value of I. Any disk output that may be generated later in the
MESOFILE run, therefore, will start on Record 1 of File 25. In
Example 2B, SO^ is specified as the pollutant of interest. The
disk output of this MESOFILE run will begin on Record 20. The
concentration array size is assumed (by default) to be 26 x 26.
17
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-3
CARD INPUTS TO SUBROUTINE DEFN
SUBROUTINE DEFN
NAMELIST TITLE - SAME
Parameter
IPOL
IMAX
JMAX
IOUT
Type
INTEGER
INTEGER
INTEGER
INTEGER
Definition
Pollutant (for S02, IPOL
for S0£, IPOL =2).
Default
= i;
Number of elements of the
concentration array in the X
direction (<40).
Number of elements of the con-
centration array in the Y
direction (<40).
Record number of File 25 at
which MESOFILE disk output is
to start.
26
26
18
-------
ENVIRONMENTAL RESEARCH STECHNOLOGY INC
2.2.3 Subroutine FIND
FILMAN, the file management subroutine incorporated in each of
the mesoscale air quality simulation models, dynamically allocates
available disk records (on previously created disk Files 21 and 22) to
store SC>2 and SO^ concentration fields, and records the
location of these fields in the Library File (File 13). These
cataloging and archiving operations are automatically controlled by
FILMAN as long as sufficient disk space was originally allocated when
disk Files 21 and 22 were created. The concentration fields for any
previous MESOPLUME, MESOPUFF, or MESOGRID run are located (and
therefore can be accessed by other MESOFILE subroutines) with a call
to subroutine FIND.
Subroutine FIND performs the following sequence of operations:
• reads user inputs (see Table 2-4) to identify the model
output to be located:
model run number;
starting hour, day, and year of data; and
number of concentration fields;
• determines disk file record numbers of requested
concentration data by reading Library File (File 13);
• checks data of first concentration array to verify that the
proper arrays have been located; and
• defines the requested set of concentration arrays as
runstream number n, where n = 1 (first call of FIND/SEEK),
n = 2 (second call of FIND/SEEK), etc.
Each call to subroutine FIND defines a runstream (i.e., one or a
group of concentration fields) that can be accessed by other MESOFILE
subroutines. A runstream number is a sequential internal reference
number associated with a group of concentration arrays located by
subroutine FIND or SEEK and is used to identify these arrays in other
MESOFILE subroutines. FIND is one of two runstream defining
subroutines (subroutine SEEK is the other). The first set of
concentration fields located by FIND (or SEEK) is referred to as
Runstream 1, the second set of concentration fields defines
Runstream 2, etc; concentration array runstream numbers should not be
confused with model run numbers INUMB.
Because subroutine FIND is used to locate the output of any
previously run model, it must be called before an attempt is made to
process these data subsequently with any of MESOFILE's data processing
subroutines. Before any MESOFILE data processing subroutines of
MESOFILE are called, subroutines FIND and SEEK must be used to locate
all the model output. The following are sample card inputs.
• Sample Input—Example 3
TITLE CARD
FIND
&SAME INUMB=4,IYEAR=78,IDAY=166,IHOUR=1,IGRIDS=24,&END
FIND
&SAME INUMB=4,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=120,&END
FIND
&SAME INUMB=8,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=120,&END
19
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-4
CARD INPUTS TO SUBROUTINE FIND
SUBROUTINE FIND
NAMELIST TITLE - SAME
Parameter
INUMB
IHOUR
IDAY
IYEAR
IGRIDS
Type Definition
INTEGER Run number of the air quality
model run.
INTEGER Ending hour of the first
concentration array of interest.
INTEGER Day number of the first concen-
tration array of interest.
INTEGER Year of the first concentration
array of interest.
INTEGER Number of concentration arrays.
Default
20
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
In Example 3, the run number identified as INUMB = 4 is a
MESOGRID run starting at Hour 0, Day 165, Year 78 (refer back to
Figure 2-1). Because each of the models output their concentration
arrays at the conclusion of a time step, the first concentration array
recorded is for Hour 1 on Day 165. The first sample input above
specifies Runstream 1 as consisting of 24 hourly concentration arrays,
starting at Hour 1, Day 166 and ending at Hour 0, Day 167. The second
call to subroutine FIND defines Runstream 2 as the set of
concentration arrays output from Run Number 4, starting at Hour 1,
Day 165, through Hour 0, Day 170, (i.e., starting time plus
120 hours). Runstream Number 3 is specified as the output from the
MESOPUFF model (Run Number 8) for the same 120-hour time period.
2.2.4 Subroutine SEEK
Each set of data to be accessed by the data processing
subroutines of MESOFILE must be located and assigned a runstream
number. The SC>2 and 864 concentration data, output directly by
the models to disk Files 21 and 22, are referred to as "first" order
data fields and are located by calls to subroutine FIND. MESOFILE,
however, has the ability to process first order data and output the
resultant fields (e.g., averaged concentration fields, summed
concentration fields, or several types of concentration difference
fields), to disk File 25 for storage and further processing. These
derived fields, which have undergone at least one level of MESOFILE
processing, are referred to as "higher" order data fields. The user
wishing to reference higher order data must supply the location
(File 25 record number) of the data to MESOFILE by a call to
subroutine SEEK.
Subroutine SEEK performs the following operations:
• reads user inputs to identify the MESOFILE output of
interest:
- NSTART and
- NSTOP and
• defines the requested set of data fields as runstream
number n, where n = 1 (first call of FIND/SEEK), n = 2
(second call of FIND/SEEK), etc.
The card input requirements of subroutine SEEK are described in
Table 2-5. The following are sample card inputs.
• Sample Input—Example 4
TITLE CARD
FIND
&SAME INUMB=4,IYEAR=78,IDAY=166,IHOUR=1,IGRIDS=24,&END
SEEK
&SAME NSTART=12,NSTOP=12,&END
SEEK
&SAME NSTART=10,NSTOP=23,&END
As in the previous example, Runstream Number 1 is defined as a
set of 24 hourly, first order concentration arrays. Runstreams 2
21
-------
ENVIRONMENTAL RESEARCH 8, TECHNOLOGY INC
TABLE 2-5
CARD INPUTS TO SUBROUTINE SEEK
SUBROUTINE SEEK
NAMELIST TITLE - SAME
Parameter
NSTART
NSTOP
Type Definition
INTEGER Starting disk record number
on File 25 of the output of
interest.
INTEGER Ending disk record number on
File 25 of the output of
interest.
Default
22
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
and 3, however, are composed of higher order data fields. The second
runstream consists of a single data field (record 12 on file 25),
whereas Runstream 3 is defined to be the 14 data arrays contained in
records 10 through 23.
2.2.5 Subroutine AVRG
Subroutine AVRG calculates time averages of first order or higher
order concentration data. This subroutine performs the following
operations:
• initializes NAMELIST SAME parameters to default values,
• reads user inputs,
• calculates number of arrays in the runstream specified by
the user and determines a repetition factor, IREPF,
• for each array in the runstream, reads array and if
requested, prints the input array and sums arrays,
• after AVETM arrays have been read and summed, divides by
AVETM to obtain average, and performs linear scaling
calculation, and
• if requested, writes averaged array to disk (File 25),
writes averaged array on line printer, and plots averaged
array.
The user has the option of printing, plotting, or writing the
averaged arrays to disk File 25. The user specifies the runstream
number of the data set to be averaged and the averaging frequency (in
terms of arrays), so that the appropriate block averages will be
computed. A background concentration factor or a concentration
multiplicative scaling factor may be included in the calculations as
well (see Table 2-6). Each averaged array may be adjusted by the
form:
CADJ = a * c + b-
The location of all MESOFILE disk output (File 25) is controlled
by the TOUT variable of subroutine DEFN. The first output grid is
written on record IOUT of file 25, the next grid is written on record
IOUT + 1, etc. The user specifies the location where the disk output
is to start; the disk file pointer is incremented each time a grid is
written to disk. The following are sample card inputs.
• Sample Input—Example 5
TITLE CARD
DEFN
&SAME IOUT=50,&END
FIND
&SAME INUMB=4,IYEAR=78,IDAY=167,IHOUR=0,IGRIDS=12,&END
SEEK
&SAME NSTART=1,NSTOP=30,&END
AVRG
&SAME IRUN=1,AVETM=3,DISK=1,PLOT=1,NEWV=1,APE=1,&END
23
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY (MC
TABLE 2-6
CARD INPUTS TO SUBROUTINE AVRG
SUBROUTINE AVRG
NAMELIST TITLE - SAME
Parameter
IRUN
AVETM
PRINT
Type
INTEGER
INTEGER
INTEGER
Definition
Default
DISK
INTEGER
PLOT
INTEGER
NEWV
INTEGER
APE
INTEGER
a,b
REAL
Runstream number.
Averaging time (in terms of
number of arrays).
Line printer output control
variable. PRINT = 1—averaged
concentration arrays are printed;
PRINT = 0—averaged concen-
tration arrays are not printed.
Disk output control variable.
DISK = 1—average concentration
arrays are written on disk;
DISK = 0—averaged concentration
arrays are not written on disk.
Line printer plotting control
variable. PLOT = 1—plots are
produced; PLOT = 0—plots are
not produced.
Plotter contour values control
variable—also see Table 2-7.
NEWV = 1—user input contour
values (if NEWV = 1, user must
insert a DIFF NAMELIST card
with the apprropiate contour
information); NEWV = 0—default
contour values.
Controls echo of input
(unaveraged) fields. APE = 1—
input fields are printed; APE = 0—
input fields are not printed.
Adjustment factors for the a
averaged concentration field. b
a—multiplicative factor,
b—additive factor,
of the form,
1.
0.
C
ad j
= a
*
C + b.
24
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
&DIFF N=5,THR=-1.E-10,0.1E-6,1.E-6,10.E-6,100.E-6,20*0.0,&END
AVRG
&SAME IRUN=2,AVETM=30,PRINT=0,DISK=1,PLOT=1,&END
AVRG
&SAME IRUN=2,AVETM=10,PRINT=0,DISK=1,PLOT=1,&END
The call to subroutine DEFN sets the disk output pointer IOUT to 50.
The averaged concentration arrays written to disk, therefore, will occupy
records 50 through 50 + n on File 25, where n is the number of arrays
output to disk. Subroutine FIND is called to define a 12-array runstream
consisting of hourly concentration fields, as illustrated schematically in
Figure 2-3. Runstream Number 2 is defined as the higher order data on
records 1-30 of File 25. The first call to subroutine AVRG averages the
data defined by Runstream 1 into four 3-hour averaged arrays (again see
Figure 2-3). The maximum output available to the user is requested. The
hourly concentration input fields and the averaged fields are printed.
The averaged fields are also plotted (with user input contour levels) and
written to disk (on records 50-53). The second call to subroutine AVRG
results in one 30-array average from the data in Runstream 2. Only two
output options are invoked: line printer plots and disk output. The disk
output is routed to Record 54 because the previous AVRG call put arrays
into Records 50 to 53. The contour levels of the line printer plot will
be the same as in the previous AVRG call; when new contour levels are
defined (as in the first AVRG call), the plotting routine will continue to
use them until other contour levels are redefined in a DIFF NAMELIST (see
Table 2-7). All the parameters in NAMELIST SAME that have default values
are reset to their default values each time the subroutine is called. The
third AVRG call uses Runstream Number 2 data to calculate three 10-array
averages. The output options are the same as with the second AVRG call,
and the disk output is stored on Records 55 to 57 of File 25.
2.2.6 Subroutine ADD1
Subroutines ADD1 is used to sum all the arrays in a runstream to
yield a simple summed output array. That is,
N
k
c
k=l
ij —, 'LJ
25
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
Runstream
Number
1
Runstream
Number
2
(00,167, 78)
(01,167,78)
(02, 167, 78)
(03,167, 78)
(04, 167, 78)
(05, 167, 78)
(06, 167, 78)
(07, 167, 78)
(08, 167, 78)
(09, 167, 78)
(10, 167, 78)
(11,167,78)
(HH,DDD,YY) = (Hour, Day, Year)
File 25
Records
1-30
First Average Call
3 Hr' Average
3 Hr. Average
[ 3 Hr. Average [
I 3 Hr. Average
Second Average Call
I 30-Array Average I
Runstream
Number
2
File 25
Records
1-30
Third Average Call
I 10-Array Average I
10-Array Average
10-Array Average
Figure 2-3 Schematic Illustration of the Averaging Process
26
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-7
CARD INPUTS TO THE LINE PRINTER PLOTTING ROUTINE
NAMELIST TITLE - DIFF
(included only for line printer plots with user input contour levels)
Parameter
THR(25)
Type Definition
INTEGER Number of contour levels
(must be 25)
REAL ARRAY Contour values*
Default
-1.x 10-10
0.1 x 10-6
0.5 x 10-6
1.0 x ID"6
2.0 x 10~6
5.0 x 10-6
10.0 x 10-6
25.0 x 10-6
50.0 x 10~6
*The first element of THR should be less than the minimum value of the
field being plotted.
27
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
where (Csum)-^: is the (i,j) element of the summed array, and
(C^j) is the (i,j) element of the ktn array in the
consisting of N arrays (k = 1...N). The output options include an
echo of the input arrays, line printer gridded output, line printer
plots, and disk output and are the same as those in subroutine AVRG.
The adjustment factors a and b for the summed concentration field ara
also available (see Table 2-8). Each call to subroutine ADD1 will
initialize the output array to zero before adding to it sequentially
the concentration arrays of the specified runstream, unless the INIT
variable is set to zero in the ADD1 input NAMELIST. With INIT = 0, a
cumulative sum can be calculated with successive ADD1 calls.
The following are sample card inputs.
• Sample Input—Example 6
TITLE CARD
DEFN
&SAME IOUT=50,&END
SEEK
&S AME NSTART=1,NSTOP=6,&END
SEEK
&SAME NSTART=20,NSTOP=22,&END
ADD1
&SAME IRUN=1,DISK=1,&END
ADD1
&SAME IRUN=2,INIT=0,DISK=1,&END
The call to subroutine DEFN requests that the disk output of this
MESOFILE run begin at record 50 on disk File 25. Two runstreams are
defined: a six array runstream (Number 1) and a three array runstream
(Number 2). The first call to ADD1 sums the data in Runstream
Number 1 (Records 1 to 6) and prints the result on the line printer
and record 50. The second ADD1 call, because INIT = 0, adds the array
in Runstream Number 2 to the summed array calculated in the first ADD1
call, and the result is also written on disk (Record 51) and on the
line printer.
2.2.7 Subroutine ADD2
Subroutine ADD2 calculates "horizontal" sums of the arrays in two
runstreams. That is,
Dk » Ak. + Bk
- U -
where the summation extends over all k = 1...N arrays in runstreams A
and B, and D is the resultant runstream. Two runstream numbers must
therefore be supplied to subroutine ADD2 as input, and both runstreams
must contain the same number of concentration arrays. The other
NAMELIST inputs are the same as the subroutine ADD1 inputs (see
28
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
TABLE 2-8
CARD INPUTS TO SUBROUTINE ADD1
Description of Inputs to Subroutine ADD1
NAMELIST TITLE - SAME
Parameter
IRUN
INIT
PRINT
DISK
PLOT
NEWV
APE
a, b
Type Definition Default
INTEGER Runstreara number.
INTEGER Determines whether the summing 1
array is initialized to zero;
INIT = 1—array initialized to
zero; INIT = 0—array is not
initialized.
INTEGER Line printer output control 1
variable. PRINT = 1—summed
array is printed; PRINT = 0—
summed array is not printed.
INTEGER Disk output control variable. 0
DISK = 1—summed array is
written on disk; DISK = 0—
summed array is not written
on disk.
INTEGER Line printer plotting control 0
variable. PLOT = 1—plots are
produced; PLOT = 0—plots are
not produced.
INTEGER Plotter contour values control 0
variable (also see Table 2-7).
NEWV = 1—user input contour
values (if NEWV = 1, user must
insert a DIFF NAMELIST card
with the appropriate contour
information); NEWV = 0—default
contour values.
INTEGER Controls echo of input fields. 0
APE = 1—input fields are
printed; APE = 0—input fields
are not printed.
REAL Adjustment factors for the a = 1.
summed concentration field, b = 0.
a—multiplicative factor,
b—additive factor,
of the form,
cadj = a * C + b.
29
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
Table 2-9 for a complete description of the ADD2 input parameters).
The following are sample card inputs.
• Sample Input—Example 7
TITLE CARD
DEFN
&SAME IOUT=50,&END
FIND
&SAME INUMB=4,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=6,&END
FIND
&SAME INUMB=3,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=6,&END
ADD 2
&SAME IRUN1=1,IRUN2=2,DISK=1,PLOT=1,&END
The call to subroutine DEFN requests that disk output start on
record 50 of disk File 25. Six output files of two MESOGRID runs (see
Figure 2-1) are defined as Runstreams 1 and 2 with the calls to
subroutine FIND. The arrays of each runstream are added together,
printed, written to disk, and plotted with the default contour
levels. The "horizontal" summary process with the two 6-array
runstreams results in an output runstream of 6 arrays.
2.2.8 Subroutine STAT
Subroutine STAT is designed to produce quantitative as well as
qualitative measures of the point-by-point and bulk differences
between two concentration fields—a 'base1 field and a 'test' or
'perturbed* field. The base concentration fields are reference fields
resulting from a particular model run specified by the user. The test
concentration fields can be any other model output generated with some
test parameter of the model varied; for example, the emission
inventory, deposition velocity, decay rate, time step, or even the
mesoscale model used, may be varied and the results defined as the
test concentration fields.
When the user has defined a base case and test case concentration
field (or set of fields), line printer plots or gridded tables of the
following fields may be produced:
• the base field, identified as BF,
• the test field, identified as TF,
• the difference field, identified as DF = Cg - C^,
CB-CT
• the fractional difference field identified as FDF = — , and
CB
V CT
• the weighted difference field identified as WDF = ——
CB
where Cg is the base field concentration at a particular grid point,
Cj is the test field concentration at that point, and Cg is
defined below.
30
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-9
CARD INPUTS TO SUBROUTINE ADD2
SUBROUTINE ADD2
NAMELIST TITLE - SAME
Parameter
IRUN1
IRUN2
PRINT
DISK
PLOT
NEWV
APE
a, b
Type Definition Default
INTEGER Runstream Number 1.
INTEGER Runstream Number 2.
INTEGER Line printer output control 1
variable. PRINT = 1 - summed
arrays are printed; PRINT = 0 -
summed arrays are not printed.
INTEGER Disk output control variable. 0
DISK = 1—summed arrays are
written on disk; DISK = 0 - summed
arrays are not written on disk.
INTEGER Line printer plotting control 0
variable. PLOT = 1—plots are
produced; PLOT = 0—plots are
not produced.
INTEGER Plotter contour values control 0
variable. NEWV = 1—user input
contour values (if NEWV = 1, user
must insert a DIFF NAMELIST card
with the appropriate contour
information—see Table 2-7);
NEWV = 0—default contour values.
INTEGER Controls echo of input fields. 0
APE = 1—input fields are printed;
APE = 0—input fields are not
printed.
REAL Adjustment factors for the summed a = 1.
concentration fields, b = 0.
a—multiplicative factor
b—additive factor
of the form,
= a * C + b.
31
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
The fractional difference field PDF can be calculated only for
grid points with nonzero base field concentrations, but because the
FDF is most meaningful in comparing base case and test case plumes
which overlap exactly or nearly exactly, the FDF is calculated only
for those points in the intersection of the two plumes (that is
CB = 0 and CT = 0)
The WDF is the difference field weighted by the average base
plume concentration (Cg).
N
£, (C_)
~ - n=1 B n
N
where N includes only those points in the base field plume (defined as
the set of points in the base field with nonzero concentrations).
In addition to line printer plots of the DF, FDF, and WDF,
subroutine STAT has the ability to write these fields to the MESOFILE
direct access disk output file (File 25), so that Calcomp plots may be
generated for these fields.
Variation of the test parameter can substantially change the
nature of the concentration distribution in the base and test plumes;
these differences in turn determine which of the difference field
representations is appropriate for a particular analysis. The FDF
field is useful in determining the relative spatial location of the
base and test plumes and differences in the concentration
distribution, and should be used when the effect of the input
parameter does not change the gross spatial distribution of the
plume. The WDF allows the differences in concentration to be weighted
by a constant factor.
Subroutine STAT also generates a set of quantitative
(statistical) measures of the differences in the base case and test
case concentration fields. Whereas the graphical output is optional,
the statistical output is always produced. Figure 2-4 is a sample of
the statistical output. The statistics calculated and the subsets of
the grid over which the calculations are performed are contained in
Table 2-10 and Figure 2-5. Clearly, the most meaningful statistic for
a given base case-test case comparison depends heavily on the nature
of the test parameter varied and must be determined by the user.
Figure 2-6 is a flowchart of subroutine STAT. The input
variables are defined in Table 2-11. It is assumed that the
statistics for multiarray runstreams are to be calculated on an
array-by-array basis; the variable BYONE, therefore, has a default
value of 1. It is possible, however, to logically concatenate
successive arrays in a particular runstream by specifying BYONE = 0.
For example, consider base case and test case runstreams consisting of
three 24-hour averages. If BYONE = 1, array-by-array statistics
(i.e., 3 sets of statistics, one set for each 24-hour averaged array)
will be produced; BYONE = 0 will result in only one set of statistics
over the entire 72-hour period.
It is possible to write DF, FDF, or WDF to the MESOFILE direct
access disk output file (File 25), although only one of these fields
can be written on a particular call to STAT.
32
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
CO
UJ
z
tn
UJ
z
0.
a
o
UJ
a>
X
UJ
a.
O
-o
o
I
o
o
*
UJ
ra
o
eo
-c
O
I
CO
<
CC
UJ II
X
I- O
X
CO C
« u
UI
O X
CO H-
n co
x
c
to
X
X
uj
a.
H- O
ai
G f\J ~ IT CD (C
a
z
o
z
o
o
UJ
UJ
i
o
a.
o
n
X
uj
—II
II
f- — II Z
< ^ ^^ tl II X
^>-'Xa « « »-
31 — i « — . a. s u.
II II
CD "J
20 20
— i x >-i X
z c * c
Q CJ O C_>
-I UJ -J -U
_j or _ix
3 O
U- »- U. t-
10 -•
O
U.
u. •-» JJ •« £ 2 a.
O Q i-t 1-4 UJ Q
-IO2 JXX_)O
UJUJOUJUJ^UJUJUJ
>-«ao«k-CiZU.'-'ai
u.u.x
"i 3
OUJh-
x
co o co
- i ^
1-4 UJ It •
X OJ O
co in —
t- »• a u
2 X
II O —
UJ O ^^
CO «t r>
UJ
I
UJ CC C
a •< >-H
UJ UJ <
LS iD _1
z
o
CO
X
UJ
I
ru
o o
o »
» UJ
UJ —•
o -c
Cl ,0
O in
—i fVJ
o o
o
r~ 4> II
O UJ II
I in ~*
O X O O
•o "i o u.
O O U. —J
I- • « z
O- O « X
l-< CC O
x o u z z
t- i o o
i-i uj II <-* i-i i-i
Z f- O t- h-
CO -> O < •«
CO CC O U. •-> —4
z in < —' uj uj
i-i •« o a
O 0 — 2
O. I O _l _l
U.
o
CO
UJ -D
co >n
<
CC
UJ
X
t—
II -O
u. in —
o o in •*
uj x it o y f\t
CO UJ I O •
X Q. UJ Uj Kt O
UJ Z fM • I
t— x o cr o
Z O II _l (M II
•-4 Q. O
UJ -U "O II —
^ uj co z o • z
p^ X 4 O uj O ^^ O
•c >- cc _i a) o u.
— a. x Q. —<
Z O II U.
I-I CO UJ *— > CO
2 CO X ^ < Z
O O •< uj O —• <
II 2 *— UJ UJ Z
h-i < UJ oj > O
ai
O
rt
en
i
CM
J5
X Z
l U. U.
CO
>— XXX
•< UJ UJ X
i- > :> o
CO < < CJ
UJ
I 2
»— O UJ 2 UJ UJ
l-l •- O t- t-
X t- ^ l-i ^ ID
O •« _1 t- _l _l
u. •-< o o c o
> CO < CO CO
co uu a> x cc ^e
o o « u. < <
I- UJ UJ UJ UJ Z
co cj ci is U) ;D
i-i « « < < Z
•- X X X X -4
•< UJ UJ UJ UJ X
H- > > » > «t
CO < < < «K Z
i/5
h-1
X
Uj
h—
U
<
X
41
X
UI
s.
_i
0.
0- UJ O. O. ~ LU
u. vi _i ii i
o c i a o o. x
M z -i « a
xxoacxuj'-
LU U> 2 '-fl & CO X
X < a,
2 UJ UJ O
X X X X J J) i-H
i
I-ZZZZUJUJ-*
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-10
STATISTICAL MEASURES CALCULATED BY SUBROUTINE STAT
Variable Grid Points
Name Included
1. Mean base plume concentration, Cg
2. Mean test (perturbed) plume
concentration, C-j«
3. Mean base field concentration
4. Mean test field concentration
5. Average deviation, Cg-CT
6. Average absolute deviation, Cg-CT
7. Maximum local deviation,
MAX {CB-CT}
8. Maximum base field value,
MAX {CB}
9. Maximum test field value,
MAX |CTl
10. Difference of maxima,
MAX |CB} - MAX {CT}
11. Fractional difference of maxima,
MAX{CB}-MAX {CT}
AVEBO
AVEPO
AVEB
AVEP
AD
ADI
ADO
AAD
A ADI
AADO
XMLD
XMBF
XMPF
DLM
FDLM
BP
TP
BF
TF
BFTF
BTU
BTI
BFTF
BTU
BTI
BFTF
BF
TF
DFTF
BFTF
MAX C
B
12. Correlation coefficient,
RBA
BTU
CBCT ~ °B °T
34
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 2-10 (Continued)
13. Average fractional deviation, AFDO BTI
14. Average absolute fractional deviation
r —PI
CB CT!
AAFDO
BTI
15. Maximum absolute fractional deviation, XMLFDO BTI
MAX J
i r — r i
ICB CT|
16. Fractional deviation of the means
FDM XB~BP
- TP
35
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
(BP) BASE PLUME ONLY
(BF) ENTIRE BASE FIELD GRID
(TP) TEST PLUME ONLY
(TF) ENTIRE TEST FIELD GRID
M/,
(BTI) BASE-TEST PLUME
INTERSECTION
(BFTF) BASE FIELD-TEST
FIELD UNION
(BTU) BASE-TEST PLUME
UNION
Figure 2-5 Grid Subsets Used in the Statistical Calculations
36
-------
ENVIRONMENTAL RESEARCH STECHNOLOGY INC
INITIALIZE NAMELIST 'SAME' PARAMETERS TO DEFAULT VALUES
I
READ USER INPUTS
I
CHECK THAT THE NUMBER OF ARRAYS IN
RUNSTREAM IND1 IS THE SAME AS THE
NUMBER OF ARRAYS IN RUNSTREAM IND2
NO
IS
BYONE EQUAL
T01?
YES
BREAK THE USER DEFINED RUNSTREAMS
INTO SETS OF ONE-ARRAY RUNSTREAMS
READ AN INPUT ARRAY FROM THE BASE CASE
RUNSTREAM. IF REQUESTED (APE= 1), PRINT
THE INPUT ARRAY.
Figure 2-6 Flow Chart of Subroutine STAT
37
-------
ENVIRONMENTAL RESEARCH a TECHNOLOGY INC
NO
YES
FROM THE SUMMED QUANTITIES, CALCULATE
AND PRINT THE COMPLETE SET OF STATISTICS
YES / MORE
C V-^-^ARRAYS LEFT?
MORE
C W--^AR RAYS LEFT
NO
FROM THE SUMMED QUANTITIES, CALCULATE
AND PRINT THE COMPLETE SET OF STATISTICS
I
RETURN
Figure 2-6 Continued
38
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
READ AN INPUT ARRAY FROM THE PERTURBED (TEST) CASE RUNSTREAM.
IF REQUESTED (APE =1), PRINT THE INPUT ARRAY.
CALCULATE THE DIFFERENCE FIELD
IF REQUESTED,
WRITE THE DIFFERENCE FIELD TO THE LINE PRINTER
WRITE THE DIFFERENCE FIELD TO DISK (FILE 25)
PLOT THE DIFFERENCE FIELD
COMPUTE THE PARTIAL SUMS FOR THE DIFFERENCE
FIELD STATISTICS
CALCULATE THE FRACTIONAL DIFFERENCE FIELD
IF REQUESTED,
WRITE THE FRACTIONAL DIFFERENCE FIELD TO THE LINE PRINTER
WRITE THE FRACTIONAL DIFFERENCE FIELD TO DISK (FILE 25)
PLOT THE FRACTIONAL DIFFERENCE FIELD
COMPUTE THE PARTIAL SUMS FOR THE FRACTIONAL
DIFFERENCE FIELD STATISTICS
IF THE WEIGHTED DIFFERENCE FIELD IS TO BE
PRINTED, PLOTTED, OR WRITTEN TO DISK, CALCULATE
THE WEIGHTED DIFFERENCE FIELD
IF REQUESTED,
WRITE THE WEIGHTED DIFFERENCE FIELD ON THE LINE PRINTER
WRITE THE WEIGHTED DIFFERENCE FIELD TO DISK (FILE 25)
PLOT THE WEIGHTED DIFFERENCE FIELD
Figure 2-6 Continued
39
-------
ENVIRONMENTAL RESEARCH* TECHNOLOGY INC
TABLE 2-11
CARD INPUTS TO SUBROUTINE STAT
SUBROUTINE STAT
NAMELIST TITLE - SAME
Parameter
IND1
IND2
BYONE
PRINTD
DISKD
PLOTD
NEWVD
PRINTF
Type Definition Default
INTEGER Base case runstream number.
INTEGER Perturbed (test) case run-
stream number.
INTEGER Determines whether mul.ti-array 1
runstreams are to be treated as
one concatenated data set (pro-
ducing one set of statistics)
or as a group of one-array run-
streams (producing a set of
statistics for each array pair)
BYONE = 1—array by-array
statistics; BYONE = 0—collective
statistics.
INTEGER Line printer output control 0
variable for the difference
fields. PRINTD = 1—difference
fields are printed; PRINTD = 0—
difference fields are not printed.
INTEGER Disk output control variable for 0
the output fields. DISKD = 1—
difference fields are written on
disk; DISKD = 0—difference fields
are not written on disk.
INTEGER Line printer plotting control 0
variable for the difference fields.
PLOTD = 1—plots are produced;
PLOTD = 0—plots are not produced.
INTEGER Plotter contour values control 0
variable (also see Table 2-7).
NEWVD = 1—user input contour
values (if NEWV = 1, user must
insert a DIFF NAMELIST card with
the appropriate contour information)
NEWVD = 0—default input contour
values.
INTEGER Same as PRINTD, except for the 0
fractional difference fields.
40
-------
ENVIRONMENTAL RESEARCH S TECHNOLOGY INC
TABLE 2-11 (Continued)
DISKF
INTEGER Same as DISKD, except for the
fractional difference fields.
PLOTF
INTEGER Same as PLOTD, except for the
fractional difference fields.
NEWVF
INTEGER Same as NEWVD, except for the
fractional difference fields.
PRINTW
DISKW
PLOTW
NEWVW
APE
INTEGER Same as PRINTD, except for the
weighted difference fields.
INTEGER Same as DISKD, except for the
weighted difference fields.
INTEGER Same as PLOTD, except.for the
weighted difference fields.
INTEGER Same as NEWVD, except for the
weighted difference fields.
INTEGER Controls echo of input fields.
APE = 1—input fields are printed;
APE = 0—input fields are not
printed.
41
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
The following are sample card inputs.
• Sample Input—Example 8
TITLE CARD
DEFN
&SAME IOUT=50,&END
SEEK
&SAME NSTART=9,NSTOP=12,&END
SEEK
&SAME NSTART=19,NSTOP=22,&END
SEEK
&SAME NSTART=28,NSTOP=32,&END
STAT
&SAME IND1=1,IND2=2,DISKD=1,PLOTD=1,NEWVD=1,&END
&DIFF THR=-100.E-6,-5.E-6,-l.E-6,-.5E-6,-l.E-15,0,l.E-15,
E.5-6,1.E-6,5.E-6,15*0.0,N=10,&END
STAT
&SAME IND1=1,IND2=3,DISKD=1,PLOTD=1,&END
In this example, the call to subroutine DEFN requests that the
disk output of this MESOFILE run start at Record 50 of disk File 25.
Three runstreams are defined by calls to subroutines SEEK, each
consisting of four arrays. The first call to STAT results in
four sets of statistics; each array of Runstream 1 is compared to the
corresponding array of Runstream 2. The fields associated with the
runstream identified with IND1 are defined to be the base case fields;
IND2 defines the test case fields. The difference fields are plotted
with the user-specified contour levels in the DIFF NAMELIST, and they
are written to disk File 25 (on Records 50 to 53). The second call to
STAT will produce statistics comparing the arrays in Runstream 1 (base
case) to the arrays in Runstream 3 (test case). The difference fields
are plotted with the same contour levels as in the previous STAT call;
when new contour levels are defined (in the DIFF NAMELIST), they
become the "default" contour levels for subsequent calls to the
plotting routine. The difference fields are written to disk File 25
on Records 54 to 57.
2.3 Sample Card Inputs for Some Useful MESOFILE Applications
• Print Library File 13
TITLE CARD
ECHO
&SAME NFILE=13,&END
• Print Library File 13 and NAMELIST File 15
TITLE CARD
ECHO
&SAME NFILE=13,&END
ECHO
&SAME NFILE=15,&END
42
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
Calculate 24-hour S02 averages from hourly output of two
model runs; write results on disk
TITLE CARD
DEFN
&SAME IOUT=1,&END
FIND
&SAME INUMB=1,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=120,&END
FIND
&SAME INUMB=2, IYEAR=78, IDAY=165 , IHOUR=1, IGRIDS=1210, SEND
AVRG
&SAME IRUN=1,AVETM=24,DISK=1,&END
AVRG
&SAME IRUN=2,AVETM=24,DISK=1,&END
Perform statistical analysis of the 24-hour average
concentrations calculated for two model runs in example above
TITLE CARD
SEEK
& SAME NSTART=1,NSTOP= 5,&END
SEEK
&SAME NSTART=6,NSTOP=10,&END
STAT
&SAME IND1=1,IND2=2,&END
Calculate and plot "horizontal" sums of the hourly SC>2
output of two model runs (useful for runs made with
different subsets of the entire source inventory; the
resulting horizontal sum is a superposition of the
concentration fields reflecting the effects of the sources
modeled in two runs)
TITLE CARD
DEFN
&SAME IOUT=11,&END
FIND
&SAME INUMB=3,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=24,&END
FIND
&SAME INUMB=4,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=24,&END
ADD 2
&SAME IRUN1=1,IRUN2=2,PRINT=0,PLOT=1,&END
Transfer a set of 3 hourly concentration fields from the
S02 concentration File (21) to the MESOFILE output File
(25) (useful if the hourly concentration fields are to be
plotted with the Calcomp plotting routine MESOPLOT (see
Section 3).
TITLE CARD
DEFN
&SAME IOUT=35,&END
FIND
&SAME INUMB=4,IYEAR=78,IDAY=165,IHOUR=1,IGRIDS=1,&END
FIND
&SAME INUMB=4,IYEAR=78,IDAY=165,IHOUR=2,IGRIDS=1,&END
FIND
43
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
&SAME INUMB=4,IYEAR=78,IDAY=165,IHOUR=3,IGRIDS=1,&END
ADD1
&SAME IRUN=1,DISK=1,&END
ADD1
&SAME IRUN=2,DISK=1,&END
ADD1
&SAME IRUN=3,DISK=1,&END
44
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
3. MESOPLOT DESCRIPTION
MESOPLOT is a contour plotting package designed to produce
simultaneous Calcomp and line printer contour plots of any
two-dimensional scalar field array, for example, ambient
concentrations, PGT stability class, or mixing heights. Both line
printer and Calcomp plots are made available because the contour lines
in the Calcomp plots are not labeled; the line printer plots enable
the user to easily identify the contour lines. (Modifications of the
Calcomp contour plotting routine may be necessary to make MESOPLOT
compatible with the user's plotting facilities.) Samples of the
Calcomp and line printer plot are shown in Figure 3-1.
Any scalar field which is stored on the direct-access disk
File 25 (MESOFILE output file) can be contour plotted by specifying
IVAR = 1 and the first and last disk file record number containing the
appropriate fields (see Table 3-1). The PGT stability and mixing
height fields, output from the MESOPAC meteorological preprocessor,
may be plotted by specifying IVAR = 2 or 3, respectively. It is
assumed that the stability and mixing height fields are stored on a
data set corresponding to Logical Unit 2. For convenience, different
default contour values are defined for each value of IVAR (see
Table 3-2). The hour, Julian day, and year of the first stability or
mixing height field to be plotted, the number of fields to be plotted,
as well as the time interval (DELTAT) over which subsequent fields are
to be plotted must be specified via the DATE NAMELIST (see Table 3-3)
if IVAR = 2 or 3.
45
-------
ENVIRONMENTAL RESEARCH &TECHNOLOGY, (NC
Oil i 1
11 11000000000
0 0 1 ? 2 21
1122 21
012 ? i 1
111111111111
11111
1111222221
12222222 2
12 233333
2 f 211
VALUE IHRtShUU
U) >
h
t
f
t-
NU&««Mb
O.I
u .s
1.0
•i.U
tl'"
^ U . (1 0
Figure 3-1 (a) Sample MESOPLOT Contour Plots - Concentration Fields
46
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY, INC
VALUE runts
Figure 3-1(b) Sample MESOPLOT Contour Plots - Stability Class Fields
47
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY, INC
' C C C
D D D C C
a o t
' (, C
ecu
U 0
C U
iflUDOIlDDDOOUOODEEEEEE
0 E t t
D E t
DOE EEtEEF
0 0 D t E t F F F F F
ODEEE EEF
U E E F F
e t F F
D EEEEF F F G G
U E
E
C D
UCCLCCO D F
0 0 D D D I) t t f
P E E F F )
UU OfcEFFG
tEDi) DDE EF G
E t U U D I) t t ^ f
t E E t E t
E F
DEE
C C t F F
DEE
G G G
C E F £ D
BBDLEF GF
ACDE GFEE
CD I» F F 0
U6 THRE
0
300
SHOLD
0 Lf.
000 Lt
1_
L
100
4UU
PLOT NUMBER: i VALUE THR
000 9 900
000 A 1000
ooo a isoo
000 M 5000
SHOLQ
000 LE
000 LE
000 LE
L
L
1500
aooo
000
000
Figure 3-1(c) Sample MESOPLOT Contour Plots - Mixing Height Fields
48
-------
TABLE 3-1
CARD INPUTS TO MESOPLOT—'SAME' NAMELIST
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
NAMELIST TITLE - SAME
Parameters Type
IVAR INTEGER
IMAX
JMAX
CALCOMP
NSTART
NSTOP
NPLOTS
METCOD
DELTAT
NEWV
INTEGER
INTEGER
LOGICAL
INTEGER
INTEGER
INTEGER
INTEGER
REAL
INTEGER
Definition Default
Variable plotted 1
(for concentration or other
scalar fields from File 25,
IVAR = 1; for P-T stability
fields, IVAR = 2; for mixing
height fields, IVAR = 3.)
Number of elements in the X 26
direction of the grid to be
plotted (_ 40).
Number of elements in the Y 26
direction of the grid to be
plotted (_ 40).
If .TRUE., Calcomp plots and line .FALSE.
printer plots are produced; if
.FALSE., only line printer plots
are produced.
Disk record number on File 25
of the first field to be plotted
(used if IVAR =1).
Disk record number on File 25 -
of the last field to be plotted
(used if IVAR =1).
Number of data fields to be plotted
(used if IVAR = 2,3).
4-digit identifying meteorological 1003
data code number.
Field will plotted every DELTAT 1.
time steps (used if IVAR = 2,3).
Plotter contour values control 0
variable. NEWV = 1—user input
contour values (If NEWV = 1, the
user must insert a DIFF NAMELIST
card with the appropriate contour
information—see Table 3-2);
NEWV = 0—default contour values.
49
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
TABLE 3-2
CARD INPUTS TO MESOPLOT—'DIFF1 NAMELIST
NAMELIST TITLE - DIFF
(included only if NEWV = 1)
Parameter Type
N
THR (20)
INTEGER
REAL ARRAY
Definition
Number of contour levels
(must be _ 20)
Contour values
Default
see
below
see
below
The default values of N and THR depend on the value of IVAR (see
Table 3-1). The defaults for each value of IVAR are:
IVAR Field N
1 Concentrations or 9
other scalar from
File 25
P-G-T stability
Mixing height 18
THR*
-l.xlO-10 0.1 x ID"6,
0.5 x 10-6, i. x 10"5,
2. x 10-6 5. x io~6?
25. x 10-6, 50. x 10~6
0.5, 1.5, 2.5, 3.5, 4.5,
5.5, 6.5
*The first element of THR should be less than the minimum value of the
field being plotted.
50
-------
TABLE 3-3
CARD INPUTS TO MESOPLOT--'DATE' NAMELIST
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
NAMELIST TITLE - DATE
(included only if IVAR = 2 or 3)
Parameter
JHOUR
JDAY
JYEAR
Type
INTEGER
INTEGER
INTEGER
Definition
Hour of first field to be
plotted.
Julian day of first field to
be plotted.
Year of first field to be
plotted (last two digits
only.
Default
51
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
4. PLOTVEC DESCRIPTION
PLOTVEC is a vector and isotach contour plotting routine for use
with the wind field data generated by the MESOPAC program. PLOTVEC
may require modification to make the Calcomp vector and contour
plotting routines compatible with the user's plotting facilities.
PLOTVEC reads u and v gridded velocity components from a data set
corresponding to Logical Unit 2. These velocity components are
converted to fields of wind direction (measured positive
counterclockwise from the x-axis) and wind speed in meters per second
(m/s). Calcomp vector plots and isotach contour plots are then
generated (see Figure 4-1). A line printer isotach plot is produced
for each Calcomp plot, thus allowing the contour levels of the Calcomp
plot to be easily identified. All the vectors are scaled such that a
length of one grid spacing corresponds to a wind speed of 25 m/s. The
direction of the wind is indicated by the vector direction. A
description of PLOTVEC's input parameters is contained in Tables 4-1
and 4-2.
53
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY, INC
VtLUE THRE
Figure 4-1 Sample PLOTVEC Vector and Contour Plots
54
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
TABLE 4-1
CARD INPUTS TO PLOTVEC—'SAME1 NAMELIST
NAMELIST TITLE - SAME
Parameter
IMAX
JMAX
JHOUR
JDAY
JYEAR
NEWV
Title
INTEGER
INTEGER
METCOD INTEGER
INTEGER
INTEGER
INTEGER
NPLOTS INTEGER
DELTAT REAL
INTEGER
Definition Default
Number of elements in the X direction 26
of the grid to be plotted ( 40).
Number of elements in the Y direction 26
of the grid to be plotted ( 40).
4-digit identifing meteorological data 1003
code number.
Hour of the first field to be plotted.
Julian day of the first field to be -
plotted.
Year of the first field to be plotted
(last two digits only).
Number of data fields to be plotted.
Fields will be plotted every DELTAT
time steps.
Plotter contour value control variable.
NEWV = 1—user input contour values
(if NEWV = 1, the user must insert
a DIFF NAMELIST card with the
appropriate contour information—see
Table 4-2); NEWV = 0—DEFAULT
contour values.
1
12.
0
55
-------
ENVIRONMENTAL RESEARCH I. TECHNOLOGY INC
TABLE 4-2
CARD INPUTS TO PLOTVEC— 'DIFF1 NAMELIST
NAMELIST TITLE - DIFF
(included only if NEWV =1)
Parameter Title Definition Default
N INTEGER Number of contour levels 13
(must be 20).
THR(20) REAL ARRAY Contour values. 0., 2., 4.,
6. , 8., 10. ,
12., 14.,
16., 18.,
20., 25.,
30.
56
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
5. BACKUP01 AND ZER050 DESCRIPTION
Each mesoscale diffusion model run that outputs 502 and
SC>4 concentration data to disk is automatically recorded in a run
log (Library File 13) by the file management system. The disk file
record numbers of the disk output data and all the related run log
information is stored on disk, and can be accessed by the user by
subroutine ECHO of the MESOFILE program (see Section 2.2.1).'
Figure 2-1 is a sample of this file management run log.
As indicated in Section 2.2.1, a normal run termination indicator
ICHECK is one of the variables displayed with the run log
information. The file management system determines the proper
locations (disk file record numbers) of the output concentration
fields before these arrays are actually written on the disk file. A
check is made at the end of the run to verify that all the
concentration fields have been written to disk; the normal termination
indicator is then assigned a value of 1. If, however, the run
terminated abnormally, ICHECK retains a value of 0. An abnormally
terminated run* must be erased from the run log (library file) before
more model runs are made. BACKUP01 accomplishes this by decrementing
the appropriate run pointer in the direct-access disk storage system
files. An attempt to run one of the models when a previous run
terminated abnormally will result in the following message:
ERROR: INCORRECT VALUE IN FILE 13 OF PARAMETER = ICHECK
(Previous run normal completion flag)
BACKUP01 requires no user card inputs. It should be emphasized that
BACKUP01 will remove from the run log the record of the last run made,
making the concentration data produced by the run inaccessible.
When the record of a run has been removed from the run log by
BACKUP01, the disk space occupied by the output of this run is again
available for subsequent model runs. Another application of BACKUP01,
therefore, is to remove model runs where output is no longer needed
from the run log, thus releasing their disk space for future runs.
*Runs that terminate abnormally caused by errors in the user's card
input data may not require the use of BACKUP01. The mesoscale
diffusion models call the file management subroutine, FILMAN, after
all the user's card inputs have been read. It is FILMAN that enters
a record of the run in the run log; if FILMAN has not been called, it
is not necessary to run BACKUPOl. It is suggested, therefore, that
the user verify an ICHECK = 0 with an ECHO of the run log before
running BACKUPOl.
57
-------
ENVIRONMENTAL RESEARCH & TECHNOLOGY INC
Although multiple runs of BACKUP01 is allowed, it may be
desirable to remove in one run the record of all the model runs made
on a particular set of disk files. ZER050 is a program that erases
the entire run log, thereby yielding a 'clean slate1 on which further
model runs may be made.
The most useful application of ZER050 is in a situation in which
the disk files have been filled with data from model runs. It is
possible to spool to tape the entire set of disk files; ZER050 can
then be run, clearing the run log and releasing the direct-access disk
space for subsequent model runs. The data from the first set of model
runs may be accessed by the file management system by transferring the
set of files on tape back to direct-access disk, and then using
MESOFILE for post-processing operations. As with BACKUP01, ZER050
requires no user card inputs. Care should be taken to ensure that the
data stored on the disk files are transferred to tape before running
ZER050, because once the run log is erased, the disk file data are
inaccessible by the MESOFILE program.
58
-------
ENVIRONMENTAL RESEARCH 8 TECHNOLOGY INC
REFERENCES
Bass, A., C. W. Benkley, J. S. Scire, and C. S. Morris 1979.
Development of Mesoscale Air Quality Simulation Models Volume 1.
Comparative Sensitivity Studies of Puff, Plume and Grid Models
for Long-Distance Dispersion Modeling. EPA 600/7-79-XXX,
Environmnental Protection Agency, Research Triangle Park, NC,
238 pp.
Benkley, C. W. and A. Bass 1979a. Development of Mesoscale Air Quality
Simulation Models Volume 2. User's Guide to MESOPLUME (Mesoscale
Plume Segment) Model. EPA 600/7-79-XXX, Environmental Protection
Agency, Research Triangle Park, NC, 141 pp.
Benkley, C. W. and A. Bass 1979b. Development of Mesoscale Air Quality
Simulation Models Volume 3. User's Guide to MESOPUFF (Mesoscale
Puff) Model. EPA 600/7-79-XXX. Environmental .Protection Agency,
Research Triangle Park, NC, 124 pp.
Benkley, C. W. and A. Bass 1979c. Development of Mesoscale Air Quality
Simulation Models Volume 6. User's Guide to the MESOPAC
(Mesoscale Meteorology) Package. EPA 600/7-79-XXX.
Environmental Protection Agency, Research Triangle Park, NC,
76 pp.
Morris, C. S., C. W. Benkley and A. Bass 1979. Development of
Mesoscale Air Quality Simulation Models Volume 4. User's Guide
to MESOGRID (Mesoscale Grid) Model. EPA 600/7-79-XXX,
Environmental Protection Agency, Research Triangle Park, NC,
118 pp.
-------
TECHNICAL REPORT DATA
(Please read Instructions on the reverse before completing)
1 REPORT NO.
EPA-600/7-79-XXX
2.
3. RECIPIENT'S ACCESSION NO.
4. TITLE AND SUBTITLE
Development of Air Quality Simulation Models Volume 5
User's Guide to the MESOFILE Postprocessing Package
5. REPORT DATE
November 1979
6. PERFORMING ORGANIZATION CODE
7 AUTHOR(S)
Joseph S. Scire, John E. Beebe, Carl W. Renkley, and
Arthur Bass
8. PERFORMING ORGANIZATION REPORT NO.
9. PERFORMING ORGANIZATION NAME AND ADDRESS
Environmental Research f? Technology, Inc.
696 Virginia Road
Concord, MA 01742
10. PROGRAM ELEMENT NO.
11. CONTRACT/GRANT NO.
03-06-022-35254/NOAA Contract
12. SPONSORING AGENCV NAME AND ADDRESS
Environmental Sciences Research Laboratory
Office of Research and Development
U.S.Environmental Protection Agency
Research Triangle Park, NC 27711
13. TYPE OF REPORT AND PERIOD COVERED
Contract Report
14. SPONSORING AGENCY CODE
EPA-600/7
15. SUPPLEMENTARY NOTES
Performed under contract to the National Oceanic and Atmospheric Administration
16. ABSTRACT
The MESOscale FILE management and analysis package (MESOFILE) is
a highly flexible post-processing system designed especially for
interface with the MESOPLUME, MESOPUFF, and MESOGRID regional-scale
air quality models, and the MESOPAC meteorology package. The MESOFILE
package is composed of five distinct program modules consisting of
file management, file merging, file manipulation, statistical
analysis, and graphical display.
The file management system automatically catalogues input
parameter values and output file locations of all regional-scale model
simulations; any set of regional-scale model output can, therefore, be
easily accessed for postanalysis. Postprocessing capabilities include
multiple file averaging, multiple file addition, point-by-point and
bulk statistical comparison of two files, contour plots of
concentration and most meteorological fields, and vector plots of wind
fields.
A complete set of users instructions and a full FORTRAN listing
are provided.
17.
KEY WORDS AND DOCUMENT ANALYSIS
DESCRIPTORS
b.IDENTIFIERS/OPEN ENDED TERMS
c. COS AT I Field/Group
*Air Pollution
*Algorithms
Atmospheric Models
13B
12A
04A
13. DISTRIBUTION STATEMENT
Release to Public
19. SECURITY CLASS (This Report)
Unclassified
21. NO. OF PAGES
72
20. SECURITY CLASS (Thispage)
Unclassified
22. PRICE
EPA Form 2220-1 (9-73)
-------
INSTRUCTIONS
1. REPORT NUMBER
Insert the EPA report number as it appears on the cover of the publication.
2. LEAVE BLANK
3. RECIPIENTS ACCESSION NUMBER
Reserved for use by each report recipient.
4. TITLE AND SUBTITLE
Title should indicate clearly and briefly the subject coverage of the report, and be displayed prominently. Set subtitle, if used, in smaller
type or otherwise subordinate it to main title. When a report is prepared in more than one volume, repeat the primary title, add volume
number and include subtitle for the specific title.
5. REPORT DATE
Each report shall carry a date indicating at least month and year. Indicate the basis on which it was selected (e.g., date of issue, date of
approval, date of preparation, etc.).
6. PERFORMING ORGANIZATION CODE
Leave blank.
7. AUTHOR(S)
Give name(s) in conventional order (John R. Doe, J. Robert Doe, etc.). List author's affiliation if it differs from the performing organi-
zation.
8. PERFORMING ORGANIZATION REPORT NUMBER
Insert if performing organization wishes to assign this number.
9. PERFORMING ORGANIZATION NAME AND ADDRESS
Give name, street, city, state, and ZIP code. List no more than two levels of an organizational hirearchy.
10. PROGRAM ELEMENT NUMBER
Use the program element number under which the report was prepared. Subordinate numbers may be included m parentheses.
11. CONTRACT/G RANT NUMBE R
Insert contract or grant number under which report was prepared.
12. SPONSORING AGENCY NAME AND ADDRESS
Include ZIP code.
13. TYPE OF REPORT AND PERIOD COVERED
Indicate interim final, etc., and if applicable, dates covered.
14. SPONSORING AGENCY CODE
Leave blank.
15. SUPPLEMENTARY NOTES
Enter information not included elsewhere but useful, such as: Prepared in cooperation with, Translation of, Presented at conference of,
To be published in, Supersedes, Supplements, etc.
16. ABSTRACT
Include a brief (200 words or less) factual summary of the most significant information contained in the report. If the report contains a
significant bibliography or literature survey, mention it here.
17. KEY WORDS AND DOCUMENT ANALYSIS
(a) DESCRIPTORS - Select from the Thesaurus of Engineering and Scientific Terms the proper authorized terms that identify the major
concept of the research and are sufficiently specific and precise to be used as index entries for cataloging.
(b) IDENTIFIERS AND OPEN-ENDED TERMS - Use identifiers for project names, code names, equipment designators, etc. Use open-
ended terms written in descriptor form for those subjects for which no descriptor exists.
(c) COSATI FIELD GROUP - Field and group assignments are to be taken from the 1965 COSATI Subject Category List. Since the ma-
jority of documents are multidisciplinary in nature, the Primary Field/Group assignment(s) will be specific discipline, area of human
endeavor, or type of physical object. The application(s) will be cross-referenced with secondary Field/Group assignments that will follow
the primary postmg(s).
18. DISTRIBUTION STATEMENT
Denote releasability to the public or limitation for reasons other than security for example "Release Unlimited." Cite any availability to
the public, with address and price.
19. &20. SECURITY CLASSIFICATION
DO NOT submit classified reports to the National Technical Information service.
21. NUMBER OF PAGES
Insert the total number of pages, including this one and unnumbered pages, but exclude distribution list, if any.
22. PRICE
Insert the price set by the National Technical Information Service or the Government Printing Office, if known.
EPA Form 2220-1 (9-73) (Reverse)
------- |