APTD-1086
                           AIR  QUALITY DATA
                           HANDLING SYSTEM
                           USERS  MANUAL
                           U.S. ENVIRONMENTAL PROTECTION AGENCY
                           Office of Air Programs
                           Stationary Source Pollution Control Programs
                           Research Triangle Park, North Carolina 27711

-------
AIR  QUALITY DATA  HANDLING SYSTEM
             USERS MANUAL
             Applied Technology Division
           ENVIRONMENTAL PROTECTION AGENCY
               Office of Air Programs

                 November 1972

-------
The APTD (Air Pollution Technical  Data)  series  of reports  is  issued by  the Office
of Air Programs, Environmental Protection Agency, to  report technical data of
interest to a limited number of readers.  Copies of APTD reports  are  available  free
of charge to Federal employees, current contractors and grantees, and non-profit
organizations—as supplies permit—from the Air Pollution Technical  Information
Center, Environmental Protection Agency, Research Triangle Park,  North  Carolina
27711 or may be obtained, for a nominal cost, from the National Technical  Informa-
tion Service, 5285  Port Royal Road, Springfield, Virginia 22151.
                   Office of Air Programs  Publication  No.  APTD-1086
 11/72                                    ii

-------
                                    FOREWORD

     This manual is a  users  guide for the Air Quality  Data Handling System (AQDHS).
The AQDHS is a computerized processing system for  air quality data.  The system,
which is fully described in this manual,  is intended to be used by state and local
air pollution control agencies.   The manual includes samples of input and output
formats, and card and deck layouts.  User   instructions  are furnished for the
operational requirements, and for implementing the system on local computer
facilities.
     The computer programs for the AQDHS  are available  through the appropriate re-
gional office.  The programs can also be  obtained  from  Control Programs Development
Division by forwarding a blank,  one-half  inch (1/2"), magnetic tape (standard or
mini-reel) with appropriate DCB  specifications required by your installation.
Computer generated flow charts are also available  from  Control Programs Development
Division on special request.
     This system, and documentation of it, was prepared under the direction of
Jerome Mersch, Chief, Data Services Section, Applied Technology Division.  Systems
and program development was performed by  Erik Sieurin,  Jerry Moss, and Joseph Crabb,
Computer Programmers, Data Services Section.  Credit is also given to the contribu-
tions of Stephen Goranson, Carolyn Chamblee, and Lloyd  Hedgepeth, EPA.
11/72                                    iii

-------
                                    CONTENTS

List of Figures	   vi
List of Tables	   vi
Abstract	vlii
1.  INTRODUCTION	   1-1
2.  SYSTEM DESCRIPTION  	   2-1
    2.1  GENERAL	   2-1
    2.2  DATA RECORDING	   2-1
    2.3  DATA STORAGE	   2-2
    2.4  DATA RETRIEVAL AND ANALYSIS	   2-2
3.  SYSTEM OPERATION  	   3-1
    3.1  COMPUTER FACILITY  	 3-1
    3.2  SYSTEM PROGRAMMING 	   3-1
4.  PROGRAM OPERATIONS  	   4-1
    4.1  DATA PREPARATION	   4-1
         4.1.1  Data Transmittal  	   4-1
         4.1.2  Action Cards	4-11
         4.1.3  Deck Setup	4-14
         4.1.4  Data Tape Transmittal	4-15
    4.2  FILE CREATION, STORAGE, AND UPDATE PROGRAMS	4-16
         4.2.1  Description	4-16
         4.2.2  Deck Setup and JCL	4-22
         4.2.3  Input	4-22
         4.2.4  Output	4-25
    4.3  DATA ANALYSIS PROGRAM	4-32
         4.3.1  Description	4-32
         4.3.2  Deck Setup	4-33
         4.3.3  Input	4-33
         4.3.4  Output	4-34
    4.4  DATA REPORT PROGRAM	4-35
         4.4.1  Description	4-35
         4.4.2  Deck Setup	4-36
         4.4.3  Input	4-36
         4.4.4  Output	4-40
    4.5  NATIONAL  AEROMETRIC DATA  BANK INPUT  PROGRAMS  	  4-45
         4.5.1  Description	4-45
11/72                                     iv

-------
        4.5.2  Deck Setup	4-45
        4.5.3  Input	4-46
        4.5.4  Output	4-46
5.  BIBLIOGRAPHY	    5-1
APPENDIX A.  DATA IDENTIFICATION CODES 	    A-l
APPENDIX B.  TRACE AND EXHIBIT FEATURES	    B-l
11/72

-------
                                LIST OF  FIGURES

Figure 1.   AQDHS program sequence	   2-4
Figure 2.   AQDHS deck layout	   3-2
Figure 3.   Air quality data form #1  (1-  or 2-hour sampling  interval)  	   4-2
Figure 4.   Air quality data form *2  (24-hour sampling  interval)	   4-3
Figure 5.   Air quality data form #2  (multiple parameter form)	   4-4
Figure 6.   Air quality data form #3  (multiple station  form)	   4-5
Figure 7.   Action card layout	4-11
Figure 8.   Data base record format	4-15
Figure 9.   AQDHS master file: creation 	  4-17
Figure 10. AQDHS master file: first  update 	  4-18
Figure 11. AQDHS master file: update 	  4-19
Figure 12. Deck setup for AQDHS file management	4-23
Figure 13. Edit diagnostics, AQDHS input 	  4-27
Figure 14. Update action, AQDHS master file	4-28
Figure 15. Update action, AQDHS master file (ADDED only)  	  4-29
Figure 16. Data base record format	4-30
Figure 17. Deck setup for program  STATNL	4-33
Figure 18. JCL deck for program STATNL	4-35
Figure 19. Output format for program STATNL	4-37
Figure 20. Deck setup for program  REPORT	4-38
Figure 21. JCL deck for program REPORT	4-38
Figure 22. Output format for program REPORT: sulfur dioxide	4-41
Figure 23. Output format for program REPORT: soil  index	4-42
Figure 24. Output format for program REPORT: total  suspended  particulates.  .  .  4-43
Figure 25. Output format for program REPORT: sulfation rate	4-44
Figure 26. JCL deck for program NADBIN	4-45
Figure 27. Deck setup for program  NADBIN	4-46


                                 LIST OF TABLES

Table 1.   Air Quality Data Form #1   Card  Layout	   4-6
Table 2.   Air Quality Data Form #2 - Card  Layout	   4-7
Table 3.   Air Quality Data Form #3 - Card  Layout	   4-8
Table 4.   Identification Sort Keys	4-14
Table 5.   AQDHS Master File - Record Layout	4-21
11/72
VI

-------
Table 6.   AQDHS Master File Update Example	4-25
Table 7.   Validation Checks and Error Messages of Program DTBASE	4-26
Table 8.   Control Card Input Format, Program STATNL 	   4-34
Table 9.   Control Card Input Format, Program REPORT 	   4-39
Table 10.  Control Card Input Format, Program NADBIN 	   4-47
Table A-l. State Codes	    A-l
Table A-2. Agency Classification Codes 	    A-2
Table A-3. Project Classification Codes	    A-2
Table A-4. Time Codes	    A-3
Table A-5. Parameter and Method Codes	    A-3
Table A-6. Unit Codes.
A-6
11/72

-------
                                    ABSTRACT

     The Air Quality Data  Handling  System  (AQDHS) was developed to aid air pollution
control agencies in the handling  of their  air quality and meteorological  data.   The
AQDHS is intended to be used by  state  and  local air pollution control agencies  on
their own computer system.
     The AQDHS Users Manual  describes  the  computer system and its operation.  Manual
data preparation specifications  are discussed  in  detail.  The file creation,
storage, and update programs; data analysis programs; data  report programs; and the
National Aerometric Data Bank Input programs are  described  and  their operation de-
tailed.
 11/72
                                        vn

-------
             AIR  QUALITY  DATA  HANDLING SYSTEM

                             USERS  MANUAL


                               1.   INTRODUCTION

     The accumulation of air quality data at state and local agency levels  presents
a problem.   Such agencies need to begin processing their data  at their own
facilities,  using their own  computers.  They need to set up and maintain their own
data files,  to interpret and analyze their data, and to possess a practical  means of
transmitting their data to regional and national levels for inclusion in the larger
computerized data banks now  being set up.  The AQDHS is a computerized data
processing system developed  to help state and local agencies meet these needs.
     The AQDHS is capable of storing, retrieving, and processing air quality and
meteorological data.  The system consists of computer programs to create, update,
and maintain an AQDHS master file.  Computer programs are also available for special
purposes such as analyzing and summarizing the data, and re-formatting data so that
it can be directly input to  the  National Aerometric Data Bank.
     The Environmental  Protection Agency, in order to facilitate the exchange of air
quality data needed for air  pollution control, abatement, and  research, has adopted
the SAROAD (Storage and Retrieval of Aerometric Data) concept, which represents a
standard coding structure, standardized card layouts, and input formats for aerometric
data.   The AQDHS is not part of  the National  Aeroraetric Data Bank (NADB).  The
AQDHS  essentially adheres to the SAROAD concept.
11/72                                  1-1

-------
                            2.   SYSTEM  DESCRIPTION
2.1   GENERAL
     Computerized processing of air quality and meteorological  data  at  the  state and
local agency levels will entail data handling in three phases:   recording,  storage,
and retrieval and analysis.

2.2 DATA  RECORDING
     The first step in using the AQDHS to process air quality  and  meteorological
data is very basic and may not require the use of the computer.  The data,  and their
identification codes, may be tabulated on forms from which  80-column computer cards
are punched, or they may be prerecorded on magnetic tape.   The  punched  cards, which
should be verified, or the magnetic tape, is then submitted to  the computer for
processing by the AQDHS.
     If card input is used, the data, with identification,  are  tabulated on trans-
mittal forms designed for that purpose.  Three AQDHS transmittal forms, #1, #2, and
#3, have been developed.  Each form is designed to handle data  obtained during
specific time intervals.  Form #1  will  accommodate 1- and 2-hour data, whereas form
#2 will accommodate 24-hour or monthly data for multiple parameters,  and form #3 will
accommodate 24-hour or monthly data from multiple stations.   In  this  respect, the
AQDHS transmittal  forms conform to the standard SAROAD input forms,  #1, #2, and #3.
     If the data are properly prerecorded on magnetic tape, the tape can be used to
input the data directly to the AQDHS.  The tape itself must be  compatible with the
tape drives on the computer which the agency intends to use in  running  the  AQDHS.
Agencies planning to use magnetic tape input should place the  data on the tape in
card-image records.  The magnetic tapes should contain BCD  (Binary Coded Decimal)
coded characters recorded at a density of 556 bits per inch, or EBCDIC  (Extended
Binary Coded Decimal  Interchange Code) coded characters recorded at  a density of
800 or 1600 bits per inch.  Internal machine representation of numbers  or characters
is not acceptable.   Floating-point, packed-decimal, or zoned-decimal  representation
of numerical information should not be written.  A mixture  of different codes on a
single tape should also be avoided.  Prior to placing any data  on  tape, a computer
specialist should review the AQDHS in detail to determine how  the  magnetic  tape
should be generated.
     All data must be identified by agency, state, area, site,  project, parameter,
method, units, date,  time, and decimal  codes.  This identification is mandatory for
all transmittal  forms.

11/72                                    2-1

-------
2.3   DATA STORAGE
     The second step in processing the data is  storage, which  involves the computer.
The data, tabulated and punched on cards, or placed on magnetic  tape, are submitted
to the computer for processing and storage on a magnetic  tape  as an  AQDHS master
file.
     Data storage is performed in three separate computer programs.  The  first  pro-
gram accepts the data on the tapes or punched cards as  input,  edits  each  card or
card image for errors, and passes the data to the second program.  The  second
program sorts the edited data by agency, project, state, area, etc., using  all  the
significant codes needed for identification.  The third program creates  an  AQDHS
master file from the sorted data, or merges the data with an existing AQDHS  master
file.  The output of the third program is a new or updated magnetic-tape file of air
quality data.  That tape is referred to  as the current AQDHS master file.
     The data stored in the AQDHS master file are compressed to  conserve space.  One
complete unit record of 1-hour data in the master file will contain a maximum of 24
data fields.  Such a unit record  contains the data for the 24 hours in one full day.
Data for a unit record of 2-hour  data can occupy a maximum of 24 fields, but will
contain a maximum of 12 items of  data, spaced at 2-hour intervals for one full  day.
Twenty-four-hour data occupy a maximum of 31 data fields, and the unit record has
the data of one full month.  Monthly data occupy a maximum of 12 data fields, and
the unit record contains the data for one full year.
     To guard against accidental  destruction of a master file during updating
operations, three complete generations of the master file are always forwarded  with
each updating operation.  The tape reel  containing the AQDHS master maintains the
files as three independent, labeled and  named data sets.
     The AQDHS master file furnishes the data needed for the third step in  the
AQDHS--data retrieval and analysis.

2.4  DATA RETRIEVAL AND ANALYSIS
     Data retrieval and data analysis are performed by three separate  computer
programs.  The first program statistically analyzes the  air quality  data  that have
been stored.
     The statistical analysis computes minimum and  maximum values,  the arithmetic
mean, standard deviation, geometric standard deviation,  geometric mean, and  the 10,
30, 50, 70, 90, 95, and 99.9 percentile occurrences.   The analysis  is performed for
any part of the master file the user wishes.   Specifications are punched  on  a
control card, and the output is presented in simple,  readable  form.  The  analysis
program is written in a conventional  computer language,  FORTRAN  IV,  and can  easily
be expanded for special  analysis  purposes.

2-2                                                                            11/72

-------
     The second program reports the air quality data values in various formats,
depending upon sampling interval.  A limited number of summarizations, such as daily
and monthly averages, is made with each report.  In the report listings, the user
can see the actual sampling values that are stored on the AQDHS master file.  They
are identified by names and places instead of by the numerical codes used in the
computer.
     The names of significant pollutants, states, agencies, methods, units, projects,
and time intervals are stored as tables in the report program, and appear as such
in the report listings.  The user can request data reports for data stored on the
AQDHS master file.  Several output options are available to the user, which, when
exercised, will cause the program to provide multiple reports from a minimum number
of requests.  Examples of these reports, with operating instructions, are shown  in
Section 4.4.
     The third program is strictly a data retrieval routine, and is provided
primarily for coordination with the Environmental Protection Agency.  The program
transfers data from the AQDHS master file to magnetic tape in a format compatible
with the SAROAD system.
     The program output can be mailed to the National Aerometric Data Bank (NADB)
through the appropriate regional office for updating of the NADB master files.
Arrangements for coordination with the National Aerometric Data Bank should be made
through the appropriate regional office.  The name and basic functions of the com-
puter programs that comprise the AQDHS are noted in Figure 1.  Figure 1 also depicts
the sequence in which the programs are normally executed.
11/72                                                                             2-3

