Wednesday, February 21, 2007

 

Computer Programs for Calculating In Situ Phytoplankton Photosynthesis

http://www.umanitoba.ca/institutes/fisheries/PSpgms.html

Computer Programs for Calculating In Situ Phytoplankton Photosynthesis

by E.J. Fee

Canadian Technical Report of Fisheries and Aquatic Sciences No. 1740

Published 26 July 1990, revised (WWW version) February 1998

Catalog Number 97--6/1740E

ISSN 0706--6457

Abstract

This report describes computer programs for estimating in situ phytoplankton photosynthesis. The programs are written in Turbo Pascal and run on IBM compatible personal computers controlled by the MS-DOS operating system (in Windows 95, they run in an MS-DOS window). The theory of the programs is presented in detail along with instructions for use. Example data sets and resulting output are shown for each of the programs.

Keywords: Limnology; oceanography; trophic dynamics; computer; primary production; model; simulation

Preface

This manual is a revision of the "primary production model" user's manual (Fee 1984), which is now out of print. This section is intended for readers familiar with the previous report; it describes how those programs have been changed. Users unfamiliar with the previous report should skip to the Introduction.

There have been several changes in terminology. The term "primary production" is no longer used to describe what these programs estimate. Primary production and primary productivity are terms that originate in trophic dynamic theory (Lindeman 1942): Primary production is the chemical energy in an ecosystem that is the direct product of photosynthesis, and primary productivity is the sum of all photosynthetic rates in an ecosystem. Because phytoplankton are the only important photosynthesizers in deep lakes and the offshore oceans, it is reasonable to argue that phytoplankton photosynthesis and primary production are the same thing in these systems (note: Flynn (1989) argues that primary production should not be used as a synonym for phytoplankton photosynthesis even in these systems). But this is clearly not the case in small or shallow lakes and in estuaries, where terrestrially derived organics and photosynthesis by macrophytes and periphyton dominate organic carbon budgets.

The term "model" is no longer used because to many people it implies ecosystem simulations based on linked sets of differential or difference equations. This is quite different from what the programs described here do, viz., interpolate and extrapolate actual field data to estimate in situ photosynthesis. The terms "light", "irradiance", and "radiation" have been replaced with the more precise term "PAR", which stands for the photon flux of Photosynthetically Available Radiation. All references to the term "transparency", which was previously used to describe the attenuation of PAR a function of depth, have been replaced by the term "PAR extinction".

The algorithms used in the old programs required few modifications to bring them up to date. Here is a summary of all changes:

Introduction

This report describes computer programs used to estimate in situ phytoplankton photosynthesis and mean PAR in the water columns of lakes and oceans. (In this report, PAR is defined as the photon flux of Photosynthetically Available Radiation, i.e., the number of photons between 400 and 700 nm arriving at a point. PAR is elsewhere defined as Photosynthetically Active Radiation, but we avoid this term because it implies that all photons between 400 and 700 nm result in an equal photosynthetic response, which is not the case). These programs have evolved over a period of 20 years (Fee 1969, 1973, 1973a, 1977, 1984). The versions described here incorporate the following features:

Scope of the programs

Six programs are described here: Each program requires input of specific information. The information required by each of the programs is summarized in Table 1; this table also summarizes the required units of measure for each variable.

Table 1. The data used in the programs, required units, and which programs use them. Note: An Einstein (abbreviated: Ein) is 1 mole of photons.

Data Units Used by
Latitude degrees (north positive) FITSOLAR
Midday PAR mEin.m-2.min-1 FITSOLAR
Incubator PAR microEin.m-2.sec-1 PSPARMS
Photosynthesis Rate mg C.m-3.hr-1 PSPARMS
Solar PAR mEin.m-2.min-1 YPHOTO, DPHOTO,
YTOTAL, DTOTAL
In situ PAR extinction any units YPHOTO, DPHOTO,
YTOTAL, DTOTAL
Chlorophyll (B) mg chl.m-3 PSPARMS,
YPHOTO, DPHOTO,
YTOTAL, DTOTAL
alphaB mg C (or O2).mg Chl-1.Ein-1.m2 YPHOTO, DPHOTO
PBm mg C (or O2).mg Chl-1.hr-1 YPHOTO, DPHOTO
Mixing depth m YTOTAL, DTOTAL
Hypsographic (area vs depth) data m2 YTOTAL, DTOTAL

At the Freshwater Institute these programs are used in the context of research programs that operate in the following way (complete details are given in Fee et al. 1989): In the field, samples of whole water are taken; the vertical attenuation (extinction) of PAR is measured; and PAR in the air above the waterbody (solar PAR) is measured. In the laboratory, subsamples are taken from the water sample for determining the concentrations of dissolved inorganic carbon and chlorophyll. NaH14CO3 solution is added to the water, which is then siphoned into bottles. Two bottles are put in the dark, and the others are placed in a chamber having various PAR levels; they are incubated for 1--4 hr. During the incubation, PAR at each bottle position in the incubator is measured. At the end of the incubation period, 14C uptake rates are determined and photosynthesis rates are calculated.

The computer programs described in this report are used to analyze these field and laboratory data: PSPARMS estimates photosynthesis parameters from chlorophyll and incubator data (photosynthesis vs PAR). YPHOTO (or DPHOTO) simulates in situ photosynthesis vs depth profiles from solar PAR, PAR extinction, chlorophyll, and photosynthesis parameter data. Finally, YTOTAL (or DTOTAL) corrects the calculated photosynthesis profiles for the decrease of lake volume with depth and estimates photosynthesis and mean PAR in the water column above and below the thermocline.

System requirements

The programs run on IBM-PC compatible microcomputers operating under MS-DOS (=PC-DOS) version 2 or higher. Hardware requirements are minimal: one disk drive, 192Kb of memory (RAM), and a graphics card (needed only for PSPARMS; all popular graphics cards are supported). A text editing program is needed for typing data into the disk files; any program that can produce ASCII files will work.

Time requirements

The times quoted below are for an IBM-AT compatible microcomputer (Mind Computer, Winnipeg, Man.; 80286 Intel CPU running at 12 MHz; no math co-processor). FITSOLAR and PSPARMS need two to five seconds to process a single dataset. YPHOTO takes about one minute to calculate annual photosynthesis for a lake with a seven month ice-free season; YTOTAL takes about one minute to correct these results for the diminution of volume with depth. DPHOTO requires about ten seconds to calculate daily photosynthesis for a single station; DTOTAL takes about ten seconds to correct these results for the diminution of volume with depth.

Availability and transportability

The programs can be downloaded from the ELA website; copies of the Pascal source code are included along with the executable programs. The programs were created with Turbo Pascal (Borland International), which contains many extensions to the basic Pascal language, and adapting them for machines that do not have a compiler compatible with Turbo Pascal (version 4 or higher) may be difficult.

Theory of the programs

This section describes the theoretical principles on which the programs are based. Table 2 summarizes the mathematical symbols used in this section.

Table 2. Definitions of mathemathical symbols.

symbol definition
B chlorophyll concentration
PBm the rate of photosynthesis at optimal PAR divided by B
alphaB the slope of the photosynthesis vs PAR curve at low PAR values, divided by B
P the rate of photosynthesis
I PAR, the photon flux of photosynthetically available radiation
t time
Iz I as a function of depth
Io(t) I as a function of time
Pz photosynthesis as a function of depth
P vs I photosynthesis as a function of I
zeu the depth of the euphotic zone (where photosynthesis = respiration)
Io I measured in the air above the waterbody
Ik PBm / alphaB
I' I - Ik / 20
DELTA_T time between Io data; the basic time step in the simulation of daily photosynthesis
KAPPA_A the fraction of I at the top of the atmosphere that reaches the surface of the waterbody under cloud-free conditions
LATITUDE distance of the waterbody from the equator (degrees, north positive)
z depth
PHI the angle between the sun and the equator at solar noon
d the number of the day of the year
LAMBDA_Y the number of days in the year
k a constant, variously defined in the text
VARPHI the angle of the sun from due south at sunset
LAMBDA_D daylength
THETA I at the top of the atmosphere at the mean solar distance
DELTA_S2 the square of the deviation of the earth from its mean distance from the sun

Simulation of photosynthesis vs depth curves

The procedure used to estimate in situ photosynthesis is illustrated in Figure 1.

