KRS: A fast special-purpose database system

KRS: A fast special-purpose database system

Computers & Gevscienles Vol 9. No L pp. 41-52. 1983 0098- 30,~/83/0100A1-12503 0010 Pergamon Pre,,, Ltd Printed in Great Britain. KRS: A FAST SPECI...

707KB Sizes 4 Downloads 150 Views

Computers & Gevscienles Vol 9. No L pp. 41-52. 1983

0098- 30,~/83/0100A1-12503 0010 Pergamon Pre,,, Ltd

Printed in Great Britain.

KRS: A FAST SPECIAL-PURPOSE DATABASE SYSTEM G. L. HAGE Lawrence Livermore National Laboratory, PO Box 808, Livermore. CA 94550, U.S.A.

(Receii:ed 22 April 1982) Abstract--The K-Division Retrieval System (KRS) is a group of programs and files maintained by the Lawrence Livermore Laboratory to store and recall data about the geologyand events at the Nevada Test Site. KRS consists of two large data files that are updated regularly with new information, This report describes these data files and the interaction necessary to use the specialized programs, obtain access to the information, and arrange the data reports. These programs are run on CDC-7600 computers and are available in public files.

Key Words: Database, Geophysical logs, Nuclear test effects. INTRODUCTION KRS is a group of programs and data files that constitute a data bank containing information about the Nevada Test Site (NTS), its holes, test results, and some offsite data. This system is rather unorthodox because it is tuned to our large computers as two-dimensional arrays -rather than as records, keys, or indices. KRS maintains two main data files, DBASE and LBASE. DBASE contains a record of each hole at NTS as well as records of some offsite holes, which currently total about 4100. It can store more than 170 items of information about each hole, including name and type, location, geology, test effects (seismic, containment, etc.), and other information such as shot dates (see Rohrer, 1975 for a complete description of the data contained in DBASE). LBASE contains logs of the various data-collection devices lowered into the holes. It also contains pointers to the appropriate holes in DBASE to facilitate processing. About 24,000 logs are stored presently in LBASE, each comprising up to 40 words about each log, including names, numbers, dates, and general descriptions. Actual analog or digital data are kept in separate files. The family of programs that access the data files is stored in a library file and consists of a controller and three programs that select data from the proper data file and write reports. Other programs update the data files each month and perform other infrequent jobs such as expansion and rearrangement, conversion to SI units, etc. Output reports may be duplicated in binary files, and then can be read more efficiently by unique programs for statistical analysis or graphics. Several progratns of this type have been written. The general structure of this system is illustrated in Figure 1. DBASE

DBASE is composed of four logical segments totaling 876,215 words. All data are 60-bit-word oriented to match the CDC-7600 computers on which the KRS programs are run. *Throughout this section the carat (^) represents a space in a 10-character word.

Segment 1--1 word. This word contains the number of entries in the file. It has been superceded by word - 6 in segment four, and will be removed when all programs have been made independent of the one-word offset it causes in address calculations. The main reason for its removal is to allow all data input-output to be done with full 512-word sectors on disk. Segment 2--875520 words. This segment is a type of two-dimensional array or matrix in which hole data are placed in a row, data in a particular category are placed in a column, and all data are stored in columns. All the information about a specific hole is located in the same row. The data are stored here in 171 groups of 5120 words. Each group, termed a parameter, has space for a particular item of information about the holes. The hole names, for example, are in parameter 171. This arrangement has made the search and report program to be fast by minimizing the number of disk reads necessary to gather data. Segment 3--684 words. Descriptions of the data in segment 2 is stored here in the following four tables of 171 words each:. • Table 1. Parameter names in ASCII for column headings on output reports. Although limited to 10 characters here, actually they may not consist of more characters than the field widths in Table 3. • Table 2. Parameter formats, used by LST for report printing. In ASCII, with trailing comma. • Table 3. Field widths, used by INPT to check line-widths for report printing. Integers. • Table 4. Data types--an integer corresponding to the type of format in Table 2 : 1 is A, alphanumeric (ASCII); 2 is I, integer; 3 is F. real, floating-point data with fixed-decimal printing; 4 is E, real, floating-point data with scientific-notation type printing. Segment 4--10 words. These are miscellaneous constants describing the data in the other segments. Because this segment is read first, it is indexed from the end of the file and will be described in reverse order (read length minus one, etc.). 1. Number of person executing last update or modification, 6 digits justified on the right in ASCII, e.g . . . . . 393200/" 41

G. L. HAGE

42

KRS FI I I I

Controls other programs I I t

SLCT Processesusers instructions

Selectsdesired data

I I

I

Prio;t;2 s

I

SORT I

PUTT Compiles, executes calculations

Arrangesthe selecteddata

