Interactive Computer Methods for 

Generating Mineral-Resource Maps 

Interactive Computer Methods for 

Generating Mineral-Resource Maps 

By James A. Calkins, Alan S. Crosby, Tod E. Huffman, 

Allen L. Clark, George T. Mason, Jr., and Robert J. Bascle 

GEOLOGICAL SURVEY CIRCULAR 815 

Thjs Circular is based on talks presented 

at the Second U.S. Geological Survey Computer Symposium, 

March 22-23, 1978, Reston, Va. 

1980 

United States Department of the Interior 

CECIL D. ANDRUS, Secretary 

Geological Survey 

H. William Menard, Director 

Library of Congress Catalog-card No. 80-600137 

Free on application to Branch of Distribution, U.S. Geological Survey 

604 South Pickett Street, Alexandria, VA 22304 

CONTENTS 

Abstract ---------------------------------------

Introduction --------------------~--------------­

Mapmaking by conventional and computer methods ----

General considerations ------------------------

Time and cost comparisons ---------------------

Discussion ----------------------------------

Quick- Plot maps from the CRIB file, by 

Tod E. Huffman----------------------------

Introduction ---------------------------------

Operating instructions -------------------------

Step 1: Use of the GIPSY program to retrieve 

data from the CRIB file -------------------

Step 2: Edit of the GIPSY copy file-----------

Step 3: Creation of display on a Tektronix 

graphic terminal ---------------------

. PRESTATE.CLIST --------------------

Example ------------------------------------

GIPSY retrieval ------------------------- Quick-Plot map display ____________________ _ 

Program documentation materials ---------------

System description------------------------

Source listings----------------------------

Quick-Plot program (H858) --------------

Mineral-record reformat program-an 

accessory to program H858 ---------

Command procedures ----------------------

GYP .CLIST --------------------------

PREVIEW .CLIST ---------------------

PRESTATE.CLIST --------------------

Interactive Cartographic Automatic Mapping (CAM) 

system, by Alan S. Crosby --------------------

Introduction ---------------------------------

Example 1 ----------------------------------

Searching the CRIB file --------------------

Saving the information on mineral-deposit 

locations -------------------------------

Page 

1 

1 

3 

3 

3 

4 

4 

4 

7 

7 

8 

8 

9 

12 

12 

13 

13 

13 

20 

20 

30 

31 

31 

32 

33 

34 

34 

34 

34 

34 

Interactive Cartographic Automatic Mapping (CAM)-Con. 

Example 1-Con. 

Combining base-map information and 

mineral-location information ---------------

Viewing the map on a graphic display terminal __ 

Viewing a part of the map -------------------

Example 2 ----------------------------------

Conclusions ---------------------------------

CRIB TO CAM program (J499) ------------------

Introduction -----------------------------

Operating instructions ---------------------

Activating the CRIB to CAM process ------

The GIPSY search and copy output--------

Program documentation materials ------------

Program listing of CRIB to CAM (J499) ----

TSO command procedure CRIB.CLIST ----

CAM to Disk (H876) and Plotcam (J725) ----------

Introduction 

Operating instructions ---------------------

CAM-control cards and data definition (DD) 

statements --------------------------

Example of a CAM to Disk run -----------

Plotting on the Tektronix display terminal --

Image relationships --------------------

Plotcam user-prompt messages -----------

Program documentation materials ------------

Program listing of program H876 and JCL for 

link editing --------------------------

Program listing for program J725 ---------

File formats for CAM to Disk program H876 

The symbol problem --------------------

TSO command procedure CAM.CLIST -----

File formats for Plotcam program J725 ----

Glossary ---------------------------------------

References cited ---------------------------------

ILLUSTRATIONS 

Page 

35 

35 

35 

37 

38 

39 

39 

39 

39 

39 

44 

44 

47 

48 

48 

49 

49 

49 

49 

50 

50 

53 

56 

63 

67 

67 

67 

67 

67 

69 

FIGURE 1. Flow diagram of the Quick-Plot map-graphic system, separated into two terminal sessions------------------ 6 

2. List of State codes used as member names in the partitioned data set VG9195J.DIME.DATA ---------------- 10 

3. Flow chart of the Quick-Plot TSO-command procedure from GYP through PREVIEW or PREST ATE (steps 1-3) 11 

4. An example of an interactive search of the CRIB file (step 1 of Quick-Plot) showing GIPSY search and copy statements for retrieving records currently available in the CRIB file on copper and gold in California and Arizona_ 14 

5. An initial small-scale map of the United States produced by the Quick-Plot program on a graphic display terminal 

to show locations of copper and gold deposits in California and Arizona for which information is currently 

available in the CRIB file---------------------------------------------------------------------- 16 

6. A part of figure 5 enlarged by the Quick-Plot program on a graphic display terminal and showing the area of 

California and Arizona only -------------------------------------------------------------------- 17 

Ill 
Page 

FIGURE 7. A part of figure 6 enlarged by the Quick-Plot program on a graphic display terminal to show locations of copper 

and gold deposits in northern California---------------------------------------------------------- 18 

8. Flow diagram showing the functional components of the Quick-Plot map-graphic display system-------------- 19 

9. Map of the southwestern United States produced by the Plotcam program of the Interactive CAM system 

on a graphic display terminal showing locations of copper and gold deposits in California and Arizona________ 35 

10. Reduced copy of final computer-generated map produced by the CAM to Disk program H876 on an off-line 

plotter to show locations of copper and gold deposits in California and Arizona from data currently available 

in the CRIB file ----------------------------------------------------------------------------- 36 

11. The northwestern part of figure 9, enlarged and redrawn by the Plotcam program of the Interactive CAM system 

on a graphic display terminal------------------------------------------------------------------- 37 

12. The title box of figure 9, enlarged and redrawn by the Plotcam program of the Interactive CAM system on a 

graphic display terminal ---------------------------------------------------------------------- 38 

13. An example of an interactive search of the CRIB file showing GIPSY search and copy statements for retrieving 

records on copper mines in the United States, contributed to the CRIB file by Dennis Cox----------------- 39 

14. Map of the United States produced by the Plotcam program of the Interactive CAM system on a graphic display 

terminal and showing copper mines, as reported by Dennis Cox --------------------------------------- 40 

15. Part of figure 14, enlarged and redrawn by the Plotcam program of the Interactive CAM system to show only 

the western half of the United States------------------------------------------------------------ 41 

16. Flow diagram showing the Interactive CAM system------------------------------------------------- 42 

17. Example of a terminal session using CRIB to CAM -------------------------------------------------- 43 

18. Comparison of turnaround times of the standard batch CAM and the Interactive CAM systems -------------- 48 

19. Image relationships between off-line plotter and Tektronix graphic display terminal_______________________ 51 

20. Flow diagram showing order of appearance of Plotcam user-prompt messages---------------------------- 52 

21. Link-edit flow chart for CAM to Disk program H876 ------------------------------------------------- 54 

22. Logic flow chart for CAM to Disk program H876 ---------------------------------------------------- 55 

IV 
INTEilAGriVE COMPUTER. METHODS 

FOR. GENEilA TING MINEilAL-R.ESOUllCE MAPS 

By jAMES A. CALKINS, ALAN S. CROSBY, TOD E. HUFFMAN, ALLEN L. CLARK, 

GEORGE T. MASON, JR., and ROBERT j. BASCLE 

ABSTRACT 

Inasmuch as maps are a basic tool of geologists, the U.S. 

Geological Survey's CRIB (Computerized Resources Information Bank) was constructed so that the data it contains can be 

used to generate mineral-resource maps. However, by the 

standard methods used- batch processing and off-line plotting-the production of a finished map commonly takes 2-3 

weeks. 

To produce computer-generated maps more rapidly, cheaply, 

and easily, and also to provide an effective demonstration tool, 

we have devised two related methods for plotting maps as alternatives to conventional batch methods. These methods are: 1. 

Quick-Plot, an interactive program whose output appears on a 

CRT (cathode-ray-tube) device, and 2. The Interactive CAM 

(Cartographic Automatic Mapping system), which combines 

batch and interactive runs. The output of the Interactive CAM 

system is final compilation (not camera-ready) paper copy. Both 

methods are designed to use data from the CRIB file in conjunction with a map-plotting program. 

Quick-Plot retrieves a user-selected subset of data from the 

CRIB file, immediately produces an image of the desired area 

on a CRT device, and plots data points according to a limited set 

of user-selected symbols. This method is useful for immediate 

evaluation of the map and for demonstrating how trial maps can 

be made quickly. 

The Interactive CAM system links the output of an interactive 

CRIB retrieval to a modified version of the CAM program, 

which runs in the batch mode and stores plotting instructions on 

a disk, rather than on a tape. The disk can be accessed by a CRT, 

and, thus, the user can view and evaluate the map output on a 

CRT immediately after a batch run, without waiting 1-3 days 

for an off-line plot. The user can, therefore, do most of the 

layout and design work in a relatively short time by use of the 

CRT, before generating a plot tape and having the map plotted 

on an off-line plotter. 

INTRODUCTION 

Maps are a basic tool of economic geologists. 

Therefore, data in a computer file on geology and 

mineral resources should be arranged so they can 

be used to generate maps. To devise map-plotting 

applications for use with the CRIB (Computerized 

Resources Information Bank) has been a primary 

objective of the CRIB program since its inception 

(Calkins and others, 1973, p. 2, 8). The computer 

center of the USGS (U.S. Geological Survey) has 

been keenly aware of user needs in this regard and 

has provided a continuing program of evaluation, 

acquisition, and support of map-plotting devices 

1 

and map-plotting program packages. 

Maps discussed in this paper are standard 

geographic maps produced by computer methods. 

In particular, they are mineral-resource maps composed of base-map information and mineralresource information. The base-map information 

includes geographic and political boundaries and 

·other base-map features. The mineral-resource information consists of symbols showing the locations of mineral deposits in their correct geodetic 

positions, plus optional additional information (annotations) adjacent to each symbol. The mineralresource data come from the CRIB file (Calkins 

and others, 1978; Keefer and Calkins,- 1978), and 

the base-map data come from a map-plotting program and from auxiliary digitized files. The 

computer-generated geographic map is variously 

called a geographic-map plot, a map plot, or a point 

plot. 

Many different combinations can be generated 

from a given set of mineral-resource data. By 

changing the kind and size of the symbol and by 

changing the annotations, a series of resource 

maps (called map overlays) can be produced to 

show different kinds of information in various combinations. 

The basic operations performed in making 

computer-generated maps are equivalent to those 

of conventional mapmaking, except that the computer operations are automatic and thus have certain advantages and also certain inherent limitations. In conventional mapmaking, a mineralresource map normally is made in two separate 

plates: a base-map plate containing the base-map 

information and a compilation plate containing the 

mineral-resource information. In computerized 

procedures, these two plates also can be created 

separately, but for most maps, both plates are produced simultaneously on a single map sheet. If only 

a base map is desired, no compilation plate need be 

produced. 

The CRIB staff has been using CRIB data to plot 

maps since 1971 and has devised and extensively 
tested map-plotting methods for other units of the 

USGS. For example: 

1. We devised and experimented with the 

computer-generated base maps of the circumPacific area. 

2. We demonstrated the feasibility of producing 

computer-generated base maps-in various 

projections, at various scales, and in acceptable registrations-on which to plot mineralresource information. 

3. We produced arctic polar projections and 

sinusoidal projections used as base maps on 

which to show oil and gas information. 

Several map-plotting programs are stored in the 

program library of the Survey's computer center 

and are available to users by direct access. Those 

that are most highly used by the CRIB staff and 

that are discussed here are: the Quick-Plot mapgraphic program (H858), the CAM (Cartographic 

Automatic Mapping) to Disk program (H876), the 

CRIB to CAM program (J499), the Plotcam program (J725), and the CAM program (U.S. Central 

Intelligence Agency, 1975). 

The steady growth of the CRIB file during the 

past few years has been accompanied by an increasing use of the file for retrieving information 

and for producing mineral-resource maps. With 

the increased use has come an increased demand 

for more rapid turnaround in producing maps. In 

the batch-processing mode of the CAM program, 

several days, or even weeks, may be needed to 

create a new map, depending upon our familiarity 

with the particular projection to be used, the 

degree of refinement required, the nature of the 

resource data to be shown, and other factors. The 

preparation of "canned" computer routines for certain frequently used projections and scales has 

helped to alleviate this problem somewhat. Nevertheless, in the batch-processing mode of operation, 

the user is unable to see his result until the map is 

plotted on the CalComp1plotter. Usually, the turnaround time for each computer run is 2 days. 

As a means of shortening the turnaround time, 

two separate programs were written to provide for 

interactive viewing of the mineral-resource map on 

a graphic display device- a cathode-ray tube. The 

first program, called Quick-Plot, was written by 

Tod Huffman. It permits the user to retrieve a 

subset of data of his choice from the CRIB file and 

immediately produce an X-Y map plot of the 

1 Any trade names in the Circular are used for descriptive purposes only and do not 

constitute endorsement by the USGS. 

2 

desired area on a graphic display terminal. This 

method is totally interactive, is useful for immediately evaluating the mineral locations of a 

given area, and is useful for demonstrating how 

trial maps can be produced quickly. The image is 

not suitable for use as a final map. The second 

method, called the Interactive CAM system, was 

written by Alan Crosby. It is an extension of the 

standard CAM map-plotting program, which produces full-size finished maps on true geographic 

projections. The Interactive CAM. system also 

allows the user to select the data to be retrieved 

from the CRIB file. Immediately after the batch 

job has been processed through the computer, the 

user can view and evaluate the map image of the 

batch run on a graphic display terminal. Thus, the 

Interactive CAM system saves the user from 

waiting 1-3 days for an off-line plot in order to 

evaluate the map. The user can, therefore, do most 

of the design and layout work in a relatively short 

time, via the graphic display terminal, before 

generating a plot tape and before having the 

finished map plotted on the CalComp plotter. 

These methods complement· each other. The 

Quick-Plot program provides an immediate image 

suitable for a preliminary evaluation, but the image is not intended for publication. The Interactive 

CAM system provides a full-size final map on a true 

geographic projection. However, even final maps 

produced by the Interactive CAM system generally 

require additional hand-tailored work to complete 

a camera-ready compilation. 

Users can quickly learn to use the map-plotting 

methods described here, but would benefit from 

having access to certain supplementary manuals 

and publications. The following manuals contain 

complete information on software and equipment 

referred to, but not discussed in depth, in thisCircular. Complete references to these manuals are at 

the end of this Circular. 

1. IBM Time-Sharing Option Command 

Language Reference Manual (International 

Business Machines Corporation, 1973). 

2. Plot-10 Terminal Control System User's 

Manual (Tektronix, Inc., 197 4a). 

3. Users Manual for the Tektronix 4014 and 

4014-1 Terminal (Tektronix, Inc., 1974b). 

4. Users Manual for the Tektronix 4631 Hard 

Copy Unit (Tektronix, Inc., 1974c). 

5. Programming CalComp Pen Plotters (California Computer Products, Inc., 1969). 
6. GIPSY Users Manual (Oklahoma Unt\rersity, 

Office of Information Systems Programs, 

1975b). 

7. GIPSY Programmer's Manual (Oklahoma 

University, Office of Information Systems 

Programs, 1975a). 

8. CAM (Cartographic Automatic Mapping) Program Documentation (U.S. Central Intelligence Agency, 1975). 

Selected terms in common use in computer 

sciences are defined in the glossary at the end of 

this Circular. 

MAPMAKING BY CONVENTIONAL AND 

COMPUTER METHODS 

GENERAL CONSIDERATIONS 

A computer-generated map, in its final form, involves all the considerations and specialties 

associated with mapmaking in general, including 

cartography, the nature of map projections, layout 

and design, data content, and annotations. 

In conventional procedures, the geologist takes 

an existing base map and compiles geologic and 

mineral-resource data on it. This procedure is 

somewhat restraining because the geologist is 

limited to those base maps that are available, 

which may or may not be the best base maps for 

the job. Ideally, the geologist using conventional 

compilation methods should be able to envision 

beforehand exactly what he wants to compile, 

because once compiled, the data cannot be· 

changed, except by laboriously revising or by making a new co~pilation. However, new ideas often 

surface during compilation and demand a revision 

of the data already compiled. The time required for 

one compilation ranges from a few days to several 

months, depending· upon the degree of organization of the raw data and the complexity of the map 

to be produced. Normally, therefore, time and cost 

limitations prohibit the geologist from making a 

large number of compilations. 

By contrast, the computer-generated mineralresource map offers the geologist a high degree of 

flexibility. The geologist can obtain a base map for 

any area of the world, on any of the commonly used 

projections, and at any scale desired. The base map 

3 

can be produced separately, if desired, and can be 

used as the final base-map plate. The geologist can 

change the base-map scale or projection or the area 

covered at any time. The quantity and kinds of 

data shown on the map can be changed at any time. 

The geologist is not restricted to a limited number 

of hand-compiled maps. Before committing oneself 

to a fmal map, the geologist can produce many trial 

maps showing different kinds of information in 

various combinations. The geologist can then 

select the most meaningful combinations from the 

trial maps to use for one or more fmal maps. 

Depending upon the needs of the job, a 

computer-generated mineral-resource map can be 

made quickly as a rough working copy only, or it 

can be refined to the point where the final product 

approaches the form of the final (camera-ready) 

compilation copy. Nearly always, however, some 

additional hand-tailored layout and design work is 

required to produce the final camera-ready compilation plate. A computer-generated mineralresources map definitely is not intended to be the 

final camera-ready compilation plate. The machine 

is limited in symbols, print fonts, accessory annotations, and so forth, which require hand tailoring. 

Its main function is to provide overlays and working copy quickly and cheaply as an aid in the compilation process. 

TIME AND COST COMPAR.ISONS 

In 1977, in order to obtain some estimates on the 

cost-effectiveness of computer-generated maps 

and of conventionally produced mineral-resource 

maps, the CRIB staff monitored the following 

task: 

A resource specialist wished to generate 10 

mineral-resource maps showing the deposit locations of certain mineral commodities for the State 

of California. These commodities were Cr, Hg, Cu, 

Mn, W, Zn, Ni, Au, Sn, and asbestos. The maps to 

be generated were to register to an existing base 

map-a Lambert projection at a scale of 

1:1,000,000. In all, about 2,000 point locations 

were to be plotted. The resulting maps are considered to be "author's compilation copy," not final 

camera-ready copy. · 

Time and costs using computer methods. -The 

map-generating procedure can be divided into two 
phases: 1. Design and 2. Map production. The time 

and costs for both phases are summarized below: 

Design and specification Map production Total 

Computer _________ _ 

Plotter ------------- Labor (programmer) _ 

Total ------------

Computer (central 

Costs 

$102.51 

77.00 

130.48 

$309.99 

Time 

processing unit) ____ 5.85 min 

Plotter ------------- 3.50 hr 

Prog-rammer ________ 14 hr 

Beginning to end ____ 5 days 

$ 80.00 

110.00 

93.20 

$283.20 

$182.51 

187.00 

223.68 

$593.19 

7.00 min 12.85 min 

5.00 hr 8.5 hr 

10 hr 24 hr 

9 days 14 days 

When computer methods were used, the work required 3 man- days of work at a total cost of $593.19. 

Time and costs using conventional methods. -The 

time and costs for producing maps by conventional 

methods consist largely of labor (compilation) time 

and costs; compilation time can range from a few 

days to several months. However, if we assume the 

following optimum conditions, we can provide a 

rough estimate of time and costs: 

1. All map materials are on hand at no cost (base 

map plus compilation sheets). 

2. All resource data, including latitude and 

longitude coordinates, are organized before 

compilation begins, and are available. 

3. Compilation is done by a technician earning 

$43.92/day. 

4. Compilation proceeds at the rate of one point 

every 4 min, or 120 points per 8-hr day. 

Using these assumptions, we estimate that the 

compilation of the 10 resource maps by conventional methods would require 17 days of compilation time at a labor cost of $7 46.64. 

The comparison of the two methods for producing mineral-resource maps is summarized below: 

Cost Labor 

Computer method------------ $593.19 

Conventional method --------- $746.64 

DISCUSSION 

3 man-days 

17 man-days 

For successive maps showing additional commodities or for plots at other map scales, the cost 

per map generated by computer methods would 

steadily decrease; by contrast, the costs per map 

for additional hand-compiled maps would be the 

same as for each of the original maps. 

4 

The,.number of point locations plotted has little 

effect on the cost of a computer-generated map but 

directly affects the cost of a hand-compiled map. 

For example, if 4,000 rather than 2,000 points 

had been plotted in the task described above, the 

costs of conventional compilation would have 

doubled, whereas the costs of computer methods 

would have been approximately the same. 

In general, the cost-effectiveness of manual and 

computerized map compilation depends on one or 

more of the conditions listed below. 

Manual compilation is efficient if: 

Few point locations (records) are to be compiled; that is, the file is small. 

Few variables (fields) at each location (record) 

are considered. 

Only a few maps are required. 

Computerized compilation· is efficient if: 

Many point locations (records) are to be compiled; that is, the file is large. 

Many variables (fields) at each location (record) 

are considered. 

A series of resource maps is required. 

When the resource geologist needs a series of 

maps showing different kinds of information in 

various combinations for a large number of point 

locations, then the computer-generated map offers 

distinct advantages over the hand-compiled map. 