Figure 1. The procedure used to estimate in situ photosynthesis.

The relationships that must be known are: (1) solar PAR (measured in the air above the waterbody) as a function of time Io(t); top curve in Fig. 1. (2) photosynthesis as a function of PAR (P vs I; middle curve), and (3) percent of solar PAR as a function of depth (Iz); bottom left curve, expressed as a percentage).

For a given instantaneous value of Io, the depth profile of PAR (bottom left curve) is calculated by multiplying Io by the percent of surface PAR that reaches each depth (Iz). Photosynthesis as a function of depth (Pz; bottom right curve) is then calculated from the P vs I curve in the manner illustrated. The instantaneous areal rate of photosynthesis is obtained by integrating the Pz curve from the surface down to the depth of the euphotic zone (zeu). The entire procedure is repeated at successive time intervals (DELTA_T) (top curve) to obtain a set of instantaneous depth integrals. The daily rate is the integral of these instantaneous depth integrals over the entire day.

This procedure assumes that P vs I and Iz are invariant during the day, which is not strictly true (Fee 1975; Bukata et al. 1989). However, the variations of P vs I curves are inconsistent, and Fee (1975, 1980) showed that even extreme variations have only minor effects on estimates of daily integral photosynthesis estimates. Bukata et al. (1989) concluded that diurnal changes of Iz curves did not greatly affect daily areal photosynthesis estimates.

The heart of the calculation procedure just described is the P vs I curve illustrated in Figure 2.

Figure 2. The photosynthesis vs PAR curve, illustrating the equation used and graphically defining the photosynthesis parameters.

This figure illustrates how it is calculated from chlorophyll concentration (B) and two photosynthesis parameters PBm and alphaB (the superscript B indicates that PBm and alphaB are normalized on chlorophyll concentration). PBm is the maximum rate of photosynthesis divided by the chlorophyll concentration, and alphaB is the slope of the P vs I curve as PAR approaches zero divided by the chlorophyll concentration. PBm and alphaB are physiologically meaningful parameters (Bannister 1974; Jassby and Platt 1976); they are used here because the process of calculating them makes it easy to identify errors in experimental P vs I data. Further, programs based on these parameters can be driven by remotely sensed chlorophyll data.

The equation used to describe the P vs I curve (Fig. 2) is:
P = 0 if I is less than Ik / 20
P = B*PBm if I is greater than or equal to 2*Ik
P = B*alphaB*I' [1 - (I')/(4*Ik] otherwise,
where P is the rate of photosynthesis, I is PAR, Ik = PBm / alphaB, and I'= I - Ik / 20. This formulation is adapted from an equation given in Jassby and Platt (1976); it is used here because it can be evaluated in only 20% of the time required to evaluate their recommended hyperbolic tangent equation and both equations give identical integral photosynthesis estimates. As it is formulated, photosynthesis is zero at PAR=I'; this constant was determined empirically and corresponds to Jassby and Platt's constant RB. Inhibition of photosynthesis by high PAR is not included in this formulation; Marra (1978), and Welschmeyer and Lorenzen (1981) have shown that such inhibition probably does not occur in situ and Fee (1980) showed that it is of little quantitative importance even if it does occur.

Constants

There are two groups of numeric constants--those that are permanently coded into the programs and those that can be changed at the time that the programs are run. The first group includes constants that can only be changed by editing the appropriate line in the disk file GENVARS.PAS and recompiling the programs; this is also how you can change the default value of a constant in the second group. The names given below are the actual variable names used in the file GENVARS.PAS.

The first group of constants includes:

The second group of constants includes:

Interpolation procedures

Linear interpolation is used to obtain values for all variables for dates between sampling dates. For example, if a chlorophyll value of 1.0 is input on June 1 and a value of 2.0 is input on July 1 then the value used on June 10 will be 1.333, on June 15 will be 1.5, and so on.

B, PBm, and alphaB data are input as functions of depth. Values for the specific depths where photosynthesis is to be calculated are obtained by linear interpolation in the input data. If the data do not encompass the depths for which values are needed, then they are extrapolated: The value at the shallowest depth that was input is used from the surface down to that depth and the value at the greatest depth that was input is used for all greater depths.

PAR extinction, and hypsographic (lake area vs depth) data are also input as functions of depth. The run will fail if a value is not input for a depth of 0 m, or if only one value is input, or if values do not decrease with increasing depth. Values for the specific depths where photosynthesis is to be calculated are obtained by linear interpolation in the input data (PAR extinction data are linearized by taking logarithms). If it is necessary to extrapolate to greater depths than were input, a linear regression (straight line) is fit to the available data. For PAR extinction data, if five or more data points are input, the first three points are not used in fitting the straight line since the logarithm of PAR extinction vs depth is frequently nonlinear near the surface.

For all data, if only one profile is entered, it will be extrapolated forward and/or backward in time as needed. For example, if an alphaB depth profile dated June 1 is input and photosynthesis is calculated for the period May 1 through October 1, the June 1 value will be used for the entire period. Whenever input data are extrapolated forward or backward in time a warning message is recorded in the output.

Integration method

YPHOTO, DPHOTO, YTOTAL and DTOTAL use Simpson's 3-point numerical integration algorithm to integrate over depth and time. Essentially, this algorithm fits parabolas to successive groups of three points on the curve to be integrated and sums the areas under these parabolas. Elementary calculus textbooks describe this procedure in detail; the only thing of importance in the present context is that the function being integrated must be known at an odd number of equally spaced points in time or space.

Calculation of cloudless solar PAR

Generated solar data are scaled in units of mEin.m-2min-1 and are made specific for each waterbody by the constants LATITUDE and ATMOS_EFFECT. LATITUDE is the location of the waterbody in units of degrees from the equator (negative for the southern hemisphere) and ATMOS_EFFECT is the fraction of the PAR at the top of the atmosphere that reaches the surface of the waterbody under typical cloudless conditions; its value depends on air pollution, altitude and other factors.

The following is derived from Brock (1981). The declination of the earth during the year (PHI, the angle between the sun and the equator at solar noon, north positive) is calculated with the formula

PHI = 23.45osin(360o (284 + d) / LAMBDA_Y),

where d is the number of the day of the year, and LAMBDA_Y is the number of days in the year. Letting k = -tan(LATITUDE)*tan(PHI), the angle from due south of the sun at sunset (VARPHI) is calculated with the formula

VARPHI = 0o if k > 1

180oif k < -1

arccos(k)otherwise

Since the apparent movement of the sun is 0.25o of arc per minute (360o/ 1440 minutes), daylength in minutes (LAMBDA_D) is simply

LAMBDA_D = 2*VARPHI / .25 = 8 * VARPHI.

Using a value of 373.4 mEin.m-2min-1 for the solar constant (THETA, the solar PAR at the top of the atmosphere at the mean solar distance), cloudless PAR at time t is calculated from the formula

Io(t) = KAPPA_A*THETA*DELTA_S2*[sin(PHI)*sin(LATITUDE) +

cos(PHI)*cos(LATITUDE)*cos(.25o(t-LAMBDA_D/2))]

where 0 is less than or equal to t, which in turn is less than or equal to LAMBDA_D, and DELTA_S2 is the square of the deviation of the earth from its mean distance from the sun. It is calculated from the following empirical formula (Davies, 1981)

DELTA_S2 =1.00011 + 0.034221*cos(k) +

0.00128 * sin(k) - 0.000719 * cos(2*k) +

0.000077* sin(2*k)

where k = 360o*d / LAMBDA_Y.

FITSOLAR

This program estimates the constant ATMOS_EFFECTS. It needs as input a date and the cloud-free PAR observed at noon on that date. The algorithm used is: (1) The upper and lower bounds for the search are set to 1 and 0. (2) The upper and lower bounds are averaged to obtain a test value. (3) A solar PAR curve is generated using the test value. (4) If the value of PAR at noon in the generated curve is greater than the observed cloud-free noon PAR value, then the upper bound for the search is set to the test value, otherwise the lower bound for the search is set to the test value. (5) Steps 2 to 4 are repeated until the difference between the upper and the lower bounds is less than 0.001.

PSPARMS