-------
                     DATA STORAGE
                                                               UPDATE
                                                               ACTION
                                                           <	«J
                  DATA RETRIEVAL AND ANALYSIS
                                    I   I
DATA ANALYSIS
(STATNL)


                                    '   I
                      STATISTICAL
                       ANALYSIS
                        NATIONAL
                       AEROMETRIC
                       DATA BANK
                     INPUT PROGRAM
                        (NADBIN)
I     DATA
[PRESENTATION
                                                        I   I

                                                      —I
                           Figure  1.  AQDHS program sequence.
2-4
                                              11/72

-------
                            3.   SYSTEM OPERATION

     Operation of the AQDHS requires only a moderate-sized  computer  installation.
Processing is based on handling single, unit records,  not on  storing a large number
of records at any one time.  With the possible exception of a  utility sort routine,
the system does not place heavy requirements  on internal core  storage.
     The actual programming and check out of the AQDHS has  been  performed on an
IBM 360/50 computer equipped with the FORTRAN IV G-level compiler, Release 19, and
the ANSI COBOL compiler.

3.1  COMPUTER  FACILITY
     The AQDHS is programmed to operate on an IBM 360/40 computer equipped with four
tape drives and a core space of at least 110k bytes,  or on  a  computer system of
equivalent size and capacity.   The system is  developed to run  under  the full
Operating System  (OS).

3.2   SYSTEM  PROGRAMMING
     The AQDHS consists of one subsystem which creates and  maintains files, and
separate subsystems for retrieval and analysis, and for input  to the NADB.
     Every effort has been made to keep operational procedures simple.  Each of the
computer programs is furnished to the user with a deck of Job  Control Language (JCL)
cards.  The JCL decks consist of the JCL statements,  which  contain information
required by the OS to initiate and control the processing of  jobs.   The JCL decks
are written to execute the computer programs  as furnished;  that  is,  to execute them
as source decks.
     Executing the programs as source decks is not the only approach, but it is the
simplest one.  JCL statements  can be written  so that  the programs can be run from
previously compiled object decks, or run from programs stored  on a program tape that
uses JCL statements stored in  the procedures  library  of the computer facility.  It
is also possible  to utilize available disk or drum storage  in  various combinations.
An agency desiring a more sophisticated approach to program execution should consult
a competent systems analyst/programmer.
     Figure 2 shows the deck layout of the AQDHS.  All  programs  are  source decks
preceded by JCL decks.   The first three programs are  run as one  job  consisting of
three jobsteps.   The jobsteps  are the program named DTBASE, a  utility sort routine,
and the program named SUPMG.  Together, these three jobsteps  create  and update files
11/72                                    3-1

-------
The three  programs that follow,  STATNL, REPORT, and  NADBIN, are run separately, as
independent  jobs  which analyze data, present data, and provide data in the  proper
format for input  to the NADB.
     In addition  to these card decks, the user must  submit job and message  cards if
required by  the particular computer installation being used.
                                           -SOURCE DECK (PROGRAM NADBIN)

                                              - JCL DECK (PROGRAM NADBIN)

                                                   SOURCE DECK (PROGRAM REPORT)

                                                      JCL DECK (PROGRAM REPORT)

                                                       SOURCE DECK (PROGRAM STATNL)

                                                            JCL DECK (PROGRAM STATNL)
             SOURCE DECK (PROGRAM SUPMG)
                     JCL DECK (PROGRAM SUPMG)
                              UTILITY SORT DECK
                       SOURCE DECK (PROGRAM OTBASE)
                                JCL DECK (PROGRAM DTBASE)
                             Figure 2.  AQDHS  deck layout.
3-2
                                                                                   11/72

-------
                           4.   PROGRAM OPERATIONS

     Program operations for the AQDHS have  been  developed  to make using the system
as simple as possible.   All programs provided  to the  user  will operate as source
decks.  JCL decks are furnished with every  source deck  as  needed.
     The system, thus submitted, will run on  computers  meeting the size requirements
specified.  If computer facilities that differ from the specifications are used, or
if the user wants to make other arrangements  for the  operating system, the handling
of program decks, or the setting-up procedures,  a competent systems analyst/program-
mer should be consulted.

4.1   DATA PREPARATION
     The following sections describe the preparation  of air quality and meteorologi-
cal data derived from instrumentation or observation.   The AQDHS does not include
preconversion of magnetic tape or of any other telemetry output.
     If such conversion assistance is needed,  the agency should contact the
appropriate regional office.  If magnetic  tape,  rather  than punched cards, is used
as input to the AQDHS, the data must appear as card images on the tape, and must be
in accord with the three AQDHS card input  formats shown in the following pages.  In
this situation, a slight modification is needed  in the  JCL deck for the first
program of the storage function (see Section  4.2).
     Update functions are directed by action  cards inserted with the data cards (see
Section 4.1.2).  The preparation of data and  action cards  into a basic deck setup
is outlined in Section 4.1.3.

4.1.1   Data Transmittal
     Air quality and meteorological data are  transmitted on specially designed
transmittal  forms to be keypunched on 80-column  computer cards.  Each of the forms
will  accept one or more of the following sampling intervals:  1-hour, 2-hour, 24-
hour, or monthly.  Figures 3 through 6 are  samples of these forms and Tables 1
through 3 represent the corresponding card  layouts.
     Data are always transmitted with their proper identification.  The identifica-
tion  information consists  of codes which identify the data by form, state, area,
site, agency, project,  time, year, month, day, start-hour, pollutant, method, units,
and decimal  code.  This identification information is basically the same for all
forms.   Following is a  brief explanation of the  identification codes.  Guidelines
11/72                                    4-1

-------
 ro
             Less than 24-hour sampling interval

             0	
                             Agency
                                                    ENVIRONMENTAL PROTECTION AGENCY

                                                     Research Triangle Park, N. C. 27711
                                                                                             State      Area
                                                                                                                 Site
                                                                                                                                      234   56789   10
                                                                                                                                   Agency     Project   Time    Year      Month
                            City Name
                           Site Address
                                                                         Parameter observed
                                                                                                                Method
               Day
                    St  Hr
Project
Rdg1
                                                                        Time interval of obs.
Rdg2
Rdg3
Rdg 4
Rdg5
Rdg6
Rdg7
                                                                                                              Units of obs.
Rdg8
                                                                                                       .gency     Project    lime    Year      Monin
                                                                                                       n     m   n  m   m
                                                                                                        IT        12 13     14     15  16     17  18
                                                                                                         Parametei code     Method     Units    DP
                                                                                                       1111   11   m   en  n
                                                                                                        23  24  25 26 27    IS  29     30 31      32
   Rdg9
96  66  67  68
   Rdg 10
69  70  71  77
  Rdg 11
73  74  75  76
  Rdg 12
77  78  79  BO
                                                                                                                                                            OMB No. 158-R0012
                                                                                                                                                       Approval Expires 6/30/76
-vl
ro
                                             Figure  3.   Air quality data form #1  (1-  or  2-hour sampling  interval).

-------
                                ENVIRONMENTAL PROTECTION AGENCY


                                  Research Triangle Park. N. C.  27711
 24-hour or greater sampling interval
                              OMB No. 158-R0012
                              Approval expires 6/30/78
2

1 Agency
State Area Site

1

1


                       City Name
                                                          2  34687
                      Site Address
                        Project
Time Interval
             Agency  Project   Time    Year     Month
                       n   n   ~~
Day
19 20
0
0
0
0
0
0
0
0
0
1
1
1
1
1
1
1
1
1
1
2
2
2
2
2
2
2
2
2
2
3
3
1
2
3
4
5
6
7
8
9
0
1
2
3
4
5
6
7
8
9
0
1
2
3
4
5
6
71
8
9
0
1
St Hr
21 22































































Name
PARAMETER
Code





23 24 25 26 1
Method Units





28 29 30 31
331 34 36 3




























































































































7
8































DP
32

Name
PARAMETER
Code





37 38 39 40 41
Method Units

42


43
47 4
































44
B 4

































46
i 60































































DP
D
46

Name
PARAMETER
Code





SI 52 63 64 66
Method Units

56




,
67 58 69
81 82 63 6





























































































4
































DP
D
to

Name
PARAMETER
Code





86 88 87 88 69
Method Units

70





71 72 73
75 78 77 78




























































































































DP

74
                4321
                                     43210
            Figure  4.   Air  quality  data  form #2  (24-hour sampling interval).
11/72
                                                                                            4-3

-------
                       ENVIRONMENTAL PROTECTION AGENCY


                         RESEARCH TRIANGLE PARK, N.C. 277)1
                                                                    OMB No. 158 R0012
                                                                  Approval Expires 6/30/76
                                                        STATE  AREA
                                                                        SITE
2
1 AGENCY
CITY NAME
SITE ADDRESS
PROJECT TIKE INTERVAL

PARAMETER
NAME METHOD UNITS












PARAMETER
NAME METHOD UNITS












PARAMETER
NAME METHOD UNITS












PARAMETER
NAME METHOD UNITS












PARAMETER
NAME METHOD UNITS












PARAMETER
NAME METHOD UNITS












