CALPUFF and Postprocessors

CALPUFF and Postprocessors CALPUFF and Postprocessors

29.01.2015 Views

F. CALPUFF MODEL FILES The CALPUFF model obtains information about sources, receptors, meteorological data, geophysical data, and model control parameters from a series of input files. These files are listed in Table A-4. The model creates several output files, which are listed in Table A-6. Detailed information on the structure and content of each of the input and output files is provided in this section. Tables A-4 and A-6 show the Fortran unit numbers associated with each file. These unit numbers are specified in the parameter file (PARAMS.PUF). They can be easily modified to accommodate systemdependent restrictions on allowable unit numbers. Any changes to variables in the parameter file are automatically modified throughout the CALPUFF Fortran code. The code must be re-compiled for changes in the parameter file to take effect, since the parameter values are set at the program compilation stage rather than at program execution. The name and full path of each CALPUFF file (except one) is assigned in the control file (CALPUFF. INP). The exception, the control filename itself, is assigned on the command line. For example, on a DOS system, CALPUFF d:\CALPUFF\CALPUFF.INP will execute the CALPUFF code (CALPUFF.EXE), and read the input and output filenames for the current run from the file CALPUFF.INP in the directory d:\CALPUFF. If the control filename is not specified on the command line, the default control filename (i.e., CALPUFF.INP in the current working directory) will be used. The path and filename can be up to 70 characters long. The utility routine that delivers a command line argument is system dependent. The function that provides the system clock time and system CPU time are also system or compiler-specific. All systemdependent or compiler-specific routines in CALPUFF are isolated into a file called DATETM.xxx, where the file extension (.xxx) indicates the system for which the code is designed. For example, DATETM.HP contains code for Hewlett-Packard Unix systems, DATETM.SUN is for Sun Unix systems, DATETM.LAH is for Lahey-compiled PC-applications, and DATETM.MS is for Microsoft-compiled PC applications. By appending the correct system-dependent DATETM file onto the main CALPUFF code, the code should run without any modifications. F.1 User Control File (CALPUFF.INP) The selection and control of CALPUFF options are determined by user-specified inputs contained in a file called the control file. This file, which has the default name CALPUFF.INP, contains all of the information necessary to define a model run (e.g., starting date, run length, grid specifications, technical options, output options, etc.). CALPUFF.INP may be created/edited directly using a conventional editor, or it may be created/edited indirectly by means of the PC-based, Windows-compatible Graphical User Interface (GUI) developed for CALPUFF. MAR 2006 – CALPUFF F-1