The Simplex algorithm (Caceci and Cacheris 1984) is used to find the best fit of the P vs I equation to the photosynthesis vs PAR data. The initial estimate of PBm is taken as the maximum value of photosynthesis in the dataset divided by the chlorophyll concentration; the initial estimate of alphaB is the slope of a straight line fit (statistical regression) of the photosynthesis vs PAR data for all data pairs in which PAR is less than 200 microEin.m-2sec-1 divided by chlorophyll concentration.

YPHOTO and DPHOTO

These programs begin by calculating the depth of the euphotic zone (the depth where in situ PAR is 0.5% of surface PAR) from the input PAR extinction data. The euphotic zone is then divided into discrete layers of equal thickness (the number of layers is determined by the value of NDEPTHS). Before in situ photosynthesis can be simulated, values for the following variables must be known at the surface, the bottom of the euphotic zone and at the depths where the layers meet: (1) The fraction of solar PAR that reaches each depth, (2) the chlorophyll concentration (B), (3) PBm, and (4) alphaB. These values are linearly interpolated from the input data. The photosynthesis vs depth profile is then calculated according to the procedure previously described and integrated over depth (and time for YPHOTO) using Simpson's Rule.

YTOTAL and DTOTAL

The functions of these programs are not incorporated into YPHOTO and DPHOTO because: (1) It would make those programs very complex and hard to modify. (2) Not every application needs to have these procedures applied. (3) More depth intervals are usually needed for YTOTAL and DTOTAL than for YPHOTO or DPHOTO (the "I" run-time command). An example will make it clear why this is so: Suppose that DPHOTO calculated photosynthesis at 11 depths (the default) in a lake in which the euphotic zone was ten meters deep; photosynthesis was thus calculated at one-meter depth intervals. If the same number of intervals were used in DTOTAL to calculate the mixed layer integral, and if the thermocline 2 m deep, only three photosynthesis values would be used for calculating the mixed layer integral; this would be very inaccurate. Using 41 depth intervals in DTOTAL instead of 11 will result in nine data points in mixed layer and will give similar accuracy for the 0--2 m integral as was obtained for 0--10 m integral in DPHOTO.

Like YPHOTO and DPHOTO, these programs divide the euphotic zone into discrete layers of equal thickness and calculate values for the following variables at the surface, at the bottom of the euphotic zone and at each of the depths where the layers meet: (1) The fraction of solar PAR that reaches each depth, (2) the daily photosynthesis at each depth, (3) the area of the lake at each depth (if hypsographic data are input). In addition, the depth of the mixed layer must be known. Given all of the required variables, it is straightforward to calculate the various integrals with Simpson's Rule.

Using the Programs

Disk files

Except for FITSOLAR, which reads its input from the keyboard and displays its results on the computer monitor, the programs read their inputs from disk files and write their outputs into other disk files. MS-DOS file names contain two parts separated by a period (e.g., NAME.EXT). The part before the period is the primary file name (hereafter referred to as NAME); it can contain eight or fewer characters. The part after the period is called the extension (hereafter referred to as EXT); it can contain three or fewer characters. In general, you choose the file NAME; the only exception is for solar data, where the file NAME identifies the year. This name identifies the location or cruise that produced the data contained in the file. For example, you could choose the NAME "GREEN89" for the file that contains data from Green Lake in 1989. The file EXT, on the other hand, identifies the kind of information contained in a file (e.g., files with an EXT of "SOL" contain solar PAR data, and files with an EXT of "OUT" contain simulated photosynthesis profiles). The files you create must have the correct EXTs or they will not be found by the programs. Table 3 summarizes all of the file types used in the programs, giving the EXT and a description of what file contains. Table 4 summarizes the file types read as input and produced as output by each program.

Table 3. The file EXTensions used in the programs and the kind of data contained in each.

File EXTension Contents
INC Chlorophyll and photosynthesis vs PAR data
PRM Estimates of PBm and alphaB
SOL Solar PAR (measured in air)
DAT Depth profiles of PAR extinction, PBm, alphaB, chlorophyll, and area; mixing depth
STA List of the NAMEs of DAT disk files; one for each station
OUT Simulated in situ photosynthesis depth profiles and integrals of these profiles over depth
TOT Integrals of photosynthesis and mean PAR for the water columns above and below the thermocline (optionally corrected for the decrease of lake volume with depth)
### Error messages. Files with this EXTension are produced only if an unrecoverable error occurs or if a run is breakpointed
BRK Breakpoint information. Files with this EXTension are produced if a run is interrupted

Table 4. Summary of file EXTensions read as input and produced as output by each program. EXTension names enclosed in square brackets are files produced only under special circumstances: A SOL file is produced if one is not found, a ### file is produced if a run fails or is interrupted, and a BRK file is produced if a run is interrupted. Table 3 explains what kind of information each file EXT contains.

Program Input File EXT Output File EXT
PSPARMS INC PRM
YPHOTO SOL, DAT OUT, SOL, ###, BRK
YTOTAL SOL, DAT, OUT TOT, ###
DPHOTO SOL, DAT, STA OUT, ###, BRK
DTOTAL SOL, DAT, STA, OUT TOT, ###

The programs all read their input data in "free-format"; this means that it does not matter where you type data on an input line--successive values can be separated by blanks, commas, tabs, or the ends of lines, and alphabetic data can be entered in either upper or lower case. However, data must appear in the file in the proper order. For example, dates are input as the month name followed by the day of the month (e.g., Aug 1; only the first three letters of the month name are necessary). If you enter this date with the month and day reversed (i.e., 1 Aug) the programs will fail.

The first non-blank line in any disk file is simply copied to the top of the output files; it serves to identify the output. You can put any information that you want on this "header" line, but be sure that the location and time period are included so that the output will be understandable.

Error Handling

If YPHOTO, YTOTAL, DPHOTO, or DTOTAL fail for a known reason, a message describing the problem will be displayed on the screen. This message will also be permanently stored in a disk file with the same NAME as the NAME of the input DAT file and an EXT of "###". This facilitates the use of the programs in DOS batch files: If you submit several runs to DOS for execution in a single batch file you can find out which (if any) of the runs failed simply by typing the DOS command "DIR *.###".

If an unforeseen error occurs, the program will stop, displaying the message "Runtime error nnn at xxxx:yyyy". This is an emergency message produced by Turbo Pascal; nnn is the runtime error number, and xxxx:yyyy is the address of the error. Detailed explanations of runtime error messages are given in the Turbo Pascal manual. However, the cause of a problem will usually be obvious: e.g., the disk is full. If you cannot figure out why the program failed, please send a disk containing a copy of the dataset that caused the error along with a copy of the error message to the author.

If a run terminates abnormally, e.g., if the electrical power fails or if you get a runtime error message from Turbo Pascal, files with an EXT of "%%%" will appear in your disk directory. These are temporary files that will be erased automatically if you restart the interrupted run; you may safely erase them by typing "DEL *.%%%".

Input data are carefully scrutinized for plausibility. If a questionable value is found, the run continues but a warning message is recorded in any output computed from this datum.

Data Used by More than one Program

Solar data
YPHOTO, YTOTAL, DPHOTO or DTOTAL first try to read solar data from a disk file whose NAME is the year for which calculations are to be made and whose EXT is "SOL" (e.g., 1976.SOL). If this file cannot be found, the programs next search for a file called CLDLSS.SOL. If neither of these files is found, then solar PAR is simulated and are stored in a file named CLDLSS.SOL; subsequent runs will read solar PAR data from this file, rather than recreating it.

Solar data are input as tables (one for each day) that give the instantaneous flux of solar PAR at time intervals of 30 minutes. Data are required only for times when the sun is above the horizon, but including zeros for the dark periods does no harm. A solar file containing data for two days follows:

ELA cloudless solar PAR data.
May 1
0.0 11.9 18.8 27.0 36.2 46.0 56.2
66.5 76.4 85.9 94.4 101.7 107.7 112.2
114.9 115.8 114.9 112.2 107.7 101.7 94.4
85.9 76.4 66.5 56.2 46.0 36.2 27.0
18.8 11.9 0.0 -1
May 2
0.0 11.8 18.4 26.3 35.1 44.6 54.5
64.4 74.2 83.6 92.1 99.7 106.1 111.0
114.4 116.1 116.1 114.4 111.0 106.1 99.7
92.1 83.6 74.2 64.4 54.5 44.6 35.1
26.3 18.4 11.8 0.0 -1
The file starts with a header line. The data for each day begins with the date. Following the date come the data for that day. A negative value where a PAR value is expected is the signal that all data for that day have been entered. The data in a SOL file must appear in chronological order but it is not necessary that the file contain data for every consecutive day; i.e., the file can contain gaps. If missing data are generated, a warning message is recorded in the output. Theoretical cloud-free PAR values are multiplied by 0.7 to simulate average cloudiness. This is the fraction of full solar PAR that occurs on an average day at the Experimental Lakes Area (NW Ontario); more appropriate values for other locations can be specified with the "M" run-time command.
PAR extinction, PBm, alphaB, and chlorophyll data
These data are input as depth profiles. Each depth profile starts with the date. Following the date are pairs of data; the first number in each pair is taken to be a depth, the second number is taken to be the value of the variable at that depth. A negative value where a depth is expected is the signal that all data for the profile have been entered. For example, a single depth profile of PAR extinction follows:
July 17
0 100
1 50
2 25
3 12.5
4 6.25
-1
Because data entry is free-format, these data could also be input as:
July 17 0 100,1 50,2 25,3 12.5,4 6.25 -1
Notice that no header lines are shown in these examples. This is because depth profile data are always input as part of a DAT file; only the first line of the DAT file contains a header line. Note further that the PRM output file generated by PSPARMS is not in the proper format for input of B, PBm, or alphaB data.
Hypsographic (lake area vs depth) data
If you want YTOTAL or DTOTAL to correct the photosynthesis values for the decrease of the volume of the lake with depth, then you must supply hypsographic data. The format of these data is the same as for depth profile data except that no date is attached to them. A sample dataset looks like:
0 27.7E8 2 24.47E8 4 23.90E8 6 21.29E8
8 17.37E8 10 10.74E8 12 0.65E8 -1
The first number in each pair is the depth, the second is the area of the lake at that depth in units of meters2.
Mixing depth data
YTOTAL and DTOTAL need input of the mixing depth in order to calculate photosynthesis above and below the thermocline. An example mixing depth dataset follows:
Apr  1   5
May 1 3
May 5 6
May 30 10
Note that there is no negative "end of data" signal separating data for different dates (as is the case for the chlorophyll, PBm, and alphaB datasets); this is not needed because only one value of mixing depth is input for each date. If mixing depths are specified that are greater than the depths to which photosynthesis was computed then YTOTAL (or DTOTAL) will extrapolate the latter as necessary to obtain values for greater depths. If mixing depths greater than the maximum depth in the hypsographic data are specified, then the latter will be used for for the mixing depth.
Organization of data in DAT files
YPHOTO, YTOTAL, DPHOTO and DTOTAL read several types of data from a data file whose EXT is "DAT". These different data types (PAR extinction, chlorophyll, alphaB, PBm, mixing depth, hypsographic data) can be entered in any order in a DAT file. Each data type is separated from the others by a line which has a slash (/) followed by three letters, which specify the type of data which follow (ext = PAR extinction, chl = chlorophyll, alp = alphaB, pbm = PBm, zep = mixing depth, hyp = hypsographic data).

In the previous version of these programs, any information on the line after the data type identifier (e.g., /ext) was ignored; this space could thus be used for recording notes (comments) about the data. In the new version, information on this line is not ignored. The new way of commenting data is to enclose them in quotes (either single or double quotation marks can be used, but the quotation marks must be properly paired; a comment may not extend beyond the end of a line). Comments can appear anywhere inside PAR extinction, chlorophyll, alphaB, PBm, mixing depth, or hypsographic data.

Starting the Programs

All of the programs are started by typing the name of the program, a space and then the NAME of the disk file that contains input data for that program. For example, to start the program YPHOTO and tell it that the input data are to be found in the disk file ELA84.DAT you would type:
A>YPHOTO ela84 
The symbols "A>" are the DOS system prompt; you type the rest of the information on the line following this prompt (the part that appears in a bold font). Each program starts by printing its name, the version number, and the date on which it was created. While a program is running it may print informative messages on the screen. For example, YPHOTO may print:
Generating cloudless PAR data...
Press B to breakpoint run
The first line indicates that a disk file with solar data could not be found so these data were generated; the last line indicates that you may interrupt the program by pressing "B" on the keyboard.

FITSOLAR

This program prompts the user to type in the date, latitude, and the measured value of PAR at midday under cloudless weather. It displays the fitted value of ATMOS_EFFECTS on the console monitor. Shown below is a complete session with this program.
A>fitsolar

FITSOLAR Version 4.0
FWI Software Tools

Enter year (e.g. 1980): 1984
Enter latitude in degrees: 50

Enter month (e.g. May): jun
Enter day (e.g. 1): 1
Enter surface PAR at noon: 125.5
ATMOS_EFFECT = 0.3917

Enter date (e.g. May 1): ^C
The symbol ^C stands for Control-C and is obtained by pressing the Break key while holding down the "control" key. This is the way that you terminate the program.

PSPARMS

This program reads chlorophyll concentration and photosynthesis vs PAR data from a disk file whose EXT is INC. For each dataset the input data and the fitted mathematical curve are displayed on the screen. The user is then given the option to exclude individual data points with the aim of achieving the best fit of the curve to the experimental data. Final parameter values are stored in a disk file having the same NAME as the input file and an EXT of PRM. An example data file containing two datasets follows:
Yellowknife Lake Study, 1983 Data
Station-01 5.7
13 -1 0.14 -9
39.2 -1 0.67 0.78 -9
126.7 -1 2.49 3.05 -9
366.7 -1 3.05 3.13 -9
-1
'Station 75 5-Jul-83' 2.6
10.1 12.4 -1 0.11 -9
27.3 -1 0.57 0.57 -9
57.5 -1 1.49 1.62 -9
125.6 -1 5.36 3.57 -9
289.2 -1 4.80 -9
-1
These data are interpreted in the following way: The first line in the file is a header that is copied to the top of the output PRM file. Each incubator dataset starts with an identifier (e.g., Station-01), which can contain 30 or less characters (if it is longer than this it will be truncated). If the identifier contains blanks, it must be enclosed in quotes, as shown in the second dataset. The number following the dataset identifier is taken to be the chlorophyll concentration. PAR measured in the incubator at the position of the first bottle follows the chlorophyll concentration; the end of the replicate PAR measurements is signalled by a negative number. The replicate PAR measurements are averaged to obtain a single value that will be associated with the photosynthesis rates measured at this PAR. After PAR come photosynthesis rates measured at this PAR value. Successive numbers are read until one less than or equal to -5 is encountered; negative photosynthesis values greater than this can be input but are not used in the curve fitting procedure. The replicate photosynthesis rates measured at a single value of PAR are not averaged. The above format (PAR values followed by photosynthesis values) is repeated for each position in the incubator. A negative number where a PAR value is expected terminates data input for the dataset. Up to 128 photosynthesis rates can be input in a single dataset. P vs I data can be entered in any order, i.e., from low PAR to high or vice versa.

If the data shown above are in a file called TESTPRM.INC, then typing

A>psparms testprm 
starts the program. The input data from the first dataset are graphed on the screen, along with the fitted P vs I curve. When you press the ENTER key, the data are displayed in tabular form along with a menu of options:
(D)rop point, (G)raph, (A)bort, (C)ontinue
Choose an option by pressing the letter enclosed in parentheses:

It is an unfortunate fact that human judgement is a necessary part of the process of estimating PBm and alphaB. The previous version of this program fully automated this process, but it became apparent that a single bad data point in an otherwise good dataset could result in very inaccurate parameter estimates. Fortunately, it is easy to identify bad data points when the photosynthesis vs PAR data are shown graphically. Obviously, data should be dropped with caution, and you should make permanent copies of the final graphs so that you will have a permanent record of what data were used. You can do this by pressing the Shift-PrintScreen key combination at any time that a graph is displayed on the screen. DOS supplies a program (GRAPHICS.COM) for this purpose (see your DOS manual for a description of how to use this program), but it does not work with all graphics cards or printers. The program Pizzaz (Application Techniques, Inc.) is a better print-screen program that works with all popular cards and printers; it also offers much more flexibility than GRAPHICS.COM (smoothing, placement on the page, scaling the graph to a specific size, printing to a file, etc.).