\ III/

Test effects and hole descriptor data

I ouoAT

LsAsE \

Working files Catalogof logging / Job control, scratch, P-~ I ~ F ' ~ r~ data available ] communication, / I ~for holes in DeASE / printing

Ii

Updates OBASE I-,-- " while maintaining | :ompatibility with LBASE!

(

1 -LI

Savefile

X

Data for ] specialapplications /

[

I

LUPOATE

,

!-_.J UpdatesLBASE while |maintaining compatibility [ with DBASE

Application programs

Figure 1. Simplifiedstructure of KRS. Programs are denoted by rectangles; ovals indicate files of information stored on disk; dashed arrows point to programs controlled by another; solid arrows ind.icatedirection of data flow (PUTI" and SORT are not part ofKRS, but are utility programs provided by LLL Computation Department). See Howard, 1976. 2. Date of last update, computer-used, 9 characters justified on the left in ASCII, e.g. ROI/I 1/78^. 3. Time of last update, 8 characters justified on the left in ASCII, e.g. 09: 16:34^^. 4. Name of data file used for last update, justified on the right in ASCII, e.g. . . . . . UPD44. 5. Dimensions of DBASE in two 30-bit integers: left half is the number of parameters, currently 171; right half is the number of spaces, currently 5120. 6. Number of entries, currently about 4100. 7. This number through I0 are unused. LBASE This file is composed of 5 logical segments totaling 1,006,421 words. As before, all data are 60-bit-word oriented to match the CDC-7600 computers on which the KRS programs run. Segment 1--1 word.This word contains the number of entries in the file. It has been superceded by word 6 in segment 4, and will be removed when all programs have been made independent of the one-word offset it causes in address calculations. The main reason for its

removal is to allow all data input-output to be done with full 512-word sectors on disk. Segment 2--1,000,000 words. The data are stored in 40 parameters of 25,000 words. The first 25,000 words contain hole names, followed by 25,000 hole types, both of which are identical with their counterparts in DBASE. Thought of as a matrix, this segment has 40 25,000word columns, where each column is a parameter type and each row contains data on a particular log. The columns are referenced as parameters 301 through 340 by all programs in the KRS system. Segment 3----6250 words. These are pointers, or locations, of the corresponding hole in DBASE. There are four 15-bit pointers per word, each with a value from I to 5120, in the same order as the logs they represent. They allow the update and search routines rapid access to the "opposite" file. Segment 4--160 words. Descriptions of the data in segment 2 are stored here in the following four tables of 40 words each: • Table 1. Parameter names in ASCII for column headings on output reports. Although limited to 10

KRS: a fast, special-purpose database system characters, they actually may not consist of more characters than the field widths in Table 3. • Table 2. Parameter formats, used by LST for report printing. In ASCII. with trailing comma. • Table 3. Fieldwidths, used by INPT to check linewidths for report printing. Integers. • Table 4. Data types--an integer corresponding to the type of format in Table 2 : 1 is A, alphanumeric /ASCII): 2 is 1, integer: 3 is F. real, floating-point data with fixed decimal printing: 4 is E. real. floating-point data with scientific notation printing. Segment 5--10 words. These are miscellaneous constants describing the data in the other segments• Because this segment is read first, it is indexed from this end of the file and will be described in reverse order (read length minus one. etc). 1. Number of person executing last update or modification. 6 digits justified on the right.in ASCII. e.g. , , , , 393200. 2. Date of last update, computer-used. 9 characters justified on the left in ASCII. e.g. R01/I 1/78,. 3. Time of last update. 8 characters justified on the left in ASCII. e.g. 09: 16:34... 4. Name of data file used for last update, justified on the right in ASCII. e.g. • . . . . UPD44. 5. Dimensions of LBASE in two 30-bit integers: left half is the number of parameters, currently 40: right half is the number of spaces, currently 25000. 6. Number of entries, currently about 24000. 7. This number through 10 are unused.

CONSTRUCTIONOF THE CONTROLFILE The selection of various sections of the data files and the arrangement of that data in a printed report are controlled by a short file that consists of a set of control lines (cardsk This file may be constructed most easily using an interactive editing utility routine such as TRIX AC. The name of the file is a user option, and controls the names of output files generated (see the section entitled Options). Of course, cards may be punched and delivered to a card reader if that method is preferred. References to input lines and cards are equivalent in this report. Control lines consist of a three-letter command followed by three-digit or 10 character fields. The commands available are: Select Sort Compute Print

',SLD, SLI, SLA, RID, RJI SEQ, SQD, SDQ COM OUT.

At least one select and one print command are necessary for a proper KRS run. In the matrix interpretation of the data files, these commands answer "which rows" and "which columns" respectively. All commands must be in

+Throughout this section the caret (,) represents a space in a fixed-field input line. The underline (_) is the left arro,~ on teletypes and some printers.

43

the first three characters of their lines. In the following sections, small letters represent fields for parameter number. which must be justified and large letters represent alphanumeric data fields. For select commands, each line may contain as many as three parameter-limit triplets. The first limit is the lower one (either alphabetic or numeric in the algebraic sense): the second limit is either the higher one, or it is identical to the lower limit if an exact match is desired. One may specify, on as many lines as necessary, as many as 15 different parameters, with up to 50 limit-pairs each, for each type of select command. For SLD, SLI, RJD, and RII commands. multiple-limit pairs for the same parameter are considered independently. If any of the limit pairs are satisfied, the overall test is satisfied. The SLA Command is described in the section entitled Search-Selection and was added to provide an exception to this rule.

Print OUTaaabbbccc .... For the holes or logs selected, the enumerated parameters are printed in the order given. Each OUT line controls one listing• Additional listings with the same select-sort criteria may be requested using up to 30 OUT lines. The field widths of the requested parameters (listed in Appendix A) are used to determine in advance how many listings will be needed. Note that if more parameters are requested than wilt fit on a page width. the program will announce the error, scan the rest of the control file for further errors, then terminate (the pagewidth is 120 characters on most of our printers, 70 characters on our terminals). The line-numbering option uses 8 spaces on the left edge: otherwise, only one space is left on the edge. Parameters may be repeated anywhere, and will produce duplicate columns in the output listing• For example. OUT, 17.33,34,, 37+ wilt give a listing of event name, north-south corrdinate, east-west coordinate, and elevation for all holes selected from DBASE. See Appendix B for a sample report.

Search Search-Selection Dependent SLDaaaAAAAAAAAAABBBBBBBBBBbbb.•. The operator selects those holes (or logs) for which parameter aaa falls between the limits AAA... and BBB... The dependent aspect requires that SLD parameter limits for all parameters be satisfied before a hole (or log) is selected• For Example: S L D 36, 1000...... t500. SLDIT1, , 3....... , , 3 will select all holes in area three whose collar elevations are between 1000 and 1500m. All other holes will be rejected. This example also shows the use of a mask described in the following section•

G. L. I'IAGE

44

Search-Selection Independent

Masking

SLIaaaAAAAAAAAAABBBBBBBBBBbbb... The operator selects any holes (or logs) independent of any SLD parameter limit. For example:

A masking ability is allowed with the use of any one of the searching commands (SLD, SLI, SLA. RJD, or RJI) on alphabetic (A-type) data. When requesting only parts of a 10 character word, the remaining positions are filled with an arrow (,-) or underline+ (_) in the first (lower) of the two limit values. Character positions with an arrow in the lower-limit value will be disregarded both in the upper-limit value and in the data being searched. The position of characters in both limit values is important. See Appendix A for examples of the exact format of the parameters. For example:

SLD, 36,1000 .... .1500. SLDI71, ~3. . . . . , ~3 SLI, 17CANNIKIN CANNIKIN will select all holes in area three between a 1000- and 1500-m elevation plus the Cannikan emplacement hole. All other holes will be rejected.

Search-Reiection Independent RJIaaaAAAAAAAAAABBBBBBBBBBbbb... If a hole or log passes an RJI test it will be rejected. This test overrides any previous SLD or SLI. For example:

SLD 171 "--~-~I ~ ' - * ' - < - ' - " - , , , I . . . . . . . will only select holes in DBASE in "integrated testsystem," complexes (the fourth character from left in parameter 171).

Compute SLD 36, 1000. , ,,~ 1500........ 171, ,3 ....... ~~3 RJI~30 .......... QTA .......... QTA will select all holes in area three whose collar elevations are between 1000 and 1500 m but will reject all shots in alluvium.

Search-Rejection Dependent RJDaaaAAAAAAAAAABBBBBBBBBBbbb... Rejection Dependent requires that all RJD parameter limits be satisfied before a hole or log is rejected. For example: SLDI71,. ,,3. . . . . . , ,3 ........... 36^ 1000....... 1500. RJD, 30 . . . . . . . . QTA . . . . . . . . QTA, 23^, ,0.0 . . . . . . 200. will select all holes in area three whose collar elevations are between 1000 and 1500 m. but will reject all shots in alluvium where the depth to the water table is less than 200 m.

Search-Selection and SLAaaaAAAAAAAAAABBBBBBBBBBaaa... This is a special-purpose search that uses both databases. Having selected (or rejected) holes by other critieria, the SLA can be used to determine those holes in DBASE that satisfy all the limits specified on a particular LBASE parameter (up to 10 pairs). For example: SLD171T~6 ....... T,7 SLA303CALIPER___CALIPER...303 DENSITY... DENSITY will select al/holes in NTS areas 6 and 7 for which there are both caliper and density logs. *Teletypes use the back arrow (,--); TI Silent 700 terminals use the underline (_.). Both yield octal 77 internally to the 7600s.

COM(algebraic expression) Any parameter containing floating-point data ("real," in the FORTRAN sense) may enter in a calculation that is also defining another parmeter of this type. (See Appendices A or C for type 3 or 4, or with FORMATS containing E or F. The results are stored in a copy of DBASE (termed DBASECOPY) immediately after the calculation, which is done when the command is first read. (Other commands are collected for later use.) The file DBASECOPY is created unless one already exists, in which situation it is used as is. ThUs, a series of KRS runs can add as many calculated parameters as needed. The file DBASECOPY will be used in the search pass only if the KRS run includes a COM line, so if the file is saved for later use its name must be changed back to DBASE. The expression is FORTRAN-like (CDC, 1972; Lawrence, 1973) but the parameters referred to must be in the form Pnnn(I). If the calculated parameter is to be printed, it must'hav.e an adequate field width. For example: COM P78(I) = SQRT ((P33(I)-246458.158)*'2 + (P34(I)-206792.191)*'2) will calculate the distance to all holes from a particular place in the Nevada grid. Sort This command class specifies the parameters used to order the output report. For sorting, KRS uses the LTSS utility routine SORT (Gray and others, 1974). Up to 10 parameters may be specified, whether they will occur onthe report or not; the first is used for the major sort and the remainder (if any) are taken in order. The second, for example, is only used to sort output lines in which the first-named parameter is equal. Alphanumeric parameters are sorted alphabetically and numeric parameters numerically.

KRS: a fast, special-purpose database system

Sort Ascending SEQaaabbb... Smaller numeric values are sorted first and in the same order as the alphabet. For example: SEQ ,30.17 x~ill sequence the listing by geologic formation (parameter 30l to order all events in a given geologic formation by hole status (parameter 17).

Sort Descending SDQaaabbb... SQDaaabbb... The sorting is done in the reverse order beginning with the largest value first. The order of the keys, the first being the major, is the same as SEQ. These command lines may be mixed with SEQ lines up to a cumulative total of l0 parameters. For example:

1063, August 22, 1975). The programs are all contained in a self-executing LIX file (Ramus. 1975). The name of this file changes from version to version, but it is of the form KRSCymmdd, where ymmdd is the year. month, and day of its creation. Appendix C contains the contents of the latest file as of this writing. The latest version may be read from photostore with ELF using the command RSL .348500: KRS : KRS ALWITH. KRSC. DBASE and LBASE are updated monthly. Backup copies are kept with various names. A report may need one or both data files, as previously described. The latest versions may be read from photostore with ELF using the command RDS .393200:KRS:DBAS:DBASE or RDS .393200:KRS:LBAS:LBASE. The previous copies may be read from photostore using the ELF command RDS .393200: KRS : DBBUP : DBymmxxx or RDS .393200: KRS: LBBUP :LBymmxxx where ymm is the year and month the file was made and xxx refers to an update file used at that time.

Execute line The execute line 1 illustrated below produces a report determined by a control file (as previously described). The order of the first two bracketed items is immaterial:

SEQ. 88 KRSCymmdd SQD ,33 will separate the listing by diagnostic type and list the selections by their locations from north to south.

O P E R A T I O N OF KRS

To execute KRS, several files maintained by KRS personnel must be gathered onto the computer on which the user is logged, and a control file must be created (as previously described). Once started, the KRS requests certain information and then proceeds under control of the control file. The user is cautioned that DBASE contains data that would be classified if it were identified in clear text (Confidential, National Security Information, Exempt from GDS of E.O. 11652, Exemption Category 5(b)(3) Automatically Declassified on Dec. 31, 2008). Without such identification, the codes themselves and the output produced may be handled within the Q-cleared area at Lawrence Livermore Laboratory as PARD (Protect as Restricted Data). Because of this rule, the addition of headings or other annotation to KRS output may cause it to be classified and the user must protect the data. Also, any list associating names or descriptions with parameter numbers of classified parameters must be considered confidential, even when not accompanied by. data values.

45

r infile "~ [options] Fsave.file ] [ /tv ] |/ H E L P /| L omit. J L omit d Lomitd L_ omit _J (1)

where

ymmdd date of creation of the library file containing infile HELP options

savefile

/tv

the programs; year, month, and day; name of the file containing KRS commands; a request for instructions (see the HELP section); a string of letters ending with a period and each letter indicates a particular option or feature to be implemented during this run (see the Options section, next): a name to use for a binary data file in which to save all data selected and printed, as well as the data used for sorting which may be used by other application programs. time and priority value, not needed if one minute is adequate. Most KRS runs producing reports of parts of the data can be run in much less than one minute at the standard priority of 1.

Options The presently available options, which may be requested in any order, are:

Access to files Three files, recently placed in public files under the names KRS, DBASET, and LBASET, are needed to implement KRS. They are in packed form and must be restored to their original size before use. The public file PACK is used to do this (see Octopus Communique CAGEO Vol 9. N e I--D

• S The standard, search run. This is the default type if not stated. • H Output of results to an £SCII file, the name of which is the input file name with an H prefix. This is the default type if not stated.

46

G. L. HAGE

Output to the user's terminal. H overrides T in the same string. • B Make a "save" file (binary) for later use. The presence of a second file name on the execute line has the same result. If there is a B without a second file name, the name will be the input file name with an S suffix. In situation of name duplication the S will be changed to T, and so on. • K Keep all working files after run is finished (for debugging). • R Restart the program named in infile. In this situation only, +KRS is executed instead of KRSCymmdd. The programs in the KRS sequence that may be restarted are +INPT, SLCT, +SLCT, LST, and +LST. The appropriate messages are sent and the sequence continues. This option must be used alone, for example:

Any other letter (L) encountered will be discarded with the message typed: L NOT AN OPTION, and KRS will continue. trying to make sense of the execute line. The default options S and H will be used if no sensible options are found.

• T

- K R S R. +INPT/tv •X

Start the program named in infile. The savefile name is a one-word message sent to the program as it is started. This option preempts all others in the options string. It will override V if it is first (from right). If the name exists as a private file, it is started: otherwise the library index is searched for a file starting with the letters given in infile. For example, DUPDATCV24 may be started with: KRSCymmdd X. DUP DUPINPUT/tv

•V

Type the vital statistics of the database file named in infile. The contents of the header section of any LBASE or DBASE (with any name) will be typed in readable text. For example: KRSCymmdd V. DBASECOPY/tv DBASECOPY OF 17:02:30 R10/11/77 BY 348500. FILE COMJOB SIZE 171 BY 5120 WITH 4160 ENTRIES.

This option preempts all others in the options string. It will override X if it appears first (from right). After the print out, another KRS execute line is requested. Type the RETURN key to end KRS. • L Line numbers of the report listing will be on the left edge. For reports greater than 50 lines, output is continued to following pages, allowing space at the top of each page for parameter names or numbers (see the N option.) With the use of line numbers, repetition of data on subsequent listings, such as hole names, is not needed as all listings will be indexed by their common line numbers. • N Parameter names will head each column of each page of the report. Without this option, the parameter numbers will be printed, as rightjustified integers, at the top of each column.

Help Typing HELP will invoke a dialog with KRS about the features of the execute line. Its operation differs according to what is needed to start execution. It assumes that a good control file "infile" exists. An example of the HELP dialog in context follows. If no items were typed on the execute line, or if HELP appeared anywhere, the following is typed: TYPE FILE NAME(S) AND OPTIONS, OR HELP. Everything that could have been on the execute line now will be accepted, but if only one item is typed, the other will be requested. If the RETURN key only is typed, KRS ends. If HELP is typed in, the following is typed: TYPE INPUT FILE-NAME. Anything that is typed at this point will be used as the input filename, including HELP or a name ending with a period. KRS will end if the RETURN key only is typed. In this mode, options will be requested next (if a file name only were typed on the execute line the default options would have been used). The request is: TYPE OPTIONS OR HELP. Anything ending with a period will be used as an option string. If HELP is typed again, a description similar to that contained in the section entitled Options will be typed (12 lines). Then KRS waits for the string. Any other response caused KRS to end. Acknowledgments--The programs described herein were first written as long ago as 1970. J, T. Rambo, C. Norgauer, L. C. Porter, B. C. Howard, L. A. Lawson, and P. H. Gray have all contributed to the programming effort. The author has rewritten or modified every program, however, in the last three years. M. L. Higuera has maintained the data files on a daily basis and, as the most proficient user of the system, has devised some examples used in this report. All of this work has been done as a part of K Division's support to LLL's Nuclear Test Program (Containment) under the immediate direction of R. C. Carlson, who was a major contributor to this report. REFERENCES

Cecil, A,, and Moll, H., 1982. TRIX AC--A set of generalpurpose text-editing commands: Lawrence Livermore National Laboratory Internal Document LCSD-808, 69 p. Gray, P., Riviel[o, R., Huskamp, J., and Dusenbury, K., 1974, Sort utility routine UR-334: Lawrence Livermore National Laboratory Internal Document M-020, 35 p. Derby, W.. Engle, J., and Martin. J., 1981. LRLTRAN language used with the CHAT and CIVIC compliers: Lawrence Livermore National Laboratory Internal Document LCSD-302, 324 p.

KRS: a fast, special-purpose database system

47 APPENDIXA

Control Data Corporation. 1970, Control Data 7600 Computer System Fortran reference manual: CDC Publ. No. 60280400 (Appendix C), p. C-I, C-3. Howard. N. W., 1976, The Lawrence Livermore National Laboratory nuclear test effects and geologic data bank: Lawrence Livermore National Laboratory Rept. UCRL-78799, p. 17. Howard. N. W., 1979. LLL K-Division nuclear test effects and geologic data base: Glossary and Parameter Definitions, Lawrence Livermore National Laboratory Rept. UCID-18300, Part 1, 69 p.. Part 2.98 p. tPart 2 Confidential, National Security Information). Lawrence, J. D.. and Solbeck. S.. 1973, CLIB subroutine librarx (2nd ed.): Lawrence Livermore National Laboratory Internal Document M-026, LTSS IV Chapter 303. 144 p. Ramus, J. E.. 1975. LIX utility routine UR-32h Lawrence Livermore National Laboratory Internal Document M-020, 22 p. Smith. N.. and Belles, R., 1981, XPORT reference manual: Lawrence Livermore National Laboratory Internal Document LCSD-1196. 153 p.

Data descriptions The tables in this appendix are intended as references to the arrangement of the stored data to aid in searching as well as the field widths used in the report listings to aid in their composition. As such, it contains no helpful information that would cause this report to be classified. The "Example for search" column lists alphabetized data only, because numeric data are word-oriented and can be located by value. (Some feeling for the ranges and accuracy needed for each parameter may be gleaned from the "Listing format" column.) Conversely, alphabetic parameters are character-oriented within words (except for those described as text), and can be searched only if characters match in the correct column. The usual error has been to use left-justified limits on a right-justified parameter. or vice-versa. The ,Data type" and "Listing field width" columns are redundant, but are listed both as a convenience and to avoid writing a full description of FORTRAN formats.

Table 1, LBASE Parameter No.

Data a type

Name or description

301 d

Hole name, including

Listing field width

Listi~b foramt

11

IXAI0

A

for search c Tb6bAi~bbb

site, area, and hole complex designator 302 d

Hole type

A

10

AI0

Elbbbbbbbb

303 d

Log type

A

ii

1XAI0

CALI PERIobb

304

Tool model number

A

ii

IXAI0

LEFAbbbb30

and serial number 305

Digitizer,

A

ii

IXAI0

LLLbbbbbbb

306 d

Date: year, month, day

A

9

IXA8

72-09-12bb

307

Stert-st~p

A

i0

IXA9

1200--1330b

308

Data storage

A

ii

IXAI0

bbbbloGbTbF

309

Logging agency

A

ii

IXAI0

BIRDWELLbb

310 d

Run number

A

6

R6

bbbbbbbl-2

311

Depth drilled,

F

6

F6.0

agency

time location

ft

312

Depth logged, ft

F

6

F6.0

313

Top of log, ft

F

6

F6.0

314

Bottom of log, ft

F

6

F6.0

315

Fluid level in hole, ft

F

6

F6.0

316-319

Data quality

A

41

320-340

Log remarks

A

aA - alphabetic,

F - numeric,

floating-point,

IXAI0 e

text e

201

IXAI0

text

I - integer

(no decimal

printed). bA discussion of formats may be found in Ref. 4. Cb - blank-character dldentifiers. log. five

position,

Parameters

Parameters

to fill 10-character

171 and 4 determine a unique hole.

(or ~¢o) may yield more than one log

eText runs through ~ r d

~rd

(A-type).

301, 302, 303, 306 and 310 determine a unique

boundaries;

A seerd~ not using all

(or hole) satisfying

only the first ~ r d

such criteria.

is preceeded by IX.

48

G. L. HAGE Table 2. DBASE Parameter No.

Data type e

Name o r d e s c r i p , t i o n Hole ~ e n t e

Liating field width

Llltln~ a fo~t

Example for Hatch a TOlqN'lLbbbb

A

11

IXAI0

A

10

AI0

A

i0

AI0

A

11

1XAI0

5

F

i0

F10.1

6

F

10

7

F

7

1 2 3 4b

HOle t y p e

IL].bbbbbbbb

F10.1 F? .2

8

F

7

F7.2

9

F

9

F9.1

ii

A

Ii

IXA10

b~IRbPEOTO

12

A

11

IXAI0

bE. bAHDbH.

13

A

Ii

IXA10

text a

14

A

i0

AI0

text

15

A

i0

At0

text

I0

OnuNd

A

4

R4

bbbbbbblTl

17

Hole status

A

ii

IXAI0

G~Ebbbbb

18

Hole status, continued

bbbbbbbbbb

16

A

I0

AI0

19

F

I0

FI0.4

20

F

9

21

F

9

F9.4

F

8

F8 •2

Fg. 4

22

Depth of burial

23

Depth t~ hydraulic head

F

6

F6.0

24

Depth to tuff

F

6

F6.0

25

Depth to paleozolc rocks

F

6

F6.0

26

Work-polnt rock

A

3

R3

A

2

R2

27 28

Work-point grain density

F

5

F5.2

29

Work-point gas-filled

F

5

F5.1

A

ii

F

7

FT.1

F9.3

bbbbbbbb,'4,L

porosity 30

Geological formation at

IXA10

bbbbbbTRAL

work point 31

Distance from work-point to nearest fault

32

Bottom hole elevation

F

9

33

N-S coordinate (Nev.)

F

11

FII.3

34

E-W coordlnate

F

11

Fli.3

35

Off-site meridian,

A

ii

IXA10

(Nev.) town-

NX023SO30E

ship, and range 36

Collar elevatic~

F

9

F9.3

37

Surface elevation

F

9

F9.3

Off-slte section and

A

Ii

38

IXAI0

quarter section 39

3

I3

40

3

I3

41

3

I3

42

3

13

43

3

I3

44

3

13

45

7

F7.2 F7.3

46

7

47

11

IXAI0

48

II

IXA10

S 14bSWtl¢~4

KRS: a fast, special-purpose database system

49

Table 2 (Cored) Parameter NO.

Name o r description

49 50

Data tYPe a

Listing field width

A

11

Listing s format IXA10

Unused

51

F

Ii

E11.4

52

F

10

F10.2

53

F

10

F10.2

54

F

10

F10.2

55

F

10

Fl0.2

56

F

i0

FI0.2

57

F

10

F10.2

58

F

10

FI0.2

59

F

10

FI0.2

60

F

I0

F10.2

61

F

i0

FI0.2

62

F

10

FI0.2

63

F

i0

FI0.2

64

F

9

F9.4

65

F

9

F9.4

66

F

ii

67

F

6

Ell. 4 F6.2

68

F

9

F9.4

69

F

9

F9.4

70

F

11

71

F

6

72

F

9

F9.4

73

F

9

F9.4

74

F

11

75

F

6

F6.2

76

F

9

F9.4

77

F

9

F9.4

78

F

11

79

F

6

80

Unused

81

Unused

Eli. 4 F6.2

Eli. 4

Ell. 4 F6.2

B2

F

9

F9.4

83

F

9

F9.4

84

F

9

F9.4

85

F

9

F9.4

86

F

9

F9.4

87

A

4

R4

{type)

A

ii

F

9

F9.3

Latitude

(degrees)

F

5

F5.0

92

Latitude

(rain)

93

Latlt udk~ (see)

88

Diagnostic

89

Unused

90 91

IXA10

F

4

F4.0

F

7

F7.3

94

Longitude

(deg)

F

5

F5.0

95

Longitude

(min)

F

4

F4.0

96

Longitude

(sec)

F

7

F7.3

97

F

9

F9.3

98

F

9

F9.4

99

F

9

F9.4

i00

F

9

F9.4

101

F

7

F7.2

Example f o r search a

G. L. HAGE Table 2 (Co.td) Parameter No.

Name or description

Data tYPe a

Listing field width

Listing a format

Example for searcha

102

A

ii

IXAI0

ZbAbbbbbbb

i03

A

i0

AI0

bbbbbbbbbb

A

Ii

IXAI0

bLASL/ARPA

F

6

F6.2

F

7

F7.0

F6.1

104 105

Density work point to

106

Velocity work point to

surface

surface 107

Work point of water, Wt %

F

6

108

Work point of CO2d~y, Wt %

F

6

F6.1

109

Depth to water table

F

8

FS.0

II0

Distance to fault

F

7

F7.1

iii

Work-polnt density

F

5

F5.2

112

Work-point velocity

F

7

F7.0

113

Qualifier for parameter 24

A

5

A5

114

Qualifier for paramete~ 109

A

5

A5

ESTbbbbbbb

115

Qualifler for parameter 23

A

5

A5

K~ASbbbbbb

116

Qualifier for parameter 25

A5

~STbbbbbbb

117 118 119

B o t t o n hole N-S c o o r d i n a t e

120

Bottom Hole E-W c o o r d i n a t e

121

A

5

F

13

F

13

F13.5

F

ii

Fll.3

F13.2

F

ii

FII.3

F

Ii

E11.3

122

Unused

123

Outer

F

6

F6.2

124

Outer casing diameter

F

6

F6.3

125

Inner casing depth

F

8

F8.2

126

Inner casing diameter

F

6

F6.3

127

Orilled h o l e d e p t h

F

8

F8.2

128

Drilled hole diameter

F

6

F6.3

(su~face)casing depth

129

Liner depth, top

F

8

F8.2

130

Liner depth, bott~a

F

8

F8.2

131

Liner inside diameter

F

6

F6.3

132

Unused

133

Distance to measurement hole F

8

F8.2

134

Work-point porosity

5

F5.0 FS.0

F

NEASbbbbbb

135

Wor k-polnt saturation

F

5

136

Qualifier for saturation

A

11

IXAI0

FI0 •2

and water content 137

F

10

138

F

I0

FI0.2

139

F

i0

F10.2

140

F

10

FI0.2

141

F

9

142

F

9

F9.4

143

F

9

F9.4

144

F

9

F9.4

145

F

9

F9.4

146

F

9

F9.4

F9.4

147

F

9

F9.4

148

F

9

F9 •4

149

F

9

F9.4

150

F

8

1'8.2

151

F

9

F9.4

CALCbbbbbb

KRS: a fast. special-purpose database system

5]

Table 2 {Contd) Parameter No.

Data type a

Name or description

Listing field width

Listing s format

Example for search a

152

F

9

P9.4

153

F

9

F9.4

154

F

9

F9.4

155

F

9

F9 •4

156

F

9

F9.4

157

F

9

F9 •4

lXA10

Tb2bDJbbbb

IxAIo

Elbbbbbbbb

158

Unused

159

Measurement hole name

A

11

160

Measurement hole type

A

n

161

Gas-porosity work point to

F

5

F5.1

surface 162

Qualifier for parameter 28

A

4

R4

bbbbbbbDRY

163

Quallfie~ for parameter

A

5

R5

bbbbb@:~.,RAV

164

F

9

Fg. 1 Fg. 1

iii

165

F

9

166

F

9

Fg. 1

167

F

9

F9.1

A

Ii

168

Unused

169

Unused

170

Unused

171 b

Hole name

asee footnotes for LBASE. bldentifiers.

IXAI0

Tb2blBQblbb

5]

G. L. HAGE APPENDIXB

Sample report The following computer printout is a two-page report created using one SLD and three OUT command lines.

KRS L I S T I N G

08:58~11

Res/e8/78

BY 3 4 8 5 0 0

DBASE

e8s18:02

R07/26/78

BY 3 9 3 2 ~ 0

FILE

UPD80

8 SELECTIONS 33 246458.158 246431.156 245486.565 246476,000 246454.g00 246471.761 246435.155 246461.813

34 206792.181T 296807.162 2e6783.927 206804.000 206816.000 206791.118 206823.813 2068e6.659

171 6 T 6 T 6 T 6

A A A A

4

T 6 A T 6 A

H E LI RID R2D S R-$

T 6 A

A

T 6 A

33 246458.158 246431.156 2464e6.565 246476,000 246454.000 246471.761 246435.155 246461.813

91 36. 36. 36. 36. 3636. 36. 36.

92 58. 58. 58. 58. 58. 58. 58. 58.

93 11.720 10.841 10.048 12.310 11.585 12.162 10.967 11.836

34 206792.18! 206807.162 206?83.92? 2068e4.go0 296816.g00 206791.118 206823-813 206806.659

94 116. 116. 116. 116. 116116. 116, 116.

95 3. 3. 3. 3, 3. 3. 3. 3.

96 20.879 2e.28e 21.226 20.389 19.890 20.918 19.606 20.292

APPENDIX C

KRS Library file The following table lists the LIX file contalning the most important KRS programs.

The controller KRSCV7 is started whenever the library file is

executed.

DBL(X)K and LBL00K are older programs that search the data files

for a few "hits" and make on-the-spot changes.

PACK can compress files

containing repetitive data, sometimes to 204~ of the original length. is a special, report-heading routine. calculations and plots.

NVO0

WEST uses the SAVE file to make yield

LUPDATE and DUPDATE are the programs used for our

regular updating of LBASE and DBASE, respectively. Table C-I.

ADDRESS 0 20577 125446 211263 ~76306 320163 435353 4552?5 4?3543 527072 5532?4

LIX file.

LENGTH 20577 10464? 63615 65023 21655 115170 17722 16246 33327 24202 1761I

NAHE KRSCU7 LBL00KCVf f 2 DBL00KC~106 ~EST3A INPTCVI8 5LCTCVII L~TCVI6 PACK DUPDATE26A LU~DATCVI6 NV00