The CALPUFF GUI not only prepares the control file, it also executes the model and facilitates file management functions; and it contains an extensive help system that makes much of the information in this manual available to the user on-line. When using the GUI, the source data and receptor information required for a CALPUFF run can be entered through the edit screens or read from external ASCII files (spreadsheet-compatible). Each source type (points, areas, volumes, and lines) contains an external ASCII file format description and sample file in the help system. Although the model can be set up and run entirely within the GUI system, the interface is designed to always create the ASCII CALPUFF.INP file. This allows runs to be set up on PC-based systems and the control file transferred to a workstation or a mainframe computer for computationally intensive applications. The ASCII CALPUFF.INP file should be directly transportable to virtually any non-PC system. When CALPUFF is setup and run entirely on a non-PC system, or if the GUI is not used on a PC, the control file CALPUFF.INP may be configured by using a conventional editor. This is facilitated by the extensive self-documenting statements contained in the standard file. As explained further below, more comments can be readily added by the user to document specific parameter choices used in the run. These comments remain in the file, and are reported to the CALPUFF list file when CALPUFF is executed from the command line. Note, however, that the GUI always writes the standard comments to CALPUFF.INP, and ignores any additional text. Furthermore, the control file is always updated by the GUI, even if the GUI is only used to run CALPUFF without altering the technical content of the control file. Thus, the user must save the control file to another filename prior to using the GUI if non-standard comments are to be saved. This feature of the GUI can be used to create a new copy of the standard control file by merely saving a “new file” to disk, so a fresh version of the control file is always available. The control file is organized into 18 major Input Groups and a variable number of subgroups within several of the major Input Groups. The first three lines of the input file consist of a run title. As shown in Table F-1, the major Input Groups are defined along functional lines (e.g., technical options, output options, subgrid scale, complex terrain inputs, etc.). Each subgroup contains a set of data such as source variables, subgrid scale hill descriptions, or discrete receptor information. The number of subgroups varies with the number of sources, hills, etc., in the model run. A sample control file is shown in Table F-2. The control file is read by a set of Fortran text processing routines contained within CALPUFF which allow the user considerable flexibility in designing and customizing the input file. An unlimited amount of optional descriptive text can be inserted within the control file to make it self-documenting. For example, the definition, allowed values, units, and default value of each input variable can be included within the control file. The control file processor searches for pairs of special delimiter characters (!). All text outside the delimiters is assumed to be optional documentation and is echoed back but otherwise ignored by the input module. Only data within the delimiter characters is processed. The input data consists of a leading delimiter followed by the variable name, equals sign, input value or values, and a terminating delimiter (e.g., !XX = 12.5 !). The variable name can be lower or upper case, or a mixture of both (i.e., XX, xx, Xx MAR 2006 – CALPUFF F-2

F. <strong>CALPUFF</strong> MODEL FILES<br />

The <strong>CALPUFF</strong> model obtains information about sources, receptors, meteorological data, geophysical<br />

data, <strong>and</strong> model control parameters from a series of input files. These files are listed in Table A-4. The<br />

model creates several output files, which are listed in Table A-6. Detailed information on the structure<br />

<strong>and</strong> content of each of the input <strong>and</strong> output files is provided in this section.<br />

Tables A-4 <strong>and</strong> A-6 show the Fortran unit numbers associated with each file. These unit numbers are<br />

specified in the parameter file (PARAMS.PUF). They can be easily modified to accommodate systemdependent<br />

restrictions on allowable unit numbers. Any changes to variables in the parameter file are<br />

automatically modified throughout the <strong>CALPUFF</strong> Fortran code. The code must be re-compiled for<br />

changes in the parameter file to take effect, since the parameter values are set at the program compilation<br />

stage rather than at program execution.<br />

The name <strong>and</strong> full path of each <strong>CALPUFF</strong> file (except one) is assigned in the control file (<strong>CALPUFF</strong>.<br />

INP). The exception, the control filename itself, is assigned on the comm<strong>and</strong> line. For example, on a<br />

DOS system,<br />

<strong>CALPUFF</strong> d:\<strong>CALPUFF</strong>\<strong>CALPUFF</strong>.INP<br />

will execute the <strong>CALPUFF</strong> code (<strong>CALPUFF</strong>.EXE), <strong>and</strong> read the input <strong>and</strong> output filenames for the<br />

current run from the file <strong>CALPUFF</strong>.INP in the directory d:\<strong>CALPUFF</strong>. If the control filename is not<br />

specified on the comm<strong>and</strong> line, the default control filename (i.e., <strong>CALPUFF</strong>.INP in the current working<br />

directory) will be used. The path <strong>and</strong> filename can be up to 70 characters long.<br />

The utility routine that delivers a comm<strong>and</strong> line argument is system dependent. The function that<br />

provides the system clock time <strong>and</strong> system CPU time are also system or compiler-specific. All systemdependent<br />

or compiler-specific routines in <strong>CALPUFF</strong> are isolated into a file called DATETM.xxx, where<br />

the file extension (.xxx) indicates the system for which the code is designed. For example, DATETM.HP<br />

contains code for Hewlett-Packard Unix systems, DATETM.SUN is for Sun Unix systems,<br />

DATETM.LAH is for Lahey-compiled PC-applications, <strong>and</strong> DATETM.MS is for Microsoft-compiled PC<br />

applications. By appending the correct system-dependent DATETM file onto the main <strong>CALPUFF</strong> code,<br />

the code should run without any modifications.<br />

F.1 User Control File (<strong>CALPUFF</strong>.INP)<br />

The selection <strong>and</strong> control of <strong>CALPUFF</strong> options are determined by user-specified inputs contained in a file<br />

called the control file. This file, which has the default name <strong>CALPUFF</strong>.INP, contains all of the<br />

information necessary to define a model run (e.g., starting date, run length, grid specifications, technical<br />

options, output options, etc.). <strong>CALPUFF</strong>.INP may be created/edited directly using a conventional editor,<br />

or it may be created/edited indirectly by means of the PC-based, Windows-compatible Graphical User<br />

Interface (GUI) developed for <strong>CALPUFF</strong>.<br />

MAR 2006 – <strong>CALPUFF</strong><br />

F-1

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!