If the above example is run and no data points are dropped, PSARMS will produce a disk file called TESTPRM.PRM which should look like this:

Yellowknife Lake Study, 1983 Data
Identifier #Iter B(Chl) PBm alphaB Sum.Sq
============================================================
Station-01 28 5.7 0.55 1.49 0.010
Station 75 5-Jul-83 30 2.6 1.96 4.76 0.442
This file contains the following information: The first three lines are the run identifier (header) and column labels; following this come the results, one line per dataset. Column 1 is the dataset identifier. Column 2 is the number of iterations required for convergence to a solution; small numbers mean that a solution was found quickly. If the number is 100 it means that convergence was not obtained. Column 3 is the chlorophyll concentration. Column 4 is the estimate of PBm. Column 5 is the estimate of alphaB. Column 6 is the sum of the squares of the deviations of the photosynthesis equation to the experimental data; the higher this number, the worse the fit.

YPHOTO

This program reads data from two disk files: (1) A SOL file containing PAR values in air for the period for which photosynthesis is to be calculated. (2) A DAT file containing a header line, the starting and ending dates for which calculations are to be made, and depth profiles of chlorophyll, PAR extinction, alphaB and PBm. An example DAT file for YPHOTO looks like:
Lake Winnipeg 1976, Cruise 3
May 1, May 10, 1976
/ext
May 5 0 100 10 1 -1
/chl
May 1 0 1 -1
May 10 0 10 -1
/alp
Jan 1 0 5 -1
/pbm
Dec 31 0 1.98 -1
This file is interpreted in the following way: The first line is a header. The starting and ending dates for which photosynthesis is to be calculated follow; these dates must both be in the same year and separate runs must be made if the period for which photosynthesis is to be calculated extends past the end of a year (e.g., photosynthesis for the period Oct 20, 1976 to Mar 31, 1977 would have to be done in two runs: Oct 20, Dec 31, 1976 and Jan 1, Mar 31, 1977). The year for which photosynthesis is to be calculated is input next. Depth profiles of PAR extinction, chlorophyll, alphaB and PBm follow.

If the data shown above are in a file called TESTYR.DAT and if neither 1976.SOL nor CLDLSS.SOL can be found on the disk, then typing

A>YPHOTO testyr 
will produce a disk file called CLDLSS.SOL that contains simulated cloudless PAR values for the period for which photosynthesis was simulated:
Simulated PAR data for 1976; latitude=50.0; atmos_effect=0.3250; % of cloudless=100.00
MAY 1
0.0 4.8 14.3 24.0 33.6 43.1 52.3 61.0 69.1 76.4 82.8 88.1 92.4
95.5 97.4 98.1 97.4 95.5 92.4 88.1 82.8 76.4 69.1 61.0 52.3 43.1
33.6 24.0 14.3 4.8 0.0 -1
MAY 2
0.0 5.3 14.8 24.4 34.1 43.6 52.7 61.4 69.4 76.7 83.1 88.5 92.7
95.9 97.7 98.4 97.7 95.9 92.7 88.5 83.1 76.7 69.4 61.4 52.7 43.6
34.1 24.4 14.8 5.3 0.0 -1
MAY 3
0.0 5.8 15.2 24.9 34.5 44.0 53.1 61.8 69.8 77.1 83.4 88.8 93.1
96.2 98.0 98.7 98.0 96.2 93.1 88.8 83.4 77.1 69.8 61.8 53.1 44.0
34.5 24.9 15.2 5.8 0.0 -1
MAY 4
0.0 6.2 15.7 25.3 34.9 44.4 53.5 62.1 70.1 77.4 83.7 89.1 93.4
96.5 98.3 99.0 98.3 96.5 93.4 89.1 83.7 77.4 70.1 62.1 53.5 44.4
34.9 25.3 15.7 6.2 0.0 -1
MAY 5
0.0 6.7 16.1 25.7 35.3 44.8 53.9 62.5 70.5 77.7 84.1 89.4 93.7
96.7 98.6 99.2 98.6 96.7 93.7 89.4 84.1 77.7 70.5 62.5 53.9 44.8
35.3 25.7 16.1 6.7 0.0 -1
MAY 6
0.0 7.2 16.6 26.2 35.7 45.1 54.2 62.8 70.8 78.0 84.4 89.7 93.9
97.0 98.9 99.5 98.9 97.0 93.9 89.7 84.4 78.0 70.8 62.8 54.2 45.1
35.7 26.2 16.6 7.2 0.0 -1
MAY 7
0.0 7.6 17.0 26.6 36.1 45.5 54.6 63.2 71.1 78.3 84.7 90.0 94.2
97.3 99.2 99.8 99.2 97.3 94.2 90.0 84.7 78.3 71.1 63.2 54.6 45.5
36.1 26.6 17.0 7.6 0.0 -1
MAY 8
0.0 8.1 17.4 27.0 36.5 45.9 54.9 63.5 71.5 78.6 84.9 90.3 94.5
97.6 99.4 100.0 99.4 97.6 94.5 90.3 84.9 78.6 71.5 63.5 54.9 45.9
36.5 27.0 17.4 8.1 0.0 -1
MAY 9
0.0 8.5 17.9 27.4 36.9 46.2 55.3 63.8 71.8 78.9 85.2 90.5 94.7
97.8 99.7 100.3 99.7 97.8 94.7 90.5 85.2 78.9 71.8 63.8 55.3 46.2
36.9 27.4 17.9 8.5 0.0 -1
MAY 10
0.0 8.9 18.3 27.8 37.3 46.6 55.6 64.2 72.1 79.2 85.5 90.8 95.0
98.1 99.9 100.5 99.9 98.1 95.0 90.8 85.5 79.2 72.1 64.2 55.6 46.6
37.3 27.8 18.3 8.9 0.0 -1
A second file (called TESTYR.OUT) will also be produced:
Lake Winnipeg 1976, Cruise 3
Depths
0.00 1.20 2.40 3.60 4.80 6.00 7.20 8.40 9.60 10.80 12.00
mg/m^2 ------------------------- mg C/(m^3.day) -------------------------
MAY 1 163 | 28 27 26 24 19 13 7 4 2 1 0
MAY 2 328 | 56 54 52 47 38 25 15 8 4 1 0
MAY 3 494 | 84 82 78 71 58 38 23 12 6 2 0
MAY 4 662 | 113 110 104 95 78 51 30 16 8 3 0
MAY 5 831 | 142 137 131 120 98 65 38 20 9 3 0
MAY 6 1001 | 171 166 158 144 118 78 46 25 11 4 0
MAY 7 1173 | 200 194 185 169 138 92 54 29 13 5 0
MAY 8 1346 | 229 222 212 194 158 105 62 33 15 5 1
MAY 9 1519 | 258 250 239 219 179 119 70 38 18 6 1
MAY 10 1694 | 287 279 266 244 200 133 78 42 20 7 1
================================================================================
total 9.2 | 1.6 1.5 1.5 1.3 1.1 0.7 0.4 0.2 0.1 0.0 0.0
(gm)
I N P U T D A T A

Depths
0.00 1.20 2.40 3.60 4.80 6.00 7.20 8.40 9.60 10.80 12.00
------------------------------------------------------------------
PAR extinction: % of Surface PAR

MAY 5 100.00 57.54 33.11 19.05 10.96 6.31 3.63 2.09 1.20 0.69 0.40

Chlorophyll: mg/(m^3)

MAY 1 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00
MAY 10 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00

alphaB: mg C/(mg chl.E.m^-2)

JAN 1 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00

PBm: mg C/(mg chl.hr)

DEC 31 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98

Command line: TESTYR

Solar data: Cloudless PAR data for 1976 latitude = 50.0 atmos_effect = 0.3250

Warning: TESTYR, MAY 5: PAR extinction data extended to start date
Warning: TESTYR, JAN 1: alphaB data extended to finish date
Warning: TESTYR, DEC 31: PBm data extended to start date
Warning: TESTYR, MAY 5: PAR extinction data extended to finish date

This file contains the following information: For each day, the depth profile of photosynthesis and the integral of this curve over depth. The depth profile of photosynthesis for the entire time period for which calculations were made and the integral of this curve over depth follow. Finally, the values of the input data that were used at each depth where photosynthesis was calculated and warning messages (if any) are summarized. Here is the output produced from the example dataset.