QUICK-PLOT MAPS FROM THE CRIB FILE 

By Too E. HUFFMAN 

INTRODUCTION 

Quick-Plot is one of the interactive-output programs of the CRIB (Computerized Resources Information Bank). Quick-Plot draws map displays 

on a graphic terminal showing the locations of 

user-selected mineral deposits; these locations are 

retrieved interactively from CRIB by using the 

GIPSY (General Information Processing System) 

program (Oklahoma University, Office of Information Systems Programs, 1975). Quick-Plot provides 

a visual means of making rapid appraisals of 

selected parts of the file in terms of types and 

distributions of mineral deposits existing in a 

geographic area. Quick-Plot is useful for 

preliminary evaluation of subsets of the master 

CRIB file and for demonstration purposes. 

The principal output products from the CRIB 

system include finished compilation (not yet 

camera-ready) copies of maps produced by the 
CAM (Cartographic Automatic Mapping) system 

using GIPSY batch retrievals from the CRIB file. 

If a finished full-size map is not required, the 

9uick-Plot interactive terminal retrieval and map 

plot may by itself satisfy a user request. Usually, 

however, the Quick-Plot map is used to preview 

specific CRIB retrievals before submitting the data 

to the CAM system for plotting on the CalComp 

plotter. 

Basically, the graphic part of the Quick-Plot 

system provides a map display of any data that can 

be represented by single points whose latitude and 

longitude are known. When Quick-Plot is used to 

display mineral-commodity data from the CRIB 

file, the user can interactively: 

1. Choose the geographic area within which 

mineral-deposit data are to be plotted. 

2. Select data on different minerals (short for 

mineral commodities) to be plotted from the 

subfile of data previously retrieved from 

CRIB by GIPSY. 

3. Assign symbols to the individual minerals to 

be plotted. 

4. Select the scale of the map. 

5. Indicate what worldwide coastlines and international boundaries or continental U.S. 

State and county boundaries should be 

shown. 

The Quick-Plot system consists of three interactive user-controlled steps, as follows: 

1. Retrieval of data from CRIB by use of the 

GIPSY program and copy of the retrieved 

data to a preallocated workfile. 

2. An optional user edit of the data in the workfile; edit is under control of the IBM-TSO 

edit procedure. 

3. Interactive map display using the Quick-Plot 

program (H858). 

Steps -1 and 2 are the retrieval/edit function of 

the Quick-Plot program, and step 3 is the display 

function. Each of the two functions is initiated and 

fully controlled through a single TSO command 

procedure. The user merely invokes the proper 

command to enter the desired step. While in direct 

communication with the computer, the user guides 

and controls each step and is aided by user prompts 

and other messages from the computer. 

The retrieval/edit and display functions may be 

performed as two distinct interactive operations, 

or the two functions may be combined into a single 

5 

interactive session (fig. 1). If a Tektronix terminal 

is not readily available, the retrieval and editing 

can be performed on any type of terminal (interactive or batch), and the Quick-Plot graphic map 

display can be completed later when the Tektronix 

terminal is available. If the Tektronix is available, 

then the two functions can be combined into a 

single interactive session. 

In step 1, selected data are retrieved from the 

CRIB file by using the appropriate commands of 

the GIPSY retrieval language (Oklahoma University, Office of Information Systems Programs, 

1975b). Subsets of selected CRIB records are 

created until all selection criteria have been 

satisfied. A fixed-length output file is then 

automatically created when the user gives the 

GIPSY copy command. The required output data 

items from each selected CRIB mineral-deposit 

record are: 

1. An identifier for the principal mineral commodity to be plotted. 

2. Geographic latitude and longitude values. 

Once the copy procedure is completed, the fixedlength output file is available for editing (step 2). 

Under control of the IBM-TSO data editor, the output file may be printed or records may pe changed, 

added, or deleted as desired. 

After editing is completed, the file is automatically prepared for plotting. This preparation 

consists of the conversion of latitude and longitude 

to units of angular measure (radians). 

At this point, the mineral data are ready to be 

plotted on the Tektronix terminal (step 3). Depending upon the geographic distribution of the 

minerals and the degree of map boundary detail 

desired by the user, one of two TSO command procedures that control the display is selected. These 

procedures primarily differ only in the digital map 

boundary files that are available for plotting. 

After the initial map plot is created, several options allow generation of hard-copy output, 

enlargement of specific areas within the display 

under user control, or the complete redefinition of 

the map display in terms of geographic boundaries 

and mineral data to be replotted. 

The following operating instructions describe 

procedures for retrieving data from the CRIB file, 

editing that data, and creating a map plot on the 

Tektronix terminal. 
Geographic 1-------~ boundary 

files 

CRIB 

GIPSY 

Subtile of 

mineral data 

TSO 

data 

editor 

Edited 

subtile 

of 

mineral 

data 

QuickPlot 

SESSION 

1 

SESSION 

2 

FIGURE 1.-Flow diagram of the Quick-Plot map-graphic system, separated into two terminal sessions. 

6 
OPERATING INSTRUGriONS 

In order to gain access to the Quick-Plot system, 

the user must sign on TSO: 

System: LOGON (Tektronix 4010 or 4014 series 

terminal if plotting is to be 

done in the same session as 

the data retrieval) 

System: USERID 

System: READY 

This section gives instructions for performing the 

three distinct steps of the entire Quick-Plot 

retrieval and display procedure. As mentioned in 

the "Introduction" to this section, these steps are: 

1. GIPSY retrieval from the CRIB file using 

selection logic appropriate for the particular problem. 

2. TSO edit of the CRIB data copied from the 

SRF (selected record file) to a preallocated 

dataset (WRK.DATA). 

3. Execution of the command procedure that 

will create the Tektronix display of the 

edited CRIB data. 

STEP 1: USE OF THE GYPSY PROGRAM TO RETRIEVE 

DATA FROM THE CRIB FILE 

User Execute GYP.CLIST 

System: Responds with access to the GIPSY. 

System: ? (Responds with question mark and 

turns control back to user.) 

User :FORM 

System: --------

User : CRIB 

System: ? 

User SELECT 

System: FULL OR TERM SEARCH? 

User : FULL 

System: A. 

User : A40<CA> 

System: B. 

User : C10<AGbb> 

System: C. 

User : A70 

System: D. 

User : A80 

System: E. 

User : Presses return key 

System: LOGIC 

User : A and B and C and D 

System: SEARCH BEGINNING 

System: SEARCHED XXX 

System: SELECTED XXX 

System: VARIABLES SATISFIED 

System: A XXX 

System: B XXX 

System: C XXX 

System: D XXX 

System: ITERATE? 

User : NO 

7 

(All Canadian records.) 

(Any deposit containing silver. Two blank spaces 

are indicated by ''bb.") 

(Contains latitude value.) 

(Contains longitude value.) 

(Asks for logical relations desired among previously entered search parameters.) 

(Records must satisfy all conditions.) 

(At this time, GIPSY searches the CRIB file to 

retrieve all records meeting the stated criteria.) 

(System provides statistics on results of search. 

Number values indicated by "XXX.") 
System: ? 

User COPY 

System: 

System: TERMINAL OR WORKFILE? 

User W 

User 'AGbb' or C10 4 

User A70 9 

User A80 10 

User I 

System: ? 

(Reformat the SRF into the required fixed-length 

output record.) 

(Workfile- a preallocated output file called 

WRK.DATA.) 

(Copy the mineral identifier AG or the first four 

characters of another mineral identifier from each 

qualifying record.) 

(Copy the first nine characters in the latitude field.) 

(Copy the first 10 characters in the longitude field.) 

(To end input.) 

User END (To end the GIPSY session.) 

At this point, step 1 is completed. The CRIB file procedures differ primarily in the map boundary 

has been searched, and qualified records have been files that are made available to the user. The user 

reformatted and written to an output file called - chooses the procedure that will best show the data 

WRK.DATA. The WRK.DATA records contain and the required map boundary details, and then 

the latitude and longitude of mineral deposits and types in EXEC PREVIEW or EXEC PREcontain the symbol for the primary mineral itself. STATE. 

STEP 2. EDIT OF THE GIPSY COPY FILE The procedure named PREVIEW.CLIST is used 

After step 1 has been completed, the terminal for worldwide display. By use of this procedure, 

automatically enters the TSO edit mode. The CAM WDBI (World Data Bank I) background map 

GIPSY file, WRK.DATA, may now be edited by data are superimposed on the plotted CRIB data. 

using the standard TSO edit commands summar- Both coastline and international boundary inforized below. mation is included. 

To list the data: LIST The procedure named PRESTATE.CLIST is 

To change a record: TV used for display of CRIB data within the continenDown XX or Find,, tal boundaries of the United States. In this procedure, the CENSUS/DIME State and county 

boundary files are available. The display may be of 

one or more States. 

Change * " " " " 

To delete a record: Dele~ * 

To add a record: Insert " " 

When the user is satisfied with the CRIB data, 

the data may be saved and the display part of the 

procedure may be initiated. 

User SAVE 

System: SAVED 

User END 

System: READY 

STEP 3. CREATION OF DISPLAY ON A TEKTRONIX 

GRAPHIC TERMINAL 

After mineral data have been selected, retrieved, 

and edited by using the GYP.CLIST procedure, 

they may be plotted on a Tektronix graphic terminal. In order to gain access to the plot software, 

the user must gain access to TSO and sign on his 

Tektronix graphic terminal. (If CRIB file retrieval 

and map plot are done in the same session, then the 

user can simply issue the selected plot procedure 

for execution.) Two TSO-command proceduresPREVIEW.CLIST and PRESTATE.CLIST-are 

available to control the interactive display. These 

8 

If the PREVIEW procedure is chosen for 

display, all files are allocated automatically, and 

the user selects his geographical display window by 

defining maximum and minimum latitude and 

longitude limits. If the PRESTATE procedure is 

chosen, then the user must select States to be 

displayed. States are selected by altering the command procedure so that only the necessary DIME 

boundary file members are allocated. Those State 

file members chosen by the user are concatenated 

as in the example on p. 9 of a PRESTATE procedure set up to display only the States of California and Arizona. 

Modification of the PRESTATE procedure consists of entering the TSO data editor and adding or 

deleting ALLOC FI (allocate-file) statements, including the member names of the State boundaries 

to be displayed. The member names follow the 

standard FIPS (Federal Information Processing 

Standards) naming convention (U.S. Dept. Com-
PREST ATE.CLIST 

OOOOOOlOPROC 0 

00000020TERM SECONOSCJO) INPUT(QUIT> 

OOOOOOJOTPRINT t **** WELCOME TO THE MINERAL DISPLAY SYSTEM ****' 

00000040TPRINT •STEP #3, THE t~TERACTIVE DISPLAY Or EDITED CRIB DATA WILL BEGIN: 

OOOOOOSOTPRINT • THIS PROC LINKS DIME STATE BOUNDARY MEMBERS•••' 

OOOOOOSlALLOC FI<FT20F001> DAC•VG919SJ.OIME.DATACCA)') SHR 00000052~LLOC FICFT?.lFOul> 0AC•VG9!9SJ.OI~E.OATACAZ)t) SHR 

OOOOOOSJCONCAT <FT20f00l FT21FOOll 

00000070ALLOC FICfT06F001) DAC*) 

00000090ALLOC FICFT31F001) DACWRK.DATA> 

00000091ALLOC FICFT30FOOll DACWRKl.DATA> O~OOOlOOLOAO •SYSl.LOADLIBCH858)t FORTLIB EPCMAIN> 

OOOOOllOTPRJNT •*** LOAD DISPLAY PROGRAM - PRIOR TO INTERACTIVE SESSION• 

00000120ALLOC riCFTOSFOOl> DA<*> 

00000121 LOAD 'SYSl.LOADLIBCJ732l' LIAC•SYSl.PLOTlO' •SYSl.TEKTRON.LOAD•> fOPTLI 

00000141 FRFEALL 

OOOOOlSOEND 

II 

merce, 1973). A list of the State codes used as 

member names in the partitioned data set 

VG9195J.DIME.DATA is shown in figure 2. As indicated within the example of PRESTATE procedure, State boundaries are allocated serially increasing file designations beginning at FT20F001 

and ending at FT29F001. The CONCAT (concatenation) statement also must be modified to include only those boundary files being allocated. 

When using PRESTATE, the user is not required 

to define his geographic boundary limits because 

the allocation of specific State boundary files explicitly defines the geographic limits. Figure 3 is a 

flow chart of the TSO-command procedure from 

GYP through PREVIEW or PRESTATE. 

On access to TSO and execution of the appropriate command procedure-PRESTATE or PREVIEW-the interactive display session will begin. 

The user is prompted for input on the characteristics of the niap plot. Four groupings of input are 

requested: 

1. Titling information for the display. 

2. Physical-plot size in terms of terminal-screen 

height and width. 

3. Geographic area of the map to be plotted. 

4. Option selection for either total or selective display of data from the mineral input file. 

After the appropriate command procedure is 

issued, the Tektronix screen will initially erase. Input entry will begin as follows: 

System: START OF TAPE 

System: OPTIONS? The bell will sound. 

User : Respond by typing 1. The bell will sound. 

User : Respond by typing C. 

9 

System: INPUT TITLING INFORMATIONMAX. 56 CHARACTERS. 

User : Respond by typing a character string to 

be used for titling the map plot. 

System: DEFINE GRAPHIC DISPLAY AREA 

(MAX. 10x6 in) WHAT IS PLOT 

SC.REEN WIDTH IN DECIMAL 

INCHES: 

User : Respond by entering a number that is 

used to scale the plot size in inches; for 

example, 8.5 (max.= 8. 7). 

System: WHAT IS PLOT SCREEN HEIGHT IN 

DECIMAL INCHES: 

User : Respond with height; for example, 5.5 

(max.= 5. 7). For the most realistic map 

portrayal, the ratio of plot height to plot 

width should be the same as the ratio of 

map latitude range to map longitude 

range. 

If the PRESTATE.CLIST procedure is 

being executed, the next three prompts 

will not appear. 

System: DEFINE GEOGRAPHIC .AREAINPUT E = 1 or W = 2 hemisphere 

User : Respond with the quadrant for which 

mineral data are to be displayed. 

System: INPUT N = 1 OR S = 2 hemisphere 

User : Respond with the appropriate quadrant. 

System: INPUT GEOGRAPHIC BOUNDARIES-NW LAT, NW LONG, SE LAT, 

SE LONG-IN DEC DEG (F5.1) 

User : Respond with the coordinates of the fourcornered area for which data are to be 

displayed in the geographic order requested (decimal degrees, no embedded 
1ds 'vg9195j.dime.data' m 

VG9195J.DIME.DATA 

--RECFM-LRECL-BLKSIZE-DSORG 

FB 34 12988 PO 

--VOLUMES--

CCD921 

DATA SET IS ON A 3330 AND HAS ROOM FOR A MAXIMUM OF 5,730 RECORDS. 

THERE ARE 190· TRACKS ALLOCATED AND 175 TRA CKS USED FOR THIS DATA SET 

--MEMBERS--

AL NC 

AR ND 

AZ NE 

CA NH 

co NJ 

CT NM 

DC NV 

DE NY 

FL OH 

GA OK 

IA OR 

ID PA 

IL RI 

IN sc 

KS SD 

KY TN 

LA TX 

MA us 

MD UT 

ME VA 

MI VT 

MN WA 

MO WI 

MS wv 

MT WY 

READY 

FIGURE 2-List of State codes used as member names in the partitioned data set VG9195J.DIME.DATA. 

blanks). For example, 

048.0120.0028.0042.0 

NW NW SE SE 

LAT LONG LAT LONG 

System: DO YOU WANT TO DISPLAY ALL 

MINERALS WITHIN THE AREA 

(TYPE IN 1) OR DO YOU WANT TO 

SELECT MINERALS TO BE 

DISPLAYED (TYPE IN 2): 

User : Respond with either 1 or 2. If 1 is 

entered, then locations of all the mineral 

deposits for which data are in the edited 

CRIB COPY file will be displayed (if the 

deposits are within the geographic limits 

as previously defined by the user); all 

deposit locations will be marked by the 

10 

default symbol 0 . If a 2 is entered, then 

the user will be required to list those 

minerals for which he wants information 

displayed and to designate a particular 

symbol to be associated with each 

mineral. 

If the user enters 2, then: 

System: ENTER MINERAL NAMES (2 CHAR) 

AND SYMBOL (1 CHAR)-

0=1; 6=2;+=3; X=4; ¢=5 

TO END INPUT, TYPE IN SYMBOL=0 

[zero]: 

User : Respond with mineral symbol name and 

code for type of symbol to be used for portrayal; for example, CU3. 
EXEC GYP. CLIST 

Allocate CRIB record file RETRIEVAL-EDIT 

STEPS 1-2 

Allocate CRIB dictionary file 

Allocate CRIB selected records file 

Execute GIPSY 

Edit copy output file 

Free all files 

//"""-'-..... 

/ ~ . dS Worldwide Data Bank Continental Umte tates 

minera; distribution mineral dis~ution 

/ '-..... 

EXEC PREVIEW. CLIST / 's,. EXEC PRESTATE. CLIST 

Allocate CRIB copy file (original) 

Allocate reformat-CRIB file 

Execute REFORMAT program 

Allocate Worldwide Data Bank I 

boundary file 

Allocate terminal input 

Allocate terminal output 

Execute plot program 

Free all files 

Allocate CRIB copy file (original) 

Allocate reformat-CRIB file 

Execute REFORMAT program 

Allocate DIME file members 

Concatenate DIME file members 

Allocate terminal input 

Allocate terminal output 

Execute plot program 

Free all files 

PLOT 

STEP 3 

FIGURE 3.-Flow chart of the Quick-Plot TSO-command procedure from GYP through PREVIEW or 

PRESTATE (Steps 1-3). 

The system will echo each item of input 

as: 

System: MINERAL: CU SYMBOL: 3 

User ZN5 

System: MINERAL: ZN SYMBOL: 5 

This sequence continues until the user 

types in the symbol 0 to halt input and 

signal readiness to continue to the next 

prompt. 

User bb0 Two blanks followed by a zero will 

terminate input of minerals and symbology. At this point in the interactive 

problem definition, the system searches 

the digital boundary file(s) for maximum 

and minimum latitude and longitude 

values so as to size the total map-plot 

area to the previously defined screen 

height and width. This search procedure 

is only performed when executing 

PRESTATE.CLIST which accesses the 

DIME files. The system search is not required in PREVIEW.CLIST because the 

geographic boundaries are defined by the 

user. 

11 

System: DIGITAL OUTLINE FILE SEARCHED 

FOR SCALE FACTORS. This is an informative message and does not require 

user response. At this point in processing, the system searches the edited CRIB 

copy file to determine (1) whether any of 

the mineral depo~its described in the file 

are outside the user-defined geographic 

area or (2) whether information on all the 

minerals designated by the user is actually contained within the input file and can 

be displayed. Any discrepancies are listed 

on the screen. At this point in processing, 

several options are available. 

System: TYPE 1 TO CONTINUE. TYPE 2 TO 

SELECT OTHER MINERALS FOR 

DISPLAY FROM THE CRIB FILE. 

TYPE 3 TO REDEFINE THE ENTIRE 

PROBLEM. TYPE 4 TO END SESSION. 

User If the user types 1, the screen erases and 

map plotting is initiated. If the user types 

2, the program returns for redefinition of 

minerals for which information is to be 
displayed. If the user types 3, the program returns to the beginning of problem 

definition, and the user may then completely redefine the display parameters. 

If the user types 4, the map-plot session is 

ended, and the terminal returns to the 

TSO idle mode. 

Depending upon the option selected 

(except 4), the screen will eventually 

erase, and the map plot will be initiated. 

After the entire map plot is created, 

several options are listed at the lower 

right corner of the plot area. 

System: *ENTERS TO END SESSION, 

* ENTER W TO WINDOW: 

(FIRST MIN LAT/LON THEN MAX) 

*ENTER H FOR HARDCOPY AND 

WINDOWING, 

* ENTER R TO DEFINE ANOTHER 

PLOT. 

At this point in processing, the 

crosshair cursor will appear on the face of 

the screen. 

User : If the user types S, the cursor will move 

to the lower left of the screen, and 

READY will appear. The display session 

has ended. 

If the user wishes an area within the 

current map plot to be enlarged, he must 

first position the crosshair cursor (by using the two thumbwheels on the lower 

right of the console) according to the instructions for windowing printed at the 

lower right corner of the plot. Screen 

coordinates for the minimum latitude and 

longitude of the area of interest must be 

designated as step 1, and maximum coordinates must be designated as step 2. The 

user first positions the cursor to the 

minimum position and enters W. At this 

point, the cursor will disappear for an instant and then reappear. The user then 

repositions the cursor to the maximum 

latitude and longitude position and again 

enters W. At this point, the screen will 

erase, and plotting of an enlarged map of 

the selected area will begin. 

To obtain an image of the screen plus 

windowing, follow the same procedure of 

positioning the cursor but enter H, rather 

than W. 

If the user types R, the cursor will 

12 

move to the upper left corner of the 

screen, the program will then request a 

complete redefinition of the map plot, and 

another completely new display will be 

created. This recycling back to the beginning may continue as long as desired. 

EXAMPLE 

The following example illustrates how Quick-Plot 

can be used to retrieve data and produce map plots 

of mineral data from the CRIB file. The retrieval 

was made by using the GIPSY program on the 