FILTER
137 Ml
(51-60)
1(5741
(23 32)
137 4(1
151 601
165 Ml
[23 321
1374(1
(51 «OI
165741
(23 321
137461
(51 Mi
1(5 741
123 321
[374(1
151 601
165 741
123-321
[37 46,
151 601
(65 741


|

1 1



234S678910
AGENCYPROJECTTIME YEAR
D m D m
11 1213 14 15 16
DAY ST HR
CD CD
19 20 21 22
NUMBER AIR VOLUME
PARAMETER CODE METHOD UNITS DP








































PARAMETER CODE METHOD UNITS OP








































PARAMETER CODE METHOD UNITS DP








































PARAMETER CODE METHOD UNITS DP








































PARAMETER CODE METHOD UNITS DP








































PARAMETER CODE METHOD UNITS OP
I
4-
1






























MONTH
m
17 18
PARTICULATE
WEIGHT
VALUE
(33 30
147 50)
161-64)
(757!l
13336)
147 SOI
(6144)
(75781
133 36)
(4750)
[(1441
17578)
133361
147501
161-641
f757!)
133 3(1
147 SOI
Id 441
(75-781
133-3(1
147501
'61 60
.", •«•
















VALUE
















VALUE
















VALUE
















VALUE
















VALUE














l

             Figure 5.   Air quality data  form #2  (multiple  parameter  form),
4-4
                                                                                        11/72

-------
                           ENVIRONMENTAL PROTECTION AGENCY
                              RESEARCH TRIANGLE PARK, N.C.  27711
   OMB No 158 R0012
Approval Expires 6/30/76
3
1 AGENCY
PARAMETER OBSERVED TIME INTERVAL
METHOD UNITS PROJECT
STATE AGENCY PROJECT TIME
m n rn n
23 4 56 7
PARAMETER METHOD UNITS DP



_LJ L
8 9 10 11 12 13
YEAR MONTH
m m
18 19 20 21
LJ
14



15 16 17
SITE ADDRESS A SITE ADDRESS B
SITE t
DAY
rof24-25,
'37-38,
(50-51)
(63-64)
DDRESS C
START
HOUR AREA SITE




(26-32)
(39-45)
(52-58)
(65-71)













SITE ADDR
A (33-36)
„ (46-491
D
c (59-62)
D (72-75,
ESS D
VALUE


















SITE ADDRESS E SITE ADDRESS F
SITE
DAY
[ | | (24-25)
22 23 ,37-38)
(50-51)
f63-64)
ADDRESS G
START
HOUR AREA SITE




(26-32)
(39-45)
(52-58)
,65-711













SITE ADDR
E 133-361
p (46-49,
G '59-62'
H '•«-«'
ESS H
VALUE


















SITE ADDRESS 1 SITE ADDRESS J
SITE
DAY
1 1 1 (24-25)
22 " ,37-38,
(50-51)
(63-64)
ADDRESS K
START
HOUR AREA SITE




(26-32,
(39-45)
(52-58)
(65-71 )












SITE ADDR
1 (33-36)
S (46-49)
K (59-62)
L (72-75)
ESS L
VALUE

















              Figure  6.   Air quality data  form #3 (multiple station  form),
11/72
                                                                                        4-5

-------
                 Table 1.  AIR QUALITY DATA FORM #1 - CARD LAYOUT
Card Column
1
2-3
4-7
8-10
11
12-13
14
15-16
17-18
19-20
21-22
23-27
28-29
30-31
32
33-80
Picture
Xa
XX
xxxx
XXX
Ab
XX
X
XX
XX
XX
XX
xxxxx
XX
XX
X
X...X
Value
Form code
State code
Area code
Site code
Agency code
Project code
Time code
Year code
Month code
Day code
Start-hour code
Parameter code
Methods code
Units code
Decimal code
Data field
             Alphanumeric  character
             Alphabetic character

and references for their proper use  are  given,  as well  as  bounds  for  the  validation
checks performed in the program.   (The user  may refer  to Tables A-l through  A-6  of
Appendix A to locate codes which  are commonly used.)

     Form Code
     The three SAROAD transmittal-form codes currently accepted by  the  AQDHS are:
     form #1, 1- or 2-hour data;  form #2,  multiple-parameter  data;  and  form  #3,
     multiple-station data.
     State Code
     The names of the states  are  arranged  alphabetically,  and assigned  numbers  from
     1 to 52.  For consistency, both the District of Columbia and Puerto  Rico are
     considered states.   These  state codes are  shown in Table A-l,  Appendix  A.
     Area Code
     Within each state, the names of all incorporated  areas with  a  population of more
     than 2500, and all  counties, are arranged  alphabetically and assigned a four-
     digit number.  County codes  are used  only  for  stations located outside  incorpo-
     rated areas.
 4-6
11/72

-------
                  Table  2.  AIR QUALITY DATA FORM #2 - CARD LAYOUT
Card Column
1
2-3
4-7
8-10
11
12-13
14
15-16
17-18
19-20
21-22
23-27
28-29
30-31
32
33-36
37-41
42-43
44-45
46
47-50
51-55
56-57
58-59
60
61-64
65-69
70-71
72-73
74
75-78
Picture
Xa
XX
xxxx
XXX
Ab
XX
X
XX
XX
XX
XX
xxxxx
XX
XX
X
xxxx
xxxxx
XX
XX
X
xxxx
xxxxx
XX
XX
X
xxxx
xxxxx
XX
XX
X
xxxx
Value
Form code
State code
Area code
Site code
Agency code
Project code
Time code
Year code
Month code
Day code
Start-hour code
Parameter code
Methods code
Units code
Decimal code
Data field
Parameter code
Methods code
Units code
Decimal code
Data field
Parameter code
Methods code
Units code
Decimal code
Data field
Parameter code
Methods code
Units code
Decimal code
Data field
             Alphanumeric character
             Alphabetic character
11/72
4-7

-------
                 Table  3.   AIR QUALITY  DATA  FORM  #3 - CARD LAYOUT
Card Column
1
2-3
4
5-6
7
8-12
13-14
15-16
17
18-19
20-21
22-23
24-25
26-29
30-32
33-36
37-38
39-42
43-45
46-49
50-51
52-55
56-58
59-62
63-64
65-68
69-71
72-75
Picture
Xa
XX
Ab
XX
X
xxxxx
XX
XX
X
XX
XX
XX
XX
xxxx
XXX
XX
XX
xxxx
XXX
xxxx
XX
xxxx
XXX
xxxx
XX
xxxx
XXX
xxxx
Value
Form code
State code
Agency code
Project code
Time code
Parameter code
Methods code
Units code
Decimal code
Year code
Month code
Day code
Start-hour code
Area code
Site code
Data field
Start-hour code
Area code
Site code
Data field
Start-hour code
Area code
Site code
Data field
Start-hour code
Area code
Site code
Data field
             Alphanumeric  character
             Alphabetic  character
4-8
11/72

-------
     Site  Code
     Specific sampling  sites  are  designated  by  a  three-digit number.   Users are
     advised to  contact the National  Aerometric Data  Bank  to obtain  their site codes.
     Agency Code
     The type of agency responsible  for the  sampling  is  designated by  a single,
     alphabetical  code.   The  current agency  codes are shown in Table A-2, Appendix A.
     Project Code
     The project codes  classify projects  by  the reasons  for generating the data.
     The principal  categories are shown in Table  A-3, Appendix A.
     Time  Code
     A single-digit numerical code.   The  time codes used by the AQDHS  to indicate
     sampling intervals are shown in Table A-4, Appendix A.
     Year  Code
     A two-digit numerical  code.   An AQDHS data validation check  accepts year codes
     from  1960-1980.
     Month Code
     A two-digit numerical  code.   An AQDHS data validation check  accepts month codes
     from  01 to  12.
     Day Code
     A two-digit numerical  code.   The AQDHS  accepts day  codes from 01  to 31.
     Start-Hour  Code
     A two-digit numerical  code.   The operation of the start-hour code is described
     in Section  2.3 of  this manual.   Its  relation to  the time code plays an impor-
     tant  part in  data  validation tests.
     Parameter Code
     A five-digit  numerical code  which permits  a  branching subcategorization of pol-
     lutants.  Table  A-5, Appendix A, contains  a  list of frequently  used parameters
     and methods,  and their codes.   If a  pollutant method  is encountered which is not
     presently in  Table A-5,  contact NADB to update the  table.
     Method Code
     A two-digit numerical code designating  the methods  of collection  and analysis.
     Table A-5,  Appendix A, contains  the  codes  for frequently used methods and
     parameters.
     Unit  Code
     A two-digit numerical code used  to designate the unit of measurement.
     Frequently  used  units are shown  in Table A-6, Appendix A.
11/72                                                                            4-9

-------
     Decimal  Code
     A single-digit  numerical  code  from 0  to  4 which  indicates the number of  digits
     in the  data field  that  are  to  fall  to the right  of  the decimal point.
     Data Field
     The data fields containing  the data are  four-digit  numerical fields.   Data  must
     be keypunched right-justified  with leading-left  zeroes.

     The user is  urged  to contact the  NADB through  the appropriate  regional  office
to obtain the coded  designators  (area  code and site code)  that identify sampling
stations within his  state.   This will  enable  all  data at the  local,  state,  and
national level to  be uniquely identified and  compatible.
     The transmittal forms  differ somewhat in the ways in  which  the  data are entered.
This is particularly so with regard to the time  and start-hour codes  for different
sampling intervals.
     The AQDHS transmittal  form #1  is  shown in  Figure 3, and  the layout of  the 80-
column computer card to be punched from the transmitted  information  is shown in
Table  1.  Form #1  is used to transmit  both 1- and 2-hour data.
     When the form is used to transmit 1-hour data, the  time  code for form  #1 is 1.
The start-hour code is  then 00 for a.m. readings, and 12 for  P-fl-  readings.   A desig-
nation of the time of the day at which the reading  was made is entered in the column.
A complete set of 1-hour data for one  24-hour day requires punching  at least two
cards, and a 24-hour set may be spread out over  as  many  cards as needed; the number
of cards required depends upon the manner in  which  the data are  made  available for
submittal.
     When form #1  is used to transmit  2-hour data,  the time code is  2.  The start-
hour code is then 00 or  01,  depending on whether the readings were  initiated on an
even or an odd hour of  the day.   Twelve readings complete  the data  for one  24-hour
day; again, the readings may be submitted and updated as they are made available.
     The AQDHS form #2  exists in two formats.  Figure 4  shows the first format,
entitled "24-hour Sampling Interval,"  which is  to be  used  for a maximum of  four
different pollutants sampled at 24-hour intervals for a  maximum of 31 days.   Figure
5 shows the second format of form #2,  entitled "Multiple Parameter Form."   It can be
used for data obtained  at 24-hour or monthly sampling intervals.  It is capable  of
handling a maximum of one reading for  each of 24 pollutants,  all sampled in the  same
24-hour period, or all  sampled during  the same month.
     The time code for  both formats of the AQDHS form #2 is  7 for 24-hour data and  8
for monthly data.   Note that the start-hour code is not  necessarily significant now.
The start-hour code which is entered in the master  record  is  that of the first data
 4-10                                                                           11/72

-------
item processed.  This  start-hour code may or may not hold true for data  (24-hour  or
monthly) items subsequently  processed.   Table 2 shows the layout of the  80-column
computer card which  is  to  be punched from this information.
     The AQDHS form  #3  is  entitled "Multiple Station Form," and is capable  of
handling both 24-hour  and  monthly data.   It is used for transmitting data which have
the same parameter,  but were obtained at different stations.  The time code  is 7  for
24-hour data and 8 for  monthly data.  The start-hour code in form #3, as in  form  #2,
can be significant if,  and only if, the data items processed after the first item are
all processed in accordance  with the initial start-hour code.  Table 3 shows the
layout of the computer  card  to be punched from this information.

4.1.2  Action Cards
     In addition to  creating a master file, the AQDHS updates the data in that file.
A special computer card known as an "action card" has been devised to instruct the
computer to delete,  change,  or add data to a master file.
     An action card  (Figure  7) is an 80-column card which has only two entries, a
dollar sign in column  1, and an action  code in column 2.  The action code is a one-
digit number, 1 for  delete,  2 for add,  or 3 for change.  The action card is  inserted
in front of the air  quality  data card,  or group of cards, to which it refers.  The
action code remains  the same for all following cards, until the program  encounters
another action card.   For  example, if a group of cards is to be added to the master
file, one action card marked $2 is inserted in the deck in front of the  first card of
that group.  The action code will  remain 2, that is, "add," until the program encoun-
ters a new action card  with  another action code.
 $a
 0 0 0 0 0 0 H 0 li 0 0 0 0 3 0 5 0 0 D 9 C 0 3 0 3 0 0 D 0 0 0 0 0 0 0 3 0 8 0 0 8 0 0 0 0 I! 0 0 9 0 a 0 a 0 0 0 0 0 0 D 0 0 0 0 0 0 0 0 0 0 a 0 G C 0 0 0 0 0 0
 i  I 3 * i b ; s D 13 n  ' :] u >', i! ii i' n ;: : r. -, ;< :; n ji ?3 .-3 \r, ji ]> u ?! ]• >b :' •' '; ;) n n u 11 JJ.JD o jj 49 S3 'J w i] w li •* •• >* '.i w ti J 6) ci ci C6 61 bE M ID it a n it h t6 I! ;; 13 to
 I  1 1 1 ! 1 1 1 1 M H 1 1 i  M 1 1 11 I I I M 1 ! 1 11 t I 1 I 1! ! 1 1 1 1 I I 1 1 1 11 1 !' i 1! 1 1 M I 1 1 I 1! I I I II ! I ' 1 I I I 1 1 1
 2  2 2 2 2 2 2 2 2 2 2 2 2 7 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ? 2 2 2 2 2 2 2 I 2 2 ? 2 2 2 2 2 2 2 2 ? 2 2 2 2 2 2 ; 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 ::?; 2 2
                            Legend
                            $  - Action card

                            a  - Action code:  1 = Delete
                                              2   Add
                                              3   Change
 5  S 8 B 8 8 8 8 8 8 E 8 E U 8 8  B fl B & 8 8 C 3 B 8 3 B 8 C " E 3 8 t 2 C 8 C 6 $ 8 3 fl 8 8 3 8 0 3 : 2 8 8 3 8 I) 3 3 8 11 8 8 8 8 (1 8 8 3 3 fl 8 8 II 8 8 8 3 B 8
 S  9 3 9 3 S fl 9 3 3 S 9 S 9 0 5  3 3 9 9 9 9 9 9 9 9 9 9 9 3 9 S 9 9 9 9 9 9 3 9 3 3 3 9 9 9 9 3 9 3 9 9 9 9 9 9 9 9 : 9 9 D 9 0 0 3 9 9 9 9 9 9 9 9 S 9 3 9 9 9
 V]  7 3 * b 6 I 3 9 IQ H I? IJ li I' IG II H ]l ?0 n V ?3 N ;i 2E ?l H n .0 U 11 3] 3J Jl 3b 31 33 39 id 41 U *3 U Jl Ib JJ flfl 19 >3 jl 1? S3 M Lj 'jG ^1 j3 33 oj Gl b/ b3 G* Ci &S bl 6S 63 10 'I I? I] M li IE 11 Ifl J9 53  /
 	                          HP/ ECC SORI	_^/

                            Figure 7.  Action  card  layout.
11/72                                                                              4-11

-------
     Agencies are cautioned that the action code is only used on AQDHS forms; it is
not reproduced as part of any records that can be directly transmitted from AQDHS to
the National Aerometric Data Bank.  The exact effect of the three action codes in
updating an AQDHS master file is discussed below.

4.1.2.1  Delete Card ($1)   The action card is inserted in front of a data card, or
data cards, containing the information to be deleted.  The data card is then re-
ferred to as a delete card.  A delete card is a regular air quality data card in one
of the three previously defined forms.
     The identification portion of a delete card is checked against the AQDHS master
file.  If a matching record is found, the entire record matching the identification
is deleted, and will not be included in the updated master file.  Because the
identification is the only portion of a delete card checked against the master, a
delete card may or may not have entries in the data field.
     A delete card for 1-hour data deletes all 24 data fields in one full day.  A
delete card for 2-hour data deletes all 12 data fields in one full day.  A delete
card for 24-hour data deletes all 31 data fields in one full month.  A delete card
for monthly data deletes all 12 data fields in one full year.  In every case, one
entire record is removed from the file.
     If no record is found in the master file to match the identification of the
delete card, no deletion takes place, and the error message UNMATCHED DELETE IGNORED
is printed out.
     All air quality data cards that follow an action card marked $1 become delete
cards until a new action card marked with a different action code ($2 or $3) is
encountered.

4.1.2.2.  Add Card  ($2) - The action card is inserted in front of a data card, or
data cards, containing the information to be added.  This data card is then known as
an add card.  An add card is a regular air quality data card in one of the three
previously defined forms.
     An add card can be used to create a new record in the master file containing one,
some, or all of the data readings in the data fields.
     An add card can be used to add one or more data readings to an established
record in the master file, if no data readings have previously been entered into the
corresponding data fields of the master.
     Under no circumstances can an add card be used to change a data reading already
contained in the master file.
     Both the identification and the data portion of an add card are checked against
the AQDHS master file.  If a record is not found in the master file to match the

 4-12                                                                           11/72

-------
identification of the add card, the add card is inserted as a newly created record
in proper sequence according to the established sort keys.   If a record is found in
the master file to match the identification of the add card, the data portions  of
the master record and the add card are compared.   If the data field in the master
record which corresponds to a data item on a matching add card has a previously en-
tered item of data, there is conflict between the record in the master and the  add
card, and no change takes place.  The add card is rejected, and the error message
MATCHED ADD IGNORED is printed out.
     An add card is accepted, and the master file is modified, only if there is no
conflicting data item.  If only one data item is  in conflict and the other data items
are proper, the entire add card is still rejected and no add takes place.
     Following an action card marked $2, all air quality data cards become add  cards
until a new action card marked with a different action code ($1 or $3) is encountered.

4.1.2.3.  Change Card ($3) - The action card is inserted in front of a data card, or
data cards, containing the new data to be inserted.  This data card is then referred
to as a change card.  A change card is a regular air quality data card in one of the
three previously defined forms.
     A change card is used to change one or more data readings in an established re-
cord in the master file.  Such data readings must have previously been entered  into
the corresponding data fields of the master.
     Both the identification portion and the data portion of a change card are  checked
against the AQDHS master file.
     If no record is found in the master to match the identification of a change
card, no change takes place, and the error message UNMATCHED CHANGE IGNORED is
printed out.  If a record is found in the master file to match the identification of
the change card, the data portions of the master record and the change card are com-
pared.  A specific data item in a change card replaces the corresponding data item
in the master file if the master contains a corresponding, previously entered item of
data.  If the master record is found to contain no such previously entered data item,
the change record is in conflict with the master record.  No change takes place, and
the error message UNMATCHED CHANGE IGNORED is printed out.
     A change card is accepted, and the master file modified, only when no data item
is in conflict.   If only one data item is in conflict, and other data items are
proper, the entire change card is rejected, and no change takes place.
     Following an action card marked S3, all air quality data cards become change
cards, until a new action card marked with a different action code  ($1 or $2) is
ei.-Of. *~ered.
11/72

-------
     The following special cases may be of interest:

     1.  A record of data can be deleted and added, or added and deleted, in one and
         the same run.
     2.  A data card can be submitted in one and the same run as a change and as an
         add in no particular order.  The legitimate update is processed, and the
         other is rejected.
     3.  To eliminate a specific item of bad data from a record in the master file,
         enter a change with "9999" punched in the appropriate data field.  Note that
         if, in a subsequent update run, the correct value is obtained for this item,
         it must be processed as an add.
     4.  A standard filler for data in the AQDHS master file records that are not
         complete is "9999."

4.1.3   Deck Setup
     Table 4 shows a typical layout of a deck of data and action cards ready to be
included on a file-maintenance or file-creation run.

                         Table 4.  IDENTIFICATION SORT KEYS
Sort key
1
2
3
4
5
6
7
8
9
10
Field sizea
1
2
2
4
3
6
2
1
6
2
Typeb
A
N
N
N
N
N
N
N
N
N
Name
Source agency code
Project code
State code
Area code
Site code
Parameter code
Method code
Time code
Date
Start-hour code
             Field size is expressed in 8-bit bytes.
             Type: A = alphanumeric; N = numeric.

     In order to be accepted by the 360 OS, the card deck must be preceded by a
special data card which has the appearance:
     //GO.DD1  DD DATA
The card deck must be followed by an end card that appears as:
     /*
4-14
                                                                                11/72

-------
     If a particular  run  is  for  the  purpose of creating an AQDHS master file, only
one action card  is  used—an  add  card ($2),  which is the first card of the data deck.
All data cards following  will  be added;  that is, they will create a new file.  If
the run is for regular maintenance,  the  appropriate action cards are included with
the data cards,  as  described in  Section  4.1.2.

4.1.4  Data Tape Transmittal
     Data can also  be transmitted into the  AQDHS directly from magnetic tape, paper
tape, or any other  form of direct telemetry.  This is possible if the data records
written on such  devices are  card-image records of one or more of the defined, card
input formats established in Section 4.1.1.  If, for instance, it is necessary to
enter data directly from  magnetic tape,  modifications such as the following must be
made to the program.

                                        -360 SYSTEM END CARD

                                              DATA CARDS
                                                 -ACTION CARD
                                                    DATA CARDS
                                                      ACTION CARD
                       DATA CARDS

                           ACTION CARD
                            DATA CARDS
                             ACTION CARD
                               DATA CARDS
                                 ACTION CARD
                              SPECIAL DATA CARD
                              (//GO.DD1 DD DATA)

                       Figure 8.  Data preparation - deck setup.

     The special data card  mentioned in  Section 4.1.3, and shown with the deck setup
in Figure 8 above, must  be  replaced  by  three cards in order to specify the tape  used
for input.  If  the tape  has the volume  serial  number 006999, data set name DATA1,  and
label number 1, the  cards would be  as shown on the following page.
 11/72
                                                                                  4-15

-------
     //GO.DD1      DD     UNIT=TAPE,VOL=SER=006999,DSNAME=DATA1,
     //                  LABEL=1,DISP=(OLD,PASS),
     //                  DCB=(RECFM=FB,LRECL=80,BLKSIZE=800)

     If paper  tape or any other special  telemetry device is used, the specification
cards must be  changed accordingly.   Such specification cards replace all the cards
shown in the deck setup in Figure 8, with the exception of the last card, the 360
system end card.
     It is probable, however, that if such direct telemetry output media are used in
the place of cards, the action cards are not part of the data, and the action code
must then be transmitted by other means.  In this situation, the action code is
transmitted as a parameter in the card marked "Parameter Card" in the JCL listings
(Figures 9 through 11).  If the records  on the tape are to be processed as add
records, the parameter card will appear as follows:

     //     PARM.GO=$2

If all the records are "change" records, the parameter card will be:

     //     PARM.GO=$3

     The only restriction imposed by this approach is that the data contained on
any one tape must all be either add, change, or delete records.   However, it is per-
fectly admissible to run a tape twice in the same run, once for the add records, and
once for the change records.  It is very unlikely that material  will be submitted as
delete records on this basis.
     If a tape or telemetry device actually has action records inserted with the data
as specified in Section 4.1.2, the action code is not submitted as a parameter, and
the only program modification is the specification of the data set DD1, as shown
above.

4.2   FILE CREATION, STORAGE, AND UPDATE  PROGRAMS
     The Air Quality Data Handling System performs the functions of file creation,
storage, and management, as well as those of data retrieval and analysis.  The
storage and update functions are performed by two ANSI COBOL computer programs, and
by a standard, utility sort routine.

4.2.)  Description
     Storage and update functions are performed as one job consisting of three pro-
gram steps.
 4-16                                                                            11/72

-------
//
//STP1
//
//
//
//
//
//COB.SYSIt!
                                  JOG 1 I1CSSAGL CARDS
                                  EXF.C   COr;l,CLG,
                                  PIGICN.C03 =9?K,
                                  PARK. CCO ( ' SIZL--90000 ,CUI>COOO' ,
                                                              .
                                  PARM.ULD='NOLIS1 .(lOXP.EF.LCT1
                                  PARl;.GO=0'J
                                  DD     WTA
                           IMCLUlJE SOURCE Dr.f!; OF
                           PROGRAM CTBASt
                                                                                   -Parameter  Card
                  /*
                  //GO.DD2
                  //GO.LU3
                  II
                  //CO.DDT
                DD
                DD
                DCD
                DATA
                          INCLUni-I  DATA AIID
                          ACTIO;I CARI;:
                  /*
                  //STP2          CXEC  SORT
                  //SORT.GOI'TIN   DD    USCAIX^SIiTPT ,1INIT»TAPE,
                  //              DCD=(R!Xn>Fu,IJ:LCl -SI ,CLIC5!7.:=C10) ,nirP=(OLD,PASS)
                         .soi-m.r.oi  DD iiMT=3Y.si)A,SPAcr=(TR,i.,(ic) , ,cn:;Ti")
                  //soRT.sop.Ti.'Koa  nn ij;in=!rYscA,Gr7CL=(Tn:,(i5),,co:iTiG)>
                  //             AFF=SO!'TI'i-ni
                  //SORT.SCr'TV.'KO-I  t:? UllT-l-Y'.lJA.SPACL-fTP;-:, (1 ^) , ,CC:,TIG) ,
                  //SORT.SYSIi;
                   SORT Fir.LDS = (3,l.A,';>?,A.O,2)A>3/-,M2)3,A>lb,!;,A,2n
                          24,1 .A.Zy.Z.A.ffi^.A.Sl.Z.A^S.Z.Aj.FfipriAT-Ci:
                  END
                  //STP3          EXEC  CO:"Cn,
                  //
                  //
                                  r?
                                 CD    l-'i'iA ^-~'.i LLTILL
                                 DD    RS::'V':--:.l.lLLriLE
                                 DO    rri'/r.'-
                                                                                       flew Master
                                                           Old  raster
                              Figure  9.   AQDHS  master  file:  creation.
11/72
                                                                                        4-17

-------
                     //             JOL f, MESSAGE  CARDS
                     //STPl         EXEC    rGliUCLG,
                     //             nEGio;(.cc;,-9rK,
                     //             PAm.CCiL,= ( 1SIX.E=90000,L27,2,A,29,2JA,31,2,A,2!),2,A)FORt!AT=CII
                       END
                     //STP3         EXEC   COCUCLG,
                     //             REGION.COB=9EIC
                     //             PARM.CO[J=('SIZE=90000,BUF=8000'  ,
                                     'NODECI'.,KOSOURCE,SUP!'AP,t!CCLIST,HOXrEF'),
                     //             PARH.LKED-'NOLIST.IiOXREF.LET1
                     //COB.SYS IN    DD      DATA
                             INCLUDE  SOURCE  DECK CF
                             PROGRAM  SUPHG
                      /*
                      //60.DD1
                      II
                      //GO.DD2
                      II
                      //GO.DD3
                      //GO.DD4
                      //
                      //GO.DD5
                      //GO.DOS
                      //GO.UD7
                      //GO.DD17
                      /*
                      II
                                                                                  New Haster
DD  Ui!IT=TAPE ,VOL=(,, ,1 ,SER=00619C) ,DS"AHE=AQDIIS1 ,
DCC=(RECFM=FB,LRECL^160,nLi;SlZE=1600),DISP=(,KEEP),LABi:L=l
DD  UNIT=TAPE,VOL=REF=*.GO.DD1 ,DSHAME=AQDHS2,
LADEL=2,DISP=(,IXtP),DCfc=*.rO.DDl
DD  DS;iA;;t=Nl!Ll.FILE
DD  US;W!f.=AqDHSl ,VOL=(,, ,1
UNIT=TAPE,DISP=(OLD,PASS),LA8EL=1,DCB=*.GO.DD1
DD  DSNAME=NULLFILE
DD  USIWiE=SRDL!PD,DISP= (OLD,PASS)
DD  SYGOUT=A
DD  UilIT=SYSDA,SPACE = (
Old Master
                         Figure  10.   AQDHS  master file:  first update.
4-18
                                                                                                         11/72

-------
         INCLUDE si';:;u  CECK  or
                                                         Parameter Card
 ii
 //CO.DDl
        li'iCLUDE n.'UA AliD
        ACT I Ot; CAIIDS
 /*
 //STP2         ^XLC  SORT
 //S'jRT.SOUTIil  CD    DJ,iA;-',E=Sr'.T'1TsU:iIT=TArE,
                  DO u;;iT=SYf2A,sr/.cE.=--(TP>i;, (i 5) , ,r.^::T
 //SORT. SORT1,. K03  CH  U.'lll =SYSP/\SPACE=(TRK, (1 5) , , COMIC) ,
 //            AFF=SORT'.,'1,01
 //SOf(T.SOFAQPHS3,
                                LABEL=3,DISr=(,r.CEP),DCt>*.GO.PDl
                      DD4       DD      DSHAM=AQDKS1,VOL=(>,,1,SER=OOG190),
                                UNIT=TArE,DISP=(OLD,PASS),LACLL=l,DCC-*-.GO.DDl
                      DD5       DD      DSflAME=AqDllJ2,\'OL = REF=*.nn.DD4,
                                UNIT-TAPE, DISP=(OLD,PASS) ,LAGEL=2,DCt=*.GO.DD1
                      DDG       DSNAKE=SRDUPD,DISP=-- (OLD, PASS)
                      CD7       DD      SYSOUT=A
                      DD17      DD      uriIT=SYSDA,SPACE=(TRK,(10,10))
                                                                    Now  Master
                                                                           °ld '''aster
               Figure  11.   AQDHS master  file:  update.
11/72
                                                                                           4-19

-------
     The first step consists of a computer program named DTBASE, which inputs and
edits data.  The purpose of this step is to input data in the form of AQDHS data and
action cards.  The input data are validated, and diagnostics for all error conditions
are printed out.  Data passing all edit tests are accepted as good data, and are
transformed into the AQDHS common, data-base format.   The data-base format is an
81-character transaction tape record.  The data-base transaction tape is fed directly
into the second program step.
     Program step 2 is a standard, utility sort routine, which sorts the data-base
records in numerically ascending order according to the sort keys shown in Table 4.
The output of step 2 consists of the sorted data-base records.  The output is
written on tape as a data set named SRDBS, and uses the number of the update as a
label number.
     The purpose of the third program step, which involves the computer program
SUPMG, is to use the data on the sorted tape file to create or update the AQDHS
master file.  The update action code is again validated, and diagnostics are provided
via printer output.
     The master file is a magnetic tape record (Table 5) consisting of fixed length,
160-byte, unit records.  Each unit record has an identification part and a data part
which were created and completed during the updating process.  The identification
part is the 33-byte identification field of the AQDHS data-base record.  The data
part consists of 31 4-byte data fields.  The stored data are compressed as outlined
in Section 2.3.
     Three complete generations of master files are forwarded with each updating
operation.  The files are maintained as three, independent, labeled and named data
sets on the tape reel containing the AQDHS master.   The master with its three current
generations may occupy more than one, but not more than five, tape reels.  Provisions
are made for tape volume switching.
     Labels and data set names are written and specified on the JCL cards; no action
is required by the user.  Apart from preparing the AQDHS data cards or magnetic tape
for input, and preparing the proper action cards, the user merely specifies the tape
volume serial numbers of the old master and the new master, and furnishes the update
number.   As a safeguard during the updating procedure, the old master must be retained
until  the updated records have been inspected.
     A user may retrieve records lost by accidental destruction of a master file
during an update in two ways.  Such accidental destruction of records could occur,
for instance, if an action card marked "delete" is  entered in front of a single
record which is to be deleted, but an action card marked "add" or "change" is not  in-
serted behind that single record.  Such neglect would mean that the rest of the cards
4-20                                                                           11/72

-------
in the deck were not marked as add cards or change cards, but as delete cards,  and
that a number of records could be deleted.

                     Table 5.  AQDHS MASTER FILE - RECORD LAYOUT
Bytes
XX
X
XX
XX
xxxx
XXX
xxxxx
XX
XX
X
XX
XX
XX
XX
X
xxxx
xxxx
xxxx

xxxx
xxxx
XXX
Description
Blank (not used)
Agency code
Project code
State code
Area code
Site code
Parameter code
Method code
Unit code
Time code
Start-hour code
Year code
Month code
Day code
Decimal point code
Data field 1
Data field 2
Data field 3

Data field 30
Data field 31
Blank (not used)
     The easiest way to retrieve lost records is to rerun the entire update process
using the same tape assignments throughout, correcting only the necessary action or
air quality data cards.  The entire new master file will be rewritten as though the
faulty update had never been made.  This procedure may be repeated as many times as
needed to achieve a perfect file.  This also applies in the event of a systems failure
during an update.  The whole update process is simply rerun without any changes.
     If the second or third generation master file is needed for an updating opera-
tion, it is called by using DSNAME=AQDHS2 and LABEL=2, or DSNAME=AQDHS3 and LABEL=3,
in the card marked "Old Master" in Figure 9.
11/72
1-21

-------
4.2.2  Deck Setup and JCL
     The function of file management is to establish and maintain an AQDHS master
file of air quality data.  Procedurally, file creation and file updating are
identical; they differ only in the control information which must be submitted by
the user.
     Figure 12 shows the deck setup for this program.  The user furnishes job cards,
and message cards if required by the particular computer installation.  The three
program steps, preceded by their respective JCL decks, then follow.
     Program step 1 consists of a JCL deck, which is shown in detail in Figure 9.
The source deck for the program DTBASE follows this first group of JCL cards.
Following the source deck is a second set of JCL cards and the data and action cards.
An end card consisting of /* terminates step 1.
     Program step 2 consists of a JCL deck and sort specification statements.  The
deck is shown in detail in Figure 9.  An end card again completes the step.
     Program step 3, also listed in Figure 9, consists of a group of JCL cards, a
source deck for the program SUPMG, and a second group of JCL cards.  Two end cards
are required to complete the job step and the job.

4.2.3   Input
     Input material consists of air quality data cards and action cards, assembled
into a deck as shown in Figure 8.  The position of the input deck within the program
is shown in Figure 12.
     A total of three magnetic tape drives are needed to operate the system, provided
direct-access storage facility (disk, drum, etc.) is available.   The JCL programming
depicted in Figures 9 through 11 is based on using three tape drives, plus disk
storage for data set number DD17, as follows:

     //GO.DD17     DO     UNIT=SYSDA,SPACE=(TRK,(10,10))

     If direct access storage is not available, the system can be run by using four
tape drives.   The data set number DD17 must then be changed to call for a scratch
tape.   No tape serial number will be needed, since this scratch tape need not be
saved.   The specification would be:

     //GO.DD17     DD     UNIT=TAPE,DSNAME=UPDTE,DISP=(,PASS),
     //                   DCB=(RECFM=FB,LRECL=133,BLKSIZE=1330)

     As part of the input to the program, the user must specify the tape volume
serial  numbers of the other three tapes to be used during an update operation.  Some
4-22                                                                            11/72

-------
                                 360 SYSTEM END CARDS
                                      STP3JCL CARDS
                                        (DATA SETS)
                                         SOURCE DECK (PROGRAM SUPMG)
                                               STP3JCL CARDS

                                                  STP2 JCL CARDS
                                                      INPUT DATA AND ACTION CARDS
                                                             STP1 JCL CARDS
                                                               (DATA SETS)
                 SOURCE DECK (PROGRAM DTBASE)
                                  STP1 JCL CARDS—
                                JOB AND MESSAGE CARDS'
                   Figure 12.  Deck setup for AQDHS  file  management.
of these  specifications do not change; they are  obtained only once from the computer
facility.   Others  must be changed at every run.
     The  update  tape will have a volume serial number  that will  not be changed.  It
will, however, have  a different update number  for every  run.   The card that carries
the update  number  is marked "Update Card" in Figure  11,  and is reproduced here:
     //SORT.SORTOUT
DD
DSNAME=SRDUPD,VOL=(,,,2,SER=006195) ,LABEL=3,
     In the place  of the number 006195, the user  punches  his  own update tape number,
which does not  need  to be changed.  The update number  is  punched in the place of the
number 3 following the term LABEL.  This number is  increased  by 1  at every run.  The
user must be  careful  to keep track of the update  number.   If  a system fails during an
update, the entire process is rerun using the same  update and tape numbers.
 11/72
                                                                                   4-23

-------
     The AQDHS master file is written on magnetic tape, and the user must again re-
cord his own tape volume serial number.  This must be done prior to every run, since
the file is always written on a new tape reel.  This is done on the card marked "New
Master" in Figure 11, and reproduced here:

     //GO.DD1     DD     UNIT=TAPE,VOL=(,,,1,SER=006196),DSNAME=AQDHS1,

     In the place of the number 006196, the user punches the number of the tape upon
which his new, updated master file is to be written.  If more than one tape reel is
needed to contain the new, updated master file, the number ,,,1, is changed accord-
ingly.  The maximum number of tape reels that can be used is five.  Furthermore,
the user must specify to the computer the tape volume serial number (or numbers) of
the current master file—the master file which is to be updated.  This is done on the
card marked "Old Master" in Figure 9, and appears as:

     //GO.DD4     DD     DSNAME AQDHS1,VOL=(,,,1,SER=006194)

     For regular updating of an established file, the user might need one, two, or
possibly as many as five tape reels, depending on the size of the file.  The infor-
mation enclosed in parentheses would then be punched by the user in one of the
following ways:

     (,,,1,SER=006194)
     (,,,2,SER=006194,006183)
     (,,,3,SER=006194,006183,006188)
     (,,,4,SER=006194,006183,006188,006191)
     (,,,5,SERO06194,006183,006188,006191 ,006192)

     These procedures apply to regular updating of an existing AQDHS master file.
When an agency creates a new AQDHS master file, only slight differences are involved.
     The process of file creation  involves update number 1.  The JCL deck for update
number 1 is shown in Figure 9.  The only difference between this JCL deck and the one
used for a regular update is that  an old master file does not exist.  Since an old
master does not exist, only one data set is written on the new master file.
Consequently, all the other data sets must be eliminated.  This is done by simply
entering the work NULLFILE into the DSNAME slot on these cards.  For the same reason,
the first regular update (update number 2) of a newly created file must also
eliminate some data sets.  This procedure is shown in Figure 10.
     Only one current (old) master file exists before update 2.  The old master file
is updated, and the updated master is written as data set number 1 on the new master.
 4-24                                                                           11/72

-------
The current master file is simply copied as data set number 2 on the new master.
During  update number 2, two data sets are marked with NULLFILE as shown in Figure 10,
     Updating runs which follow update number 2 are performed as regular updates, and
the JCL decks are composed as shown  in Figure 11.  In every run, the current master
is updated and written as data set number 1 on the new AQDHS master.  The current
master  is simply copied and written  as data set number 2 on the new master.  The
second  data set of the current master is copied and written as data set number 3 on
the new master.  The third data set  of the current master is not used (see Table 6).

                     Table 6.  AQDHS MASTER FILE UPDATE EXAMPLE
Data set number
1
2
3
Data set name
AQDHS1
AQDHS2
AQDHS3
Data set label
1
2
3
4.2.4   Output
     The user receives output from both of the computer programs connected with the
file management system.  The program DTBASE prints out diagnostics for all AQDHS
cards which for various reasons were rejected and could not be used to create or up-
date the master file.  The program SUPMG prints out the disposition of all data
submitted as input and not previously rejected by the DTBASE program.
     The diagnostic output from the program DTBASE comprises a thorough validation
check of the data submitted as input.  If an air quality data card or card image
does not pass all validation checks, no data on that card or card image are processed.
The error on the card or tape must be corrected, and the corrected card must be input
during a subsequent update run.  The specific check features now in the system, withnh
attendant error messages are given in Table 7.  Figure 13 shows the actual printer
listings for AQDHS data cards which did not pass one or more of the defined valida-
tion checks .
     The output from the program SUPMG is a complete list of all actions taken during
the updating of the AQDHS master file.  Data on AQDHS input cards or tape that did
not pass the validation checks in program DTBASE will not appear on this listing.  As
shown in Figures 14 and 15, the listing is comprised of two columns, one headed
DATABASE RECORD PROCESSED and the other, ACTION TAKEN.  Care must be taken to note
the format of the first column in order to determine which data have been acted upon.
Each line in the first column is actually a magnetic tape file record capable of con-
taining up to 12 data values, depending upon the time code of the input data, as well
as upon the order in which the data was originally input.  The format for this record
(Figure 16) is the format of the transaction tape file produced by program DTBASE
and subsequently by the sort.

11/72                                                                            4-25

-------
          Table 7.  VALIDATION CHECKS AND ERROR MESSAGES OF PROGRAM DTBASE
     Type of error
     Blank card
     Blank data  field
     Embedded blanks in data
        field (form #1 only)
     Form 0 or blank
     Form code 4, 5, or 6
     Form code > 6
     State code  0 or state
        code > 60
     Form code 1 with time
        code other than 1 or 2
     Form code 2 or 3 with
        time code other than
        7 or 8
     Time code 1 with start-
        hour other than 0 or 12
     Time code 2 with start-
        hour other than 0 or 1
     Year code < 60 or > 80
     Month code  < 1 or > 12
     Day code <  1 or > 31
     Decimal code > 4
     Action code < 1 or > 3
     Any embedded blank

     Alphabetic  or other
        non-numeric character
        (except agency code)
Message printed out
BLANK CARD
CARD CONTAINS NO DATA
EMBEDDED BLANKS IN DATA
  FIELD
NO SAROAD FORM CODE
SAROAD FORM CODE NOT USED
ILLEGAL SAROAD FORM CODE
ILLEGAL STATE CODE

TIME CODE NOT USED FOR
  AQDHS
TIME CODE. INCOMPATIBLE
  WITH THIS SAROAD FORM

START-HOUR INCOMPATIBLE WITH
  TIME CODE
START-HOUR INCOMPATIBLE WITH
  TIME CODE
ILLEGAL DATA CODE (YEAR)
ILLEGAL DATA CODE (MONTH)
ILLEGAL DATA CODE (DAY)
ILLEGAL DECIMAL CODE
ILLEGAL ACTION CODE
EMBEDDED BLANKS OR ILLEGAL
  CHARACTERS IN CARD FIELD
EMBEDDED BLANKS OR ILLEGAL
  CHARACTERS IN CARD FIELD
Action
Card ignored
Card ignored
Card not processed

Card not processed
Card not processed
Card not processed
Card not processed

Card not processed

Card not processed
Card not processed

Card not processed

Card not processed
Card not processed
Card not processed
Card not processed
Program terminated
Card not processed

Card not processed
     When data are input using AQDHS card format 1, a data base transaction record is
created and processed for each card.  As a result, the data base transaction record
could contain from 1  to 12 data fields, depending on the number of data values punched
on the card.  When data are input using AQDHS card formats 2 or 3, a data base record
is created for each data value punched on the card.  Therefore, only data field 1
will be used in the data base record for formats 2 and 3.  It is very important to
understand the difference between the data base record created by card input format 1
and the data base record created by card input formats 2 and 3.  When a data base
record is not processed, one must know exactly which data have not been processed,
 4-26
                                                11/72

-------
                                                      ***** _tC IT-D IAGNOSTICS FOP ACCHS  INPUT  DATA  CARDS  *****
                                   IF3RMA1- AQCHS-ll :     1Q35. L2L10iA66171 07320042<.Cl35027442518353121 670779296843380971078937
                         _                                   .
                                *» ERROR:  ILLEGAL  DATE  CODE  ( CAY I :
                                ** ACTICN: CARC  NCT PROCESSED.


                         ~V**' CARD (CPRMAT   AOOHS-il :     1035 1 21 1 CIA 6617 1 0732 12424 C'. 910111 881 04916433 13 1 50569061921618707712982 193841 8563
                         _ *« ERROR;  ILLEGAL  DATE  CODE  (PAYJj _____
                                *» ACTICN: CARC  NCT PROCESSED.


                          *** CARCL(FQRMAT   AOCHS-M :     10351211 01A66171033200424C191 Oli 376750298767719731 11 53*996155341 5303293375199501
                                ** ERROR:  ILLEGAL  CATE  CODE  (CAY);
                                ** ACTION; CARD  NOT PROCESSED.
                          *** CARD IFCRMST   AQCHS-1):     10351211 01A6617 1033212424 C191CU 839873389390705078067A3'i2078978668	EOIT-OIAGN-02	
ro
                                                         Figure  13.   Edit diagnostics,  AQDHS  input.

-------
.&.
 I
00
                      ***** ACTIGNS TAKEN DURING UPDATE OF AQDHS PASTER FILE ****
       DAJTA BASE_RECgRD_PRCCESSEO

23B0320026000V1110J91017C07007170 3333
22BC32CC2600C
-------
                                          ***** ACTIONS TAKEN DURING UPOATE OF AQOHS MASTER FILE ****
CATA BASE RECORD PROCESSED
2280320026000*1120181097007004081
22BC3200260004112018109700 7004091
2280320026000*1 120 18109 700 7004101
22BC32Q0260.05K1120181C970.0 70041 11
22B032002600C41 1201 810970070041 21
22B032002630041120181C97C07004131
22BC32002600041120181097007PC4141
22B032002600041120181097CC7CC4151
22B032002600C411201810970f 70T4161
226032002600C41120181C97007CP4171
22Br32002600041120181C970C70C4181
228032002639041 1201 81 09700 70C 4 191
22BC 3200260004 11201 81 CS7CC7CC42C1
22BO 32002600041120181 G97CU7C042 11
22B032C02600C4112C181C97e07Ca4221
22B03200260C^41 1201 81 C 970^70042 31
22Bf 3230260f)r*112C 181 T9 7(10 7CJ4241
22BC320Q2603C41 120 181 697007^042 51
22BC3203260CC41l2tl81C97CC7:)i-;4261
22B032dD2603:41120181-97rr7C:4271
22BC3200260C'-4112ri81 '9 7CC 7'V4281
22B03230260004112C181C97CC7Gu4291
22BC32002600C4112018H:97C070iJ4301
22BC32002600C41120ieiC97CG7(.L5Cll
22B032002600''4112C>leit97C07vH-5l31
228032C0260QC41L201,81C97Cj7r.05041
120012642800014260111071007110312
12GJLLZ4426CQQ1426011107H27U0312
12G012642800014260111071C07111C12
12G012642800014260111071127111012
12GO 1264280001 426C1 11C71C071 11032
12G01264280001426C111071127111C32
12G012642800014260 11107 1007 11 1042
12GC 126428000 1426C1 11071127111C42
12GC 126428000142601 1107 1C07 11 1052
12GO 12642800014260 11 1071 127 111C52
liGC 12642 8000 14260 111C7 10071 11C62
12GO 126428000 142601 11071 127 111C62
12GC 12642 6000142601 1107 10071 11072
12GO 126428000 14260 11 107 1127 11 10 72
12GC 126428000 14260 11 107 1007 11 1C 82
12GO 126428000 14260 11 1071 1271 11082
12GOi2642eOC014~2601 110710071 11CS2
1260 126428000142601 1107 11271 11092
UGC 126428000 14260 111C71CC71 11102
12GO 126428000 142601 11071 1271 11102
l2G0126«2e006i426ClHC710071111l2
12GO 126428000 14260 11 107 11 27 111 112

0010
0012
0015
0010
0011
0012
OC13
0016
nr>i7
'.'017
0017
0018
OT2C
C321
JJ17
0016
OJ14
H1J
nccs
i';c_6
CC34
TOG 8
•J?C3
J002
3306
0007
CCCC
0006
0004
cocc
CCC4
OOC6
CCC6
occe
0001
cccs
cccs
0003
coco
OC05
0008
cccc
0021
OC42
0012
0033
COC6





CCCC
ooot
OCC2
OCC1
CC02
0005
0005
CCCS
ococ
cccs
cccs
0003
occo
OCC7
0009
COCC
0022
CC38
OC13
0028
0006





CCOC
occe
cccc
CCC2
OCC1
COC4
0005
ccce
oooc
COC4
cccs
0003
oocc
0004
0010
cocc
0024
OC37
CC13
0015
ccc?





OOC2
COC9
ocoo
COC3
OCC1
0001
0005
COC7
0000
0006
CC09
0003
0000
ooo<
0012
nci4
C021
0029
OC12
0009
0004






0002
OCC6
nooo
CCC7
OOC2
0001
ooce
roco
ococ
0005
OOK
0003
OOC2
noo<
0013
OC13
0022
OC29
0024
OCCS
0014






OCC3 OC03
ccc7 ecu
ooco ocoo
con ccio
0008 OC10
OOCO OC02
0010 0012
ooco ococ
COC4 CCC3
0007 0006
CCC9 CCIO
0004 0003
0001 OCOO
COC6 CCCS
0013 0013
CC14 OC16
C023 CC1S
0029 0031
00 6 S C061
0009 OC09
0004 OC29





0004 00(15
0013 001C
0001 0006
OOC6 0007
OC09
0008 0007
0021 OC18
0009 Of06
0000 0002
0000 0000
0007 OOC9
0011 0013
0001 OOC1
OOCl 0004
001C 0011
0003 0001
0020 0022
0022 OC2t
0065 0067
0058 0062
0016 0020
0038 0032






0006
OCC2
0001
OOC6
0008~
0001
OC13
0006
0002
0001
OC09
0004
occe
0004
ccce
occe
0021
CC41
0041
0079
OC40
0026






0006
OCC3
0002
0006
ooce
0002
0006
0006
0003
OC03
0009
0003
OOCO
0006
0008
OCOO
0020
OC57
6620
0043
CC2S
0015









0005
0003
OOOC
OOC6
0003
0006
0007
0005
0005
0009
0003
0000
0003
0008
0000
0021
0051
6612
0038
00 10
0020

ACTION TAKEN
ADDED
ADDED
ADDED
AQQE& 	
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
AOOEC
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDED
ADDEC
ADDED
ACCEC
ACOEC
ADDED
ACCEC
ADCED
ACCEC
ACCEC
ADDEC
ACCEC
ACOEC
ACOEC
ACCEC
ADCEC
ACDED
ADDED
AODEC
ACCEC
ACDEC
>CCEC
ADDED
ADDEC
ACCEO

ro
10
Figure  15.   Update action,  AQDHS master file (ADDED only).

-------
co
o
                               IDENTIFICATION
DATA
xj x x jxxjxx










i





i ;
i

•
! QJ QJ
•-OI-D
tu o o
-a o o
<_> C >,
o o
E -T c
o
LJ_
4->; 
O
*
D-
*O
XXXX








XXX XXXXX XX

xx xixxlxxixx
1 1











I






"O
o
O QJ

QJ QJ t-
•o : -o : 

fO QJ fO
QJ ; 4—* ' ^
S- •!- IO
-o
O "O
o
-a u








QJ
T3
o





XX



1




'




X













S-
o '•
8 -T
O -H 1
-c •*->  j QJ

OJ

^J
o
o

to

+-> -r-
d
o
tO 0)
Q Q




















xxxx xxxxjxxxx'xxxxixxxx'xxxx'xxxx xxxx




i






.— CVJ

•a "a









j


i
ID r^ ; co
! i
-a • -o i -o : T3 i TS ~o
01 OJ i OJ 0)
4- ! M- i 4- 1 4-
|
to : to I to
fO • tO 'i rO
Q , Q Q
03
10
Q
OJ 01
4- 4-

1O tO
10 IO
Q ! Q
xxxx











O"i

T3
OJ
^-


-------
from which input cards they came, and how to correct the situation.   An  understanding
of the data base record and of the description of ACTION TAKEN should be sufficient
to handle any necessary corrections.
     The second output column of the program SUPMG, headed ACTION TAKEN, refers  to
the action performed on coinciding data base transaction records.  Possible actions
and their descriptions are:

     ADDED
     This action indicates that all data values listed in the coinciding data base
     transaction record have been added to the AQDHS master file under the identifi-
     cation given.
     MATCHED ADD IGNORED
     This action indicates that one or more of the data values listed in the coin-
     ciding data base transaction record have already been stored in the AQDHS master
     file, and that the input data base record has been ignored.  That is, none of
     the data fields shown for the data base transaction record under consideration
     have been added to the AQDHS master file.
     CHANGED
     This action indicates that all data values listed in the coinciding data base
     transaction record have replaced similarly identified data on the AQDHS master
     file.
     UNMATCHED CHANGE IGNORED
     This action indicates that one or more of the data values listed in the coinci-
     ding data base transaction record does not have a similarly identified data value
     already stored on the AQDHS master file, and that the data base transaction
     record shown has been ignored.  That is, none of the data fields shown for the
     data base transaction record under consideration have replaced any data on the
     AQDHS master file.
     DELETE
     This action indicates that all data related to the identification portion of the
     coinciding data base transaction record have been deleted from the AQDHS master
     file.  For this action, the data fields are ignored.
     If the identified time code is 1, the 24 data values for the identified day are
     deleted.  If the time code is 2, the 12 data values for the identified day are
     deleted.  If the time code is 7, the 31 data values for the identified month
     are deleted; in this case, the day code has no meaning.  If the time code is 8,
     the 12 values  for the identified year are deleted; in this case, the month and
     day codes have no meaning.
11/72                                                                            4-31

-------
      UNMATCHED DELETE IGNORED
      This action indicates that data matching the identification of the coinciding
      data base transaction record could not be found on the AQDHS master file, and
      that no data were deleted from the AQDHS master file.

 4.3   DATA ANALYSIS  PROGRAM
      The purpose of the data analysis program (STATNL)  is to allow state and local
 agencies to perform simple statistical  analyses for air quality and meteorological
 data stored on an AQDHS file.  The analysis program computes the maximum and minimum
 values, arithmetic mean, standard deviation,  geometric  standard deviation,  geometric
 mean, and the 10, 30, 50, 70, 90, 95, 99,  and 99.9 percentile occurrences.

 4.3.1  Description
      The data analysis program uses data stored on the  AQDHS master file, and is  run
 separately, as a program independent of file  maintenance or creation.   This basic
 statistical analysis program is written in FORTRAN IV language, and can be  easily
 expanded for special needs.
      The following statistics are used in  this program  (x represents  a raw  data value
 and n represents the number of values):

      Arithmetic Mean:
0 =
      Arithmetic Standard Deviation:
/ n \2 1
n i y 4 x 1
2—i x • ~ Yi = 1 /
i=l ' n
n - 1
1/2



~ ""
, , , s2
2 2 2 ^ 1 2 n;
X+Y+ + y
xi X2 n n
n - 1
                                                                                    1/2
      Geometric Mean:
                      't
       x  = Antilog  \ i=1
Li  log x.
4-1       I
log x,  + log x9 + .  .  .  + log x
      Geometric Standard Deviation:
                    a  = Antilog
£ (log x.)2 -
n
f n \2 ~
E log x.j
O' = l 7
n
n 1
1/2
 4-32
                                                          11/72

-------
     Note that since the logarithm of  a  zero  value  is  negative  infinity the  NADB
has adopted the substitution of  half the minimum  detectable  value  of the given
pollutant for a zero value.  Thus, for example, if  the chemical  analysis of  sulfur
dioxide is accurate to 5 micrograms per  cubic meter,  a value of 2.5  micrograms per
cubic meter is substituted  for a zero  value.

4.3.2  Deck Setup
     The user is furnished  a complete  program source  deck  and a JCL  deck.  To these
decks must be added job and message cards required  by  the  individual  computer
facility.  The user must also add certain control cards and  the 360  system end cards,
and must punch the AQDHS master  tape volume serial  numbers in the  proper JCL card.
These procedures are outlined in Section 4.3.3.   A  complete  deck setup is  shown in
Figure 17.
                                                    360 SYSTEM END CARDS
                                                        CONTROL CARDS
                                                              JCL CARDS
                                                             '(DATA SETS)
                 SOURCE DECK (PROGRAM STATNL)
                                       JCL CARDS

                                JOB AND MESSAGE CARD(S)
                      Figure  17.   Deck  setup  for  program STATNL.
4.3.3   Input
     The  input  material  furnished by the user for the data analysis program consists
of job and message  cards,  control  cards, and certain modified JCL cards.  The user
must submit  job and message  cards  required by the individual computer installation.
 11/72
4-33

-------
The user also furnishes control cards to designate the data and the time intervals
for which the analysis is to be performed.
     For every analysis, the user submits full specification codes for agency,
project, state, area, site, parameter, method, units, and time.  In addition, two
sets of dates (year, month, day) must be furnished, "from" and "to," in order to
indicate the inclusive starting and ending dates of the period of analysis.  Further,
as described in Section 4.3.1, the user may specify the pollutant minimum detectable
value and decimal point indicator for that value used in the substitution of zero
                                                                  DP
data values.  If these two fields are left blank, a value of   10"    (where DP is the
pollutant reporting decimal point) will be substituted for any zero value encountered,
     To analyze the entire file for a specific time period, one control card contain-
ing the start date (columns 24 through 28) and stop date (columns 29 through 34) is
necessary.  The rest of the card is blank.  This option, therefore, uses only one
control card and will result in the analysis of each site and pollutant given in the
master file.  Another convenient option is to analyze the entire file for a certain
pollutant-method.  For this option, the user need only specify pollutant and method
code, as well as start and stop dates, on one control card.
     The input format of the control card is shown in Table 8.  Next to the column
of dates, there is a field entitled "Additional Area Information."  Information en-
tered here will appear at the head of the output listing.  It is suggested that this
information identify sampling station locations.

                 Table 8.  CONTROL CARD INPUT FORMAT, PROGRAM STATNL
Card Column
1
2-3
4-5
6-9
10-12
13-17
18-19
20-21
22
23-24
25-26
27-28
29-30
31-32
Picture
Aa
xxb
XX
xxxx
XXX
xxxxx
XX
XX
X
XX
XX
XX
XX
XX
Value
Agency code
Project code
State code
Area code
Site code
Parameter code
Methods code
Units code
Time code
Year code (From)
Month code (From)
Day code (From)
Year code (To)
Month code (To)
4-34
11/72

-------
                Table  8 (continued).   CONTROL CARD INPUT FORMAT,  PROGRAM STATNL
Card Column Picture Value
33-34
35-38

39
40

41-80



XX
xxxx


X

Day code (To)
Minimum detectable
value
Blank
Minimum detectable
decimal point
Additional area information, at user's
discretion. Content of this field is
simply listed on output (city name, street
name, site description, etc.).
a Alphabetic character
b „ -, ,
     Modifications to the JCL cards include the volume serial number of the tape on
which the AQDHS master file is written.  (This master file is needed for the

analysis.)  The user punches this tape number in the place of the number 006196 on

the card labeled "master" in Figure 18.  That card appears as:
     //GO.FT08F001
DD
DSN=AQDHS1,VOL-SER=006196 ,
The user must add the  customary  360  system end cards /* and // at the end of the deck
            II
            II
            //FORT.SYS IN
     JOB  CARD
     EXEC FORTGCLG
     DD     DATA
                        INCLUDE SOURCE DECK
                        OF PROGRAM STATNL
            /*
            //GU.FT08F001
            II
            II
            //GO.SYSIN
                                                                       Master
     DD     DSN=AQDHS1,VOL=SER=006196 ,
     DISP=(OLD,KEEP),UNIT=TAPE,LABEL-1,
     DCB=(RECFM=FB,LRECL=160,BLKSIZE=1600)
     DD     DATA
                      INCLUDE DATA
                      CONTROL CARDS
11/72
            /*
            //
                       Figure 18.  JCL deck for program STATNL.
                                                                                4-35

-------
4.3.4  Output
     For the user's convenience, the program stores a number of tables internally.
These tables translate coded input data into actual names, places, units, pollutants,
etc.  They may be expanded from time to time, but are up to date as they appear  in
Appendix A.
     Figure 19 shows the output format.  A separate output listing is received for
every control card submitted if it differs from the other control cards with respect
to site code and one or more of the other codes.  Control cards that differ only with
respect to site code will receive listings on the same computer output page.

4.4  DATA  REPORT PROGRAM
     The data report program (REPORT) furnishes a clean presentation of the material
stored in the current AQDHS master file.  Output is furnished for the different
categories of data, and simple summations are made.

 4.4.1  Description
     The data report program uses data stored on the AQDHS master file, and is run
separately, as a program independent of file maintenance and creation.
     The report program is written in ANSI COBOL language.   The program produces
fixed-format listings of the 1-hour, 2-hour, 24-hour, or monthly data stored on  the
AQDHS master file.  The type and volume of listings generated by the program are
governed by control cards submitted by the user.  A control  card can produce a single
page of output or many pages.  A page of 1-hour and 2-hour data contains data for a
full month.  A page of 24-hour or monthly data contains data for a full  year.
     In addition to the raw data, maximum and mean values are also listed in the
output.

4.4.2  Deck Setup
     The user is furnished a complete program source deck and a JCL deck.  To these
decks must be added job and message cards required by the individual computer
facility.   The user must also add control  cards and the 360 system end cards, and
must punch the master tape volume serial numbers in the proper JCL cards.  These
procedures are outlined in Section 4.4.3.   A complete deck setup is shown in Figure
20, and the JCL listing is shown in Figure 21.

4.4.3  Input
     The input material  furnished by the user for the data report program consists of
job and message cards, control  cards, and modified JCL cards.  Job and message cards
required by the individual computer installation must be submitted by the user.
 4-36                                                                           11/72

-------
                                                                   STATISTICAL  ANALYSIS
AGFNCY:SPA-ATMOSPHERIC  SURVEILLANCE   PROJECT: 2

STATE:FLOOIOA             POLLUTANT:SULFUR DIOXIDE
                                                                 STATE-AREAUO-  140

                                                                            METHOD:CONOUCTOMETRIC
                                                                                                                PERIOD  71/ 6/ 1 TO  7l/  6/30
                                                              SAMPLING INTERVAL:?  HOURS    UNITS:PARTS  PER MILLION
PERCENTHES
SITE NUM
NUM OBS
1 36"!
MIN
OBS l.< 3" 5ij 70
°.1 3.01 O.L2 ).f2 0.04

9J 95
0.61 1.01

99
1.81

99.9
2.48
MAX
OBS
2.48
ARITH
MEAN
0.15
STD
DEV
C.36
GEOM
MEAN
0.04
GEOM
STD
4.17
              AGENCYiEPA-METECROLOGICAL ACTIVITY   PROJECT: 3
                                                                 STATE-AREA:20-  260
^•MA^E
LOCATION:PORTLANO


SITE NUM MIN
MUM OBS OPS
4 347 70.
POLLUTANT:TOTAL SUSPENDED PARTICULATE METHOD:HI -VOL GRAVIMETRIC
SAMPLING INTERVAL:24 HOURS UNITS: M ICRCGRAMS/CUBIC

PERCENTILES
MAX ARITH
1.1 30 5K 70 10 9!) 99 99.9 OHS MEAN
95. 156. 2CO. 232. 300. 322. 428. 428. 428. 199.96
PERIOD 70/ I/ 1 TO 7C/12/ 1
METER


STO GEOM GtOM

77.04 184.54 1.52
-p.
GO
                                                  Figure  19.  Output format for program STATNL.

-------
                                                     360 SYSTEM END CARDS
                                                          CONTROL CARDS
                                                               JCL CARDS
                                                              {DATA SETS)
              SOURCE DECK (PROGRAM REPORT)
                                      JCL CARDS

                               JOB AND MESSAGE CARD(S)

                      Figure 20.   Deck setup for program REPORT.
     Control cards are submitted by the user  to  specify  the parameters for which out-

put reports are wanted.  There is no restriction on  the  number of control cards or

control groups that may be submitted for any  one run.  The control  card codes used

        //               JOB & MESSAGE CARDS
        //               EXEC COBUCLG,
        //               PARM.CQB-'NODECK.NOSOURCE.NOCLIST.NOXREF1,
        //               FARM.LKtD='NOCLIST,NOXREF,LET1
        //COB.SYSIN      DD     DATA
       /*
       //GO-
       //
       //GO,
       //GO,
                  INCLUDE SOURCE DECK
                  OF PROGRAM REMORE
                                                                      /Master
INPFIL     DD     DS?1AME-AQDHS1,UNIT-TAPE,VOL-3ER-006196,LABEL-!,
           DISP  (OLU,KEEP),DCB=RECFM=FB,LRECL=160,6LKSIZE 1600)
PRTFIL     DD     SYSOUT=A
HDRFIL     DD    DATA
       /*
       //
                  INCLUDE  DATA
                  CONTROL  CARDS
                       Figure 21.  JCL deck for program  REPORT.
4-38
                                                                    11/72

-------
are the AQDHS codes shown in Appendix A.  Columns 40 through 55 on a control  card
are used to designate the name of the city in which the site is located.   Table  9
shows the input format of the data report program.

                 Table 9.  CONTROL CARD INPUT FORMAT, PROGRAM REPORT
Card Column
1
2
3-4
5-6
7-10
11-13
14-18
19-20
21-22
23-24
40-55

Picture
xa
Ab
XX
XX
xxxx
XXX
xxxxx
XX
XX
XX
Value
Time code
Agency code
Project code
State code
Area code
Site code
Parameter code
Method code
Year code
Month code
(City name as it should appear on
printout. )
             Alphanumeric character
             Alphabetic character

     The complete codes for time, agency, project, state, area, site, parameter, and
method constitute a control group.  If the control group is defined as time code 1
(1-hour data) or time code 2 (2-hour data), the date code is then fully specified by
the year and month.  If the control group is defined as time code 7 (24-hour data)  or
time code 8 (monthly data), the date code is only specified by the year code.
     The following special coding situations may be used:

     (1)  Time codes 1 or 2:  if 99 is punched in the control card for month code,  all
          12 months of data for that control group will be output.
     (2)  Time codes 1 or 2:  if 99 is punched in the control card for both year code
          and month code, all 12 months of data for all years of that control group
          will be output.
     (3)  Time codes 1 or 2:  if 9's are punched in the control card for parameter,
          method, year, and month codes, all 12 months of data for all years, and all
          parameters and methods for that control group will be output.
     (4)  Time codes 1 or 2:  if 9's are punched in the control card for site,
          parameter, method, year, and month codes, all 12 months of data for all
 11/72
                                                                                 4-39

-------
          years,  all  parameters  and methods, and all  sites for that control  group
          will  be output.
     (5)   Time  codes  7 or  8:   if 99 is  punched in the control  card for year code, all
          years of data for that control  group will  be output.
     (6)   Time  codes  7 or  8:   if 9's are  punched in  the control card for parameter,
          method, and year codes, all years of data  for all  parameters and methods
          for that control  group will  be  output.
     (7)   Time  codes  7 or  8:   if 9's are  punched in  the control card for the site,
          parameter,  method,  and year codes, all years of data for all parameters
          and methods, and all  sites for  that control group will  be output.

     Control  cards do not  have  to be in any particular order.   However, considerable
tape rewinding  time may be saved if they  are sorted  sequentially on columns 1  through
24.

4.4.4  Output
     Typical  output reports are  shown in  Figures 22  through 25.  One separate report
is produced for every case.
     Eleven error messages are  associated with the program.   The format consists of
the error message and a card image printout of the faulty control card.  In all cases,
the program bypasses  the card in error, and goes on  to the next control card in the
deck.   The messages and their causes are:

     ERROR MESSAGE              Error.
     CD-CONT NOT 1278           Control card column  1 does not contain a 1, 2, 7,
                                or 8.
     NO MATCH CC1               A record  could not be found in the master file to
                                match the agency, project, state, and area codes on
                                the control card.
     CC3  FLAG                   A record  could not be found on the master file to
                                match the site code  on the control card.
     CCS  FLAG                   A record  could not be found on the master file to
                                match the pollutant  code on the control card.
     CC7  FLAG                   A record  could not be found on the master file to
                                match the year code on the control card.
     CC9  FLAG                   A record  could not be found on the master file to
                                match the month code on the control card.
     PROG1 FLAG-AG              Agency  code not found in program table.
     PROG1 FLAG-ST              State code not found in program table.
 4-40                                                                            11/72

-------
               AIR QUALITY DATA  REPORT



AGENCY: EPA -


ABATEMENT


ACTIVITY STATE: FLORIDA CITY: MERSCH - HOURLY
SITE: 001
YEAP:
1971
MONTH: JUNE
POLLUTANT: SULFUR DIOXIDE (ICCNDI UNITS: ppM DATA FORMAT: XX. XX
CA
01
02
03
04
05
06
07
P8
09
10
11
12
13
14
15
16
17
18
19
20
21
22
23
25
26
27
29
29
JO
N
MN
00
0.01
0.02
0.07
C. 18
C.03
0.8C
2.48
0.05
C.PI
0.01
0.02
0.02
0.02
0.03
0.03
0,03
0.04
0.06
0.02
0.01
0.03
0.83
0.40
0.01
0.01
0.02
0.02
0.02
0.02
0.03
30
0,18
2.48
01
O.CI
0.03
C.02
0.20
0.04
1.00
2.0d
0.05
0.01
0. 01
C.02
0.32
0.02
0,03
C.03
0.03
0.06
0.06
0.03
0.01
3.03
0.80
0.33
0.01
0.01
0.02
0.02
0.02
0.02
0.03
30
0.16
2.00
02
0.01
0. 06
0.01
P. 22
O.C4
2.01
O.C4
0.01
C.01
0.02
Q.Q2
0.02
0.03
P. 03
0.03
0.02
O.C6
0.03
0.01
0.03
0.90
C.2C
0.01
0.01
0.02
O.P2
0.02
0.02
C.03
30
0.17
2.01
03
0.01
0.07
O.oi
r.22
O.C4
1.81
0.03
O.CI
o.ci
0.02
-O^CZ
0.02
0.03
C.C3
0.03
O.CI
C.06
0.06
0.01
0.03
0.90
0.10
0.01
0.01
0.02
C.02
O.C2
0.02
O.C3
30
C.16
1.81
»***
C4 P5 ~«- 07 08 09 1C 11 12 13 14 15
J.02 0.02 0.01 0.02 P. 03 O.P3 C.03 0.^3 0.04 1-.P6 0.02 0.01
0.10 C.ll 0.12 0.13 0.12 0.11 C.C9 0.08 0.06 ',.r6 0.96 0.06
3.01 0.01 0.01 0.01 0.33 0.03 0.">6 0.03 0.02 0.1.3 0.03 0.06
0,22 0.24 0.18 0.18 0.10 0.02 u.Jl 0.01 P.ul v.Ol o.Ol 0.01
P. 04 0.05 0.06 O.C6 0.06 0.06 0.04 0.04 C.C3 '..03 O.J3 0.33
Jj-PJLialC A._LJ 1.10 ItlC 1.21 1.16 1.09 O.go 'j.gc. C.9Q 5.9C
1.76 1.54 1.21 l.UD 0.90 '.80 0.70 o.6:> 0.40 (..30 u.20 0.10
r.02 0,01 O.il O.CI C.01 0.01 C.01 0.01 o.ci C.cl 0.01 O.CI
o.ji o.oi o.oi o.:i o.oi o.ui o.oi c.ui o.oi f.
-------
-p"
I
                                                                  AIR QUALITY DATA  REPORT

                                                                  ***********************
             AGENCY: EPA - METEOROLOGICAL ACTIVITY
                                                     STATE: MAINE
CITY:  MERSCH  -  DAILY
                                                                                                     SITE: 904   YEAR:  1970
             POLLUTANT: SOIL INO (COS/10COLFI
                                                 UNITS: CCHS/1000 L FT
                                                                              CATA  FORMAT:  XXX.X
                                                                           MONTH
                                                                           *****
OA
Tl
"2
C3
04
05
9.6 _
07
C8
09
10
11
12
13
14
15
16
17
18
19
20
21
22
23
2t 	
25
26
27
28
29
30
N
• N
MX
JAN
r.2

C.6
C.7
0.5

C.9
l.C
1.2
1.5
1.3
1.1
1.2
1.3
1.6
1.7
1.7
1.7
1.8
2.0
2.1
1.7
1.6

1.0
0.9
0.6
0.4
0.8
0.3
29
1.1
~~~~2^l
FEP
C.2

C.6
0.7
C.5
M«9_
C.9
1.0
1.2
1.5
l.C
\m i
1.2
1.3
1.6
1.7
1.7
1,7
1.8
2.f
2.1
1.7
1.6
_1*4
1.0
0.9
0.6
C.4
C.8
0.3
29
1.1
2.1
                                        MAR
                                                 APR
                                                         MAY
                                                                  JUN
                                                                           JUL
                                                                                    AUG
                                                                                             SEP
                                                                                                     OCT
                                                                                                              NQV
                                                                                                                       EEC
                                                                                                                                       MEAN
0.6
0.7
1.5
o.a
0.9
l.C
1.2
.5
.C
.2
.3
.6
1.7
1.7
1.7
1.8
2.0
2.1
1.7
1.6
1.4
1.0
C.9
0.6
0.4
o.e
0.3

0.2
1.6
0.7
0.5
c.a
0.9
1.0
1.2
1.5
1.0
1.1
.2
.3
.6
.7
.7
i7
i.e
2.C
2.1
1.7
1.6
U4. .
1.0
0.9
0.6
0.4
j.e
Orl

0.2
0.6
3.7
0.5
c.a
0.9
1.0
1.2
1.5
1.0
.1^1
1.2
1.3
1.6
1.7
1.7
1.7
1.8
2.0
2.1
1.7
1.6
1^4. .
1.0
0.9
3.6
0.4
0.8
0.3

0.2
••.6
0.7
0.5
0.8
0.9
1.0
1.2
1.5
1.0
1.1
1.2
1.3
1.6
1.7
1.7
1.7
1.8
2.C
2.1
1.7
1.6
1.4
1.0
0.9
0.6
0.4
0.8
0,3

0.2
0.6
0.7
0.5
?.8
0.9
1.0
1.2
1.5
l.C
_!.!_
1.2
1.3
1.6
1.7
1.7
l«i
1.8
2.0
2.1
1.7
1.6
!•*_
1.0
0.9
0.6
0.4
o.a
0,1

0.2 C
0.6 C
0.7 C
0.5 C
0.8 C
0.9 C
1.0
1.2
1.5
1.0 1
1.1 1
1.2
1.3
1.6
1.7
1.7
1.7
1.8
2.0
2.1
1.7
1.6
1.4
1.0
0.9 (
0.6 (
0.4 (
0.8 (
0.3 (

>.2 (
).6 (
.7 C
1.5 (
1.8 '
). 9 (
1.0
.2
.5
.0
.1
.2
.3
.6
.7
.7
.7
.8
.0
.1
.7
.6
.4
.0
).9
>.6 (
).4 <
). 8
3_*3_

1.2
1.6
(.7
1.5
).8
).9
L.O
.2
.5
.0
.1
.2
.3
.6
.7
.7
.7
.8
.C
.1
.7
.6
Lt4
L.O
3.9
).6
).4
3.8
3_*3

0.2 C
0.6 C
0.7 C
0.5 C
0.8 C
0.9 C
1.0 1
1.2 1
1.5 1
1.0 1
1.1 1
1.2 1
1.3 1
1.6 ]
1.7 1
1.7
1.7
1.8
2.0
2.1
1.7
1.6
1.4
1.0
0.9 (
0.6 (
0.4 (
0.8 (
0.3 (

.2 12
0
.6 12
.7 12
.5 12
.8 12
>.9 12
.0 12
.2 12
.5 12
.0 12
L.I 12
.2 12
1.3 12
L.6 12
.7 12
.7 12
.7 12
.8 12
.0 12
.1 12
.7 12
.6 12
.4 12
.0 12
1.9 12
3.6 12
).4 12
;.s 12
),3 12
0
0.2
0.6
0.7
0.5
0.8
0.9
1.0
1.2
1.5
1.0
1.1
1.2
1.3
1.6
1.7
1.7
1.7
1.8
2.0
2.1
1.7
1.6
1.4
1.0
0.9
0.6
0.4
0.8
0.3

29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
29
1.1
2.1
348
348
348
1.1
2.1
                                          Figure  23.  Output format for program REPORT: soil  index.

-------
                                                               AIR QUALITY  DATA REPORT
                                                               ***********************
AGENCY: STATE AGENCY STATE; OKLAHOMA
POLLUTANT: TOT SUSPENDED PART UNITS: U GM/M3 (250EGI
DA JAN FEB MAR APR MAY JUN
Cl 101 60
02
03 60
04 168
C5 70 54
06 177
07
08 _. 38 38
09 51
10
11 81 40 76
12
13
14 . 66 42 37
15 99
16 _._ 	 _.. 	 80 	 83
17 62 77
18 67 51 52
19
20
21 40 48 71
22
23 63 51
24 73
25 45
26 70 68
27 40
28 52 113
29 45
30 103
31
N 656786
Wi 59 70 72 74 79 55
"X 81 101 103 177 168 71
CITY
DATA
MONTH
*****
JUL
9C
62
59
77
89
31
3C
52
38
57
10
59
90
: ADA
FORMAT:
AUG
44
46
31
72
39
22
89
95
56
48
63
66
87
13
58
95
SITE: 243 YEAR: 1971
xxxx.
SEP
56
55
57
59
74
44
7
34
35
19
34
39
12
42
74

OCT NOV
17 35
34
70
37
52
54 38
43
50
20
11
35
37
37
23
32 24
13 5
37 34
70 38

DEC N
2
25 4
2
3
5
15 5
2
5
1
3
2
0
25 7
1
4
4
4
2
1
6
1
4
3
2
4
2
5
2
4
2
3 94
22 94
25 94
MEAN
81
33
52
84
66
43
38
52
72
66
41
45
99
57
76
44
53
89
47
31
47
50
32
60
46
58
42
50
72
55
177
-p.
CO
Figure 24.   Output format for  program REPORT: total  suspended particulates.

-------
-p»
-p.
                                                                     AIR OUALITY DATA REPORT
                                                                     *«»««»»»»«*««»»**»»«*»«
AGENCY; EPA - EFFECTS RESEARCH
STAJEJ HAJ
(All CJTVI J*ER$CH - MONTHLY YEAR: 19TO

MONTH
*****
POLLUTANT: SULFATION RATE ILPGI
UNITS: M S03/100 C2/DAY SITE: 001
FOLLUTANT: SULFATIC»> RATE ILPGl
UNITS: * S03/10C C2/DAY SITE: C02
PCILUTANT: SULFATIOK RATE (LPG)
CNITS: M S03/150 C2/OAY SITE: 003
POLLUTANT: SUIFATJO "ATE (LPGI
UNITS: • S03/10C C2/OAY SITE: 064
PCILUTANT: SULFATIOK RATE (LPGI
UNITS: M S03/100 C2/DAY SITE: 005
POLLUTANT: SULFATICK RATE (LPGI
UNITS: H S03/100 C2/OAY SITE: 006
POLLUTANT: SULFATIOK RATE (LPGI
UNITS: M S03/1CO C2/DAY SITE: 007
POLLUTANT' SULFATION RATE 1LPG)
UNITS: M S03/100 C2/OAY SITE: 008
JAN FEB
2.1 2.1
JAh EEL
1.6 1.6
JAN F£B
3.2 3.2
JAN FEB
4. 1 4. 1
JAN FEB
JAN FEB
2. 1 2. 1
JA* FEB
3.2 3.2
JAN . f Efl_

MAR .APR MAY JuN JUL AUG SEP.. OCT NOJt._OJEj: 	 £ 	 SEAN 	
2.1 2.1 2.1 2.1 2.1 2.1 2.1 2.1 2.1 2.1 12 2.1
MAR_ APR MAY JUN JUL AUG SEP OCT NOV DEC N MEAN

NAR_ APR MAY JUN JUL AUG. . _ _SEJ>_ . DCI_ _ NOJL_ J!Ei_ _ Jl 	 «4H 	
3.2 3.2 3.2 3.2 3.2 3.2 3.2 3.2 3.2 3.2 12 3.2
MIR IPO MAY JuN JUL AUG SEP OCT MOV DEC . N MEAN

4.1 4.1 4.1 4.1 4.1 4.1 4.1 4.1 4.1 4.1 12 4.1
MAR APR MAY Ju" JUL ...AUG. 	 SEP 	 OCT 	 NOV 	 K£ 	 N 	 MEAN

MAR APR MAY JuN JUL AUG SEf OCT NOV DEC N i4EAN

2.1 2.1 2.1 2.1 2.1 2.1 2.1 2.1 2.1 2.1 12 2.1
MAR _ APR. MAY ... JuN JUI 	 AUfi _.SEe___QtT_ _NflV__fi« 	 Jl 	 MEAN
3.2 3.2 3.2 3.2 3.2 3.2 3.2 3.2 3.2 3.2 12 3.2
MAR APR MAY JUN JUL AUG SEP OCT NOV DEC N MEAN


                                         Figure  25.   Output  format  for program  REPORT:  sulfation  rate.

-------
     PROG! FLAG-MO              Month code not found in program table.

     PROG1 FLAG-POL             Pollutant code not found in program table.

     PROG1 FLAG-UNITS           Unit code not found in program table.

4.5   NATIONAL  AEROMETRIC DATA BANK  INPUT PROGRAMS

     The program NADBIN allows state and local agencies to furnish data from their
individual AQDHS master files for direct input to the National Aerometric Data Bank
via magnetic tape.

4.5.1  Description

     The NADBIN program is run separately from the operations of file maintenance or
file creation.  The computer program is written in ANSI COBOL language.  The JCL
statements are written so that the program can be run as a source deck.  Figure 26
lists the JCL deck.

          //              JOB & MESSAGE CARDS
          //              EXEC COBUCLG,
          //              PAkM,COB='NODLCK,NOSOURCL,NOCLIST,NOXREF',
          //              PAKM.LKED='HOCLIST,NOXREF,LET'
          //CUb.SYSlH     UD    OATA
                      INCLUDE SOURCE DECK
                      OF  PkuGRAM
                                                                    -Master
          /*
          //GU.DD1
          II
          II
          II
          11 r

              lv,E
LD    DS,J=AQDhSl, Vf>L=SER=006196,
DISP=(ULL,KEEP),UiMT=TAPE,LABEL=l,
DCti=(RECFK=Fy,LRECL=160,3LKSI7.L=1600)
DD    SYS.;UT=A
DlJ    L)S;i=SHGADl ,VUL=SER=006197,
DIbF=( ,KELP),Ur!IT=TAPE,LABEL = l ,
                       Figure 26.  JCL deck for program NADBIN.


 4.5.2   Deck  Setup

     The  user  is  furnished  with  a  complete program source deck and a JCL deck.   Job
 and message  cards  required  by  the  individual  computer facility must be added to these
 decks.  The  user  must also  add  control  cards,  the 360 system end cards, and must punch
 11/72
                                                       4-45

-------
the tape volume serial numbers in the  proper  JCL  cards.   These  procedures are out-
lined in Section 4.5.3.  A complete  setup  of  a  running deck is  shown in Figure 27.
                                                       360 SYSTEM END CARDS
                                                         CONTROL CARDS
                                                             JCL CARDS
                                                             (DATA SETS)
               SOURCE DECK (PROGRAM NADBIN)
                                       JCL CARDS
                              JOB AND MESSAGE CARD(S)
                      Figure 27.  Deck setup for  program  NADBIN.

4.5.3  Input
      The  input  material  furnished by  the  user  for the program NADBIN consists of job
and message  cards,  a  control card,  modified JCL cards, and the 360 system end cards.
Job and message cards are  submitted by  the  user as required by the individual computer
installation.
      The  layout of  a  control card is  shown  in  Table 10.   The control designation con-
sists of  a starting date (year,  month,  day) and an ending date (year, month, day),
which designates the  time  period for  which  NADBIN output is desired.  A single con-
trol  card with  From and  To dates will  cause all data on  the AQDHS master file within
the designated  period to be output.   Only one  input control card is submitted for any
one run.

4.5.4   Output
      The  output consists of SAROAD  forms  #1 and #2.  One-hour data for a 24-hour
period is output as two  card image  records  of  SAROAD form #1.  Two-hour data for a
24-hour period  is output as one  card  image  record of SAROAD form #1.  Twenty-four-
hour  data covering  a  1-month period will  output up to 31  card image records of SAROAD
form  #2,  each record  containing  only  one  data  field entry.  Monthly data covering a
 4-46
11/72

-------
period of 1  year will  output up to 12 card image records  of SAROAD form #2,  each
record containing only one data field entry.

                Table  10.   CONTROL CARD INPUT FORMAT,  PROGRAM NADBIN
Card Column
1-2
3-4
5-6
7-8
9-10
11-12
Picture
XX
XX
XX
XX
XX
XX
Value
Year (beginning)
Month (beginning)
Day (beginning)
Year (ending)
Month (ending)
Day (ending)
     The output tape should be IBM-compatible 0.5-inch-wide magnetic tape,  containing
EBCDIC-coded characters recorded at a density of 800 or 1600 bits per inch.
 11/72
                                                                                 4-47

-------
                               5.   BIBLIOGRAPHY
1.   Job Control  Language,  IBM Systems Reference Library,  Form  C28-6539-9, Tenth
    Edition,  July 1969.
2.   USA Standard COBOL,  IBM  Systems Reference Library, Form GC28-6396-1, Second
    Edition,  March 1969.
3.   IBM System/360 and System 370 FORTRAN IV Language, IBM Systems  Reference
    Library,  Form GC28-6515-8,  Ninth Edition, January 1971.
4.   Users Manual: SAROAD (Storage and Retrieval of Aerometric  Data),  Environmental
    Protection Agency, Office of Air Programs Publication No.  APTD-0663, July 1971
 11/72                                    5-1

-------
                           APPENDIX A
                    DATA IDENTIFICATION  CODES
                        Table A-l.  STATE CODES
Code
01
02
03
04
05
06
07
08
09
10
11
12
13
14
State
Alabama
Alaska
Arizona
Arkansas
California
Colorado
Connecticut
Delaware
District of Columbia
Florida
Georgia
Hawaii
Idaho
11 linois
15 Indiana
16 Iowa
17 Kansas
18 Kentucky
19 Louisiana
20 Maine
21 Maryland
22 Massachusetts
23 , Michigan
24 Minnesota
25
Mississippi
26 Missouri
Code
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
State
Montana
Nebraska
Nevada
New Hampshire
New Jersey
New Mexico
New York
North Carolina
North Dakota
Ohio
Oklahoma
Oregon
Pennsylvania
Puerto Rico
Rhode Island
South Carolina
South Dakota
Tennessee
Texas
Utah
Vermont
Virginia
Washington
West Virginia
Wisconsin
Wyoming
11/72
A-l

-------
                      Table A-2.  AGENCY CLASSIFICATION CODES
       Code
                             Type
       A
       B
       C
       D
       E
       F
       G
       H
       I
       J
       K
       L
       M
       N
       0-Y
       Z
EPA group responsible for atmospheric surveillance
EPA group responsible for meteorological activity
EPA group responsible for effects research
EPA group responsible for atmospheric research
EPA group responsible for abatement activity
State agency
County agency
City agency
District agency
Private
Institution (university, college, etc.)
Military
International agency
Other Federal nonmilitary agencies
Open for future expansion
Other
                     Table A-3.  PROJECT CLASSIFICATION CODES
       Code
                                 Category
    Long-term surveillance
       01
       02
       03
    Short-term surveillance
       04
       05
       06
       07 through 99
                          Population-oriented surveillance
                          Source-oriented ambient surveillance
                          Background surveillance

                          Complaint investigation
                          Special studies
                          Episode monitoring
                          For Federal networks and expansion
A-2
                                                                11/72

-------
                              Table A-4.  TIME CODES
               Code
Sampling Interval
                                                          1-hour
                                                          2-hour
                                                          24-hour
                                                          1-month
                       Table A-5.   PARAMETER AND METHOD CODES
Parameter
Suspended particulate
Total suspended particulate
Benzene-soluble organics

Soiling index (COH/1000LF)
Soiling index (RUD/10000LF)
Light scatter

Radioactivity (gross beta)
Antimony
Antimony
Arsenic
Beryl 1 i urn
Bismuth
Barium
Boron
Cadmi urn
Chromium
Cobalt
Copper
Iron
Lead
Manganese
Molybdenum
Nickel
Mercury
Selenium
Tin
Vanadium
Parameter
code

11101
11103

11201
11202
11203

11302
12102
12102
12103
12105
12106
12107
12108
12110
12112
12113
12114
12126
12128
12132
12134
12136
12142
12154
12160
12164
Method of collection and analysis
Collection

Hi-Vo1
Hi-Vol

Tape sampler
Tape sampler
Integrating
nephelometer
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Analysis

Gravimetric
Benzene extraction-
Soxhlet
Transmittance
Reflectance


Proportional counter
Emission spectra
Atomic Absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Atomic absorption
Method
code

91
91

81
91


91
91
92
92
92
92
92
92
92
92
92
92
92
92
92
92
92
92
92
92
92
11/72
                                                                                 A-3

-------
                  Table A-5 (continued).   PARAMETER AND  METHOD CODES
Parameter
Suspended participate
(continued)
Zinc
Fluoride
Ammonium
Ammonium
Nitrate
Nitrate
Sulfate
Sulfate
Benzo(A)pyrene
Settled particulate
(dustfall)
Total particulates
Sulfation rate
Sulfation rate
Sulfation rate
Sulfation rate
Sulfation rate
Gases
Carbon monoxide
Sulfur dioxide
Sulfur dioxide
Sulfur dioxide
Sulfur dioxide
Sulfur dioxide
Nitric oxide
Nitrogen dioxide
Nitrogen dioxide
Oxides of nitrogen
Ammonia
Ammonia
Parameter
code

12167
12202
12301
12301
12306
12306
12403
12403
17242

21101

42410
42410
42410
42410

42101
42401
42401
42401
42401
42401
42601
42602
42602
42603
42604
42604
Method of collection and analysis
Collection

Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol
Hi-Vol

Bucket; jar

Lead plate
Lead plate
Lead candle
Lead candle

Instrumental
Instrumental
Instrumental
Instrumental
Gas bubbler
Gas bubbler
Instrumental
Instrumental
Gas bubbler
Instrumental
Gas bubbler
Gas bubbler
Analysis

Atomic absorption
Specific ,ion
electrode
Nessler
Sodium phenol ate
2-4 xylenol
Reduction-Diazo
coupling
Colorimetric
Turbidimetric
Thin-layer
chroma tography

Gravimetric

Gravimetric
Potassium carbonate
Gravimetric
Titrimetric

Nondispersive
infrared
West-Gaeke
colorimetric
Conductometric
Coulometric
West-Gaeke
Conductometric
Colorimetric
Colorimetric
Jacobs-Hochheiser
Colorimetric
Nessler
Sodium phenol ate
Method
code

92
91
91
92
91
92
91
92
91

81

71
74
91
92

11
11
13
14
91
93
11
11
91
11
91
92
A-4
11/72

-------
                 Table A-5 (continued).  PARAMETER AND METHOD CODES
Parameter
Gases (continued)
Aldehyde
Total oxidants
Total oxidants
Total oxidants
Total oxidants
Ozone
Methane
Hydrocarbon
Meteorological observations
Wind speed
Wind direction
Parameter
code

43501
44101
44101
44101
44101
44201
43201
43101

61101
61102
Method of collection and analysis
Collection

Instrumental
Instrumental
Instrumental
Gas bubbler
Gas bubbler
Instrumental
Instrumental
Instrumental

Instrumental
Instrumental
Analysis

Colorimetric
Alkaline KI
Neutral KI
colorimetric
Alkaline KI
Phenol phthalein
Chemi luminescence
Flame ionization
Flame ionization



Method
code

11
11
14
81
51
11
11
11

11
11
This list covers the methods used by about 95 percent of the currently operating
control agencies.   If a parameter or method is not listed here, a code can be
assigned upon evaluation of the method by EPA.
11/72
                                                                                 A-5

-------
                               Table A-6.   UNIT CODES
             Code
            number
                    Units
              01
              02
              03
              04
              05
              06
              07
              08
              09
              10
              11
              12
              13
              14
              20
              30
              31
              32
              33
              34
              35
              50
              70
              80
              81
              90
              91
              92
              98
              99
micrograms/cubic meter (25° C, 1013 millibars)
micrograms/cubic meter (0° C, 1013 millibars)
nanograms/cubic meter (25° C, 1013 millibars)
nanograms/cubic meter (0° C, 1013 millibars)
milligrams/cubic meter (25° C, 1013 millibars)
milligrams/cubic meter (0° C, 1013 millibars)
parts per million (volume/volume)
parts per billion (volume/volume)
COHS/1000 linear feet
RUDS/10,000 linear feet
meters/second
miles/hour
knots
degrees
microns
picocuries/cubic meter
microcuries/cubic meter
picocuries/square meter
microcuries/square meter
picocuries/cubic centimeter
picocuries/gram
number of threshold levels
milligrams F/100 square centimeters-day
milligrams SOa/lOO square centimeters-day
micrograms S02/square meter-day
tons/square mile-month3
milligrams/square centimeter-month3
micrograms/cubic meter-month3
milligrams S042~/square centimeters-30 days
milligrams/square centimeters-30 days
              On  a  calendar-month basis.
A-6

-------
                                  APPENDIX  B
                        TRACE  AND  EXHIBIT  FEATURES

     Trace  and exhibit statements were left in the programs as an aid to  agencies
who want to make changes in the programs.  If an agency wants to remove the trace
and exhibit features, the following  changes are required:

     Remove:
     ADB03610
     ADB06390
     ADB06400
     ADB06930
     ADB06990
     ADB07000
     ADB07010
     AUP04290
     AUP04420
     AUP04430
     AUP05470
     AUP05480
     ANB02110
     ANB02560
     ANB02570

     Add:
     Column 12                             Column 73
         4.                                     1
     If state = IB2, move zero to state     ADB06390
     Go to  TSX                             ADB06990
 11/72                                   B-l

-------