Lake Winnipeg 1976, Cruise 3

+----------+-----------------------------------------+-----------
| Uncorr. | Morphometry Corrected | mean PAR
+----------+-----------+---------+-------------------+-----------
Epi | mg C/m2 | mg C/m2 | mg C/m3 | Mass Fixed, gm C | mE/m2.min
Depth|Total Epi| Total Epi|Total Epi| To zmax In Epi | Epi Hypo
======|=====|==========|===========|=========|===================|===========
MAY 1 3.00 164 80 141 76 17 27 3.925E+08 2.098E+08 20.23 2.94
MAY 2 3.60 326 189 281 176 35 53 7.810E+08 4.901E+08 18.43 2.39
MAY 3 3.60 494 285 425 266 52 79 1.182E+09 7.391E+08 18.55 2.41
MAY 4 4.20 662 436 569 403 70 104 1.582E+09 1.120E+09 17.00 1.96
MAY 5 4.20 830 547 715 506 88 131 1.987E+09 1.406E+09 17.10 1.97
MAY 6 4.80 1003 735 863 673 106 154 2.398E+09 1.870E+09 15.77 1.60
MAY 7 4.80 1175 860 1011 788 124 180 2.808E+09 2.189E+09 15.86 1.61
MAY 8 4.80 1345 986 1158 903 142 206 3.216E+09 2.508E+09 15.94 1.62
MAY 9 5.40 1521 1210 1308 1098 161 226 3.633E+09 3.049E+09 14.79 1.32
MAY 10 5.40 1696 1349 1458 1224 179 252 4.050E+09 3.399E+09 14.87 1.33
======|=====|==========|===========|=========|===================|===========
totals (gm) 9.2 6.7 7.9 6.1 1.0 1.4 2.203E+10 1.698E+10

Mean PAR values are calculated for 24 hour period
Maximum depth = 12.00
Number of depth intervals = 41
Command line: TESTYR,I=41
Cloudless PAR data for 1976 latitude = 50.0 atmos_effect = 0.3250

Warning: TESTYR, MAY 5: PAR extinction data extended to start date
Warning: TESTYR, MAY 5: PAR extinction data extended to finish date

YTOTAL

This program requires the same input data files that YPHOTO required. In addition it reads the OUT file produced by YPHOTO. The DAT file must contain mixing depth data. If you wish to have the totals corrected for the diminution of lake volume with depth, the DAT file must also contain hypsographic data. An example DAT file for YTOTAL looks like:

Lake Winnipeg 1976, Cruise 3
May 1, May 10, 1976
/ext
May 5 0 100 10 1 -1
/chl 'this is a comment'
May 1 0 1 -1 "another comment"
May 10 0 10 -1
/alp
Jan 1 0 5 -1
/pbm
Dec 31 0 1.98 -1
/hyp
0 27.78E8, 2 25.57E8, 4 23.90E8, 6 21.29E8,
8 17.37E8, 10 10.74E8, 12 0.65E8 -1
/zep
May 1 3
May 30 10
The structure of this DAT file is the same as that described for YPHOTO. Indeed, the same DAT file can be used as input to both YPHOTO and YTOTAL, with all data needed by both programs included; each program will simply ignore data in the file that it does not use.

If the files TESTYR.OUT and CLDLSS.SOL produced by the example are on the disk, and if the data shown above are contained in the file TESTYR.DAT, then typing

A>YTOTAL testyr,i=41 

will produce a file called TESTYR.TOT:

Lake Winnipeg 1976, Cruise 3
Depths
0.00 1.20 2.40 3.60 4.80 6.00 7.20 8.40 9.60 10.80 12.00
mg/m^2 ------------------------- mg C/(m^3.day) -------------------------
MAY 1 163 | 28 27 26 24 19 13 7 4 2 1 0
MAY 2 328 | 56 54 52 47 38 25 15 8 4 1 0
MAY 3 494 | 84 82 78 71 58 38 23 12 6 2 0
MAY 4 662 | 113 110 104 95 78 51 30 16 8 3 0
MAY 5 831 | 142 137 131 120 98 65 38 20 9 3 0
MAY 6 1001 | 171 166 158 144 118 78 46 25 11 4 0
MAY 7 1173 | 200 194 185 169 138 92 54 29 13 5 0
MAY 8 1346 | 229 222 212 194 158 105 62 33 15 5 1
MAY 9 1519 | 258 250 239 219 179 119 70 38 18 6 1
MAY 10 1694 | 287 279 266 244 200 133 78 42 20 7 1
================================================================================
total 9.2 | 1.6 1.5 1.5 1.3 1.1 0.7 0.4 0.2 0.1 0.0 0.0
(gm)
I N P U T D A T A

Depths
0.00 1.20 2.40 3.60 4.80 6.00 7.20 8.40 9.60 10.80 12.00
------------------------------------------------------------------
PAR extinction: % of Surface PAR

MAY 5 100.00 57.54 33.11 19.05 10.96 6.31 3.63 2.09 1.20 0.69 0.40

Chlorophyll: mg/(m^3)

MAY 1 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00 1.00
MAY 10 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00 10.00

alphaB: mg C/(mg chl.E.m^-2)

JAN 1 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00 5.00

PBm: mg C/(mg chl.hr)

DEC 31 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98 1.98

Command line: TESTYR

Solar data: Cloudless PAR data for 1976 latitude = 50.0 atmos_effect = 0.3250

Warning: TESTYR, MAY 5: PAR extinction data extended to start date
Warning: TESTYR, JAN 1: alphaB data extended to finish date
Warning: TESTYR, DEC 31: PBm data extended to start date
Warning: TESTYR, MAY 5: PAR extinction data extended to finish date

This file contains the following results: For each day, the mixed layer depth; uncorrected and (if hypsographic data were input) corrected integrals of photosynthesis over depth; average photosynthesis (per meter3) above and below the thermocline, and mean PAR above and below the thermocline. This is followed by integrals and averages for the entire time period for which calculations were made. Finally, warning messages (if any) are summarized.

Note in the example output that the uncorrected integrals (col. 4) do not exactly match the corresponding results in the file TESTYR.OUT; this is because the integrals reported by YTOTAL were calculated with 41 depth intervals while those calculated by YPHOTO were calculated with only 11 depth intervals. The reason for using more depth intervals in YTOTAL and DTOTAL than in YPHOTO and DPHOTO was previously discussed.

DPHOTO

In addition to the input files required by YPHOTO, this program needs a STA file, which contains a header line for the entire run, followed by a list of NAMEs of disk files (one per station). An example STA file follows:
Lake Winnipeg 1976, Cruise 3
318
The first line is a header. The character strings on the following lines (any number can be input; for simplicity, only one is shown here) are the NAMEs of DAT files, that contain the input data for the named station. In this example DPHOTO would search for a file named 318.DAT; which contains the following data:
L. Wpg, Sta 318, 1976 Cloudless weather
Jun 6, 1976
/ext 'this is a comment'
Jun 6 0 100 2 2.19 -1
/chl
Jun 6 0 1.7 -1 "another comment"
/alp
Jun 6 0 5.4 -1
/pbm
Jun 6 0 4.7 -1
The format of this DAT file is identical to the DAT files input to YPHOTO except that only one date is specified on the second line instead of a range of dates. If a date of any data in the DAT file does not match the date for which photosynthesis is to be calculated, then a warning message is recorded along with the computed results. The output is the same as for YPHOTO except that only results for a single date appear.

If the data sets shown above are in the disk files TESTDAY.DAT and 318.STA, and if there are no solar data on the disk then typing A>DPHOTO testday will produce a file TESTDAY.OUT:

Lake Winnipeg 1976, Cruise 3

Command line: TESTDAY

L. Wpg, Sta 318, 1976 Cloudless weather
Depths
0.00 0.30 0.60 0.90 1.20 1.50 1.80 2.10 2.40 2.70 3.00
mg/m^2 ------------------------- mg C/(m^3.day) -------------------------
JUN 6 105 | 114 104 83 53 31 16 7 2 0 0 0

I N P U T D A T A

PAR extinction: % of Surface PAR
JUN 6 100.00 56.37 31.78 17.91 10.10 5.69 3.21 1.81 1.02 0.57 0.32

Chlorophyll: mg/(m^3)
JUN 6 1.70 1.70 1.70 1.70 1.70 1.70 1.70 1.70 1.70 1.70 1.70