USGS IBM -370 computer at Reston, Va. Both data 

retrieval and map plots were made in interactive 

time-share runs. The map images were plotted on a 

Tektronix graphic display terminal. Some map illustrations in this Circular are unretouched direct 

copy, obtained through an attachment that makes 

a paper (hard) copy of the screen image; other illustrations are photographs of the screen. Detailed 

descriptions of the command stream, computer 

statements, and user-generated statements are 

contained in the preceding section on "Operating 

Instructions." 

Request: Produce a preliminary map on a graphic 

terminal showing copper deposits and 

gold deposits currently available in the 

CRIB file that have a recorded production within the States of California and 

Arizona. 

GIPSY RETRIEVAL 

Mter a phone connection is made between the 

user's terminal and the computer, the user engages 

in a controlled "conversation" with the computer. 

The user translates the request into a set of logical 

components, called search statements, and indicates the logical relationship among the search 

statements. The GIPSY program searches the 

CRIB file and retrieves records according to the 

logic specified by the user. A copy of this "conversation," which constitutes step 1 of the session, is 

shown in figure 4. 

The mineral-deposit records that pass all selection criteria are copied into a fixed-length output 

file containing an identifier of the major mineral 

commodity and the latitude and longitude of each 

deposit. 

At this point, the user may enter step 2 and edit 

the data in the output file, or the user may go 

directly to step 3. Editing methods are briefly 
described in the section on "Step 2. Edit of the 

GIPSY Copy File" (p. 8). Complete information is 

contained in the IBM Time-Sharing Option 

reference manual (International Business 

Machines Corp., 1973). 

QUICK-PLOT MAP DISPLAY 

The locations of copper and gold deposits in 

California and Arizona are now available and ready 

for display by means of step 3 of the Quick-Plot 

program. The user issues the PREVIEW command. Then in the first part of the map plot session, four kinds of input on the characteristics of 

the map plot are requested: 

1. Map titling information. 

2. Physical plot size. 

3. Geographic area. 

4. Mineral selection. 

The user chooses to have a small-scale map pro-

. duced initially in t}lis example. Continental and international boundaries are shown, and both the 

copper- and gold-deposit locations are indicated by 

dots. The input statements and the resulting map 

are shown in figure 5. 

For a more detailed display of the individual 

coppe'r- and gold-deposit locations retrieved from 

CRIB, the characteristics of the map plot are 

redefined in order to produce a larger scale map of 

California and Arizona. State and county boundaries are shown. Different symbols are used to 

distinguish between copper and gold deposits. The 

13 

interactive statements and resulting map are 

shown in figure 6. 

A section of the large-scale map (fig. 6) containing overlapping symbols is enlarged to show the 

exact number and location of deposits. To define 

the area to be enlarged, the user moves a crosshair 

cursor on the screen over the display of figure 6. 

Another map plot (fig. 7) is then created at a larger 

scale; it shows the locations at the county level of 

copper and gold deposits in northern California. 

On figure 7, the user can see details that are 

obscured on the primary map. 

PROGRAM DOCUMENTATION MATERIALS 

SYSTEM DESCRIPTION 

Quick-Plot is written in fortran using the 

Tektronix Plot-10 terminal control-system preview 

software. Plot-10 consists of a series of functional 

subroutines allowing graphic display on the 4010 

and 4014 series Tektronix display terminals 

(Tektronix, 1974a, b, 1977). Quick-Plot operates 

via TSO on the IBM-370 computer. 

The Tektronix terminal consists of ~ storage 

tube and keyboard and is capable of both 

alphanumeric and graphic display under program 

control. The 4010-series terminal has a screen size 

of 5 x 7 inches. A later model-the 4014-series terminal- has a screen size of 11 x 15 inches. 

A flow diagram showing the functional components of the Quick-Plot map-graphic system is 

shown in figure 8. Source listings and command procedures are shown in the pages following figure 8. 
exec gyp.clist -.'d~i'>·* WELCOME TO THE MINERAL DISPLAY SYSTEM **** 

THIS COMMAND PROCEDURE PERFORMS STEPS #l AND #2 OF THE 

3 STEP PROCESS: 

THE THREE STEPS ARE: 

(1) GIPSY QUERY, RETRIEVAL, AND COPY OF CRIB DATA 

(2) USER EDIT OF SELECTED CRIB DATA 

(3) INTERACTIVE DISPLAY OF EDITED CRIB DATA 

STEP #l, THE GIPSY CRIB RETRIEVAL WILL NOW BEGIN: 

G I P S Y - UNIVERSITY OF OKLAHOMA 

DAY SEPTEMBER 7,1978 

? 

form 

crib 

? 

select 

FULL OR TERM SEARCH? 

full 

A. a50< 04 > 

STATE CODE .............. . B. a50< 06 > 

STATE CODE .............. . C. a40< us > 

COUNTRY CODE ................ . D. 

LOGIC (a or b) and c 

SEARCH 

LOGIC 

11:12:37.5 SEARCH BEGINNING 

11:12:47.5 

SEARCHED 

SELECTED 

VARIABLES 

A 

B 

c 

ITERATE? 

yes 

SEARCH COMPLETED 

115 

115 SUBSET 

SATISFIED 

33 

82 

115 

1 

11:11 A.M. THURS 

FIGURE 4.-An example of an interactive search of the CRIB file (step 1 of Quick-Plot) showing GIPSY search and copy statements 

generated statements, computer 

14 
A. major< cu > 

MAJOR PRODUCTS .. B. major< au > 

MAJOR J;>RODUCTS .. c. yes YES 

D. a70 

LATITUDE 

E. aBO 

LONGITUDE 

F. 

LOGIC (a or b) and (c and d and e) 

SEARCH 

LOGIC 

11:16:46.8 SEARCH BEGINNING 

11:16:49.2 

SEARCHED 

SELECTED 

VARIABLES 

A 

B 

c 

D 

E 

ITERATE? 

no 

? 

copy 

SEARCH COMPLETED 

115 

115 SUBSET 

SATISFIED 

32 

83 

115 

115 

115 

TERMINAL OR WORKFILE? 

w 

major 4 

a70 9 

a80 10 

I 

? 

end 

2 

G I P S Y - UNIVERSITY OF OKLAHOMA 

DAY SEPTEMBER 7,1978 

THE RETRIEVAL IS COMPLETED- NOW EDIT DATA ... DATA SET WRK.DATA NOT LINE NUMBERED, USING NONUM 

EDIT 

11:17 A.M. THURS 

for retrieving records currently available in the CRIB file on copper and gold in California and Arizona. Search consists of userc~ responses, and messages. 

15 
START. OF. TAPE 

OPTIONS?1 

c 

INPUT TITLING INFORMATION - MAX 56 CHARACTERS 

COPPER AND GOLD: CALIF. AND ARIZ. 

DEFINE GRAPHIC DISPLAY AREA (MAX 10X6 IN.) -- WHAT IS PLOT SCREEN WIDTH IN DECIMAL INCHES : 

8.5 

WHAT IS PLOT SCREEN HEIGHT IN DECIMAL INCHES : 

s.s 

DEFINE GEOGRAPHIC AREA -- INPUT E=1 OR W=2 HEMISPHERE 

2 

INPUT N=1 OR S=2 HEMISPHERE 

1 

INPUT GEOGRAPHIC BOUNDARIES 

NW LAT. NW LONG. SE LAT. SE LONG IN DEC DEG.(FS.1) 

060.0130.0020.0060.0 

DO YOU WANT TO DISPLAY ALL MINERALS WITHIN THE AREA 

(TYPE IN 1) OR DO YOU WANT TO SELECT MINERALS TO BE 

DISPLAYED ~TYPE IN 2) : 

1 

COPPER AND GOLD; CALIF. AND ARIZ. 

130 0 

+ 

-, 

, .. , . 

t EN'fB S~S .. SION, t ENTER W TO WINDOW, (FIRST WIN LAT/LON T~EN WAX I 

... 

1 ENTER H FOR HARDCOPY ANO IINOOIING, t ENTER R TO DEFINE ANOTHER PLOt 

FIGUf:{E 5.-An initial small-scale map of the United States produced by the Quick-Plot program on a 

graphic display terminal to show locations of copper and gold deposits in California and Arizona for 

which information is currently available in the CRIB file. The input information used to generate the 

map is also shown. 

16 

.. 
START OF TAPE 

OPTIONS?1 

c 

INPUT TITLING INFORMATION - MAX 56 CHARACTERS 

COPPER AND GOLD: CALIF. AND ARIZ. 

DEFINE GRAPHIC DISPLAY AREA (MAX 10X6 IN.) -- WHAT IS PLOT SCREEN WIDTH IN DECIMAL INCHES : 

7.4 

WHAT IS PLOT SCREEN HEIGHT IN DECIMAL INCHES : 

5.5 

DO YOU WANT TO DISPLAY ALL MINERALS WITHIN THE AREA 

(TYPE IN 1) OR DO YOU WANT TO SELECT MINERALS TO BE 

DISPLAYED. (TYPE IN 2) : 

2 

ENTER MINERAL NAMES (2 CHAR) AND SYMBOL (1 CHAR) 

TO END INPUT, TYPE IN SYMBOL=O 

CU3 

MINERAL: CU SYMBOL: 3 

AU4 

MINERAL: AU SYMBOL : 4 

110 

DIGITAL OUTLINE FILE SEARCHED FOR SCALE FACTORS 

TYPE 1 TO CONTINUE, OR 2 FOR HARDCOPY AND CONTINUE 

1 

COPPER AND GOLD; CALIF. AND ARIZ. 

124 23 

+cu '+ AU •X 

10e 2 +"2 1 

+ 

FHai}{E 6.-A part of figure 5 enlarged by the Quick-Plot program on a graphic display terminal and 

showing the area of California and Arizona only. The input information used to generate Ute map 

is also shown. 

17 
X 

X 

oJ~ !N~ GOLD 

124 I~ ~ ~ 

~~A..,-----L:.----1 

CALIF. AND ARIZ. 

1 1 8 1 1 

+~O 3~ 

FIGURE 7.-A part of figure 6 enlarged by the Quick-Plot program on a graphic display terminal to show locations of copper and 

gold deposits in northern California. Some symbols that were overlapping are now distinct. 

18 
CRIB 

dictionary 

file 

Copy 

fileunedited 

~---

1 

I 

I 

Copy 

fileedited 

and 

reformatted 

GIPSY 

TSO 

data 

editor 

REFORMAT 

program 

QuickPlot 

CRIB 

record 

file 

I RETRIEVAL/EDIT I FUNCTION 

I 

I 

I 

I - -~ DISPlAY 

I FUNCTION 

I 

I 

I 

I 

I 

I 

FIGURE 8.-Flow diagram showing the functional components of the Quick-Plot map-graphic display system. 

19 
~ 

0 

SOURCE LISTINGS 

QUICK-PLOT PROGRAM (H858) 

DIM~NSION 18UFCIOOOJ.XC2J.Vf2J,XCORC41•VCORC4t,ANNOTC8) 

DIMENSION JTEMflOJ.JSVMBflOJ 

REAL*8 HEAOC7t.XJN 

INTEGER*2 IR 

COMMON ,PARAM' IHEMNS.IHEMEW 

CALL PLOTS(IBUF,lOOO,llt 

C MOVE PEN 0.5 IN AND REDEFINE ORIGIN 

1025 CALL PLOTCJ.O,l.0,-3) 

WRJTEC6.826J 

826 FORMATC1X, 1 1NPUT TITLING INFORMATION -MAX 56 CHARACTERS :•J 

READC5,8?7J HEAD 

827 FORMATC7A8) 

WRITEC6,828J 

e2e FORMATflX,•DEFINE GRAPHIC DISPLAY AREA CMAX 10X6 IN.) --•t 

WRJTEC6,403) 

403 FORMATClX.•WHAT IS PLOT SCREEN WIDTH IN DECIMAL INCHES :•J 

READC5,404) XLIM 

404 FORMATCF3.1) 

WRITEC6.405) 

405 FORMATflXt 1 WHAT IS. PLOT SCREEN HEIGHT IN DECIMAL INCHES : 1 ) 

READC5,404) VLIM 

WRJTEI6,829J 

829 FORMATC1X. 1 0EFJNE GEOGRAPHIC AREA --•) 

WRITEI6,400) 

400 FORMATflX, 1 INPUT E•l OR Wa2 HEMISPHERE') 

READC5,401J IHEMEW 

401 FORMATfllt 

WRIT£.(6,402) 

402 FOR~ATC1X,•JNPUT N=l OR S•2 HEMISPHERE 1 J 

READC5,401) IHEMNS 

WRIT£(6,2000) 

2000 FORMATC1X, 1 INPUT GEOGRAPHIC BOUNDARIES --1 ) 

WRJTEC6,2001) 

0000001"0 

00000020 

00000030 

00000040 

00000050 

00000060 

00000070 

00000080 

00000090 

00000100 

00000110 

00000120 

00000130 

00000140 

00000150 

00000160 

00000170 

00000180 

00000190 

00000200 

00000210 

00000220 

00000230 

00000240 

00000250 

00000260 

00000270 

00000280 

00000290 

00000300 

00000310 

00000320 

00000330 

2001 FORMATC1X, 1 NW LAT, NW LONG. SE LAT, SE LONG -- IN DEC 

READC5t2002) DLAT1tDLON1.DLAT2,0LON2 

DEG.CF5.1J'J00000340 

00000350 
t...:> 

~ 

2002 FORMATC4F5.1t 

WRJTEC6.830) 

QUICK-PLOT PROGRAM (H858)-Continued 

830 FORMATflX. 1 DO YOU WANT TO DISPLAY ALL MINfRALS WITHIN THE AREA t) 

WRJTEf6.831) 

!31 FORMATf1X. 1 1TYPE IN 1) OR DO YOU WANT TO SELECT MINERALS TO BE 1 ) 

WRITEC6.832t 

832 FORMATIIX.•DISPLAVED ITYPE IN 2) :•t 

REA-DC 5.834) ICHOS 

834 FORMATCJl) 

IFCICHOS .NE. 2) GO TO 503 

NUM • 0 

WRITEf6.407J 

407 FORMATC1X. 1 ENTER MINERAL NAMES 12 CHARI AND SYMBOL fl CHAR) --•t 

WRITEf6.835J 

835 FORMATI1X. 1 TO END INPUT. TYPE IN SYMBOL=O : 1 ) 

DO 500 I • 1.10 

READI5.408) ITEMflt. JSYMBCIJ 

502 FORMATflX. 1 0NLV 10 ITfMS/~MBOLS ALLOWED-PROCESSING CONTINUE0 1 J 

503 CONTINUE 

RAD • 0.0174533 

C COMPUTE XV MIN/MAX ACCORDING TO QUADRANT 

JFIIHEMEW.EQ.2) GO TO 4001 

XMAX • DLON2 * RAD 

XMIN • OLONl * RAD 

408 FORMAT(A2.Il ) 

IF fiSVMBCJ) .EQ. 0) GO TO 503 

WRJTEf6.409) JTEMCIJ. ISYMBIIJ 

409 FORMATflX. 1MINERAl: 1 .2X.A2.1X.•SYMBOL:•.zx.IlJ 

NUM • NUM+l 

IF fi.EQ. 10) GO'TO 501 

500 CONTINUE 

GO TO 503 

501 WRJTEI6.502) 

00000360 

00000370 

00000380 

00000390 

00000400 

00000410 

00000420 

00000430 

00000440 

00000450 

00000460 

00000470 

00000480 

00000490 

00000500 

00000510 

00000520 

·00000621 

0000063, 

0000064( 

0000065( 

00000660 

00000670 

00000680 

00000530 

00000540 

00000550 

00000560 

00000570 

000005@0 

00000590 

00000600 

00000610 
I:\:) 

I:\:) 

GO TO 4003 

4001 XMAX c DLONl * RAO 

XMIN • DLON2 * RAD 

QUICK-PLOT PROGRAM (H858)-Continued 

4003 IFCIHEMNS.EQ.l) GO TO 4002 

YMAX • DLAT2 * RAD 

YMJN • DlATl * RAD 

GO TO 4004 

4002 YMAX • DLATl * RAD 

YMJN • DLAT2 * RAO 

4004 CONTINUE 

300 FORMATI5X.8F08.3J 

DELX • XMAX-XMIN 

DELY c YMAX-YMJN 

XS • XLJM/DELX 

YS c YLJM.IDELY 

IF CICHOS .EQ. 1) GO TO 836 

DO 600 J• l.NUM 

660 READI30,510,END=680) Yll),Xfl),JMIN 

JFIIMIN.EO. JTEM(J)) GO TO 620 

GO TO 660 

620 IFIXClJ.LT.XMJN.OR.XIlJ.GT.XMAX) GO TO 640 

IFCYCtJ.LT.YMIN.OR.Yil).GT.YMAX) GO TO 640 

GO TO 670 

640 WRJTEC6,650) JMIN 

650 FORMATI1Xt 1 ---MJNERAL 1 t2X,A2t1Xt 1 1N CRIB FILE OUTSIDE OF AREA') 

GO TO 670 

680 WRITE(6,621J ITEMIJJ 

621 FORMATC1Xt 1 ***MINERAL 1 ,2X,A2t1X, 1 NOT IN CRIB FILE') 

C IF MINERAL NOT IN CRIB FILE DO NOT PLOT; SET FLAG = 0 

ISYMBIJ) • 0 

670 REWIND 30 

600 CONTINUE 

WRITEI6,690) 

690 FORMATtlX•'TYPE l TO CONTINUE, OR 2 FOR HARDCOPY AND CONTINUE 1 J 

00000681 

00000690 

00000700 

00000710 

00000720 

00000730 

00000731 

00000740 

00000750 

00000751 

00000760 

00000770 

00000780 

00000790 

00000800 

00000810 

00000820 

00000830 

00000840 

00000850 

00000860 

00000870 

00000880 

00000890 

00000900 

00000910 

00000910 

00000930 

00000940 

00000950 

00000960 

00000970 

00000980 

00000990 
('~.:) 

~ 

READC5-,691) IGO 

691 FORMAT(J1) 

QUICK-PLOT PROGRAM (H858)-Continued 

IF fJGO .EQ. 2t CALL HDCOPY 

3000 CONTINUE 

CALL PLOTCXX,YY,3) 

CALL ~LOTCXX.YY.2J 

LN01 a LNO 

3001 CONTINUE 

READf20,END•100) LND.IR.FlAT.FLON.KNT 

CALL QUAD CFLAT,FLON.IYN) 

IF IIYN.EQ.1) GO TO 3001 

JFCFLON.GT.XMAX.OR.FLON.LT.XMINJ GO TO 3003 

JF(FLAT.GT.YMAX.OR.FLAT.LT.YMINJ GO TO 3003 

YY • FLAT 

XX • FLON 

CALL CNVRTCXX.YY .xs.vS.XMIN.VMIN.XMAX.VMAX) 

C CHECK IF PEN UP OR DOWN 

IF (IPU.EQ.IJ GO TO 3005 

836 CALL ERASE 

C SET PEN INDICATOR 

111 IPU • 0 

110 REA0(20.END=100J LNO.IR.FLAT.FLON.KNT 

CALL QUAD IFLAT,FLON.IYN) 

IF IIYN.EQ.l) GO TO 110 

IFIFLON.GT.XMAX.OR.FLON.LT.XMIN) GO TO 110 

I~(FLAT.GT.YMAX.OR.FLAT.LT.VMIN) GO TO 110 

YY • FLAT 

XX • FLON 

CALL CNVRTIXX.YY .xs.vS,~IN.YMIN.XMAX.YMAX) 

00001000 

00001010 

00001020 

00001140 

00001150 

00001160 

00001170 

00001180 

00001190 

00001200 

00001210 

00001220 

00001230 

00001240 

00001150 

00001260 

00001270 

00001280 

00001030 

00001040 

00001050 

00001060 

00001070 

00001080 

00001090 

00001100 

00001110 

00001120 

00001130 
[:...:> 

~ 

QUICK-PLOT PROGRAM (H85SJ-Continued 

IF CLNO.NE.LNOI) GO TO 3000 

CALL PLOTCXX.YY.2) 

GO TO 3001 

C COORD$ OUTSIDE MAPPED AREA - RAISE PEN 

3003 JF CIPU.EQ.lJ GO TO 3001 

CALL PLOTCXX.YY.3) 

IPU • 1 

GO TO 3001 

C COORD$ HAVE AGAIN ENTERED AREA - LOWER PEN AND PLOT 

3005 CALL PLOTCXX.YY.3J 

CALL PLOTCXX.YV,2J 

JPU • 0 

GO TO 3001 

100 CONTINUE 

XCORCIJ • XMIN 

JFCIHEMEW.EQ.lJ XCORfl) • XMAX 

YCORCIJ • YMIN 

JFCIHEMNS.E0.2J YCORfl) • YMAX 

XCORf2) • XMIN 

IFCJHEMEW.EQ.l) XCORC2J • XMAX 

YCOR(2) • YMAX 

IFCIHEMNS.EQ.2J YCORf2) = YMIN 

XCORC3) • XMAX 

IFCIHEMEW.EQ.1) XCORI3J • XMIN 

VCORf3) • YMAX 

IFCJHEMNS.EQ.2) YCORI3) • YMIN 

XCOR(4) • XMAX 

IFIIHEMEW.EQ.l) XCORC4) • XMIN 

VCORI4t • YMIN 

JFCIHEMNS.EQ.2) YCORI4) • VM~X 

C DRAW CORNER TICS 

DO 800 J•1•4 

CALL CNVRTCXCORIJJ.YCORIJ) .xs,YS.XMIN,VMJN.XMAX, 

00001290 

00001300 

00001310 

00001320 

00001330 

00001340 

00001350 

00001360 

00001370 

00001380 

00001390 

00001400 

00001410 

00001420 

00001430 

00001440 

00001450 

00001460 

00001470 

00001480 

00001490 

00001500 

00001510 

00001520 

00001530 

00001540 

00001550 

00001560 

00001570 

00001580 

00001590 

00001600 

00001610 
1:-..:l 

01 

QUICK-PLOT PROGRAM (H858)-Continued 

*YMAXJ 

CALL SVMBOLIXCORfJJ.YCORIJJ,0.25,3,0.0,-JI 

800 CONTINUE 

C ANNOTC8)1XULLO,VULLO,XURLO.VURLO.XURLT.YURLT,XLRLT,VLRLT 

ANNOT(l) c XCORClJ 

ANNOTt2J • VCORC2J + 0.20 

ANNOT(3J = XCORf3) 

ANNOT(4) • ANNOT(2) 

ANNOT(5) • XCORC2J + 0.14 

ANNOTf6) = VCORC3t 

ANNOT(7) c ANNOTC5) 

ANNOTC8) • VCORC41 

DO 840 1•1•7•2 

J • 1+1 

IF IJ.EQ.2) XIN•XMJN 

IFIJ.E0.2.AND.IHfMEW.EQ.1) XJN • XMAX 

IF CJ.E0.4J XIN•XMAX 

IFfJ.EQ.4.AND.JHEMEW.EQ.l) XIN = XMIN 

IF (J.EQ.6) XIN=YMAX 

JFCJ.EQ.6.ANO.IHEMNS.EQ.2) XIN • YMJN 

IF CJ.EQ.8) XIN=VMIN IFCJ.EQ~8.ANO.JHEMNS.EQ.1) XIN c YMAX 

CALL RTOMS IXIN.IXD.IXMJ 

XD = IXD 

XM • JXM 

CALL NUMBERIANNOTCit.ANNOT(JJ.O.l4.XO,o.o.-IJ 

ANNOTCI) = ANNOT(J) + 0.56 

CALL NUM8ERCANNOTCIJ.ANNOTCJJ.O.J4.XM,o.o.-1J 

840 CONTINUE 

ANNOTC2) = ANNOTC2) + 0.60 

C PLOT TITLING 

CALL SVM80LCO.O.ANNOTf2J.0.25.HEAD.0.0,56) 

00001620 

00001630 

00001640 

00001650 

00001660 

00001670 

00001680 

00001690 

00001700 

00001710 

00001720 

00001730 

00001740 

00001750 

00001760 

00001770 

00001780 

00001790 

00001800 

OOOOT81-0 

00001820 

00001830 

00001840 

00001850 

00001860 

00001870 

00001880 

000018~0 

00001900 

00001910 

00001920 

00001930 
t...:> 

~ 

QUICK-PLOT PROGRAM (H858)-Continued 

C READ MINERAL FILE,CHEtK MIN tOOE £ GET SVMBOL,JD,SCALE9 XY 

540 READC30,510tEND=520J YCJJ,Xf1J,IMIN 

510 FORMATf2F7.5,2X.A2,56X) 

IF fiCHOS .EQ. lJ GO TO 512 

DO 511 Jsl,NUM 

IF fJMIN.EQ.JTEMfJ)J GO TO 512 

511 CONTINUE 

C IF CRIB MINERAL NOT IN USER AREA DO NOT PLOT 

GO TO 540 , 

512 CALL CNVRTIXCIJ,Vfl) ,XS,YS,XMJN,YMIN,XMAX,YMAXJ 

IF fJCHOS .EO. 1) CALL SYMBOLCXCIJ,VCIJ,O.OOS,J,o.0,-1) 

IFfiCHOS .NE. lJ CALL SVMBOLCXC1J,YflJ,0.14tiSYMBCJJ,o.o,-J) 

GO TO 540 

520 CONTINUE 

C PRINT LEGEND AT LOWER LEFT 

XLEG 1: 0.20 

YLEG • 0.0 

IF C JCHOS .eo. 1 J GO TO 837. 

DO 820 J•l,NUM 

C IF MINERAL INVALID C=O ) THEN DO NOT PLOT 

IF CISYMBCJJ.EQ. OJ GO TO 820 

CALL SYMBOLCXLEG,YLEG,O.l4tiTEMIJJ,O.Ot21 

XLEG = XlEG + 0.40 

CAll SYMBOlCXLEG,YLEG,0.14,•:•,o.O,lJ 

XlEG • XLEG + 0.10 

CAll SYMBOLCXLEG,YLEG,O.l4,1SYMBCJJ,Q.O,-JJ 

XLEG • XlEG - 0.60 

YLEG s YlEG - 0.20 

JFCYlEG .EO. -1.0) GO TO 821 

GO TO 820 

821 XLEG • XLEG + 0.80 

VLEG • 0.0 

00001940 

00001950 

00001960 

00001970 

00001980 

00001990 

00002000 

00001010 

00002020 

00002030 

00002040 

00002050 

00002060 

00001070 

00002080 

00002090 

00002100 

00002110 

00002120 

00001130 

00002140 

00002150 

00002160 

00002170 

00002180 

00002190 

00002200 

00002210 

00002220 

00002230 

00002240 

00002250 

00002260 
t-:) 

~ 

QUICK-PLOT PROGRAM (H858)-Continued 

820 CONTI.NUE 

837 IFCICHOS.EQ.l) CALL SVMBOLIXLEG,YLEG,O.J4, 

*'All MINERALS PLOTTE0 1 ,0.0t20t 

C COMPUTE XCOORO FOR USER INFO THEN PLOT OPTIONS 

XMJD = CXMAX-XMIN)/2.0 + XMIN 

CALL CNVRTCX"IDtYil) ,XS,YS,XMJN,YMIN,XMAX,YMAX) 

CALL SYMBOLCXMIO,o.o,O.l4, 1 * ENTER S TO END SESSJON,•,o.0,25) 

CALL SYMBOLIXMIO,-o.20t0•14, 1 * ENTER W TO WJNDOW:•,o.0.201 

CALL SYM80LCXMID,-o.40,0.14, 1 CFIRST MIN LAT,LON THEN MAX)•,o.o. 

*28) 

CALL SYMBOLCXMJD,-0.60,0.14, *'* ENTER H FOR HARDCOPY AND WJNDOWJNG,•,o.0,37) 

CALL SYMBOLCXMID,-o.eo,O.l4, 

*'* ENTER R TO DEFINE ANOTHER PLOT•,o.0,32) 

CALL VCURSRCICHAR,XX,VVJ 

C VCURSR COORD REL SCREEN WINDOW SO SUBT 1.0 IN. FOR ORIGIN SHIFT 

xx • xx-1.0 

YY • YY-1.0 

C STRIKE S TO TERMINATE 

IF CICHAR.E0.83) GO TO 901 

IF CICHAR.EQ.72J CALL HDCOPY 

C IF R-FLAG THEN DUMP BUFFER AND DEFINE ANOTHER PLOT 

IF CJCHAR.EQ. 82) GO TO 1020 

CALL BCKXYCXX,YY,DELX,DELY9 XMJN,YMJN,XMAX.YMAX,XLIM 9 YLJM) 

CALL VCURSRIICHAR,XXX,YYYJ 

xxx = xxx-t.o 

YYV c YVY-1.0 

IF CICHAR.EQ. 83) GO TO 901 

CALL BCKXYCXXX,YYY,DELX,DELY,XMJN,YMJN,XMAX,YMAX,XLIM 9YLI"J 

XMJN • XX 

YMJN • YY 

X,..AX • XXX 

00002270 

00002280 

00002290 

00002300 

00002310 

00002320 

00002330 

00002340 

0000?350 

00002360 

00002370 

00002380 

00002390 

00002400 

00001410 

00002420 

00002430 

00002440 

00002450 

00001460 

00002470 

00002480 

00002490 

00002500 

00002510 

00001520 

00002530 

00002540 

00002550 

00002560 

00002570 
1:\.:) 

00 

VMAX • VYV 

CALL ERASE 

QUICK-PLOT PROGRAM (H858)-Continued 

C WITH NEW XMIN/YMIN AND XMAX 9 VMAX CREATE NEW PLOT 

REWIND 20 

REWIND 30 

DELX c XMAX-XMIN D~LV • VMAX-VMIN 

XS • XLIMAlELX 

VS • VlJM/OELY 

GO TO 111 

C MDV~ CURSOR TO 0.0. ERASE SCR~EN, AND REDEFINE PLOT 

1020 CALL PLOT f-l.O,-l.0,-3) 

CALL ERASE 

CALL ANMODE 

CALL HOME 

REWIND 20 

REWIND 30 

GO TO 1025 

901 CALL PLOTC0 •• 0.,999) 

200 FORMATC1X, 1 END OF JOB') 

STOP 

END 

SUBROUTIN~ 8CKXVIX,Y,DELX,DELY,XMIN,YMJN,XMAX,YMAX,XLIM.YLIM) 

C SUBROUTINE TO CONVERT SCREEN COORDS IN XV TO RADIANS 

COMMON /PARAM/ IHEMNS,IHEMEW 

IFCIHEMNS.EQ.l) Vc YMIN + CfY/YLIM)*DELY) 

IFCIHEMEW.E0.1) Xc XMAX - CCX,XLIM)*DfLX) 

JFCIHEMNS.E0.2) Y• YMAX - CCY/YLIM)*DELY) 

JFCJHEMEW.EQ.l) X• XMIN + CCX/XLJM)*DELX) 

RETURN 

END 

...... 

SUBROUTINE CNYRTCXM.VM ,xs,YS,XMIN,YMJN,XMAX,Y"AX) 

COMMON /PARAMI IHEMNS,IHEMEW 

IF CJHEMNS.EQ.l) VM • CYM-Y~JN) * YS 

00001580 

00002590 

00002600 

00002610 

00002620 

00002630 

00001640 

00002650 

00002660 

00002670 

00002680 

00002690 

00002700 

00002710 

00002720 

00002730 

00002740 

00002750 

00002760 

00002770 

00002780 

00001790 

00002800 

00002810 

00002820 

00002830 

00002840 

00001850 

00002860 

00002870 

00002880 

00002890 

00002900 

00002910 
~ 

~ 

QUICK-PLOT PROGRAM (H858)-Continued 

IF IIHEMNS.EQ.2) VM • fYMAX-YM) * VS 

IF (IHEMEW.EQ.ll XM a (XM-XMIN) * XS 

IF IIHEMEW.EQ.2) XM • CXMAX-XMI * XS 

RETURN 

END 

SUBROUTINE RTDMS CPHJ.IDEG.IMJN) 

IMPLICIT REAL*8 CA-H.D-ZI 

RHO = 206264.80624700 

SEC = DABSIPHII*RHO 

IDEG c SEC/3.603 

IMIN c CSEC-IDEG*3.603),6.001 

IFIPHI.LT.O.DO.AND.IDEG.GT.O) IDEG = -JDEG 

IFfPHI.LT.O.OO.AND.IDEG.EQ.O.ANO.IMIN.GT.O) IMJN • -IMIN 

RETURN 

END 

SUBROUTINE QUAD CFLAT.FLON,IVN) 

C PROCESS ONLY THOSE WOB ENTRIES WITHIN QUADRANT 

C IHEMEW•l=E,IHEMEW•2=W•IHEMNS•l•N•IHEMNS=2=S 

C IVN•l MEANS OUT OF QUADRANT 

COMMON /PARAM' IHEMNS.IHEMEW 

JVN • 0 

JFCJHEMEW.EQ.7.AND.FLON.GT.O.OI GO TO 10 

IFIIHEMNS.EQ.2.ANO.FLAT.GT.O.OI GO T~ 10 

IFIIHEMEW.EQ.l.AND.FLON.LT.O.OI GO TO 10 

IFfiHEMNS.EQ.l.AND.FLAT.LT.O.O) GO TO 10 

IFCIHEMEW.EQ.2) FLON • -FLON 

IFCIHEMNS.EQ.2) FLAT =-fLAT 

RETURN 

10 IVN • 1 

RETURN 

END 

00002920 

00002930 

00002940 

00002950 

00002960 

00002970 

00002980 

00002990 

00003000 

00003010 

00003020 

00003030 

00003040 

00003050 

00003060 

00003070 

00003080 

00003090 

00003100 

00003110 

00003120 

00003130 

00003140 

000031~0 

00003160 

00003170 

00003180 

00003190 

00003200 

00003210 

00003220 
1:/.j 

0 

MINERAL-RECORD REFORMAT PROGRAM -AN ACCESSORY TO PROGRAM H858 

IMPLICIT REAL*& CA-H,D-Z) 

200 READf31.20.ENDclOOJ SYM,XOL,XML,XSL,XDLN,XMLN,XSLN 

20 FORMAT( A2,2X,31F2.0,1X),F3.0,2C1X,F2.0)J 

XDL • CXDL+((XML+IXSL/60.0))/bO.OJ) 

XDLN = CXDLN+f(XMLN+CXSLN/60.0)),60.0)) 

XDL • XDL/57.29577951 

XDLN • XDLN,57.29577951 

WRITEC30,30) XDL,XDLN,SYM 

30 FORMAT( 2F7.5,2X,A2.62X) 

GO TO 200 

100 CONTINUE 

WRJTE(6,101) 

101 FORMATClX.•THE CRIB MINERAL POSITIONS HAVE BEEN CONVERTED') sroP 

END 

00000010 

00000020 

00000021 

00000040 

00000050 

00000060 

00000070 

00000080 

00000090 

00000100 

00000110 

00000120 

00000130 

00000140 

00000150 
Col.:) 