alphaB: mg C/(mg chl.E.m^-2)
JUN 6 5.40 5.40 5.40 5.40 5.40 5.40 5.40 5.40 5.40 5.40 5.40

PBm: mg C/(mg chl.hr)
JUN 6 4.70 4.70 4.70 4.70 4.70 4.70 4.70 4.70 4.70 4.70 4.70

Warning: 318, JUN 6: Solar data missing; 70% of simulated cloudless used

DTOTAL

This program requires the same input data files required for input to DPHOTO; in addition, it reads the output file produced by DPHOTO. The DAT file must contain mixing depth and hypsographic data the hypsographic data can be omitted if you do not wish to have the totals corrected for the diminution of volume with depth. The STA file for use with DTOTAL would look exactly like the DPHOTO. The file 318.DAT pointed to by this example contains the following information:

L. Wpg, Sta 318, 1976 Cloudless weather
Jun 6, 1976
/ext
Jun 6 0 100 2 2.19 -1
/chl
Jun 6 0 1.7 -1
/alp
Jun 6 0 5.4 -1
/pbm
Jun 6 0 4.7 -1
/hyp
0 27.78E8, 2 25.57E8, 4 23.90E8, 6 21.29E8,
8 17.37E8, 10 10.74E8, 12 0.65E8 -1
/zep
Jun 6 10.0
As with the YTOTAL example data set, this DAT file contains more data than the DAT file given as an example for DPHOTO. Normally the same DAT file is used as input to both DPHOTO and DTOTAL, with all data needed by both programs included; data that are not needed are simply ignored.

If the disk contains the TESTDAY.OUT file produced by DPHOTO and if the example data shown in above are contained in the file TESTDAY.DAT then typing

A>DTOTAL testday,i=41 
will produce a file called TESTDAY.TOT:
Command line: TESTDAY,I=41
Lake Winnipeg 1976, Cruise 3



L. Wpg, Sta 318, 1976 Cloudless weather

+----------+-----------------------------------------+-----------
| Uncorr. | Morphometry Corrected | mean PAR
+----------+-----------+---------+-------------------+-----------
Epi | mg C/m2 | mg C/m2 | mg C/m3 | Mass Fixed, gm C | mE/m2.min
Depth|Total Epi| Total Epi|Total Epi| To zmax In Epi | Epi Hypo
======|=====|==========|===========|=========|===================|===========
JUN 6 10.00 106 106 103 103 13 13 2.873E+08 2.873E+08 2.81 0.00

Mean PAR values are calculated for 24 hour period
Maximum depth = 10.00
Number of depth intervals = 41

Breakpointing Runs

YPHOTO and DPHOTO can be interrupted and subsequently restarted without losing intermediate results. This allows you to ensure that there are no errors in the data before calculating photosynthesis for an entire year; it is also convenient to be able to interrupt a long run if you need the computer for something else. You breakpoint a run by pressing the letter "B" anytime after the message "Press B to breakpoint run" appears on the screen or by using the "B" run-time command. When you breakpoint a run, intermediate results are stored in three disk files: (1) NAME.OUT contains the photosynthesis profiles calculated up to the breakpoint, (2) NAME.### contains diagnostic messages, and (3) NAME.BRK contains intermediate results needed to restart the run. If any of these files cannot be found when you restart the run, the others will be erased and calculations will start over from the beginning.

Run-time commands

The programs incorporate specific values for variables that vary from place to place; they also perform some calculations in ways that may not be universally applicable. By appending certain letters to the NAME of the data file when you start a program, you can alter these constants and calculation procedures to make them apply to your situation. These run-time commands are separated from the file NAME and from each other by spaces and/or commas (see examples below). In the following command descriptions, names enclosed in angle brackets (<>) are to be replaced with actual values (e.g., you might type "101" where <> appears); items enclosed in square brackets ("[]") are optional. The letter enclosed in parentheses is what you type on the command line to select the option. Currently implemented run-time commands are: Some examples are:
A>YPHOTO ELA84,Z,B,I=15 
This run will use the maximum depth in the input PAR extinction data as the depth of the lake, it will calculate photosynthesis at 15 depth intervals and it will automatically breakpoint itself after calculating photosynthesis for the first day.
A>YPHOTO WPG76,Z=10.5,L=53,C,S=B,O=C,P 
This run will use 10.5 meters as the maximum depth, 53 degrees for the latitude if cloudless PAR values are calculated, the solar PAR data will be checked for errors before doing the calculations, solar PAR data will be read from disk drive B, the output file (WPG76.OUT) will be written on drive C. The "P" option (which is used to tell YTOTAL to calculate mean PAR in the water column only for the part of the day when the sun is above the horizon) is ignored by YPHOTO.

Unusual problems

This section describes some unusual situations that may arise and presents solutions.

Acknowledgments

Many colleagues helped me design these programs, tested preliminary versions, and notified me of inconsistencies (bugs). I thank in particular John Shearer, Ed DeBruyn, Martin Bergmann, Scott Millard, Harvey Bootsma, and Rose Mugidde.

References

Bannister, T.T. 1974. Production equations in terms of chlorophyll concentration, quantum yield, and upper limit to production. Limnol. Oceanogr. 19: 1--12.

Brock, T.D. 1981. Calculating solar radiation for ecological studies. Ecol. Modell. 14: 1--19.

Bukata, R.P., J.H. Jerome, and J.E. Bruton. 1989. Determination of irradiation and primary production using a time-dependent attenuation coefficient. J. Great Lakes Res. 15: 327--338.

Caceci, M.S., and W.P. Cacheris. 1984. Fitting curves to data. Byte 9: 340--362.

Davies, J.A. 1981. Models for estimating incoming solar irradiance. Can. Climate Centre Rep. 81-2.

Fee, E.J. 1969. A numerical model for the estimation of photosynthetic production, integrated over time and depth, in natural waters. Limnol. Oceanogr. 14: 906--911.

Fee, E.J. 1973. A digital computer program for calculating integral phytoplankton primary production in vertically stratified water bodies. Fish. Res. Board Can. Tech. Rep. 376: i+14 p.

Fee, E.J. 1973a. Modelling primary production in water bodies: a numerical approach that allows vertical inhomogeneities. J. Fish. Res. Board Can. 30: 1469--1473.

Fee, E.J. 1975. The importance of diurnal variation of photosynthesis vs. light curves to estimates of integral primary production. Int. Assoc. Theor. Appl. Limnol. Verh. 19: 39--46.

Fee, E.J. 1977. A computer program for estimating annual primary production in vertically stratified waterbodies with an incubator technique. Can. Fish. Mar. Serv. Tech. Rep. 741: v+38 p.

Fee, E.J. 1980. Important factors for estimating annual phytoplankton production in the Experimental Lakes Area. Can. J. Fish. Aquat. Sci. 37: 513--522.

Fee, E.J. 1984. Freshwater Institute primary production model user's guide. Can. Tech. Rep. Fish. Aquat. Sci. 1328: v+36 p.

Fee, E.J., R.E. Hecky, M.P. Stainton, P. Sandberg, L.L. Hendzel, S.J. Guildford, H.J. Kling, G.K. McCullough, C. Anema, and A. Salki. 1989. Lake variability and climate research in Northwest Ontario: Study design and 1985--1986 data from the Red Lake District. Can. Tech. Rep. Fish. Aquat. Sci. 1662: v+39 p.

Flynn, K.J. 1988. The concept of "primary production" in aquatic ecology. Limnol. Oceanogr. 33: 1215--1216.

Hecky, R.E., and S.J. Guildford. 1984. Primary productivity of Southern Indian Lake before, during and after impoundment and Churchill River diversion. Can. J. Fish. Aquat. Sci. 41: 591--604.

Jassby, A.D., and T. Platt. 1976. Mathematical formulation of the relationship between photosynthesis and light for phytoplankton. Limnol. Oceanogr. 21: 540--547.

Lindeman, R.L. 1942. The trophic-dynamic aspect of ecology. Ecology 23: 399--418.

Marra, L. 1978. Effect of short term variations in light intensity on photosynthesis of a marine phytoplankter--laboratory simulation study. Mar. Biol. (N.Y.) 46: 191--202.

Welschmeyer, J.A., and C.J. Lorenzen. 1981. Chlorophyll-specific photosynthesis and quantum-efficiency at subsaturating light intensities. J. Phycol. 17: 283--293.


Program changes since technical report 1740 was printed

At the end of the output of the DTOTAL and YTOTAL programs, vertical profiles of volume-corrected photosynthesis are printed; separate profiles for the euphotic zone and for the surface mixed layer are given. The headings at the top of the output of the TOTALs programs are also slightly different than shown in the manual: everywhere that the word "Epi" (i.e., epilimnion) appeared, it has been changed to "Zmix" (mixed layer).

Bug fixes

25 October 1990

The totals programs (DTOTAL and YTOTAL) previously failed if they were run after the photosynthesis programs (DPHOTO or YPHOTO) had been run with I=<> on the command line, where <> was greater than 33. This error occurred because the very long lines created by DPHOTO or YPHOTO were truncated when read as input by DTOTAL or YTOTAL.

21 January 1990

If hypsographic data were not supplied, YTOTAL or DTOTAL would only permit mixing depths less than 100m. Mixing depths greater than 100m in the /ZEP section of the DAT file were set to this depth, even if "Z" was specified on the command line. [Thanks to Scott Millard for finding this bug.]

2 April 1992

If all PAR values in an incubator dataset were >200 microEin/m2.sec, PSPARMS failed, giving a meaningless diagnostic message. This happened because the initial estimate of alphaB is made by fitting a straight line to the photosynthesis vs light data, but only data points for which light is < =200 are used. When there were no data points in this region--which is highly probable when in situ data are used to generate the P vs I curve--the algorithm failed. The program now checks for this condition, and if occurs it uses as the initial estimate of alphaB the rate of photosynthesis at the lowest measured PAR value divided by that PAR value. [Thanks to Rose Mugidde for finding this bug.]

21 April 1993

The documentation states that if DPHOTO does not find empirical solar data (in a disk file named <>.SOL), it simulates solar PAR values under the assumption that weather is perfectly cloud-free. In fact, totally cloudless values were multiplied by the value of the 'M' command line parameter (0.7 by default). DTOTAL, on the other hand, calculated mean water column irradiances using the totally cloudless values. THE BOTTOM LINE: If (and only if) empirical solar data were not used to 'drive' these programs, photosynthesis values calculated by previous versions of DPHOTO were obtained not from simulated cloudless PAR solar values but with this value multiplied by the value of 'M' (0.7 unless the user specifically set a different value on the command line); these results thus represent photosynthesis under average solar PAR values rather than cloud-free conditions, and should be recalculated to be consistent with the mean PAR values calculated by DTOTAL (which used cloudless PAR); only results calculated by DPHOTO and when no empirical solar data could be found are affected by this error. Finally, previous versions of DTOTAL ignored the setting of 'M'; all mean water column PAR values reported by this program when no empirical solar data could be found were calculated from cloudless solar PAR values, regardless of the setting of 'M'.

Here's how things work now: If DPHOTO or YPHOTO cannot find a solar data file (<>.SOL), they use a mathematical model to simulate solar PAR values. The 'M' parameter was originally designed to permit the user to specify the fraction of cloudless irradiance to use for those instances when a <>.SOL file IS found but contains a missing day (i.e., it is used to simulate a day of 'average' cloudiness and is thus more comparable to empirical solar data). However, it is entirely logical for a user to want to use the 'M' parameter to make simulated PAR values reflect average cloud conditions rather than perfectly cloud-free conditions; the programs have been changed to permit this: If the user does not specify a value for 'M' on the command line, things work pretty much as before---simulated cloud-free PAR solar values are used everywhere (as before for YPHOTO, YTOTAL, and DTOTAL, and now also for DPHOTO), and 70% of simulated cloud-free PAR (or the value of 'M' specified by the user on the command-line) is used to fill gaps in empirical solar data. However, if a value for 'M' is specified on the command line and empirical solar data (<>.SOL) cannot be found, simulated PAR values are everywhere multiplied by specified 'M' value. In the case of YPHOTO, these are stored in the file CLDLSS.SOL---which thus contains simulated solar PAR values for average cloudiness rather than cloud-free weather---and the percent of cloudless PAR values that are contained in this file are permanently stored in the header line at the start of this file. [Thanks to Harvey Bootsma for finding the bug and suggesting these changes.]

PASCAL SOURCE FILES

The Turbo Pascal source files for the programs are contained in the archive file SOURCE.LZH; most users will never need to look at these files. However, if you need to modify the programs or if you want to examine the algorithms to find out how the calculations are made, you can extract the files from this archive by typing the following command at the DOS prompt:
  LHA e source
LHA.EXE is a program (on the disk) that restores all the files contained in the named archive to their full size; type LHA for a list of options. Be sure that there is enough room on the disk to hold the extracted files before you run LHA (you will need about 160Kb, depending on how your hard disk is set up).


Copies of the programs described in this report may be obtained by downloading a self-unzipping file (below).

Click here to download a self-unzipping file containing executable programs for calculating rates of photosynthesis by phytoplankton.


E-mail comments and questions to efee@monarch.net.

Sunday, February 11, 2007

 

Jeannette M. Wing

Jeannette M. Wing

 

ICAN The International Canopy Network

ICAN

The International Canopy Network


Saturday, February 10, 2007

 

Database Tools for Analyzing Forest Canopy Information

http://academic.evergreen.edu/n/nadkarnn/cv/index.html
Nalini Nadkarni

Award Abstract #9630316 Database Tools for Analyzing Forest Canopy Information
NSF Org:
DBI
Initial Amendment Date:
August 29, 1996
Latest Amendment Date:
January 10, 2000
Award Number:
9630316
Award Instrument:
Standard Grant
Program Manager:
Sylvia J. Spengler DBI Division of Biological InfrastructureBIO Directorate for Biological Sciences
Start Date:
September 1, 1996
Expires:
February 28, 2001 (Estimated)
Awarded Amount to Date:
$234855
Investigator(s):
Nalini Nadkarni nadkarnn@evergreen.edu(Principal Investigator) David Maier (Co-Principal Investigator)Jerry Franklin (Co-Principal Investigator)Judith Cushing (Co-Principal Investigator)
Sponsor:
Evergreen State College Olympia, WA 98505 206/867-6000
NSF Program(s):
INFORMATION & KNOWLEDGE MANAGE,BIOLOGICAL DATABASES & INFORMA
Field Application(s):
0102000 Data Banks,0108000 Software Development,61 Life Science Biological
Program Reference Code(s):
HPCC,9251,9229,9184,9169,9139,1592
Program Element Code(s):
6855,1165
ABSTRACTThe forest canopy is increasingly regarded as a region of great ecological importance. Canopy communities are poorly understood, partly due to access problems and partly due to a lack of expertise and software tools to analyze complex three-dimensional tree crown data. The PIs propose an interdisciplinary effort to develop database systems to manage, analyze, and disseminate shared data pertaining to complex ecological questions using forest canopy data. The demonstration project will be carried about among seven cooperating but independent researchers at a forest canopy research site, the Wind River Canopy Research Facility in Washington State. Data from existing projects that focus at different spatial and temporal scales will be linked to allow efficient use of site data and to solve novel questions that could not be addressed by a single researcher's data sets. The resulting database management tools will allow researchers to easily gain access to site- specific data and each others' data, which will enhance the productivity both of the individual scientists and of the site as a whole. The initial research focus will be on the development of data models and prototype data structures and data sets for one concurrent study of forest canopy structure and hydrology. That research examines the role of forest canopies in intercepting, modifying, retaining, and conducting water from atmospheric sources (rain, mist, snow) to the forest floor. Forest canopy structure has obvious implications in these processes, but the complexity and three-dimensional nature of forest canopies (especially those of old-growth, structurally complex forests) has prevented ecologists from gaining a quantified understanding of the patterns and processes underlying these interactions. The PI will also continue refining the two database browsers for the Wind River Site data and will extend the data model for those browsers to show the connection with the canopy structure and hydro logy model. Development of a sound data model will allow forest canopy scientists to organize, visualize, and analyze their data in powerful ways. It will also provide the means to link forest canopy structural data with relevant environmental data sets (such as meteorological data) and with other forest functional data sets (e.g., photosynthesis of canopy organisms).

This page is powered by Blogger. Isn't yours?