""""" 

COMMAND PROCEDURES 

GYP.CLIST 

OOOOOOlOALLOC FJ<SY~DICT> 0~(•RIF.niCTl.CR1801 ) SHR 

00000020ALLOC FI<SY~REC> DA<•Rtf.WOOOl.CRTB1 1 ) SHR 

00000030ALLOC FI<SY~GW~K) DA<•RIF.K0022.TS0SAVE•> SHR 

00000040ALLOC fl(SYSWRKO) DA(tVGql9SJ.WRK.DATAt) SHR 

OOOOOOSOALLOC fl(SYSPCH) DA(*) 

00000060TPPTNT '***~ WELCOME TO THE MINERAL DISPLAY SYSTEM ' 

00000070TPRINT •THI~ COMMANO PROCEDURE PERFORMS STEPS 11 AND •z OF THE• 

OOOOOOBOTPRJNT • ~STEP PROCESS:• 

00000090TPRTNT •TH( THREE STEPS ARE:• 

OQOOQlOOTPRTNT t (1) GYPSY QUERY, RETRIEVAL, AND COPY Or CRIB DATA• 

OOOOOllOTPRINT • < 2) USER EOIT OF SELECTED CRIB DATA' 

OQ000120TPPJNT • (~) I~TERACTIVE OISPLAY Of EDITED CRIB OATA• 

00000130TPRtNT t t 

00000140TPRINT •STEP ilt THE GIPSY CRIR RETRIEVAL WILL NOW REGINI' 

00000150TPRINT • ' 

06000160CiLL •SYSI.niPLIR<TS02741)t 

OQ000170FRFF. FI<SYSf,WRKtSYSWRKO,SYSDICTtSYSRECtSYSPCH) 

OOOOOlBOTPRINT t • 

00000190TPRINT •THE RETRIEV~L IS COMPLETEO - NOW EDIT DATA•••' 

00000200TPRINT • ' 

00000210EDTT WRK DATA OLD NONUM 

00000230ENn 

II 
PREVIEW. CLIST 

OOOOOOlOPROC 0 00000020TER~ SECONOJ30) INPUTCQUITJ 00000030TP.RINT '** ** WE~COME TO THE MINERAL DISPLAY SYSTEM ****' 

OOOOOQ40TPRINT •THIS PROC LINKS.TO WOB I BOUNDARY FILE' 

00000050ALLOC FICFT06F001) DAC*> 

00000060ALLOC FICFT31F001) DACWRK.DATA) 

00000070ALLOC FICFT30F001; DACWRKl.OATA) 

00000080 LOAD tSYSleLOADliBCH858)t FORTLIB EPCMAIN) 00000090A~LOC FI<FT20F001) DA<•VG5207AeWDBICOSTeDATAt) SHR ~ OOOOOlOOALLOC FI<FT21F001) 0A('VG5207A.WDBIBNDSeDATA') SHR 

OOOOOllOCONCAT CFT20F001 FT21F001) 00000120ALLOC FI<FT05F001) DAC*) 00000130 LOAD •SYSleLOADLIB<J729) 1 LIB<•SYSlePLOTlO' •SYSl.TEKTRONeLOAD'> FoRTLI 

00000140FREEALl 

00000150END 

II 
Cl.:l 

Cl.:l 

00000010PROC 0 

OQ000020TFRM SECOND~<JO> INPUT<QUIT> 

00000030TPRJNT I **** WELCOME TO THE MINERAL DISPLAY SYSTEM ****' 

00000040TPRJNT •STEP #3t THE INTERACTIVE DISPLAY OF EDITED CRIB DATA WILL BEGIN: 

OOOQOOSOTPRTNT I THIS PROC LINKS DIME STATE BOUNDARY MEMBERs ••• • 

00000051ALLOC FI<FT?OFOOl> DAC•VG9}9SJ.OIME.OATA(UT)t) SHR 

00000070ALLOC FI<FTo6FOOl> DAC*> 

00000090ALLOC Ft<FTilFOOl) DA<WRK.DATA) 

0000009lALLOC FICFT;OFOOl) 0A(WRK1.DATA) 

OOOOOlOOLOAn •SYSlel 0ADLIA<HAS8)' FORTLIB EP<MAIN) 

OOOOOllOTPRTNT I*** LOAD DISPLAY PROGRAM - PRIOR TO INTERACTIVE SESSION• 

00000120ALLOC FI(FToSFOOl) OAC*) 

0000012l LOAD 1 $YSI.L0AOLIBCJ732) • LIB<•SYS1.PLOT10' •SYSl.TEKTRON.LOAOt) FORTLI 

00000141 FREEALL OOOOOlSOEN~ 

II 
INTERACTIVE (:ARTOGRAPHIC 

AUTOMATIC MAPPING (CAM)SYSTEM 

By ALAN S. CROSBY 

INTRODUCTION 

The Interactive CAM (Cartographic Automatic 

Mapping) system is an enhanced version of the 

standard CAM program (U.S. Central Intelligence 

Agency, 1975). The Interactive CAM system was 

devised to shorten the map-creation time primarily 

through the use of interactive methods, which 

simplify the data-input procedures and allow the 

user to view the result on a graphic-display terminal immediately after each job run. Interactive 

CAM is used to plot on base maps information from 

mineral-deposit records stored in the CRIB (Computerized Resources Information Bank) of the 

USGS (Calkins and others, 1973, 1978; Keefer and 

Calkins, 1978). The user may make a base map only 

(base-map plate), may plot mineral-location data 

only (compilation plate), or may have both basemap and mineral-location data combined on a 

single map. Usually both base-map and mineral information are plotted on the same map. 

The mapmaking procedures of the Interactive 

CAM system are discussed in the following pages. 

First, the whole process is briefly described and 

two examples are given. More detailed operating 

instructions and program documentation follow. 

Some of the details of the interactive conversation 

between man and machine have been omitted from 

the examples in order to make them simpler and 

clearer. 

EXAMPLE I 

SEARCHING THE CRIB FILE 

The first step in making a map that shows 

mineral data on a base map is to conduct an interactive search of the CRIB file for the data on 

mineral deposits of interest. Because the CRIB file 

operates. under the GIPSY (General Information 

Processing System), the search is done in the 

GIPSY retrieval language (Oklahoma University, 

Office of Information Systems Programs, 1975a, 

b). The search procedures are similar to those used 

for Quick-Plot. Example 1 in the Interactive CAM 

system is the same example used to illustrate the 

Quick-Plot -program (p. )14.:.18, figs. 4-7). 

The object of example 1 is to plot on a base map 

the locations of productive copper and gold 

deposits in California and Arizona. By means of a 

set of logical statements, the user will instruct the 

GIPSY program to select from the CRIB file 

records containing latitude and longitude coordinates on those mineral deposits in Arizona and 

California that have produced copper or gold as 

major products. These logical statements are 

shown below. 

FORM 

CRIB 

SELECT 

A. A50<04> 

B. A50<06> 

C. A40<US> 

LOGIC (A or B) and C 

ITERATE 

A. MAJOR<CU> 

B. MAJOR<AU> 

C. YES 

D.A70 

E. A80 

LOGIC (A or B) and (C and D and E) 

GIPSY will make a list of the records meeting 

these criteria and will pause for further instructions. 

SAVING THE INFORMATION ON MINERAL-DEPOSIT 

LOCATIONS 

The chemical symbol and coordinates from each 

mineral-deposit record on the list are extracted 

(copied) from the CRIB file and passed along to 

other programs in the Interactive CAM system. 

The commands below instruct GIPSY to extract 

the records. 

34 

COPY 

'02' 

MAJOR 2 

'!' 

A70 9 

A80 10 

END 

GIPSY copies the mineral-deposit information to 

disk and passes control over to the CRIB to CAM 

program, which automatically reformats the information into a format acceptable to CAM. 
COMBINING BASE-MAP INFORMATION AND MINERALLOCATION INFORMATION 

Next, the base map is defined by preparing CAM 

control statements. In a batch run, the CAM to 

Disk program of the Interactive CAM system 

prepares a base map according to these control 

statements, overlays the mineral-location data just 

copied by CRIB to CAM, and stores the resulting 

map in digital form on disk. 

VIEWING THE MAP ON A GRAPHIC DISPLAY TERMINAL 

The Plotcam program of the Interactive CAM 

system uses the base-map and mineral-location 

data stored on disk to draw the map on a graphicdisplay terminal (fig. 9). Figure 9 is a draft map 

that is reviewed interactively by using Plotcam 

(see the section below, "Viewing a Part of the Map'). 

crosshai.r 

cursors 

-

--

If the map requires modification, the CAM control 

statements are corrected, and the CAM to Disk 

run is repeated. This process continues until a good 

draft of the map is obtained. When a satisfactory 

map is obtained, the previous batch-job run is 

repeated, this time writing the digitized information on tape. The tape is used to plot the final map 

on an off-line plotter. The final map plotted on an 

off-line plotter is shown in reduced form in figure 

10. 

VIEWING A PART OF THE MAP 

The screen of the graphic-display terminal 

measures only 15 in. by 11 in., and a typical map 

plotted on an off-line plotter is three times as large. 

When the map is reduced to fit the terminal display 

screen, some of the fine detail is lost. However, 

• 

• • • 

: . 

. • • 

• 

• 

• 

• 

DO VOU YANT TO PLOT THE FILE AGAIN? 

FIGURE 9.-Map of the southwestern United States produced by the Plotcam program of the Interactive CAM system on a graphic 

display terminal and showing locations of copper and gold deposits in California and Arizona. Positions of user-controlled 

crosshair cursors define the part of the map to be enlarged and redrawn as shown in figure 11. 

35 
~ 

~ 

AU A~U AU/ AU 

." 

I 

<:::, ~ 

~ 

~ 

clJitu cu cu 

cu 

,'§u 

F Hit: JU: 10.-Reduced copy of final computer-generated map produced by the CAM to Disk program H876 on an off-line plotter to show locations of copper and gold deposits 

in California and Arizona from data currently available in the CRIB file. The plotter produced the map at the scale of 1:2,500,000; it has been reduced for publication. 
Plotcam can be instructed to draw an enlargement 

of any part of the map. The user defines the area to 

be redrawn at a larger scale by marking the lowerleft and upper-right corners of the desired area. 

The marking is accomplished by moving two fine 

lines (cursor lines), which appear on the screen, until their intersection defines a crosshair ( crosshair 

cursor) at each corner of the desired area. Plotcam 

erases the current image and then searches 

through the digital surrogate of the map and draws 

only the digital information within the area of interest. The enlargement is drawn quickly in front 

of the user. 

The ability to enlarge parts of the map aids in the 

layout and design of the final map. For example, 

where symbols are dense and overlap, an enlargement is needed to show greater detail. The positions of the crosshair cursors for redrawing a part 

of the map are shown in figure 9, and the enlargement of that part of the map is shown in figure 11. 

As another example, the title box shown on the 

original map (fig. 9) is illegible. In order to check 

the layout and design, the title box was redrawn to 

occupy the entire screen as shown in figure 12. 

EXAMPLE 2 

Example 2 of the complete Interactive CAM 

process begins with the GIPSY query shown in 

figure 13; the query will select and copy records on 

those United States copper mines contributed to 

the CRIB file by Dennis Cox. After the selected 

data are put into CAM format and are stored on 

6.30 XSPAN• 12.60 VMIN• 15.00 VSPAN• ;.ss 

AU 

AU 

AU 

AU 

AU 

AU 

AU 

AU 

AU AU AU 

AU 

AU 

AU 

AU AU 

AU AU AU AU AU 

u 

T THE FILE AGA N? REPLV V OR N 

FIGURE 11.-The northwestern part of figure 9, enlarged and redrawn by thef'1otcam program of the Interactive CAM system on 

a graphic display terminal. Formerly overlapping symbols in California are now distinct. 

37 
disk by the CRIB to CAM program, they can be 

combined with a base map by the CAM to Disk program. The resulting map drawn by Plotcam is 

shown in figure 14. The same map has been enlarged and redrawn to show only the western half 

of the United States in figure 15. 

CONCLUSIONS 

The CAM to Disk and Plotcam programs of the 

Interactive CAM system can be used to display information from most files containing latitude and 

longitude information, if the latitude and longitude 

can be extracted and converted to the CAM format 

(U.S. Central Intelligence Agency, 1975, p. 2-18). 

At present, CRIB to CAM performs these tasks 

'<MIN• 6.91 XSPAN• 3.20 VMIN• 

only for the CRIB file, but the same techniques 

used in CRIB to CAM could also be used to extract 

coordinates from other GIPSY files. 

The programs of the Interactive CAM system 

are available for general use. Details on their 

construction and operation are contained in the 

following sections. 

Sometimes tools designed for specific tasks are 

found to have a wider use. Although they were 

designed to speed up the reviewing of a draft map, 

the programs of the Interactive CAM system can 

also be used to produce a final compilation. The 

programs are used for CAM training; students 

learn by watching the map-drawing process. The 

programs can also be used to display information 

for a group of viewers. 

6.81 VSPAN• 2.30 

COPPER AND GOLD IN 

CALIFORNIA 

AND ARIZONA 

ALBERS PROJ. ·2500000 

DO YOU WANT TO PLOT THE FILE AGAIN? REPLY Y OR N 

FIGURE 12.-The title box of figure 9, enlarged and redrawn by the Plotcam program of the Interactive CAM system o~ a graphic 

display terminal. This enlargement allowed an immediate check of spelling and the placement of textual matenal. 

38 
QUERY: Find all the records on copper mines in the United States 

contributed to the CRIB file by Dennis Cox. 

The records must contain "latitude and 

longitude coordinates in order to be 

plotted by the Interactive CAM· system. 

SEARCH METHOD: Look for United States 

(A40<US>) records reported by Cox 

(G2<COX>) to have copper as the major 

element (MAJOR<CU>). Deposit must have 

produced some copper (YES), and record 

must contain latitude (A70) and longitude (A80) information. 

System: READY 

User: exec crib 

System: LINK CRIB FILE AND INTERACTIVE CM1 

System: G I P S Y - UNIVERSITY OF OKLAHOMA 

System: ? 

User: form 

System: 

User: crib 

System: ? 

User: select 

System: 

System: 

User: f 

System: A. 

User: a40<us::> 

System: 

System: B. 

User: g2<cox> 

System: 

System: C. 

User: major<cu> 

System: 

System: D. 

User: yes 

System: 

System: E. 

User: a70 

System: 

System: F. 

User: a80 

System: 

System: G. 

FULL OR TERM SEARCH? 

COUNTRY CODE 

NAME 

MAJOR PRODUCT 

YES 

LATITUDE 

LONGITUDE 

(User touches the carriage-return key.) System: LOGIC 

User: a and b and c and d and e and f 

System: LOGIC 

(User touches the carriage-return key.) 

System: 17:50:20.4 SEARCH BEGINNING 

System: 

User: 

System: 

User: 

System: 

System: 

User: 

User: 

User: 

User: 

User: 

User: 

User: 

System: 

User: 

System: 

System: 

System: 

System: 

17:51:27.3 SEARCH COMPLETED 

* * * * * * ITERATE? 

n 

? 

copy 

TERMINAL OR WORKFILE? w 

'02' 

major 2 I! I 

a70 9 

a80 10 

I 

? 

end 

G I P S Y - UNIVERSITY OF OKLAHOMA 

RECORDS READ: *** 

READY 

FIGURE 13.-An example of an interactive search of the 

CRIB file showing GIPSY search and copy 

statements for retrieving records on copper mines in 

the United States, contributed to the CRIB file by 

Dennis Cox. 

39 

CRIB TO CAM PROGRAM (J499) 

INTRODUCTION 

The CRIB to CAM program reformats CRIB 

mineral information into a form CAM can use. It is 

activated by the TSO-command procedure, CRIB, 

which begins by activating GIPSY. A search of 

CRIB is conducted in the GIPSY retrieval 

language (Oklahoma University, Office of Information Systems Programs, 1975a, b) for records on 

mineral deposits. The records are copied out of the 

CRIB file, and CRIB to CAM reformats them and 

stores them on disk (fig. 16). 

OPERATING INSTRUCTIONS 

ACII\"A 11:'\it; TilE CRIB 10 CA!\1 PROCE.<,~ 

The TSO command to activate the CRIB to CAM 

process is: EXEC CRIB 'GIPFILE (name of a 

CRIB file) MEMBER (name of a storage area)', 

where "name of a CRIB file" is the full name of the 

CRIB file to be searched. If GIPFILE is omitted, 

then the standard CRIB file will be searched. The 

"name of a storage area" is the name (chosen by the 

user) of a member in a partitioned data set, called 

LAT.LONG.DATA in this paper, where the results 

of the run will be stored. If the name of the storage 

area is omitted, the name NONAME will be used. 

The command can have several forms, for example: 

EXEC CRIB 

EXEC CRIB 'MEMBER(PERU)' 

EXEC CRIB 'GIPFILE(CRIB7) 

MEMBER(STORE7)' 

When the command EXEC CRIB is issued, control 

is passed to the GIPSY program. 

I"IIE t;IPSY SEARCH ANI> COPY OLTTPLII 

When GIPSY gains control, conduct the search 

for information on the deposits in which you are interested. Then, copy the data elements and the 

latitude and longitude from the selected records by 

using the copy command. This command can have 

three formats. 

Format 1: 

COPY 

l-lnnnl' (inserted literal) 

A 70 9 (latitude field) 

A80 10 (longitude field) 

I 

where "nnn" is a three-digit code for the symbol to 
be plotted. 

Example: 

COPY 

!-1116!' 

A70 9 

A80 10 

I 

The copy command in this example will cause the 

delta symbol to be plotted for each record selected 

at the latitude and longitude specified in the 

record. One delta symbol will be plotted for each 

record copied from the GIPSY file. 

Format 2: 

COPY 

'nn text!' 

A70 9 

A80 10 

I 

X"IH• 4.42 XSPAN• 31.55 VMIN• 

where "nn" is a number from 01 to 40. It gives the 

length of the "text," which is a character string to 

be plotted. 

Example: 

COPY 

'06copper!' 

A70 9 

A80 10 

I 

The copy command in this example will cause the 

word "copper" to be plotted at the latitude and 

longitude contained in each record. The word "copper" will appear once for each record copied from 

the GIPSY file. 

3.50 VSPAN• 22.57 

REPLV V OR N FIGURE 14.-Map of the United States produced by the Plotcam program of the Interactive CAM system on a graphic display terminal and showing copper mines, as reported by Dennis Cox. 

40 
Format 3: 

COPY 

'nn' 

Label-l Ll 

Label-n Ln 

'!' 

A70 9 

A80 10 

I 

where "nn" is the sum of Ll, ... Ln; it should not 

exceed 40. 

"Label" is a data element, the contents of which are 

to be plotted. 

"L" is the number of characters to be plotted from 

a data element. The sum of all lengths, L should 

not exceed 40. 

Example: 

COPY 

'40' 

AlO 24 

ClO 16 

'!' 

A70 9 

A80 10 

I 

The copy command in this example will cause the 

name of the mineral deposit, AlO, and the chemica] 

symbols for the commodities present, ClO, to be 

plotted at the latitude and longitude specified in 

1 • 79 

N 

FIGURE 15.-Part of figure 14, enlarged and redrawn by the Plotcam program of the Interactive CAM system to show only the 

western half of the United States. 

41 
the record. Because the data being plotted are 

coming from the record, what is plotted will vary 

from record to record. A word of caution: if the 

mineral deposits are too close to each other, the 

data from one may be plotted on top of the data 

from another. 

An example of a complete GIPSY search and 

copy output is shown in figure 17. 

CRIB files 

CAM 

control 

cards 

Plotter 

Plot the 

map 

Map plot 

on paper 

Select CRIB records 

and copy data of 

interest 

CRIB to CAM (J499) 

Convert CRIB records 

to the CAM format 

Digitial 

map outlines 

on disk 

CAM to disk 

program (H876) 

Generate 

plotting instructions 

Plotcam (J725) 

Plot the 

map 

CRIB record 

in CAM format 

on disk 

Plotting 

instructions 

on disk 

Copied CRIB 

records 

FIGURE 16.-Flow diagram showing the Interactive CAM system. 

42 
System: READY 

User: exec crib 'gipfile(crib.data.set) rnernber(copper)' 

System: LINK CRIB FILE AND INTERACTIVE CAM 

System: G I P S Y - UNIVERSITY OF OKLAHOMA 

Sys tern: ? 

User: form 

System: 

User: crib 

Sys tern: ? 

User: select 

System: 

System: 

User: f 

System: A. 

User: clO<cu> 

System: 

System: B. 

FULL OR TERM SEARCH? 

COMHODITIES PRESENT: 

(User touches the carriage-return key.) 

System: LOGIC 

User: a 

System: SEARCH 

System: LOGIC 

(User touches the carriage-return key.) 

System: 16:49:51.3 SEARCH BEGINNING 

16:50:00.0 SEARCH COMPLETED 

SEARCHED 405 

SELECTED 122 SUBSET 1 

VARIABLES SATISFIED 

A 122 

System: ITERATE? 

User: n 

Sys tern: ? 

User: copy 

System: 

System: TEru1INAL OR WORKFILE? 

User: 

User: 

User: 

User: 

User: 

w 

'08 copper! ' 

a70 9 

a80 10 

I 

Sys tern: ? 

User: end 

System: 

System: G I P S Y - UNIVERSITY OF OKLAHOHA 

System: RECORDS READ: 122 

System: READY 

User: list 'lat .long. data 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPER 

08 COPPKR. 

08 COPPER 

08 COPPER 

(copper)' nonurn 

432727Nll42153W 

432542Nll42102W 

432636Nll41932W 

432634Nll41838H 

432652Nll41751W 

432708Nll417491-1 

433314Nll41234W 

434150Nll41723W 

434039Nll41720W 

433847Nll41446W 

434119Nll41823W 

433049Nll42 710\..J 

434002Nll41632\.J 

99 

99 

F ll; l 1u: 17. -I:<:xample uf a terminal session using CRIB to CAM. Shown are the statements 

resulting from a GIPSY sean:h of the CRIB file and a listing of part of the reformatted output. 

43 
PROGRAM DOCUMENTATION MATERIALS 

PROGRAM LISTING OF CRIB TO CAM Q499) 

//VG901745 JOB f934000231,~499J,•ALANCROSBV , COMPILE AND LINK J499 

II CLASS•A 

//Sl EXEC PLIXLIB,PROGcJ499 

//PLI.SVSCIN DO* 

J499: PROt OPTIONSfMAINJ; 

I* CONVERTS LOCATIONS COPIED OUT OF A 

DCL 

PLIXOPT CHAR (7) VAR 

DCL 

GJPSV FILE INTO THE CAM FORMAT MBFMT *J 

I* SETS ISA AT EXECUTION TIME TO 5K */ 

JNITC 1 1SAC4KJ 1 t STATIC EXTERNAL; 

COUNT FIXED BINARY f311 

JNIT (0); 

I* USED TO COUNT THE NUMBER OF RECORDS *J 

I* READ BY THIS PROGRA~ *J 

DCL 

1 CAM_RECORD, 

2 COUNT_aLKl CHAR(59J, 

2 LATO CHARf2), 

2 LATM CHARf2), 

2 LATS CHARf2), 

2 ALAT CHARCl), 

2 LONGO CHAR(3), 

2 lONGM CHARf2), 

2 LONGS CHARf2J, 

2 ALONG CHAR(J), 

2 FILLER CHARf6) JNJT f' 1 ); 

DCL I* 

IN CHAR (74); I* 

SSKJPf5); 

OUTPUT RECORD IN CAM MBFMT FORMAT 

I* 1-59 FORMAT VARIES *I 

/* 60-61 LATITUDE, DEGRE£S *J 

I* 62-63 LATITUDE, MINUTES *I 

I* 64-65 lATITUDE, SECONDS *I 

I* 66-66 S FOR SOUTH, OR N FOR NORTH*

I* 67-69 lONGITUDE, DEGR£S~ *I 

I* 70-71 LONGITUDE, MINUTES *I 

I* 72-73 LONGITUDE, SECONDS *I 

I* 74-74 E FOR EAST, OR W FOR WEST *I 

I* 75-80 BLANK */ 

INPUT RECORD IS PRODUCED BY THE GIPSY*~ 

COPY COMMAND. THE FORMAT OF THE 

RECORD IS: 

Y, ,LATJTUOE,LON~JTUDE 

Y -1 AND A 3 DIGIT SYMBOL CODE OR 

c,o 

C 2 DIGITS GIVING THf LENGTH OF D 

D UP TO 40 CHARACTERS TO BE PLOTTED 

A DELIMITER 

LATITUDE IN THE FORM DD-MM-SS, SIN 

LONGITUDE IN THE FORM DDD-MM-SS, EIW */ 

ON ENOFILE (001) GO TO AlOO; 

44 
PROGRAM LISTING OF CRIB TO CAM (J499)-Continued 

I* MAIN LOOP *I 

DO WHILE C1 1 1 B); 

READ FILE fDDl) INTO liN); 

COUNT= COUNT+ 1; 

K = INDEX fiN,• •t; 

IF K = 0 I* WAS THERE A • • ? *I 

THEN '* NO *I 

DO; 

PUT EDIT 1 1 INPUT RECORDS ARE NOT IN THE CORRECT FORNAT. '• 

'THE DELIMITER • • IS MISSING. RUN WAS STOPPED.•t 

CCOLilt,A,At; 

GO TO AlOO; I* STOP THE RUN */ 

END; 

COUNT_BLKl = SUBSTR tiN9l•K- lt; L c K + 1; 

LATD • SUBSTRCJN,L,2); 

l = L + 3; 

LATM • SUBSTR(IN.L,2t; 

l = L + 3; 

LATS = SUBSTR(IN,L,2t; 

L = L + 2; 

ALAT • SUBSTRfJN,L,l); 

L = l + 1; 

LONGO = SUBSTRCIN,L,3J; 

l • L+ 4; 

LONGM • SUBSTRfiN,L,2); 

L • L + 3; 

lONGS • SUBSTR(JN,L,2); 

L • L + 2; 

ALONG • SUBSTRCJN,L,lJ; ~SKIPC5t; 

I* IF THE OEGRESS, MINUTES, OR SECONDS PORTION OF LONGITUDE OR 

LATITUDE ARE BLANK, THEN SET THEM TO ZERO. *I 

ISKJPf5); 

IF LATD • 1 1 THEN LATD • •oo•; 

IF LATM • 1 1 THEN LATM • '001 ; 

IF LATS • 1 ' THEN LATS = 1 00 1 ; 

45 
PROGRAM LISTING OF CRIB TO CAM Q499)-Continued 

IF LONGO = 1 1 THEN LONGO • 1 0001 ; 

IF LONGM = 1 1 THEN LONGM z •oo•; 

IF LONGS = 1 1 THEN LONGS= 1 001 ; 

WRITE FILE fDD2) FROM CCAM_RECORDt: 

/* END MAIN LOOP */ 

END; 

AlOO: 

CLOSE FILE fOOl); 

CAM_RECORD • 1 1 ; 

l ATD • ·'99'; 

/* WRITE EOF RECORDS FOR CAM */ 

WRITE FILE (002) FRO~ fCAM_RECORDt; 

WRITE FILE CDD2) FROM fCA~RECORDJ; 

CLOSE FILE CDD2); 

PUT EDIT f 1 RECORDS READ:•.COUNT) 

fCOLfl).A.P 1 ZZZZZ9 1 ); 

END J499; 

,, 

46 
TSO COMMAND PROCEDURE CRIB.CLIST 

te811 PROC t GIPFILEt CRIB.DATA.SET ) ~E"BEP.CMONA~E> 

18828 PRI"TT ' LINK CRIB FILE AHD INTERACTIVE e~· 

18025 ATTRII A RECF"<F.Il LRECLC7~> ILKSIZEC13e2•> 

eeeJe DELETE CS~> 

eeeJs ALLoc FI< svsDIR > DA c 'GIPsY. INoEx.oATA '> SHR eee~e ALLOC F I ( SVSD ICT) DA C' GIPSY. DICTIONARY ' ) SHR 

eeese ALLOC FICSVSREC> DAC''GIPFILE.'> SHR 

80068 ALLOC F 1 C SVSG~RK) DA (' GIPSY .• SAVE .AREA ' ) OLD 

80078 ALLOC FICSORTLIJ) DAC'SVS1.S"81SORT') SHR 

eeese ALLOC FICSORTWK01) SPACE<28> ILOCKC13838> "E~ 

88090 ALLOC FitSORTWK02> SPAC£<20) ILOCKC13e3e> NE~ 

80180 ALLOC FICSORTWK03> SPACEt20l ILOCKC1383e> NEW 

00110 ALLOC FICSORT"SG> DA(J) 

0012e AtLOC FICSVSURKO> DACS~> SPACECSI> TRACK USINGCAl "OD 

00130 AtLOC FI<DD1> DACS~> OlD 001~0 AltOC F!(DD2l DAC' LAT.LONG.DATA C'~EftiER. )') SHR 

00150 CAlL 'SVS1.GIPliB<TS027~1>' 

00160 CAll 'SVS1.LOADliB<J~S9l' 

08170 DELETE CS~l 

80180 FREE FitECSVSGYRK.SORTLIB.SORTYK81,SORTWK82.SORTWK03,SORT~SG,SVSYF KO> 

88190 FREE FitE<SVSDICT,SVSREC,SVSPCH.DD1.DD2,SVSDIR> 

88200 FREE ATTRLISTCA> 

47 
CAM TO DISK (H876) AND PLOTCAM (]725) 

INTRODUCTION 

CAM to Disk is CAM Version 4.0 modified to 

store the plotting instructions· on a disk file, rather 

than on tape. The CAM to Disk program H876 

is run in the batch mode to prepare the plot. The 

plotting instructions are saved in a disk-data set. 

When H876 is finished, these plotting instructions 

are used by the Plotcam program (J725), running 

under TSO (Time Sharing Option of IBM 

STANDARD BATCH CAM SYSTEM 

Digitized 

map outlines 

on disk 

Prepare the 

map 

Plotter 

Plot the 

map 

Paper 

CAM 

control 

cards 

1 to 3 hours 

1 to 48 hours 

System/370 Operating System), to draw the plot 

on a Tektronix graphic display terminal. 

The advantage of using CAM to Disk and Plotcam instead of the standard CAM is in the time 

saved from the point the CAM-control cards are 

prepared until the plot is made. A comparison of 

the turnaround times of the two versions of CAM is 

shown in figure 18. CAM takes longer to run than 

H876 because a tape must be used; jobs requiring 

tapes are delayed from running until the tape is 

15 min to 1 hour 

5 min to 1 hour 

INTERACTIVE CAM SYSTEM 

Prepare the 

map 

Plotcam (J725) 

Plot the 

map 

Graphic display 

CAM 

control 

cards 

FIGURE 18.-Comparison of turnaround times of the standard batch CAM and the Interactive CAM systems. 

48 
mounted. The delay may take hours. Once H876 

has been run, the plot may be reviewed in a few 

minutes, whereas the plot tape produced by CAM 

must wait for plotting on an off-line plotter. If the 

backlog of tapes to be plotted is large, the delay 

may be measured in days. 

OPERATING INSTRUCTIONS 

CAM-CONTROL CARDS AND DATA DEFINITION (DO) STATEMENTS 

In the example shown in figure 17, the data have 

been copied from the CRIB file, converted to CAM 

format, and stored in the member "copper" of the 

data set LAT.LONG.DATA. These data may be plotted by using the conventional CAM or CAM to Disk 

programs. The CAM control-card SYMPT provides 

the link. It has the form: 

SYMPT 2, nn 

where "nn" is a two-digit number used in the DD 

(data definition) name of the input DD statement 

that points to the mineral data to be plotted. The 

DD name has. the format of a Fortran DD name. If 

nn were 77, the DD name would.be FT77F001. 

To establish the link, choose an unused Fortran 

DD name. Take the two-digit part of the DD name 

and put it in a SYMPT statement. Add the SYMPT 

statement to the CAM control statements. Prepare 

aDD statement in which the DD name contains the 

same two-digit number. The data set named in this 

DD statement will contain the data copied from the 

CRIB file. An example of a CAM run using 77 as 

the two-digit number in the Fortran DD name is 

shown below (see Example of a CAM to Disk Run). 

The DD statement FT22F001 is used to define 

the output data set that will contain the plotting instructions for Plotcam. In the example below, the 

partitioned data set PLOT.DATA.SET has been 

allocated for the purpose of saving plots from the 

CAM to Disk program H876. The running time of 

H876 and the subsequent plotting time on the 

display can be reduced by changing field 3 (the plotting increment) of the PLOTTER card from the 

usual .01 to .11. The change will instruct H876 to 

issue fewer plotting instructions. Place the CAMcontrol cards after the FT07F001 DD statement in 

the H876 deck. 

In the example below, the DD statement 

FT14F001 has been set to the dummy condition. If 

the plotting instructions are to be saved on tape for 

plotting on a mechanical plotter, change this DD 

statement to provide the tape. 

49 

EXAMPLE OF A CAM TO DISK RUN 

//VG901743 JOB (OOOOOOOOO,H876,5,25), 

'ALANCROSBY',H876 CRIB LINK, 

II CLASS=D 

IIS1 EXEC PGM=H876,REGION =354K, 

TIME=5 

IISTEPLIB DD DSN = SYSl.LOADLIB, 

DISP=SHR 

IIFT06F001 DD SYSOUT=A 

IIFT08F001 DD DSN = VG5207A. 

WDBICOST.DATA,DISP = SHR 

IIFT11F001 DD DSN = VG5207A. 

WDBIBNDS.DATA.DISP = SHR 

IIFT14F001 DD DUMMY 

IIFT21F001 DD DSN = VG5207 A. 

DAHLUS.DATA,DISP = SHR 

IIFT22F001 DD DSN =PLOT.DATA.SET 

(name of plot),DISP = SHR 

IIFT77F001 DD DSN =LAT.LONG.DATA 

(COPPER),DISP = SHR 

IIFT07F001 DD * 

PLOTTER 14.,1.,.11,8.,1.,10.,10. 

CEAGEN 6378206.4,6356583.8,,29.,30.,,45.,30. 

CETPOT 40.,,-095. 

CONFAC 39.37 

MAPBOUND 15.,,60.,, -140.,,- 050. 

MAPSAL 7500000. 

XYLIM 20.,15. 

SAVE 

XYLIM 15.,10. 

SAVE 

OPENBOX 1., -13.,- 8., -10.,- 6.,1. 

1 COPPER IN THE U.S. 

-12.75 -6.5 

1 Dennis Cox 

-12.75 -7. 

1 ALBERS PROJECTION 

-12.75 -7.5 

SAVE 

BOX 40.,- 95.,,15.,10. 

LGRID 5.,5.,.1,.1,15.,60., -140.,,- 050. 

LINEPT 21.,6. 

SYMPT 2,77 

SPLATE 

II 

PLOTTING ON THE TEKTRONIX DISPLAY TERMINAL 

After H876 is run, the plot will be available for 

review on the Tektronix display terminal under the 

control of the Plotcam program (J725). Sign on to 

TSO in the usual manner. When the sign-on processing with TSO has been completed and the 
message "READY" appears, enter the following 

command: 

EXEC CAM 'PLOT(name of plot)'. 

The name of the plot will be the name of the 

member chosen to contain the plot when the H876 

run was made. 

During a short delay, TSO will allocate files for 

the use of Plotcam. When Plotcam has been given 

control, it will issue messages to solicit guidance in 

the preparation of the plot. The reply to most 

messages is "Y" for yes or "N" for no. These 

messages are explained in the section, "Plotcam 

User-Prompt Messages." 

IMAGE RELATIONSHIPS 

Each of the plotting instructions issued by the 

CAM to Disk program H876 of the Interactive 

CAM system has a dimension in the X direction 

and a dimension in the Y direction. These dimensions are the distances in inches to the lower left 

corner of the plotter. The values of Xmin, Xspan, 

Y min, and Y span are also in inches. When the Plotcam program is processing the plotting instructions issued by H876, it will discard all X values 

that are less than Xmin and all Y values less than 

Y min. It will discard all X values greater than the 

sum of Xmin and Xspan and will discard all Y 

values greater than the sum of Y min and Y span. 

The remaining values will be scaled to fit the 

display screen, which is 11 in.by 15 in. 

The top of figure 19 shows an image on a 

hypothetical off-line plotter. The distance between 

the lines of the grid is 10 in. For this example, 

Xmin and Ymin have been set at 10 in. The span of 

X is 50 in., and the span of Y is 40 in. The bottom of 

figure 19. shows the same image as it would be 

displayed by Plotcam on the Tektronix display terminal. Notice that vertical lines, A, H, I, J, and K 

do not appear on the display, and neither do 

horizontal lines A and G. They have been discarded 

because they are outside the values that have been 

specified to Plotcam. On the upper image, the area 

of interest has been divided into five segments in 

the X direction and four in the Y direction. The 

screen of the display has also been divided into five 

equal segments in the X direction and four equal 

segments in the Y direction. This example illustrates what will happen to every image: the part 

of the image within the span of X and Y will be 

scaled to fit the display screen. 

50 

PLOTCAM USER-PROMPT MESSAGES 

During the interactive map-plotting session, the 

user is led through a sequence of processing steps 

in which the Plotcam program issues prompts to 

the user, and the user answers by choosing one of 

the available options. These user-prompt messages 

are explained below. The order of appearance. of 

these messages is shown in figure 20. By studyJ.ng 

figure 20, one can see in advance where a particular sequence of messages and replies is leading. 

DO YOU WANT TOUSE CURSOR TO SELECT 

AREA TO BE PLOTTED? REPLY Y OR N 

This is the first message issued by the Plotcam 

program. It is issued immediately after the program is entered and at the end of each plot. Its appearance at the end of each plot allows the user to 

make a new plot, if desired, of a smaller area 

within the area of the first plot. 

y-The screen will be erased, and the crosshair cur- · 

sors will appear. Position the cursors to define 

the lower left point of the area to be plotted. 

Enter the letter "C" and press the return key. 

The crosshair cursors will disappear for a moment and then reappear. Position them to define 

the upper right point of the area to be plotted. 

Enter the letter "C" and press the return key. 

The screen will be erased and the next message 

will appear. 

N-The program will go on to the next message. 

USE DEFAULT WINDOW SIZE? REPLY Y 

OR N 

This message appears if the cursor is not being 

used to control the plot. In answer to this and succeeding messages, the values to be plotted in the X 

and Y directions can be specified. The unit of 

measurement used by CAM and Plotcam is inches. 

Plotcam will ignore all values outside the range 

specified below, and it will scale the values inside 

the range to fit the display screen. 

Y-Plotcam will use the default values of X and Y. 

The minimum value of X will be 0; the maximum, 

47.60 in. The minimufll value of Y will be 0; the 

maximum, 35 in. The screen will be erased, these 

values will be displayed at the top of the screen, 

and the map will be plotted. 

N-The values of X andY that are to be plotted will 

be solicited by a series of messages. 
G 

T 

F 

E 

Span 

D ofY 

c i 

10 in. 

8 ! -'--

~10 in.~ YB c D E F G H I J K 

E Span of X ;. 

A 

X min Y mm 

Plotter 

I/ 

I 

'\ F 

E 

I 

D 1---

c 

8 "-. / 

8 c D E F G 

Tektronix display 

FIGURE 19.-lmage relationships between off-line plotter and Tektronix graphic display terminal. 

SET X SO THAT THE RATIO OF YIX= 11/15? 

REPLYYORN 

Plotcam will take the points defined by the cursor and scale the plot to fit the screen. If the plot 

that results does not have the same ratio of height 

to width as does the Tektronix display screen, the 

plot will be distorted. 

51 

Y-Before the map is plotted, the span of X will be 

adjusted, if necessary, so that the ratio of the 

span of Y to the span of X will be 11/15. 

The display screen will be erased and the map 

will be plotted. 

N-No adjustment will be made to the span of X. 

The display screen will be erased and the map 

will be plotted. 
Enter minimum value 

of X 

Enter span of X 

Enter minimum value 

of Y 

Enter span of Y 

Do you want to use 

cursor to select area to 

be plotted? reply Y or 

N 

y 

Use default window 

size? reply Y or N 

N 

X min=O 

X span=47.6 

Y min=O 

Y span=35 

The values of X min, X 

span, Y min, and Y 

span will be displayed 

The map will be plotted 

Do you want to plot 

the file again? reply Y 

or N 

Crosshair cursors will 

appear 

Position crosshair 

cursor at lower left of 

area to be plotted. 

Enter "C" and return 

Crosshair cursors will 

disappear for a moment and then reappear 

Position cursors at 

upper right of area to 

be plotted. Enter "C" 

and return 

Screen will be erased 

Set X so that the ratio 

ofY/X=11/15? reply Y 

or N 

y 

N 

FIGURE 20.- Flow diagram showing order of appearance of Plotcam user-prompt messages. 

52 
ENTER MINIMUM VALUE OF X 

This is a request to define the minimum value of 

X that is to be plotted. All values less than this will 

be ignored. Enter the number in the format 

nnn.nn. Always supply the decimal point. 

ENTER SPAN OF X 

This is a request to define the span of the plot in 

the X direction. It is the difference of the minimum 

value of X and the maximum value of X. Values 

that exceed the sum of the minimum value of X and 

the span of X will be ignored. Enter the number in 

the format nnn.nn. Always supply the decimal 

point. 

ENTER MINIMUM VALUE OF Y 

This is a request to define the minimum value of 

Y that is to be plotted. All values less than this will 

be ignored. Enter the number in the format 

nnn.nn. Always supply the decimal point. 

ENTER SPAN OF Y 

This is a request to define the span of the plot in 

theY direction. It is the difference of the minimum 

value of Y and the maximum value of Y. Values 

that exceed the sum of the minimum value of Y and 

the maximum value of Y will be ignored. Enter the 

number in the format nnn.nn. Always supply the 

decimal point. 

This is the end of the sequence beginning with 

"Enter minimum value of X." The display screen 

will be erased and the map will be plotted. 

53 

DO YOU WANT TO PLOT THE FILE AGAIN? 

REPLYYORN 

This message will appear after the map has been 

plotted. It is the only message that can be used to 

terminate the session. 

Y-The map will remain on the screen, control will 

pass to the beginning of the program, and you 

will be given the opportunity to control the plotting process by replying to the same sequence of 

messages as before. 

N -This is the signal to end the session. The map 

will remain on the screen. There will be a slight 

delay as control is passed to TSO. When this 

transfer of control has been completed, the 

message, READY, will appear on the screen. 

The exit reply is "E." 

The reply to each message issued by Plotcam 

determines what Plotcam will do next. The reply 

"E" is used to instruct Plotcam to start over or to 

quit. When Plotcam receives an "E" in reply to a 

request for guidance, it will display the message, 

"DO YOU WANT TO PLOT THE FILE AGAIN? 

REPLY Y OR N." Reply "N" to end the session or 

"Y" to continue it. 

PROGRAM DOCUMENTATION MATERIALS 

The progam documentation materials presented 

below provide technical information on CAM to 

Disk (program H876) and its companion program 

Plotcam (J725). 

The link-edit flow chart for program H876 is 

shown in figure 21. The logic flow diagrams (fig. 

22) show the output flow for CAM to Disk (program H876) in comparison to that for the standard 

CAM program. The logic flow is similar for both 

programs except that CAM to Disk provides for 

the program results to be directed to disk storage 

as well as to tape. Either output device, or both, 

may be utilized. 
Plot 

Sysl. Flatbedd 

CAM (H592) 

Sysl. Loadlib 

S1 Fortran 

Compile 

plot 1 

S2 Fortran 

Compile 

symbol 

trnslt 

S3 F.ortran 

Compile 

plot 

S4 Fortran 

Compile 

Teksym 

S5 Link-edit 

Rename Plot 

to Calplt 

Include &&A 

Include &&B 

Include H592 

FIGURE 21.- Link-edit flow chart for CAM to Disk program H876. 

54 

Plot 1, symbol 

trnslt, plot 

Teksym 

Calplt 

&&A 

H876 

Sysl. Load I ib 
Program results 

(plotting instructions) 

Program results 

(plotting instructions) 

CAM to Disk (H876) 

Plot 1 

Collection point for 

plotting instructions 

generated by program 

Standard CAM 

Plot 1 

Collection point for 

plotting instructions 

generated by program 

Plot 

Saves plotting instructions; 

moves instructions to disk 

and/or to calplt CALPLT 

CALPLT 

Moves plotting instructions 

to tape 

Plot 

Saves plotting instructions; 

moves instructions to tape 

FIGURE 22.-Logic flow chart for CAM to Disk program H876. 

55 

Plotting 

instructions 

stored on disk 
PROGRAM LISTING OF PROGRAM H876 AND JCL FOR LINK EDITING 

IIV~Q0173C JOB (934000231.HB76.9.25), 1 ALANCROS6V 1 • liNk H87b 

II CLASSt:-8 

IISl EXEC FORTGC 

IIFORT.SYSLIN 00 OSN=&&~. 

II UNJT=SYSOk, 

II OISP=(NEW.PASSJ. 

II OC~=CRECFM=FB.LRECL=80.BLKSJZE=400J. 

II SPACE=(TRK.IJO.JO)) 

('. 

t 

c 

c 

SUBROUTINE PLOTl(X,V.N) 

tAll PLOT(X.Y.N) 

RETURN 

END 

PLOTl 

WRITTEN BY ALAN CROSBY 

REPLACES THE MOPULE IN CAM Of THE SA~f 

NAME. 

IIS2 EXEC FORTGC 

/IFORT.SYSLIN DO OSN=t£6 DI~P=(MOD,PA5S) 

C SYMBOL 

C WRITTEN BY ALAN CROSBY 

C REPLACES THE MODULE IN CAM OF THE SAME NAME. 

c 

c 

c 

c 

c 

c 

( 

c 

c 

SUBROUTINE SYMBOLCXPAGE,YPAGE,HEIGHT,JBCO,ANGLE.NCHARJ 

OJMENSJON 18(0(2) 

JF (NtHAR.EO.-lJ CALL TRNSLTCIBCDfl)J 

TEKSVM .IS THE llLO CALCOMP SYMBOL ROUTINE THAT ORAWS CHARACTERS 

INSTEAD OF ISSUING A CODE FOR THE PLOTTER TO TRANSLATE. 

CAll TEKSVM(XPAGE.YPAGE,HEIGHT,JBCO,ANGLE.~CHAR) 

RETURN 

END 

SUBROUTINE TRNSLT(J) 

WRITTEN BY ALAN CROSBY 

THIS PROGRAM WILL TRANSLATE OLD CALCOMP SYMBOL CODES TO THE 

NEW, ASCII, SYMBOL COOES. 

J CONTAINS THE OLO CODESI 0 TO 127 

DIMENSION J(2),JCODESC128) 

DATA ICODESIO.l.2•3•4•5•6•7•8•9•10,11,12.13.J4.15el6,J7,18.19e20. * 21,22.23,24,25.26.27,28,29.30.31.25.90.127.123.91.108. 

* * * * * * 

~0.12~.77,93,92.78.107,96,7~,97,t12.113.114,)J5,)Jb, 

ll7.11~.119.120.121.122.9~.76.12b.ll0.111.124,65.~6. 

b7,68,69,70,71,72,73.81,82,83,84,85.86t87988.89,q8.99. 

100tl01tl02.l03.104.105t53t55.~4.18.24.32·33.34,3~.36. 

37,38,?5,40,4l,4?,43,25.15.?5,?5,4e,4q.so.5J,52,53,54. 

55,56.57,25.25,60.61.63,62/ 

THE VARIABLE 1 Will NOW POINT TO THE PROPER ASCII COOE IN THE 

TASLE. 

I= JCll + 1 

PICK UP THE ASCII CODE. 

JCll = ICOOES(IJ 

RETURN 

ENO 

liS?. EXEC FORTGC 

1/FORT.SYSLIN DO 

c OSN=&&B.DJSP=f~OO,PASSJ 

PLOT 

c 

c 

c 

c 

c 

c 

c 

c 

WRITTEN BY ALAN CRO~BY 

R~PLACES CALCO~P SU9ROUTJNE CALLfO PlllT. 

SAVES PLOTTING INSTRUCTIONS JSSllfO ~y 

CALCOMP. CALLS CALCOMP SUBROUTINE PLOT 

WHICH HAS SEEN RENAMED CALPLT. 

56 
PROGRAM LISTING OF PROGRAM H876 AND JCL FOR LINK EDITING-Continued 

SUBROUTINE PLOTtX.Y,NI 

WRITEt22t11 X.Y,N 

1 FORMATf2F10.6,J5) 

CALL CALPLT (X,V,NI 

RETURN 

ENO 

//S4 EXEC FORTGC 

//FORT.SVSLJN DO DSNct&B,DJSP=C~OO,PASS) 

C SYMBOL 94218 9.4.9 07/70 SCD VERSION 

C SUBROUTINE SYMBOL COPYRIGHT 1970 CALIF. COMPUTER PRODUCTS 

C MODIFIED FOR JBM-360 FORTRAN JV 

C ~YMBOL V7006 06/10/70 PRODUCT NUMBER 94218 

SUBROUTINE TEKSY~(XPAGE.YPAGE,HEIGHT,JBCD,ANGLE,NCHARI 

DIMENSION JCHARCJO),XAC32I,YAC32) ,JBCOC2) 

DIMENSION NXYC21. XBf321tYBC32) 

DIMENSION ITAB( 750J.JTABf128) 

DIMENSION ITAB 11150) 

DIMENSION ITAB 211501 

OIMENSION JTAB 3(150) 

DIMENSION JTAB 4(1501 

DIMENSION ITAS 5(150) 

c 

EQUIVALENCE CITABC 1t,ITAB 1C1J) 

EQUIV.AL ENCE CITAB( 151) ,ITA& 2C1JJ 

EQUIVALENCE ( JTAB ( 301),JTAB 3(1)) 

EQUIVALENCE ClTABC 451),JTAB 4(1)) 

EQUIVALENCE CIT ABC 601),JTAB 5(1)) 

c 

DATA XAC1J,YAC1J.XBC1l,Y8(1) /o.o,o.o,o.o.o.o/ 

DATA OLOTH/QQ9./ 

DATA ASPCT,TALIC.RSPAC,SPCT/.e,o.o,1.0 •• 81 

c 

c 

c 

c 

DATA JTA8/ 

9 18433, 26633. 14357, 16411. 16418. 16425. 16432. 

Cl 14391, 20541. 16454, 38989, 28767, 14444. 10354, 

9 24694, 4226. 4228. 671'18, 6311, 16554. 10418, 

9 53431, 16593, 16601. 4321, 35043, 4340. 28918. 

9 20740, 6414. 166~7. 35089, 26914, 269?7. '14.@9?, 

9 24904, 41300, 41303, 31083, 14714, 47489, 22936, 

9 33187, 43443, 31176, 25047. 72163, 86499, 10765, 

9 29202. 12832. 12836, 8746, 8750. 8752. 4660, 

9 23094, 14q13. 16968• 23120. 10843, 10848, 10853. 

9 10856. .2056, 10861. 37490, 37508, '177@6, 15011. 

q 12964, 41642. 129qo, 4804. 31060, 10950, 6688. 

9 1703~. 10955. 4804, 47824, 19175. 150tt8. 6903t 

9 11002, 8957, 49921, 21273, 49955, 25403. 25415, 

9 50003. 23403t. 17158. 27510, 7043, 4274, 4998. 

9 45Q60, q118t: 21410. 6907, 11180. 11185, 11190, 

9 9147, 439b7. 152?.8. 29652. 4995, 6695, 37@58, 

q 4371'0, 7156. 31735, 44038, 9243, 39967, 46130. 

9 17480, 60496, 46189, 23414, 23683. 66702. 13486. 

9 11444, 27833/ 

c 

t 

c 

c 

DATA ITAB 1/ 

Q 210131, 19463. ~00787. 217056, 210131. 117776, 1 0343. 3024 74. 

57 

2tu.20000 

28420001 

28420002 

28420003 

28420004 

2842000~ 

28~20006 

28420007 

28420008 

2e420009 

28420010 

2~420011 

28420012 

2,8420013 

~8420014 

it8420015 

784'10016 

28420017 

28420018 

28420019 

?84?00'10 

28420021 

28420022 

28420023 

28420024 

28420025 

28420026 

28420027 

28420028 

28420029 

28420030 

28420031 

284?003? 

28420033 

28420034 

28420035 

28420036 

28420037 

28420038 

28420039 

28420040 

28420041 

28420042 

28420043 

28420044 

28420045 

28420046 

28420047 

2l'420048 

2842004CJ 

284200~0 

28420051 

28420052 
PROGRAM LISTING OF PROGRAM H876 AND JCL FOR LINK EDITING-Continued 

9 409907, 117056, 110131, 10634, 117056, 210131,1015821. 407520. 28420053 

9 203981. 413664, 19847,1015815. 210131. 13511. 406739,!016013. 18410054 

9 216077. 40673991016007, 209939, 412679,1016199, 210029,)015827, 28420055 

9 412679, 401376, 308429, 20448' 412877. 204768, 210323.1016112. 28420056 

9 114707.1015920, 108551.1015914, 305543,1016106. 312288. 210323. 28420057 

91016019, 204768, 400403. 1 015821 • 407520. 7373, 19859, 209927. 284200~@ 

9 40058Q. 117056, 103981. 116074, 403667,1016007, 409616, 204768, 284200!>9 

9 20999), 564551. 351239, 22710, 251156. 279792, 179215. 179438. 18410060 

9 275721. 237735, 8160, 337256, 433b39, 565833, o02669, 37~194, 284200bJ 

9 348533. 449014, 579156, 138580, 531596, 537568, 540816,1015956, 28420062 

9 544851. 609749, 476755. 280852. 251062. 120885. 19466, 41063. 28420063 

9 171240, 271627.1016135, 350710. 579156. 607792. 507215. 507463, 28420064 

9 152084,1016334. 146400. 107320, 151084.1016153, 344032, 143884, 28420065 

9 38533, 7190, 269590.1016150, 338280, 433639, 565834, 613344, 28420066 

9 678535. 9247359 687209, 106631, 204008. 272685, 38b460. 4571~3. 28420067 

9 556606, 586901, 415188, 511505, 540141, 471435, 142484, 335380, 28420068 

9 147633, 248113, 376238, 507408,1016340, 511410, 380213. 252085, 28420069 

9 151711. 228606, 291094, 315731. 313616. 272616/ 28420070 

DATA ITAB 2/ 28420071 

9 203911. 556~11. 457116. 416116, 347506, 409994, 43463). 531562. 28420072 

CJ 257202, 178412. 307597. 474683, 474605, 569452, 257210, 90298. 28420073 

9 257498, 51871S, 518618. 405853, 33781.'8, 485755, 322778, 155765. 28420074 

9 115854, 209195, 372172. 539185, 579096, 486368, 118323, 123098, 28420075 

q 15511q, 144556, 241965, 376243, 516667.,1016223. 138349, 583648, 28420076 

9 124!"21. 472621. 254169. 189560. 88115. 49130. 144589, 276853. 184?0077 

9 311630, 374221. 539183, 643702, 614969, 517243. 191738. 287027, 28420078 

9 109875, 345486, 472620. 540111. 409878, 220311. 88116, 51280., 28420079 

9 146639, 278934, 482839, 585150., 391517. 388568., 514548, 475533, 28420080 

9 340172. 144495, 115860. 220440, 353721. 452147, 118752. 585147., 28420081 

Q 311753, 154740, 116879., 210220, 437803, 1240~1. 224506. 254059, 28420082 

9 254363. 519737. 579975, 9256. 1056~. 237833. 174669, 5014114, 18410083 

9 20533. 121014, 251156.1016150, 338280, 433639, 565834, 613344. 28420084 

9 663190, 842613, 938897, 901935, 671535. 899981, 927592. 827015. 2842008!> 

9 588927., 348263, 564531. 316789, 380211.1015952., 541664, 374061. 28420086 

CJ 306539, 374297. 152079.1016332, 144352, 146964., 1~6779, 352811. 28420087 

9 11013C», 194151, "6631 99, 193983, 597500. 486715., 256217, 256315. 28420088 

9 388334, 242955., 359751. 241834,1016159, !a23531. 40547?. ?90?03., 184?0089 

~1016159, 335123. 413664, 273803.1016091, 421856/ 28420090 

DATA JTAB 3/ 28420091 

9 359751. 85205, 214099, 609355. 618464, 601179, 359707, 421215, 28420092 

9 335115. 404807. 40287., 630287, 146516. 446963, 575055. 603690, 28420093 

9 500135. 717Q9, 415470, 585273., 548309, 414298, 586238, 425279., 28420094 

9 227484, 125014, 82028. 141512. 302471. 500266, 603207, 302472, 28410095 

9 46951?, ~?5029. 550364, 424255, 97351, 597063, 86516, 86111. 2842009b 

9 589402, 586238, 425279, 227484, 125014. 8202tt. 141512. 302471., 28420097 

9 500266, 603729, 378439., 622164, 86111. 73031. 359751. 236778. 2842009(t 

Q 338247, 605263.1016135. 351772. 489855. 261277, 126072. 532039, 28420099 

91016020. 115791, 77930. 172195, 400840. 535084, 570959., I 11754, 28420100 

CJ 205095, 368072. 535085, 588895, 72786., 622560, 597238. 97351. 28420101 

9 564263, 64839, 654951. 97351, 621977.1016103, 3680?2., 535084, 28420102 

q 606806. 584220, 41'9855., 326878, 159866, 81'144, 110730, 205095, 28420103 

CJ 72799., 425470. 585273, 548309, 413780. 302439, 467466, 569936, 28420104 

9 612922, 553438, 392511. 227484, 125014, 82028. 141512. 303072. 28420105 

9 407111., 72799, 425470, 585173, 5483Qq, 413780, 414179., 310611. 18410106 

9 359711., 292143,1016137, 335111, 271689. 400799,1016095, 270304, 28420107 

9 111755, 207306, 537133, 572945, 510132. 152695, 124058, 22S756., 28420108 

9 551480, 605263,1016135. 352224, 153097,1015945, 546033, 345421'. 28420109 

9 250097,1016135, "' 236778. 338247 .. 299233, 52883/ 28420110 

DATA ITAB 4/ 28420111 

9 672351, 72780. 108712. 269703. 500266. 602703. 574931. 18651ct. 18410112 

9 124027. 160958, 294303. 522781. 585031. 359519. 621695, 111754., 28420113 

58 
PROGRAM LISTING OF PROGRAM H876 AND JCL FOR LINK EDITING-Continued 

9 205095, 368072, 535085. 588831. 

q 7276?, 348487. 348799, 97887. 

0 88116, 51?80, 146639, 278934, 

9 97471, 192604.1016415, 73696, 

9 271689,1016109. 310609, 547384, 

9 359677, 127166, 294303, 521786, 

9 564438, 318807, 449013. 577104, 

q 78816. 351706. 556191, 499199, 

q 44Q013. 577104, 604715, 533960, 

9 513587, 607820. 567784, 433415. 

9 425470, 585823, 622011, 385333, 

9 500266, 602703, 574931, 186519, 

9 585273. 548342, 216177. 80972. 

9 615996. 522655, ?Q407&. 127066, 

91016235, 521184, 614488,1016060, 

9 277745, 249110. 3~2665, 484887, 

9 119921. 145580, 239945. 402922. 

OATA ITAB 5/ 

171359, 

73287, 

482839, 

499178, 

585245. 

582166, 

6047)5, 

81487, 

36~11, 

172138. 

2469('9, 

124027, 

108712. 

87155, 

175663, 

582202. 

535831, 

499359. 

540111. 

612980, 

600647. 

522655, 

479570. 

533960. 

588959, 

204906, 

78934. 

171084. 

160958. 

269671. 

181584, 

542231. 

520605, 

324927/ 

597087,1016415, 

409878, 220311. 

641616. 539740. 

4qCJOJ7, 335111, 

326846, 128327. 

211083, 107623. 

367911. 204906, 

1~2790, 318807. 

77qo6, 1856tt6, 

125084, 7?7647. 

108712. 269703. 

294303', S2l78J, 

467466. 569936, 

509574, 81487, 

542191. 407886. 

357628. 190616, 

9 161373, 285779. 610272, 605263, 286013. 326911. 259351.1016247, 

9 488927. 425373. 450528.t016eoo.tot6eoo.to16eoo,tot6eoo,tot6eoo, 

91016800,1016800,1016800,1016800tl016800,J016800,1016800,JOJ6800, 

91016800,1016800,Jqt6800,1016800,1016800,1016800,1016800,1016800, 

91016800,1016800,1016800,1016800,1016800,1016800,1016~00,1016800, 

91016800tl016800tl016800tl016800tl016800,1016800tl016800,1016800. 

01016800,l016800,1016800.1016800tl016800,1016800t1016800.1016800. 

91016800tl016800.1016800tl016800.l016800.1016800t1016800,1016800. 

91016800tl016800.l016800tl0l6$00,J016800,1016800.1016800,J016800. 

91016800t1016800,1016800,1016S00,1016800.1016800tl016800,t016600. 

91016800~1016800,1016800,1016800,1016800~1016800,1016800,1016800. 

91016800•1016800,1016800,1016800.1016800,1016800.1016800,1016800. 

91016800•1016800.1016800,1016800tl016800.1016800,1016800,J016POO, 

9l016~00.t016800,1016800,1016800,1016800,J016800,JOJ6800.J016800t 

91016800t1016800.J016800,1016800.1016800.1016800.l016800.l016800t 

91016800,1016800,1016800,1016800,1016800.1016800,1016800,1016800, 

91016800t1016800.l016800,1016800t1016800.1016800,1016800,1016800, 

91016800,1016eoo.1oi6eoo,tot6eoo,1016eOO,J016B00.10t6soo.1016soo. 

91016800tl016800.10~6800t1016800,1016800,1016800/ 

ISH3 = 2**24 

JSH2 = 2**16 

ISH1 • 2**8 

IFCHEIGHT) 500t5t5 

5 IPEN • 3 

NT a NCHAR 

IF CNT) 10t10t30 

10 J • 4 

IF INT + 11 11 9 12,40 

11 IPEN • 2 

12 JCHAR(J) • I8COI1) 

15 

30 

40 

50 

60 

KTAB = 1 

IF CJCHARIJJ-14) 15,15,50 

DIY • 12. 

ASPCT • 1.0 

GO TO 60 

J • 1 

KTAB • 1 

DIY = 24.0001 

TH • ANGLE 

HT • HEIGHT 

FCT = HT/OIV 

OIV • RSPAC*COIV+6.0J 

IF CTH-DLOTH) 80,70,80 

59 

28420114 

28420115 

28420116 

784?0117 

28420118 

28420119 

28420i20 

28420121 

2S420122 

78470173 

28420124 

28420125 

28420126 

28420127 

28420128 

28420129 

28420130 

28420131 

28420132 

78410133 

28420134 

28420135 

28420136 

28420137 

28420138 

?8470130 

28420140 

28420141 

28420142 

28420143 

28420144 

28420145 

28420146 

28420147 

28420148 

28420149 

78-70150 

28420151 

28420152 

28420153 

28420154 

28420155 

78420156 

28420157 

28420158 

28420159 

28420160 

28420161 

28420162 

28420163 

284201~4 

28420165 

28420166 

28420167 

28420168 

28420169 

28420170 

28420171 

28420172 

28420173 

28420174 
PROGRAM LISTING OF PROGRAM H876 AND JCL FOR LINK EDITING-Continued 

70 JF I FCT-DLJFC J 90.100.90 28420175 

eo OLOTH c TH 2~420176 

TH • TH*0.0174533 28420177 

SJNC • SINITHJ 28420178 

CINC = COSCTH) ?94?017Q 

90 Ol£'FC c FCT 28420180 

XA2 = FCT*CINC ~8420181 

VA2 c FCT*SINC 28420182 

XB2 = XA2 * ASPCT 29420183 

V82 • VA? * ASPCT 29420184 

00 95 1•2.32 28420195 

I 1 • I-1 28420186 

XBCIJ = XB2 + XBCI1) 294201(17 

VBCII c V82 + V8CJ1) 2842018(1 

XACIJ • XA2+XACI1J 28420189 

95 VACIJ = VA2+VA(Jl) 28420190 

100 XT• XPAGE 28420191 

VT• VPAGE 28420192 

IFCXT-998.91 101.101.102 28420193 

101 XO=XT+VAC8J-TALIC*XBitl) 28420194 

X• XT 28420195 

102 IFCVT-998.9) 103.103.104 28420196 

103 VO =VT-XAC8J-TALIC*VBftl) 28420197 

Y=YT 2842019(' 

104 INO • 1 28420199 

NCHR c: 0 28420200 

IF INTI 110,140,140 28420201 

110 IF CJCHARCJJ-141 120.120.150 2(1420202 

120 XO • XO-CXBC7J-YA( 7)) 28420203 

YO= YO-IXAC 7J+YBI7)1 28420204 

ASPCT • SPCT 28420205 

fC' TO 150 28420206 

130 IPEN = 3 28420207 

J = J+1 2842020(' 

IF fJ-5) 150.135.135 2842020CJ 

135 J • 1 28420210 

INO = JNO+l 28420211 

140 JCHAR(1) • JBCDCINDJ/ISH3 28420212 

IF CJCHARI1)) 144.148.148 28420213 

144 JCHAR(1) = JCHAR(l) +ISHI-I 28420214 

148 l • IBCDCINOJ - JCHARCIJ*ISH3 2842021~ 

IF fL-ISH3J 149,1480.149 28420216 

1480 L•O 28420217 

JCHARCJJ•JCHARf1J+l 28420218 

149 CONTINUE 28420219 

JCHARC2J c L /JSH2 28420220 

JCHARI3J • l /256-JCHARC2)*ISH1 28420221 

JCHAR(4) • l - JCHARI3)*256-JCHARf2)*ISH2 28420222 

150 JCH • JCHARCJJ 28420223 

IF CJCH-128) 153.152.152 28420224 

152 JCH = JCH- 128 2(1420225 

153 ICHAR • JCH + K TAB 28420226 

IF CJCH - 17) 154,202.154 28420227 

154 IF (JCH- 21J 155.205.155 28420228 

155 IF CJCH - 25J 156.220.156 28420229 

156 IF CJCH - 46) 1~7.220,157 28420230 

157 IF (JCH - 47) 158.220.158 2(1420231 

158 ICHAR • JTA8 CICHARJ 28420232 

INUM • ICHAR/2048 28420233 

L a ICHAR-CINUM*2048)+1 28420234 

IlOC • l/2 28420235 

60 
PROGRAM LISTING OF PROGRAM H876 ANDJCL FOR LINK EDITING-Continued 

L = L-?*ILOC 

K c 0 

160 NXYC2J • JTAS CILOCJ/1024 

NXYClJ • ITAB CILOC) - NXYC2J *1024 

tLOC • flOC + 1 

L = 2-L 

165 NX c NXYCL)/31 +1 

NY c NXYCL) - NX*32 +33 

L = L-1 

IF CNX-32) 170,180,180 

170 XT• XO+ XBINXI-YAINYJ + TALIC*XBCNY) 

YT• YO+ YBCNX)+XACNYJ + TALIC*YBCNY) 

CALL PLOTCXT,YT,IPEN) 

IPEN • 2 

GO TO 190 

180 IPEN • 3 

1QO K = K+1 

If CK-INU~J 200,210,210 

200 IF Cll l65tl60,165 

210 XO • XO + XB2*DIV 

YO • YO + Y82*DIV 

220 NCHR • NCHR+1 

IF CNCHR-NTI 130.300.300 

202 XO • XO • X82*DIV 

YO • YO - YB2*0IV 

GO TO 220 

205 X • X + YA2*24.*12./7. 

Y • Y - XA2*?4.*12./7. 

XO • X 

YO • Y 

GO TO 220 

300 RETURN 

500 IF CABSCXPAGEI - 998.9) 510,515,515 

C ••••• ASPCT = WIDTH/HEIGHT 

510 ASPCT •0.8*XPAGE 

SPCT • ASPCT 

OLOFC • 999.0 

515 IF CABSCYPAGEI- 998.9) 52Q,525,525 

C ••••• TALIC • CHANGE OF SLANT OF LETTERS 

520 TALIC c YPAGE 

525 IF CABSCANGLEJ- 998.9) 530,550.550 

C ••••• RSPAC • CHARACTER SPACING, SPACE ~30 RSPAC • ANGLE 

550 RETURN 

END 

//S5 EXEC PGM•IEWLF128tPARM••XREF,LETtLIST,SIZE=C300K,JOOKJ,NClL 1 t 

/1 TIME•6,REGJON•310K 

//SYSPRINT DO SYSOUT•A 

IISYSUTl DO UNIT•SYS~K.SPACE•f1024,C200,30)J 

//SYSLIN DO ODNAME•SYSIN 

//001 DO DSN•SYS1.FLATBEDDCPLOT),DJSP•SHR 

IISYSLMOD 00 DSN•££A, 

II UNIT•SYSOK, 

II DISP•CNEWtPASSJ, 

/1 OCB•CBLKSIZE•l3030J, 

II SPACE•fTRK,C8,8,2JJ 

//SYSIN DO * 

CHANGE PLOTCCALPLT) 

INCLUDE DDICPLOT) 

NAME CALPLTCRJ 

II EXEC PGM•IEWLF128,PARM• 1XREF,LET,LIST,OVLY,SIZE•C300Ktl00K) 1 , 

61 

28420236 

?8420237 

28420238 

28420239 

28420240 

28420241 

28420242 

28420243 

28420244 

28420245 

28420246 

28420247 

28420248 

28420249 

26420250 

28420251 

284202~2 

284?0?53 

28420254 

28420255 

28420256 

28420257 

28410?58 

28420259 

28420260 

28420261 

28420262 

28420263 

?84?0?64 

28420265 

28420266 

2e420267 

28420268 

28420269 

?84?0270 

28420271 

28420272 

28420273 

28420274 

28420275 

28420276 

28420277 

28420278 

28420279 

28420280 
PROGRAM LISTING OF PROGRAM H876 ANDJCL FOR LINK EDITING-Continued 

II TIME•6• 

II REGJDN•310K 

//SVSLIB DO DSN•SVSl.FLATBEDO,OJSP•SHR 

II DO DSN•SVSJ.FORTLIB.DJSP•SHR 

II DO DSN~XTENT.LJB,OJSP•SHR 

IISVSPRJNT DO SYSDUT•A 

1/SVSUTl DO UNIT•SYSDK.SPACE•I1024,C200,30)) 

//SYSLIN DO OSN•&&B,OISP•CDLD.DELETEJ 

II DO ODNAME•SVSIN 

//DOl DO OSN•SVSI.LDADLIB,OISP•SHR 

//002 DO DSN•&&A.DJSP•COLD.OELETEJ 

/ISYSLMOD DO OSN•SYSl.LOAOLJB.OJSP.SHR 

1/SYSIN DO * 

INCLUDE 007CCALPLTJ 

INCLUDE DD1CH592) 

ENTRY MAIN 

NAME H876C.R) 

II 

62 
PROGRAM LISTING FOR PROGRAM J725 

/IVG9017B JOB C93400023t.H8761t 1 ALANCROSBY 1 t C&L J725 

/1 CLASS•D 

/*ROUTE PUNCH LOCAL REI 

liSt EXEC FORTGC 

IIFORT.SYSLJN DO DSN=&&A, 

II UNJTcSYSDK. 

II DlSPcCNEW.PASSJ, 

/1 DCB•CRECFM•FBS,LRECL=80,BLKSIZE•400)• 

II SPACE•ITRK.Cl0tl0,2JJ 

c 

c 

c 

c 

c 

c 

c 

c 

c 

c 

c 

c 

c 

PLOTCAM4 

BY 

ALAN CROSBY 

USGS 

ceo 

PLOTCAM REA~S PLOTTING INSTUCTIONS THAT HAVE BEEN PREPARED BY CAM 

ANO STORED ON A DISK DATA SET. THE INSTRUCTIONS ARE IN THE FORM: 

x. Yt PEN CODE. PLOTCAM USES THE PLOTTING INSTRUCTIONS TO DRAW A 

PLOT ON A TEKTRONIX GRAPHICS DISPLAY DEVICE. 

REAL NO 

DATA YES/ 1 Y1 1,N0/ 1N1 /tENDI 1 E1 / 

C INITIALIZE SOFTWARE AND ERASE SCREEN 

CALL JNJTTC120) ~ 

C SOLICIT OPTIONS 

tOO CALL HOME 

CAll ANMODE 

WRITEC6,3J 

3 r:oRMATC 1 1, 

WRITEC6,1) 

1 FORMATClX,•DO YOU WANT TO USE CURSOR TO SELECT AREA TO Bf PLOTTED? 

C REPLY Y OR N1 J 

READf5,5) ANS 

5 FORMATCAl) 

IF fANS.EQ.ENDJ GOTO 1000 

IFCANS.EQ.YESJ GOTO 150 

CALL OPKEYCXMIN 9 XSPAN,YMIN,YSPAN,ANSJ 

IF CANS.EQ~ENDJ GOTO 1000 

GOTO 300 

150 CALl OPCURSCXMINtXSPAN,YMIN,YSPAN,ANS) 

IF CANS.EQ.ENOJ GOTO 1000 

GOTO 300 

300 CALL NEWPAG 

CALL ANMODE 

WRITEC6,10) XMIN,XSPAN,YMIN,YSPAN 

tO FORMATCtX,•XMJN• 1 tf6.2t 1 XSPAN• •,F6.2t 1 YMIN= •,F6.2t 

C1 YSPAN• •,F6.2) 

C PLOT THE DATA 

CALL VWtNDO IXMIN,XSPAN,YMIN,YSPANJ 

500 READC23,2.ENO•lOOOJ J,Y,NPEN 

2 FORMATC2F10.6tl5) 

C PEN UP? 

IF CNPEN.EQ.2J GOTO 600 

C PEN DOWN? 

IF CNPEN.EQ.3) GOTO 700 

IF CNPEN.EQ.3J GOTO 700 

C TEST FOR EOF SIGNAL 

IF CNPEN.EQ.999) GOTO 1000 

c IGNORE NEGATIVE PEN POSITIONING CODES 

63 
c 

c 

c 

c 

PROGRAM LISTING FOR PROGRAM j725-Continued 

IF (NPEN.LT .OJ GOTO 500 · 

~OTO 500 

600 CALL DRAWAtX.Vl G~TO 500 

700 CALL MOVEACX.Y) 

GOTO 500 

1000 CALL BELL 

ERROR, NPEN NE 9qq. 2. 

NPEN=2• DRAW A LINE. 

NPENc3, ~OVE CURSC'R. 

fiR 3; SkiP IT 

C MOVE CURSOR TO 2ND LINE FROM THE BOTTOM OF THE SCREEN. 

c 

CALL ~OVABSI0.30) 

CALL ANMOOE 

WRITEC6,JlJ 

11 FORMATflXt'DO YOU WANT TO PLOT THE FILE AGAIN? REPLY Y OR N'J 

REWIND 23 

READC5,5) ANS 

IFCANS.EO.NOl GOTO ?000 

GOTO 100 

2000 CALL FINITTIO.OJ 

END 

SUBROUTINE OPI<EYCXMIN.XSPAN.YMJN,YSPAN,ANSJ 

REAL NO 

DATA YES/ 1 Y1 /.N0/ 1 N1 /.END/ 1 E1 / 

CALL NEWPAG 

WRITEI6.4) 

4 FORMATC1X, 1 USE DEFAULT WINDOW SIZE? REPLY Y OR N1 l 

REA0(5,5) A-NS 

5 FORMAT(Al) 

IF tANS.EO.ENO) GOTO 300 

IFCANS.EO.YESJ GOTO 200 

CALL NEWPAG 

WRJTEC6,6J 

6 FORMATClX,•ENTER MINIMUM VALUE OF X1 J 

CALL GETNUMCXMIN.ANSJ 

IF IANS.EO.ENDJ GOTO 300 

WRITEC6,7 J 

7 FORMATIIX, 1 ENTER SPAN OF X1 ) 

CALL GETNUMCXSPAN,ANSJ 

IF CANS.EO.ENDJ GOTO 300 

WRITEC6,8) 

P FORMATC1X, 1 ENTER MINIMUM VALUE OF V1 J 

CALL GETNUMC~JN,ANSJ 

IF CANS.EO.ENOJ GOTO 300 

WRITEC6 9 9l 

9 FORMATI1X, 1 ENTER SPAN Of Y'J 

CALL GETNUMCYSPAN.ANSJ 

GOTO 300 

200 Xfi'INcO. 

XSPAN=47.6 

VMIN•O. 

YSPAN•35. 

GOTO 300 

300 RETURN 

END 

SET DEFAULT WINDOW SIZE 

SUBROUTINE OPCURSIXMJN,XSPAN,VMIN,YSPAN,ANSJ 

REAL NO 

OATA YES/'Y1 /.N0/'N'/,ELO/Z00000065/,EUP/Z00000045/,END/ 1 E1 / 

C SOLICIT DEFINITION OF AREA TO BE PLOTTED. 

64 
CALL BELL 

CALL ANMODE 

PROGRAM LISTING FOR PROGRAMJ725-Continued 

CALL VCURSR CANS,XL,VL) 

C 1 f' IS SJ~NAL TO STOP CURRENT PLOT 

IF CANS.EQ.EUP) GO TO 900 

IF CANS.EO.ELO) GOTO 900 

X'4JNsXL 

YMIN=VL 

CALL BELL 

CALL ANMOOE 

CALL VCURSR CANS,XR,YR) 

C 1 E' IS SIGNAL TO STOP CURRENT PLOT 

IF CANS.EQ.EUP) GO TO 900 

IF CANS.EO.ELO) GOTO 900 

XSPAN=XR-XMJN 

VSPAN=YR-VMIN 

CALL NEWPAG 

CALL AN,.ODE 

WRITEC6tlJ 

1 FORMATC1X, 1 SET X SO THAT THE RATIO Of Y/X = 11/15? REPLY Y OR N') 

READC5t21 ANS 

'2 FORMATCAI) 

IF CANS.EO.ENO) GOTO 1000 

IF CANS.EO.NOI GOTO 1000 

XSPANct.36*YSPAN 

GO TO 1000 

900 ANS c END 

1000 RETURN 

END 

C***********************************************************************00000010 

c 00000020 

c 00000030 

C GE TNUM 00000040 

c 00000050 

C WRITTEN BY 00000060 

c 00000070 

C ALAN CROSBY OOOOOOt'O 

c 00000090 

C USGS, CCD 00000100 

c 00000110 

SUBROUTINE GETNUMCX,ANSI 

DIMENSION Af6) 

f.\ATA END/ 1 E1 / 

CALL ANMOOE 

WRITEC6tll 

1 FORMATClX,•ENTER NUMBER IN THE FORMAT NNN.NN'J 

CALL REREAD 

REAOC5,41 A 

4 FOR,.AT C6All 

IF CACII.NE.ENDJ GO TO 500 

ANS = Afl) 

GO TO 1000 

C THE FOLLOWING STATEMENT IN COMBINATION WITH REREAD 

C ALLOWS AN INPUT MESSAGE TO BE READ ~ORE THAN ONCE 

C SO IT ,.AY BE TRANSLATEO USING DIFFERENT fORMAT 

C STATEMENTS. 

500 READC99,21 X 

2 FORMATCF6.2) 

WRITEC6,3)X 

3 FORMATC1X,F6.2) 

1000 RETURN 

65 

00000130 

00000140 

00000150 

00000170 

00000172 

00000173 
PROGRAM LISTING FOR PROGRAM J725-Continued 

END 

//S3 EXEC PG"=IEWLF12P.PARM=1 XREF.LET.LJST.SIZE=C300k.lOOJ.OCBS 1 • 

// REGJON=310K 

//SYSLIB DO OSN=SVSl.TEkTRON.LOAD.OISP=SHR 

// DO OSN=SVSl.FORTliB.OISP=SHR 

1/ DO DSN=XTENT.LIB.DISP=SHR 

//SYSPRINT 00 SVSOUT=A 

//SVSUTl 00 UNIT=SYSDK.SPACE=Cl024.C200.30)) 

//SVSLIN DO DDNAME=SVSJN 

//DOl DO DSN=&&A.OISP=COLD.OELETEJ 

//SVSLMOO DO OSN=SVSl.LDAOLJB.DISP=SHR 

//SYSIN 00 * 

INCLUDE DOl 

ENTRY MAIN 

NAME J725fR J 

II 

66 

00000190 
FILE FORMATS FOR CAM TO DISK PROGRAM H876 

CAM to Disk uses the same input- and output-file 

formats as the standard version of CAM. These 

formats are described by the U.S. Central Intelligence Agency (1975). The plotting instructions 

prepared by CAM to Disk are output via the D~ 

statement FT22F001. The plotting-instructions 

record has the following format: 

Position Contents 

1-10 a value in the X direction (f10.6) 

11-20 a value in the Y direction (f10.6) 

21-25 a CalComp pen-movement code 

THE SYMBOL PROBLEM 

The newer versions of the CalComp software do 

not draw symbols. When a symbol is needed, a 

code for the symbol is recorded on the plot tape. 

When the tape is plotted, the CalComp plotter 

recognizes the symbol code and draws the symbol. 

This method of generating symbols had to be circumvented in CAM to Disk because the plotting instructions were being passed to Tektronix software, rather than to a CalComp plotter. 

Nancy Wright had a copy of the old CalComp 

subroutine Symbol; it draws symbols instead of 

passing codes. I renamed it Teksym and included it 

in the CAM to Disk program. 

The table of available symbols in Teksym does 

not agree with the latest symbols in the CalComp 

software. I wrote Trnslt to translate to the codes 

presently in use. I wrote Symbol to gain control 

from CAM, translate codes if necessary, and pass 

control to Teksym. 

TSO COMMAND PROCEDURE CAM.CLIST 

00020 PROC 0 PLOT (NONAME) 

00030 PRINT I ))))))))))))))WELCOME TO 

INTERACTIVE CAM«««' 

00060 FREE FI (FT05F001,FT06F001, 

FT23F001) 

67 

00070 ALLOC FI (FT05F001) DA(*) 

00080 ALLOC FI (FT06F001) DA(*) 

00090 ALLOC FI (FT23F001) DA('PLOT. 

DATA.SET(&PLOT.)') SHR 

00100 CALL 'SYSl.LOADLIB (J725)' 

00110 FREE FI (FT05F001,FT06F001,FT23F001) 

00120 END 

FILE FORMATS FOR PLOTCAM PROGRAM ]725 

The plotting instructions to Plotcam prepared by 

CAM to Disk are input via the DD statement 

FT23F001 and have the following format: 

Position 

1-10 

11-20 

21-25 

Contents 

a value in the X direction (fl0.6) 

a value in the Y direction (fl0.6) 

a CalComp pen-movement code 

The output of the Plotcam program is the map 

drawn on the terminal. 

GLOSSARY 

Alphanumeric information (alphanumeric, 

alphameric)-Information consisting of any combination of digits 0-9, letters A-Z, and special 

characters such as /, $, or?. 

Assumed decimal point (implied decimal point)-A 

decimal point whose position is known, even 

though it is not physically entered (punched) into 

a numeric fie,ld. 

Batch processing (batch job)-The sequential processing of records, programs, or jobs as a group 

(batch), one group at a time. Batch processing is 

in contrast to "interactive processing," during 

which each unit of data is processed immediately 

at the time of presentation- as in the airline 

reservation system. 

CAM-The Cartographic Automatic Mapping 

System devised by the U.S. Central Intelligence 

Agency to convert digitized data into geographic 

coordinates and to draw maps automatically. 

Catalog-A predefined direct-access storage area 

containing names and addresses of cataloged 

procedures and data sets. 

Cataloged procedure- A job-control-language 

generator operating in a manner similar to a 

variable in an algebraic equation. 
CLIST-The suffix of the name of a data set that 

contains a time-sharing option (TSO) command 

procedure. Name derived from catalog list. 

Command-In the sense used in this Circular, a 

command is an instruction issued by the terminal 

user in a given command-language structure, 

such as GIPSY or TSO command language. 

Command procedure- See TSO command procedure. 

COPY -One of the GIPSY retrieval-language 

commands available to the user. Provides fixedlength record output from variable-length 

GIPSY records. 

CRIB-Computerized Resources Information 

Bank- a computer file on mineral resources. It is 

operational but has not yet attained complete 

coverage. See Calkins and others (1973, 1978) 

and Keefer and Calkins (1978). 

CRT-A cathode ray tube. Some CRT's display 

graphical information; others display 

alphanumeric information. 

Data Definition (DD) statement-A particular JCL 

(job-control language) statement. Describes a 

given data set associated with the job. 

Data item (data element, information item)-The 

smallest unit of information to which reference is 

made, for example "country," "State." A set of 

related data items constitutes a record. 

Data set-A self-contained group of records. 

Direct access-The process of finding information 

in storage directly by using an index, rather than 

by starting the search at the beginning of 

storage and searching sequentially until the information is found. A tape is a sequential-access 

device. A disk is a direct-access device. 

Disk (disk pack)-A storage device consisting of a 

circular metal plate (disk) coated with magnetic 

material on both sides and mounted on a rotating 

shaft. Read-write heads service both sides of the 

disk. Stacked disks constitute a disk pack. 

Field (data item, information item)- A specified 

category of data. The basic unit of a record. See 

also data item. 

File-A collection of related records treated as a 

unit; for example, the records file and dictionary 

file of CRIB. Also in the general sense, a collection of related files; for example, the CRIB file, 

which actually consists of three files. 

File maintenance-Modification of file content; for 

example, insertions, deletions, transfers, and 

corrections. 

68 

Fixed-field-length format (fixed-length fields, fixed 

fields)-An arrangement in which the fields in a 

record are set to a specified length. 

Fixed-field records-Records of predefined length 

and loosely used to mean that both record length 

and field length are set to specified lengths. 

Floating decimal- A decimal point without a predetermined fixed position within a numeric field. 

In a six-position number field, for example, the 

decimal may be in any of the six positions, 

depending upon the size of the number. 

Format-A logical arrangement. A predefined 

arrangement of characters, fields, print lines, 

and so forth. 

GIPSY -General Information Processing System. 

The retrieval and file-management program 

written by people at the University of Oklahoma. 

Hardware-The physical, tangible components of a 

computer system, such as: a tape drive, central 

processor, or disk. 

Interactive processing-The user is communicating with the computer system in a "conversational" manner from a terminal by sending instructions (commands, parameters, data) to the 

system. The system executes the instructions 

and sends the reply (result) back to the terminal. 

Each entry is processed immediately at the time 

of presentation. Interactive processing is in contrast to batch processing in which the time of 

processing of a given statement (or job) depends 

upon the number and length of statements (or 

jobs) in front of it. 

Job (job run)- A collection of related programs, 

files, and instructions executed as a single unit of 

work by the computer. 

Job control language (JCL)-The language of the 

operating system of the computer. The user provides the necessary information in the JCL ·so 

that the computer system can run the job. JCL 

includes such items as the name and address of 

the data file to be processed, the name of the program to be executed, what to do with the results, 

and so forth. 

Job deck-A deck of punched cards which constitutes a job. 

Label-As used in GIPSY, a set of one to seven 

alphanumeric characters used to identify a data 

item or field to GIPSY program. 

Literal-In GIPSY, a set of characters inserted 

into output records written by the copy command. 
Off line- Pertaining to devices not connected to 

the computer. 

On line (on-line processing)-Essentially equivalent to "interactive." Also, describes a device 

having direct entry into the computer. 

Operating system-The set of management programs that handles the flow of jobs through a 

computer, including: job scheduling, input and 

output control, and so forth. 

Parameter statements (search variables)- A list 

of the data elements the computer is to search 

for during a retrieval. In general, any convention 

one uses to control a computer process by providing information (parameters). 

Partitioned data set-A data set divided into individually addressable subsets (partitions). Each 

partition is called a "member," and has a 

"member name." 

Program- A set of instructions that tells the computer how to solve a problem. 

Record· (records)-A group of data items (fields) 

treated as a unit. 

Retrieval operation-The actions connected with 

the recovery of information stored in a computer 

storage device. 

Software- Programs. 

Subroutine-A program that is subordinate to a 

main program (routine). A subroutine performs 

specific taks whenever the main program calls 

upon it to do so. 

Tektronix graphic terminal-A CRT (cathode-raytube) computer terminal that is made by 

Tektronix, Inc., and that is capable of drawing 

lines, symbols, and alphanumeric characters. 

The Tektronix graphic terminal was used to 

devise and implement Quick-Plot and Interactive 

CAM systems. 

Track address-A number identifying the location 

where information is stored on disk. A disk contains concentric circles (tracks) where information is recorded. Each track has an address. 

TSO-Time sharing option. One of the timesharing systems of the IBM 360/370 series computers. 

TSO command procedure (TSO procedure)- A 

predefined set of TSO command statements by 

which the computer performs a sequential series 

of processing tasks automatically. Thus, by invoking just one command, the user has a complete set of related, at times complex, tasks done 

69 

for him. It performs in the time-sharing mode a 

function similar to that performed by JCL in the 

batch mode. 

Utility programs-Programs used to peform cer-. 

tain standard functions, called housekeeping 

functions; for example, update, transfer data 

from one device to another, sort programs, and 

so forth. 

Variable fields (variable-length fields)-Fields 

having no predefined lengths. 

Variable format (variable-length format)-A field 

or record of no predefined length. 

REFERENCES CITED 

California Computer Products, Inc., 1969, Programming CalComp pen plotters: [Anaheim, 

Calif.l 25 p. 

Calkins, J. A., Kays, Olaf, Keefer, E. K., 1973, 

CRIB-The mineral resources data bank of the 

U.S. Geological Survey: Circular 681, 39 p. 

Calkins, J. A., Keefer, E. K., Ofsharick, R. A., 

Mason, G. T., Tracy, Patricia, and Atkins, 

Mary, 1978, Description of CRIB, the GIPSY 

retrieval mechanism, and the interface to the 

General Electric MARK III Service: U.S. 

Geological Survey Circular 755-A, 49 p. 

International Business Machines Corporation, 

1973, IBM System/360 Operating 

System-Time sharing option, command 

language reference. OS Release 21.7: 

[Poughkeepsie, N.Y.] 277 p. (GC28-6732-4, 

File no. S360-36). 

Keefer, E. K., and Calkins, J. A., 1978, Description 

of individual data items and codes in CRIB: 

U.S. Geological Survey Circular 755-B, 32 p. 

Oklahoma, University, Office of Information Systems Programs, 1975a, Programmer's 

guide-GIPSY documentation series, Volume 

III: Norman, Okla., variously paged. 

--1975b, Users guide-GIPSY documentation 

series, Volume II: Norman, Okla., variously 

paged. 

Tektronix, Inc., 197 4a, Plot-10, terminal control 

system, user's manual: Beaverton, Ore., 123 p. 

(Tektronix document no. 062-1474-00). 

--197 4b, Tektronix 4014 and 4014-1 computer 

display terminal-Users instruction manual: 

Beaverton, Ore., variously paged. ([Tektronix 

document no.] 070-1647-00. Reprinted 1976.) 
--1974c, Tektronix 4631 hard copy unit, users 

manual: Beaverton, Ore., 39 p. ([Tektronix 

document no.] 070-1830-00.) 

--1977, Tektronix Plot 10 4010A04 preview 

routines for CalComp plotters- user manual: 

Beaverton, Ore., 35 p. ([Tektronix document 

no.] 070-2249-00. Reprinted 1978.) 

70 

U.S. Central Intelligence Agency, 1975, CAMCartographic Automatic Mapping program 

documentation-Version 4: Washington, D.C., 

111 p. (OGCR CD 75-1 (revision)). 

U.S. National Bureau of Standards, 1973, Counties 

and county equivalents of the States of the 

United States: U.S. National Bureau of Standards Federal Information Processing Standards (FIPS) Publication 6-2, 35 p. (Supersedes 

FIPS Publication 6-1, 1970.) 

*U.S. GOVERNMENT PRINTING OFFICE: 1980 o- :UI-61-4/195