Trailing-Edge
-
PDP-10 Archives
-
decuslib10-08
-
43,50507/graph.doc
There is 1 other file named graph.doc in the archive. Click here to see a list.
This document contains the necessary information to
run the machine dependent graphics subroutines in your instalation.
All the subroutines that call machine dependent routines are stored
in the file machin.ss .
To get graphics working in your site, read carefully the descriptions
given below for OUR site's routines. Then, find routine in your instalation
that will be able to do the same job. To enable you to use the pennzyme
program without the graphics, I am providing you with a list of
dummy routines, so that you can link the different pennzyme versions
without error messages. These dummy routines are stored in dummy.ss
When you have found the equivalents, please delete those dummy subroutines
and substitute the calls in machine.ss for calls to your equivalent
subroutines.
The first routine is WHICH(IX), it takes an integer
variable IX and assigns to IX the value -1 if the user is
plotting using a TEXTRONICS graphics terminal, and
assigns to IX the value of 0 if the user is using a
CALCOMP plotter. If you do not have any of the two,
try setting the value to 0 and later try setting it to -1;
one of the two options might be compatible with your
graphics output device. If this does not work, you might
need to find a subroutine within your instalation capable
of doing the work of subroutine AXIS, located in the file
AXIS3.SS. Another (painful) alternative is to try to
modify the parameters in AXIS to fit your particular
graphics output device.
**********
STANDARD PLOTTING PACKAGE
********************
This is the "Standard" Plotting package as provided by
CALCOMP and used by many IBM installations. This package
also supports the Tektronix 4010-1 terminals.
PLOTS STANDARD PLOT PACKAGE Page 2
A Sample Plotting Program
*************************
DIMENSION XARRAY(26),YARRAY(26)
Reserve space for 24 data values plus two additional
locations required by the "SCALE", "AXIS" and "LINE"
subroutines.
10 CALL PLOTS(15.,12.,0)
Initialize the "PLOT" subroutines setting a maximum
size of 15 inches in the X direction and 12 inches in the Y
direction. The last argument, if zero, means to direct
output to the CALCOMP plotter.
20 READ 25,(XARRAY(I),YARRAY(I),I=1,24)
25 FORMAT (2F6.2)
Read 24 pairs of "TIME" and "VOLTAGE" from an input
file into two arrays with names "XARRAY" and "YARRAY".
30 CALL PLOT(0.0,0.5,-3)
Establish a new origin one-half inch higher than the
point where the pen was initially placed by the operator so
that the annotation of the "TIME" axis will fit between the
axis and the edge of the plotting surface.
40 CALL SCALE(XARRAY,5.0,24,1)
Compute scale factors for use in plotting the "TIME"
values within a five-inch plotting area.
50 CALL SCALE(YARRAY,6.0,24,1)
Compute scale factors for use in plotting the "VOLTAGE"
data values within a six-inch plotting area (I.E. the data
pairs of "TIME" and "VOLTAGE" will plot within a five-by-six
inch area).
60 CALL AXIS(0.0,0.0,20HTIME IN MILLISECONDS,-20,5.0,0.0,XARRAY
&(25),XARRAY(26))
Draw the "TIME" axis (5 inches long), using the scale
factors computed in statement 40 to determine the
milliseconds at each inch along the "TIME" axis.
70 CALL AXIS(0.0,0.0,7HVOLTAGE,7,6.0,90.0,YARRAY(25),
&YARRAY(26))
Draw the "VOLTAGE" axis (6 inches long), using the
scale factors COMPUTED IN STATEMENT 50 TO DETERMINE THE
VOLTAGE AT EACH INCH ALONG THE "VOLTAGE" AXIS.
80 CALL LINE(XARRAY,YARRAY,24,1,2,4)
PLOT "VOLTAGE" VS "TIME", DRAWING A LINE BETWEEN EACH
OF THE 24 SCALED POINTS AND A SYMBOL "X" AT EVERY OTHER
POINT.
PLOTS STANDARD PLOT PACKAGE Page 3
90 CALL SYMBOL(0.5,5.6,0.21,16HPERFORMANCE TEST,0.0,16)
PLOT THE FIRST LINE OF THE GRAPH TITLE.
100 CALL SYMBOL(0.5,5.2,0.14,16HREF. NO. 1623-46,0.0,16)
PLOT THE SECOND LINE OF THE GRAPH TITLE.
110 CALL LASPLT
CLOSE THE OUPUT FILE FOR THE PLOTTER. WRITE OUT LAST
BUFFER.
120 STOP
TERMINATE THE PROGRAM
END
REFER TO FIGURE 1 FOR THE PLOTTER OUTPUT FROM THE ABOVE
PROGRAM.
PLOTS STANDARD PLOT PACKAGE Page 4
FIGURE 1
OUPUT FROM SAMPLE PROGRAM
PLOTS STANDARD PLOT PACKAGE Page 5
PLANNING YOUR GRAPH
GRAPHS AND PLOTS, LIKE COMPUTER LISTINGS, REQUIRE SOME
PLANNING TO ACHIEVE A PLEASING AND EFFECTIVE FORMAT. THE
FOLLOWING CHECKLIST OF PLOTTING CONVENTIONS IS LETTER-KEYED
TO FIGURE 2 TO HELP YOU IN YOUR PLANNING.
A. THE INITIAL POSITION OF THE PEN WHEN THE PLOTTING OPERATION
BEGINS IS ASSUMED TO BE THE LOGICAL ORIGIN (X=0,Y=0). ALL
PEN MOVEMENTS ARE DEFINED IN X-COORDINATE AND Y-COORDINATE
INCHES FROM THE CURRENT ORIGIN. SUBSEQUENT ORIGINS CAN BE
ESTABLISHED AT OTHER POSITIONS BY APPROPRIATE PROGRAMMING TO
PROVIDE NEW REFERENCE POINTS. (SEE "PLOT") WHEN THE NEXT
GRAPH IS STARTED, A NEW ORIGIN SHOULD BE DEFINED FAR ENOUGH
AWAY TO AVOID ANY AXIS OR ANNOTATION OVERLAP WITH THE
PREVIOUS GRAPH.
B. ON THE CALCOMP PLOTTER THE X-AXIS LIES PARALLEL TO THE
SIDE, WITH THE +X DIRECTION TOWARD THE BACK.THE X-AXIS LINE
OF A GRAPH SHOULD BE AT LEAST 1/2 IMNCH FROM THE SIDES OF
THE PLOTTER TO LEAVE A MARGIN FOR LABELING.
THE MAXIMUM WIDTH OF A GRAPH (X-DIRECTION) IS LIMITED
BY THE LENGTH OF THE PAPER (120 FEET). THE FACILITY HAS
ALSO IMPOSED A 100-INCH LIMIT FOR ANY GIVEN PLOT (SEE
"PLOT").
C. THE Y-AXIS IS PARALLEL TO THE PLOTTER'S PEN-CARRIAGE BEAM.
THE Y-AXIS LINE OF A GRAPH SHOULD ALSO BE AT LEAST 1/2 INCH
FROM THE SIDES OF THE PLOTTER TO LEAVE A MARGIN FOR THE
LABEL AND ANNOTATION.
THE MAXIMUM HEIGHT OF A GRAPH (Y-DIRECTION) IS 11
INCHES.
D. THE ANGLE OF ROTATION ABOUT ANY POINT IS DETERMINED BY A
VECTOR WHICH ,WHEN EXTENDED IN THE +X DIRECTION, REPRESENTS
0 DEGREES. ANY ANGLE ARGUMENT USED IN A CALLING SEQUENCE
MAY BE STATED IN PLUS OR MINUS DEGREES RELATIVE TO THE
X-AXIS.
PLOTS STANDARD PLOT PACKAGE Page 6
FIGURE 2
PEN PLOTTING CONVENTIONS
PLOTS STANDARD PLOT PACKAGE Page 7
PLOTS BASIC SOFTWARE
THE FOLLOWING PAGES DESCRIBE IN DETAIL CALCOMP'S BASIC
SOFTWARE, WHICH COMPRISES SIX SUBROUTINES THAT CAN BE CALLED
BY YOUR FORTRAN PROGRAM. THESE SUBROUTINES ARE CALLED
"PLOT","SYMBOL","NUMBER","SCALE" ,"AXIS",AND "LINE".
THEY,IN TURN, CALL UPON EACH OTHER FOR CERTAIN OPERATIONS.
A PARTICULAR APPLICATION MAY NOT NEED ALL OF THESE
SUBROUTINES, DEPENDING ON THE USER'S REQUIREMENTS.
PLOT CONVERTS ALL PEN MOVEMENT SPECIFICATIONS FROM INCHES TO
ACTUAL PLOTTER COMMANDS, AND OUTPUTS THESE TO THE ATTACHED
DEVICE.
SYMBOL DRAWS ANY SEQUENCE OF ALPHAMERIC CHARACTERS, AS WELL AS
SPECIAL POINT-PLOTTING SYMBOLS. IT CALLS ONLY "PLOT".
NUMBER DRAWS THE DECIMAL EQUIVALENT OF AN INTERNAL FLOATING-POIN
NUMBER. IT CALLS ONLY "SYMBOL", WHICH THEN CALLS "PLOT".
SCALE EXAMINES A DATA ARRAY TO DETERMINE AN OPTIMUM STARTING VALUE
AND A SCALING FACTOR FOR USE BY "AXIS" AND "LINE" IN
CONVERTING DATA UNITS TO PLOTTER PAGE DIMENSIONS. IT IS THE
ONLY SUBROUTINE THAT DOES NOT CALL ANY OTHER, BECAUSE IT
DOES NO ACTUAL PLOTTING.
AXIS DRAWS AN AXIS LINE WITH THE APPROPRIATE SCALE ANNOTATION AND
TITLE. IT CALLS "SYMBOL" AND "NUMBER" AS WELL AS "PLOT".
LINE PLOTS A SERIES OF SCALED DATA POINTS DEFINED BY TWO ARRAYS
(X AND Y),CONNECTING THE POINTS WITH STRAIGHT LINES IF
DESIRED. IT MAY CALL "SYMBOL" AS WELL AS "PLOT".
THE ARGUMENT NAMES USED IN THE FOLLOWING SUBROUTINE
DESCRIPTIONS CONFORM TO STANDARD FORTRAN CONVENTIONS: IF THE
FIRST LETTER IS I,J,K,L,M, OR N, THE ARGUMENT MUST BE AN
INTEGER VALUE; IF IT IS ANY OTHER LETTER, THE ARGUMENT MUST
BE A REAL FLOATING-POINT VALUE. THE DESCRIPTION OF EACH
ARGUMENT IS GENERALLY CONSISTENT FOR MOST COMPUTERS AND FOR
ALL "CALCOMP" PEN PLOTTING SYSTEMS. HOWEVER, THE PROGRAMMER
SHOULD ALSO REFER TO THE "CALCOMP" PROGRAMMING SUPLEMENT ON
THE COMPUTER SYSTEM BEING USED, SO THAT HE WILL BE INFORMED
OF ANY SPECIAL CONSIDERATIONS.
PLOTS STANDARD PLOT PACKAGE Page 8
PLOT SUBROUTINE
MOST GRAPHIC APPLICATIONS REQUIRE THE GENERATION OF X-Y
GRAPHS TO SHOW THE RELATIONSHIP BETWEEN TWO OR MORE SETS OF
DATA. USUALLY THESE GRAPHS CAN BE PRODUCED EASILY AND
QUICKLY BY A SUITABLY PROGRAMMED COMBINATION OF THE FIVE
SUPPORTING SUBROUTINES "SCALE","AXIS","LINE","SYMBOL" AND
"NUMBER". THESE SUBROUTINES DO NOT DIRECTLY PRODUCE PLOTTER
COMMANDS; THEY ONLY COMPUTE APPROPRIATE ARGUMENTS THAT
DEFINE PEN POSITIONS, AND THEN CALL THE "PLOT" SUBROUTINE,
WHICH GENERATE THE ACTUAL PLOTTER COMMANDS.
WHEN UNIQUE PLOTTING REQUIREMENTS CANNOT BE SATISFIED
BY USING THE SUPPORTING SUBROUTINES, THE USER CAN RESORT TO
THE "PLOT" SUBROUTINE , WHICH GIVES HIM DIRECT CONTROL OF
PEN MOVEMENT (TO ANY X,Y COORDINATES POSITION) AND PEN
STATUS (UP OR DOWN).
BY CALLING THE "PLOT" SUBROUTINE WITH A DIFFERENT ENTRY
NAME ("PLOTS","FACTOR","WHERE","LASPLT"), THE USER ALSO HAS
CONTROL OF: OUTPUT DEVICE OPENING AND CLOSING, ENLARGING OR
REDUCING A PLOT; OR LOCATION OF PENS CURRENT POSITION. EACH
ENTRY IS DESCRIBED SEPARATELY BELOW.
PLOT ENTRY
THE "PLOT" ENTRY TO THE "PLOT" SUBROUTINE IS USED
PRIMARILY TO MOVE THE PEN IN A STRAIGHT LINE TO A NEW
POSITION, WITH THE PEN EITHER UP OR DOWN DURING THE
MOVEMENT. IT CONVERTS THE ARGUMENTS TO THE APPROPRIATE
SEQUENCE OF PLOTTER COMMANDS, AND OUTPUTS THESE TO THE
ATTACHED DEVICE (PLOTTER OR TEKTRONIX 4010-1).NOTE THAT THE
"PLOTS" ENTRY MUST BE CALLED BEFORE ANY OTHER ENTRIES ARE
CALLED.
THE CALLING SEQUENCE HAS THREE ARGUMENTS:
CALL PLOT(XPAGE,YPAGE,+OR- IPEN)
XPAGE, ARE THE X, Y COORDINATES, IN INCHES FROM THE CURRENT
YPAGE REFERENCE POINT(ORIGIN), OF THE POSITION TO WHICH THE PEN IS
TO BE MOVED. AN ORIGIN (WHERE BOTH X, Y EQUAL ZERO) MAY BE
ESTABLISHED ANYWHERE ON THE PLOTTING SURFACE, AS EXPLAINED
BELOW FOR NEGATIVE IPEN VALUES.
PLOTS STANDARD PLOT PACKAGE Page 9
+OR- IPEN IS A SIGNED INTEGER WHICH CONTROLS PEN UP/DOWN STATUS AND
ORIGIN DEFINITION.
IF IPEN = 2, THE PEN IS DOWN DURING MOVEMENT, THUS DRAWING A
VISIBLE LINE.
IF IPEN = 3, THE PEN IS UP DURING MOVEMENT.
IF IPEN = -2 OR -3, A NEW ORIGIN IS DEFINED AT THE TERMINAL
POSITION AFTER THE MOVEMENT IS COMPLETED AS IF IPEN WERE
POSITIVE. THE LOGICAL X, Y COORDINATES OF THE NEW PEN
POSITION ARE SET EQUAL TO ZERO, SO THAT THAT POSITION IS THE
REFERENCE POINT FOR SUCCEEDING PEN MOVEMENTS.
IF IPEN = 999, THE PLOTTER BUFFER IS CLOSED. TO DO MORE
PLOTS, ANOTHER "PLOTS" CALL MUST BE USED.
If IPEN is 12, 13, -12 or -13 the same action is taken as if
it were 2, 3, -2 or -3, and, in addition, the offset factors
(entered through a CALL OFFSET) are applied to compute the
new pen position.
PLOTS STANDARD PLOT PACKAGE Page 10
PLOTS ENTRY
THE "PLOTS" ENTRY IS USED TO INITIALIZE THE "PLOT"
SUBROUTINE. IT MUST BE CALLED ONLY ONCE - BEFORE ANY OTHER
CALL TO "PLOT","SYMBOL" ,"NUMBER","AXIS","LINE" OR ANY OTHER
PLOTTING SUBROUTINE UNLESS SPECIFIED OTHERWISE. THIS CALL
IS USED TO SPECIFY WHICH DEVICE IS TO RECIEVE THE PLOTTER
OUTPUT (CALCOMP OR TEKTRONIX 4010-1), AND IF DESIRED TO
SPECIFY THE LIMITS IN INCHES ALLOWED FOR THE PLOTTER
OUTPUT(CALCOMP ONLY).
THIS ENTRY'S CALLING SEQUENCE ALSO HAS THREE ARGUMENTS:
CALL PLOTS(XLIM,YLIM,LDEV)
XLIM, ARE THE LIMITS IN INCHES IN THE X AND Y DIRECTIONS FOR THE
YLIM PLOTTER OUTPUT (ONLY APPLIES TO CALCOMP OUTPUT). IF A
MOVEMENT IS ATTEMPTED BEYOND THESE LIMITS (FROM THE ORIGIN)
THE JOB IS ABORTED.
LDEV IS THE OUTPUT DEVICE NUMBER. LDEV = 0 MEANS USE THE CALCOMP
PLOTTER AS THE OUTPUT DEVICE. LDEV = 5 MEANS USE THE
TEKTRONIX 4010-1 AS THE OUTPUT DEVICE. LDEV MUST BE AN
INTEGER ARGUMENT.
The "PLOTS" call initializes the "FACTOR" (see below)
to 1.0.
IF THE CALCOMP PLOTTER IS BEING USED, THE DEFAULT
ORIGIN (0.,0.) IS SET 1 INCH FROM THE RIGHT HAND SIDE OF THE
DRUM. THE +Y DIRECTION IS FROM THE ORIGIN DIRECTLY ACROSS
THE DRUM TO THE LEFT. THE +X DIRECTION IS TOWARDS THE BACK
OF THE DRUM, IE, DRUM ROTATION TOWARDS THE FRONT.
ON THE TEKTRONIX 4010-1 THE DEFAULT ORIGIN IS AT THE
LOWER LEFT HAND SIDE OF THE SCREEN. THE +Y DIRECTION IS
FROM THE ORIGIN UP TO THE TOP OF THE SCREEN(780 POINTS) AND
IS LIMITED TO 7.8 INCHES. THE +X DIRECTION IS FROM LEFT TO
RIGHT (1024 POINTS) AND 10.24 INCHES.
PLOTS STANDARD PLOT PACKAGE Page 11
FACTOR ENTRY
THE "FACTOR" ENTRY TO THE "PLOT" SUBROUTINE ENABLES THE
USER TO ENLARGE OR REDUCE THE SIZE OF THE ENTIRE PLOT BY
CHANGING THE RATIO OF THE DESIRED PLOT SIZE TO THE NORMAL
PLOT SIZE.
CALL FACTOR (FACT)
FACT IS THE RATIO OF THE DESIRED PLOT SIZE TO THE NORMAL PLOT
SIZE. FOR EXAMPLE, IF "FACT" = 2.0, ALL SUBSEQUENT PEN
MOVEMENTS WILL BE TWICE THEIR NORMAL SIZE. WHEN "FACT" IS
RESET TO 1.0, ALL PLOTTING RETURNS TO NORMAL SIZE.
WHERE ENTRY
THE "WHERE" ENTRY SETS THE THREE VARIABLES DESIGNATED
IN THE CALLING SEQUENCE TO THE PEN'S CURRENT POSITION
COORDINATES AND THE PLOT-SIZING FACTOR (THAT ARE IN USE BY
THE "PLOT" SUBROUTINE). THIS PERMITS USER-WRITTEN
SUBROUTINES TO KNOW THE PEN'S CURRENT LOCATION FOR
OPTIMIZING PEN MOVEMENT.
THERE ARE THREE ARGUMENTS IN THE CALLING SEQUENCE:
CALL WHERE(RXPAGE,RYPAGE,RFACT)
RXPAGE, ARE VARIABLES THAT WILL BE SET TO THE PEN'S CURRENT POSITION
RYPAGE COORDINATES RESULTING FROM THE PREVIOUS CALL TO "PLOT"
(WHICH MAY HAVE BEEN CALLED BY "SYMBOL","NUMBER","AXIS" OR
"LINE").
RFACT IS SET TO THE CURRENT PLOT-SIZING FACTOR; I.E., THE VALUE
LAST SUPPLIED BY A CALL TO "FACTOR", OR 1.0 IF "FACTOR" HAS
NOT BEEN CALLED.
PLOTS STANDARD PLOT PACKAGE Page 12
LASPLT ENTRY
THE "LASPLT" ENTRY MUST BE USED TO CLOSE THE PLOTTER
OUTPUT FILE. THIS CALL WILL CLOSE THE PLOTTER OUTPUT DEVICE
AND WRITE OUT ANY PARTIALLY FILLED BUFFERS.IF YOU WISH TO
CONTINUE PLOTTING AFTER A "LASPLT" CALL YOU MUST CALL
"PLOTS" AGAIN.
THERE ARE NO ARGUMENTS TO THE "LASPLT" ENTRY.
CALL LASPLT
CLOSE THE PLOTTER OUTPUT FILE.
PLOTS STANDARD PLOT PACKAGE Page 13
OFFSET
OFFSET
This entry sets the values of the offset factors that
will be employed whenever a call to PLOT has an IPEN value
equal to 12, 13, -12 or -13.
CALL OFFSET (XOFF,XFCT,YOFF,YFCT)
XOFF, YOFF = the x and y offsets that will be subtractes
from XPAGE and YPAGE when the appropriate
call to PLOT is provided.
XFCT, YFCT = the X and Y division factors that XPAGE and
YPAGE will be divided by when the appropriate
call to PLOT is provided.
When a call to PLOT has an IPEN value of 12, 13, -12 or
-13, the values of XPAGE and YPAGE are altered as follows:
XPAGE = (XPAGE-XOFF)/XFACT
YPAGE = (YPAGE-YOFF)/YFACT
FSETON
CALL FSETON
THIS CALL WILL FORCE ALL "PLOT" CALLS WITH
IPEN VALUE OF 2,3, OR -2,-3 TO USE OFFSET
ALSO.
FSETOF
CALL FSETOF
RETURN OFFSET TO NORMAL STATUS,I.E, ONLY
OFFSET "PLOT" CALLS WITH IPEN VALUE OF
12,13,-12,OR -13.
PLOTS STANDARD PLOT PACKAGE Page 14
SYMBOL
SYMBOL
******
AUTHOR: JACK LONDON
********************
THE "SYMBOL" SUBROUTINE PRODUCES PLOT
ANNOTATION AT ANY ANGLE AND IN PRACTICALLY
ANY SIZE. THERE ARE TWO "SYMBOL" CALL
FORMATS: 1) THE "STANDARD" CALL, WHICH CAN BE
USED TO DRAW TEXT SUCH AS TITLES, CAPTIONS,
AND LEGENDS; AND 2) THE "SPECIAL" CALL, WHICH
IS USED TO DRAW SPECIAL CENTERED SYMBOLS SUCH
AS A BOX, OCTAGON, TRIANGLE, ETC., FOR
PLOTTING DATA POINTS.
THE STANDARD CHARACTERS THAT ARE DRAWN
BY "SYMBOL" INCLUDE THE LETTERS A-Z, DIGITS
0-9, AND CERTAIN SPECIAL CHARACTERS. SEE
"POINT" FOR A LIST OF THE CHARACTERS
AVAILABLE FOR THE "SPECIAL" SYMBOL CALL.
BOTH FORMS OF THE "SYMBOL" CALLING SEQUENCE
HAVE SIX ARGUMENTS.
THE "STANDARD" CALL IS:
CALL
SYMBOL(XPAGE,YPAGE,HEIGHT,IBCD,ANGLE,+NCHAR)
XPAGE, ARE THE COORDINATES, IN INCHES, OF THE LOWER
LEFT-HAND
YPAGE CORNER (BEFORE CHARACTER ROTATION) OF THE FIRST
CHARACTER TO BE PRODUCED. THE PEN IS UP
WHILE MOVING TO THIS POINT.
ANNOTATION MAY BE CONTINUED FROM THE POSITION
FOLLOWING THAT AT WHICH THE LAST ANNOTATION
ENDED. CONTINUATION OCCURS WHEN XPAGE AND/OR
YPAGE EQUALS 999.0, AND MAY BE APPLIED TO X
OR Y INDEPENDENTLY.
HEIGHT IS THE HEIGHT, IN INCHES, OF THE CHARACTER TO
BE PLOTTED. FOR BEST RESULTS, IT SHOULD BE A
MULTIPLE OF SEVEN TIMES THE PLOTTER INCREMENT
SIZE (E.G., .07, .14, .21 ETC.), BUT OTHER
VALUES ARE ACCEPTABLE. THE WIDTH OF A
CHARACTER, INCLUDING SPACING IS 6/7 OF THE
HEIGHT (E.G., A STRING OF 10 CHARACTERS 0.14
INCH HIGH IS 1.2 INCHES WIDE).
IBCD IS THE TEXT, IN INTERNAL COMPUTER REPRESENTATION
(ASCII), TO BE USED AS ANNOTATION. THE
CHARACTER(S) MUST BE LEFT JUSTIFIED AND
CONTIGUOUS IN: A SINGLE VARIABLE, AN ARRAY,
OR IN AN ASCII LITERAL.
PLOTS STANDARD PLOT PACKAGE Page 15
SYMBOL
THE TEXT MUST BE RIGHT JUSTIFIED IN ASCII IF
A SINGLE CHARACTER IS DESIRED AND "NCHAR" =0.
ANGLE IS THE ANGLE, IN DEGREES FROM THE X-AXIS, AT
WHICH THE ANNOTATION IS TO BE PLOTTED. IF
"ANGLE" = 0. THE CHARACTER(S) WILL BE
PLOTTED RIGHT SIDE UP AND PARALLEL TO THE
X-AXIS.
+NCHAR IS THE NUMBER OF CHARACTERS TO BE PLOTTED FROM
"IBCD". IF "NCHAR" GREATER THAN 0, THE DATA
MUST BE LEFT-JUSTIFIED IN THE FIRST ELEMENT
OF "IBCD".
IF "NCHAR" = 0, ONE ALPHAMERIC CHARACTER IS
PRODUCED, USING A SINGLE CHARACTER WHICH IS
RIGHT-JUSTIFIED IN THE FIRST ELEMENT OF
"IBCD".
THE SECOND FORM IS THE "SPECIAL" CALL, WHICH
PRODUCES ONLY A SINGLE SYMBOL BASED ON THE
INDEX VALUE OF "INTEQ"-NOT ON THE THE ASCII
REPRESENTATION OF A CHARACTER.
CALL
SYMBOL(XPAGE,YPAGE,HEIGHT,INTEQ,ANGLE,-ICODE)
XPAGE, ARE THE SAME AS DESCRIBED FOR THE "STANDARD"
CALL. IF
YPAGE THE SYMBOL TO BE PRODUCED IS ONE OF THE CENTERED
SYMBOLS (I.E., IF "INTEQ" IS LESS THAN 14),
"XPAGE","YPAGE" REPRESENT THE CENTER OF THE
CHARACTER PRODUCED.
ANGLE IS THE SAME AS DESCRIBED IN THE "STANDARD" CALL.
HEIGHT IS THE HEIGHT (AND WIDTH), IN INCHES, OF THE
CENTERED SYMBOL TO BE DRAWN. PREFERABLY, IT
SHOULD BE A MULTIPLE OF SEVEN TIMES THE
PLOTTER INCREMENT SIZE.
INTEQ IS THE INTEGER EQUIVALENT OF THE DESIRED SYMBOL.
VALID INTEGERS AND THEIR SYMBOLS ARE
DESCRIBED IN THE "POINT" DOCUMENTATION.
-ICODE IS NEGATIVE AND DETERMINES WHETHER THE PEN IS
UP OR DOWN DURING THE MOVE TO
"XPAGE","YPAGE".
WHEN -ICODE IS:
-1, THE PEN IS UP DURING THE MOVE, AFTER
WHICH A SINGLE SYMBOL IS PRODUCED;
PLOTS STANDARD PLOT PACKAGE Page 16
SYMBOL
-2, OR LESS, THE PEN IS DOWN DURING THE MOVE,
AFTER WHICH A SINGLE SYMBOL IS PRODUCED.
PLOTS STANDARD PLOT PACKAGE Page 17
MNUMBR
MNUMBR
******
Author: Jack London
********************
THIS SUBROUTINE WILL WRITE ON GRAPH, THE
NUMERICAL VALUE OF A VARIABLE, IN A FORMAT
SELECTED BY USER.
CALL MNUMBR (X,Y,SIZE,NUM,THETA,'(FORMAT)')
X AND Y ARE THE COORDINATES OF THE LOWER
LEFTHAND CORNER OF THE FIRST DIGIT TO BE
PLOTTED.
SIZE IS THE DESIRED HEIGHT OF A DIGIT.
WIDTH OF EACH DIGIT IS ALWAYS 4/7X(SIZE) AND
DISTANCE BETWEEN DIGITS IS 2/7X(SIZE).
NUM IS THE NUMBER TO BE PLOTTED. NUM MAY
BE A FLOATING POINT OR INTEGER VARIABLE.
THETA IS THE ANGLE (IN DEGREES) AT WHICH
THE NUMBER IS TO BE DRAWN.
'(FORMAT)' IS THE DESIRED OUTPUT FORMAT,
AND MUST BEGIN AND END WITH PARENTHESES.
USER MAY CHOOSE ANY FORMAT THAT CAN BE
HANDLED BY "ENCODE".
EXAMPLE
*******
PLOT THE VALUE OF FPN AT (3,2) HORIZONTALLY,
IN F3.1 FORMAT. CHARACTERS ARE TO BE 0.5
INCHES HIGH.
NOTE! THE WORD 'ERROR' WILL BE PLOTTED AT
(X,Y) IF:
A) THE ENCLOSING PARENTHESES ARE MISSING.
B) THE FORMAT IS NOT I, F, OR E.
CAUTION!
*******
Before calling MNUMBR, user must do a CALL
PLOTS(XLIM,YLIM,IDEV) to initialize plotter
programs.
PLOTS STANDARD PLOT PACKAGE Page 18
NUMBER
NUMBER
******
NUMBER converts a floating-point number
to the appropriate decimal equivalent so that
the number may be plotted in the FORTRAN
F-type format. The NUMBER calling sequence
has six arguments.
CALL NUMBER
(XPAGE,YPAGE,HEIGHT,FPN,ANGLE,+OR- NDEC)
XPAGE are the same as those arguments described for
YPAGE Subroutine SYMBOL. The continuation feature,
HEIGHT where XPAGE or YPAGE equals 999., may also be
ANGLE used.
FPN is the floating-point number that is to be
converted and plotted.
+or-NDEC controls the precision of the conversion of the
number FPN. If the value of NDEC>0, it specifies
the number of digits to the right of the decimal
point that are to be converted and plotted, after
proper rounding. For example, assume an internal
value (perhaps in binary form) of -0.12345678 x
10^3. If NDEC were 2, the plotted number would be
-123.46.
If NDEC = 0, only the number's integer portion and
a decimal point are plotted, after rounding.
If NDEC = -1, only the number's integer portion is
plotted, after rounding. (The above example would
be plotted as -123 with no decimal point.)
If NDEC < -1, |NDEC| -1 digits are truncated from
the integer portion, after rounding.
The magnitude of NDEC should not exceed 9.
PLOTS STANDARD PLOT PACKAGE Page 19
SCALE
SCALE
AUTHOR: PETE CLARK
******************
TYPICALLY, THE USER'S PROGRAM WILL ACCUMULATE PLOTTING
DATA IN TWO ARRAYS: 1) AN ARRAY OF INDEPENDENT VARIABLES,
X(I); AND 2) AN ARRAY OF DEPENDENT VARIABLES ,Y(I)=F(X(I)).
IT WOULD BE UNUSUAL,HOWEVER, IF THE RANGE OF VALUES IN EACH
ARRAY CORRESPONDED EXACTLY WITH THE NUMBER OF INCHES
AVAILABLE IN THE ACTUAL PLOTTING AREA. FOR SOME PROBLEMS
THE RANGE OF DATA IS PREDICTABLE, AND THE PROGRAMMER CAN
PREDETERMINE SUITABLE CONVERSION FACTORS FOR USE IN DRAWING
THE AXIS SCALE VALUES AND PLOTTING THE DATA POINTS ON THE
GRAPH. HOWEVER, IN GENERAL, THESE FACTORS ARE NOT KNOWN IN
ADVANCE.
THEREFORE, THE "SCALE" SUBROUTINE IS USED TO EXAMINE
THE DATA VALUES IN AN ARRAY AND TO DETERMINE A STARTING
VALUE, EITHER MINIMUM OR MAXIMUM , AND A SCALING FACTOR,
POSITIVE OR NEGATIVE, SUCH THAT: 1)THE SCALE ANNOTATION
DRAWN BY THE "AXIS" SUBROUTINE AT EACH DIVISION WILL
PROPERLY REPRESENT THE RANGE OF REAL DATA VALUES IN THE
ARRAY; AND 2) THE DATA POINTS, WHEN PLOTTED BY THE "LINE"
SUBROUTINE, WILL FIT IN A GIVEN PLOTTING AREA. THESE TWO
VALUES ARE COMPUTED AND STORED BY "SCALE" AT THE END OF THE
ARRAY.
THE SCALING FACTOR (DELTAV) THAT IS COMPUTED REPRESENTS
THE NUMBER OF DATA UNITS PER INCH OF AXIS, BUT IS ADJUSTED
SO THAT IT IS ALWAYS AN INTERVAL OF 1,2,4,5, OR 8 *10**N
(WHERE N IS AN EXPONENT CONSISTENT WITH THE ORIGINAL
UNADJUSTED SCALING FACTOR). THUS, AN ARRAY MAY HAVE A RANGE
OF VALUES FROM 301 TO 912, TO BE PLOTTED OVER AN AXIS OF 10
INCHES. THE UNADJUSTED SCALING FACTOR IS (912-301)/10=61.1
UNITS/INCH. THE ADJUSTED "DELTAV" WOULD BE 8*10**1=80.
THE STARTING VALUE (FIRSTV), WHICH WILL APPEAR AS THE
FIRST ANNOTATION ON THE AXIS, IS COMPUTED AS SOME MULTIPLE
OF "DELTAV" THAT IS EQUAL TO OR OUTSIDE THE LIMITS OF THE
DATA IN THE ARRAY. FOR THE EXAMPLE GIVEN ABOVE, IF A
MINIMUM IS WANTED FOR "FIRSTV", 240 WOULD BE CHOSEN AS THE
BEST VALUE. IF A MAXIMUM IS DESIRED INSTEAD, 960 WOULD BE
SELECTED.
PLOTS STANDARD PLOT PACKAGE Page 20
SCALE
THERE ARE FOUR ARGUMENTS IN THE CALLING SEQUENCE:
THE FIRST TWO ARGUMENTS MUST BE FLOATING POINT AND THE
LAST TWO MUST BE INTEGER.
CALL SCALE (ARRAY,AXLEN,NPTS,INC)
ARRAY = THE ARRAY OF DATA POINTS TO BE EXAMINED
THE ARRAY MUST BE A REAL (FLOATING POINT) ARRAY.
AXLEN = THE LENGTH OF THE AXIS TO WHICH THE DATA IS TO BE SCALED.
ITS VALUE MUST BE GREATER THAN 1.0 INCH.
NPTS = THE NUMBER OF DATA VALUES TO BE SCANNED IN THE ARRAY. THE
"FORTRAN" DIMENSION STATEMENT SHOULD SPECIFY AT LEAST TWO
ELEMENTS MORE THAN THE NUMBER OF VALUES BEING SCANNED, TO
ALLOW ROOM FOR "SCALE" TO STORE THE COMPUTED STARTING VALUE
AND SCALING FACTOR AT THE END OF THE ARRAY.
INC = AN INTEGER WHOSE MAGNITUDE IS USED BY "SCALE" AS THE
INCREMENT WITH WHICH TO SELECT THE DATA VALUES TO BE SCANNED
IN THE ARRAY. NORMALLY MAGNITUDE OF INC = 1; IF IT IS 2,
EVERY OTHER VALUE IS EXAMINED.
IF INC IS POSITIVE, THE SELECTED STARTING VALUE
(FIRSTV) APPROXIMATES A MINIMUM, AND THE SCALE FACTOR
(DELTAV) IS POSITIVE.
IF INC IS NEGATIVE, THE SELECTED STARTING VALUE
(FIRSTV) APPROXIMATES A MAXIMUM, AND THE SCALING FACTOR
(DELTAV) IS NEGATIVE.
IF MAGNITUDE OF INC = 1, THE ARRAY MUST BE DIMENSIONED
AT LEAST TWO ELEMENTS LARGER THAN THE ACTUAL NUMBER OF DATA
VALUES IT CONTAINS. IF THE MAGNITUDE OF INC 1, THE COMPUTED
VALUES ARE STORED AT (INC) ELEMENTS AND (2*INC) ELEMENTS
BEYOND THE LAST DATA POINT. THE SUBSCRIPTED ELEMENT FOR
FIRSTV IS ARRAY(NPTS*INC+1); FOR DELTAV IT IS
ARRAY(NPTS*INC+INC+1).
PLOTS STANDARD PLOT PACKAGE Page 21
AXIS
AXIS
AUTHOR: PETE CLARK
******************
MOST GRAPHS REQUIRE AXIS LINES AND SCALES TO INDICATE
THE ORIENTATION AND VALUES OF THE PLOTTED DATA POINTS. THE
MOST COMMON TYPE OF SCALED AXIS IS EASILY PRODUCED BY THE
AXIS SUBROUTINE, WHICH DRAWS ANY LENGTH LINE AT ANY
ANGLE,DIVIDES IT INTO 1-INCH OR (USER DEFINED) LENGTH
SEGMENTS,ANNOTATES THE DIVISIONS WITH APPROPRIATE SCALE
VALUES, AND LABELS THE AXIS WITH A CENTERED TITLE. WHEN
BOTH THE X AND THE Y AXES ARE NEEDED, AXIS IS CALLED
SEPARATELY FOR EACH ONE.
THERE ARE 8 (USUAL) 9,11 OR 12 ARGUMENTS IN THE CALLING
SEQUENCE. ALL ARGUMENTS MUST BE FLOATING POINT UNLESS
OTHERWISE SPECIFIED BELOW.
CALL AXIS(X,Y,IBCD,+OR-NCHAR,AXLEN,ANGLE,FIRSTV,DELTAV)
CALL AXIS(X,Y,IBCD,+OR-NCHAR,AXLEN,ANGLE,FIRSTV,DELTAV,SEGLN)
CALL AXIS(X,Y,IBCD,+OR-NCHAR,AXLEN,ANGLE,FIRSTV,DELTAV,SEGLN,
1NROT,FMT)
CALL AXIS(X,Y,IBCD,+OR-NCHAR,AXLEN,ANGLE,FIRSTV,DELTAV,SEGLN,
1NROT,FMT,IDELTA)
X,Y = THE COORDINATES OF THE AXIS LINE'S STARTING POINT. THE
ENTIRE LINE AND TERMINAL ENDS SHOULD BE AT LEAST .75 INCH
FROM ANY SIDE TO ALLOW SPACE FOR THE SCALE ANNOTATION AND
AXIS TITLE. USUALLY, BOTH THE X AND Y AXES ARE JOINED AT
THE ORIGIN OF THE GRAPH, WHERE X AND Y EQUAL 0; BUT OTHER
STARTING POINTS CAN BE USED IF DESIRED. WHEN USING THE
"LINE" SUBROUTINE TO PLOT DATA ON AN AXIS, AT LEAST ONE OF
THE COORDINATES MUST BE 0;I.E. FOR AN X-AXIS,X=0, AND FOR A
Y-AXIS, Y=0.
IBCD = THE TITLE, WHICH IS CENTERED AND PLACED PARALLEL TO THE AXIS
LINE. THIS PARAMETER MAY BE AN ALPHANUMERIC ARRAY, OR IT
MAY BE AN ASCII LITERAL.THE CHARACTERS HAVE A FIXED HEIGHT
OF .14 INCHES.
IF TITLE IS ALL BLANK AND MAGNITUDE OF NCHAR = 1 THEN NO
LABELS ARE DRAWN.
PLOTS STANDARD PLOT PACKAGE Page 22
AXIS
+OR-NCHAR SPECIES THE NUMBER OF CHARACTERS IN THE AXIS TITLE, AND
DETERMINES BY ITS SIGN WHICH SIDE OF THE LINE THE SCALE
(TICK) MARKS AND LABELING INFORMATION SHALL BE PLACED.
SINCE THE AXIS LINE MAY BE DRAWN AT ANY ANGLE, THE LINE
ITSELF IS USED AS A REFERENCE.
IF THE SIGN IS POSITIVE, ALL ANNOTATION APPEARS ON THE
POSITIVE (COUNTERCLOCKWISE) SIDE OF THE AXIS, WHICH
CONDITION IS NORMALLY DESIRED FOR THE Y-AXIS.
IF THE SIGN IS NEGATIVE, ALL ANNOTATION APPEARS ON THE
NEGATIVE (CLOCKWISE) SIDE OF THE AXIS, WHICH CONDITION IS
NORMALLY DESIRED FOR THE X-AXIS.
IF THE MAGNITUDE OF NCHAR =1 AND IBCD (TITLE) IS BLANK NO
LABELS WILL BE DRAWN.
NCHAR MUST BE AN INTEGER!
AXLEN = THE LENGTH OF THE AXIS LINE IN INCHES.
IF AXLEN IS NEGATIV THEN NO SCALE NUMBERS WILL BE DRAWN BY
THE TICK MARKS.
ANGLE = THE ANGLE, IN POSITIVE OR NEGATIVE DEGREES, AT WHICH THE
AXIS IS TO BE DRAWN. NORMALLY, THIS VALUE IS ZERO FOR THE
X-AXIS AND 90.0 FOR THE Y-AXIS.
FIRSTV = THE STARTING VALUE (EITHER MINIMUM OR MAXIMUM) WHICH WILL
APPEAR AT THE FIRST TICK MARK ON THE AXIS. THIS VALUE MAY
BE COMPUTED BY THE "SCALE" SUBROUTINE AND STORED AT
SUBSCRIPTED LOCATION "ARRAY(NPTS*INC+1)", OR MAY BE
DETERMINED BY THE USER AND STORED ANYWHERE.
THIS NUMBER AND EACH SCALE VALUE ALONG THE AXIS IS ALWAYS
DRAWN WITH TWO DECIMAL PLACES. SINCE THE DIGIT SIZE IS
0.105 INCH (ABOUT 10 CHARACTERS PER INCH), AND SINCE A SCALE
VALUE APPEARS EVERY INCH , NO MORE THAN SIX DIGITS AND A
SIGN SHOULD APPEAR AT THE LEFT OF THE DECIMAL POINT
DELTAV = THE NUMBER OF DATA UNITS PER INCH OF AXIS. THIS VALUE
(INCREMENT OR DECREMENT), WHICH IS ADDED TO "FIRSTV" FOR
EACH SUCCEEDING ONE-INCH DIVISION ALONG THE AXIS, MAY BE
COMPUTED BY "SCALE" AND STORED BEYOND "FIRSTV" AT
"ARRAY(NPTS*INC+INC+1)", OR MAY BE DETERMINED BY THE USER
AND STORED ANYWHERE.
IN ORDER TO USE A STANDARD FORMAT OF TWO DECIMAL PLACES, THE
SIZE OF "DELTAV" IS ADJUSTED TO LESS THAN 100 (FOR TEKTRONIX
4010 OR LESS THAN 1000 IF USING CALCOMP). BUT NOT LESS THAN
.01. AS A RESULT, THE DECIMAL POINT MAY BE SHIFTED LEFT OR
RIGHT IN THE SCALE VALUES AS DRAWN, AND THE AXIS TITLE IS
THEN FOLLOWED BY "*10N," WHERE N IS THE POWER-OF-TEN
ADJUSTMENT FACTOR, UNLESS FMT ARGUMENT IS SPECIFIED.
PLOTS STANDARD PLOT PACKAGE Page 23
AXIS
THE FOLLOWING ARGUMENTS ARE OPTIONAL
SEGLN = THE DISTANCE BETWEEN TICK MARKS ON THE AXIS IN INCHES. IF
AXIS IS CALLED WITH ONLY 8 ARGUMENTS SEGLN IS SET TO 1.0.
SEGLN IS MULTIPLIED BY DELTAV TO DETERMINE HOW MANY
UNITS/TIC MARK.
NROT = THE NUMBER OF 90 DEGREE, (COUNTERCLOCKWISE) ROTATIONS OF THE
SCALE VALUES, RELATIVE TO THEIR ORIGINAL POSITION WHICH IS
PARALLEL TO THE AXIS. USUALLY NROT = 0. ON PLOTTING X-AXIS
WITH NROT NOT = 0 THE AXIS SHOULD BE PLOTTED AT LEAST 1 INCH
FROM THE MARGIN TO ALLOW ROOM FOR THE SCALE VALUES.
FMT = IF AXIS IS CALLED WITH 8 OR 9 ARGUMENTS THE SCALE VALUES
WILL BE DRAWN WITH A FORMAT OF (F6.2). THE USER
MAY,HOWEVER, SPECIFY ANY OTHER FORMAT IN THE FORM OF AN
ASCII LITERAL, HOWEVER THE TOTAL FIELD WIDTH SHOULD NOT
EXCEED 10.
IDELTA = INTEGER VALUE OF UNITS/TIC MARK WHICH YOU MUST SPECIFY IF
YOU WANT TO HAVE SCALE NUMBERS AS INTEGERS.THIS IMPLIES FMT
IS AN INTEGER FORMAT SPECIFICATION.
PLOTS STANDARD PLOT PACKAGE Page 24
LINE
LINE
AUTHOR: PETE CLARK
******************
THE "LINE" SUBROUTINE PRODUCES A LINE PLOT OF THE PAIRS
OF DATA VALUES IN TWO ARRAYS (X AND Y). "LINE" COMPUTES THE
PAGE COORDINATES OF EACH PLOTTED POINT ACCORDING TO THE DATA
VALUES IN EACH ARRAY AND THE RESPECTIVE SCALING PARAMETERS.
THE DATA POINTS MAY BE REPRESENTED BY CENTERED SYMBOLS
AND/OR CONNECTING LINES BETWEEN POINTS.
THE SCALING PARAMETERS CORRESPONDING TO "FIRSTV" AND
"DELTAV" (SEE "SCALE") MUST IMMEDIATELY FOLLOW EACH ARRAY.
IF THESE PARAMETERS HAVE NOT BEEN COMPUTED BY THE "SCALE"
SUBROUTINE THEY MUST BE SUPPLIED BY THE USER.
THE SUBROUTINE CALLING SEQUENCE HAS SIX ARGUMENTS. THE
FIRST TWO MUST BE FLOATING POINT ARRAYS AND THE LAST FOUR
MUST BE INTEGER.
BEFORE CALLING LINE, SET ORIGIN (CALL PLOT X,Y,-3) TO
LOWER LEFT HAND CORNER OF GRAPHING AREA.
CALL LINE(XARRAY,YARRAY,NPTS,INC,LINTYP,INTEQ)
XARRAY = THE NAME OF THE ARRAY CONTAINING THE ABSCISSA (X) VALUES AND
THE SCALING PARAMETERS FOR THE X-ARRAY.
YARRAY = THE NAME OF THE ARRAY CONTAINING THE ORDINATE (Y) VALUES AND
THE SCALING PARAMETERS FOR THE Y-ARRAY.
NPTS = THE NUMBER OF DATA POINTS IN EACH OF THE TWO ARRAYS JUST
MENTIONED TO BE PLOTTED.THE NUMBER DOES NOT INCLUDE THE
EXTRA TWO LOCATIONS FOR THE SCALING PARAMETERS. THE NUMBER
OF POINTS IN EACH ARRAY MUST BE THE SAME.
INC = THE INCREMENT THAT THE "LINE" SUBROUTINE IS TO USE IN
GATHERING DATA FROM THE TWO ARRAYS, AS DESCRIBED FOR THE
"SCALE" SUBROUTINE.
PLOTS STANDARD PLOT PACKAGE Page 25
LINE
LINTYP = IS A CONTROL PARAMETER WHICH DESCRIBES THE TYPE OF LINE TO
BE DRAWN THROUGH THE DATA POINTS. THE MAGNITUDE OF "LINTYP"
DETERMINES THE FREQUENCY OF PLOTTED SYMBOLS; E.G., IF
"LINTYP"=4, A SPECIAL SYMBOL (DENOTED BY "INTEQ") IS PLOTTED
AT EVERY FOURTH DATA POINT.
IF "LINTYP" = 0, THE POINTS ARE CONNECTED BY STRAIGHT
LINES BUT NO SYMBOLS ARE PLOTTED.
IF "LINTYP" IS POSITIVE, A STRAIGHT LINE CONNECTS EVERY
DATA POINT DEFINED IN THE ARRAY. ( THE PEN IS UP WHEN
MOVING FROM ITS CURRENT POSITION TO THE FIRST POINT.)
IF "LINTYP" IS NEGATIVE, NO CONNECTING LINES ARE DRAWN;
ONLY THE SYMBOLS ARE PLOTTED.
INTEQ = THE INTEGER EQUIVALENT OF THE SPECIAL PLOTTING SYMBOL
CENTERED AT EACH DATA POINT.THIS VALUE CAN BE 1-8, AND HAS
MEANING ONLY WHEN "LINTYP" IS NOT ZERO. THE DOCUMENTATION
FOR "POINT" IN THE "PLOT" DOCUMENTATION HAS A LIST OF THE
AVAILABLE SYMBOLS.SOME OF THESE SYMBOLS ARE:
BOX,DIAMOND,TRIANGLE,X,AND ASTERISK.
IF INTEQ < 0 THEN A DASHED LINE WILL BE DRAWN WITH THE
LENGTH OF THE DASHES = THE LENGTH OF THE SPACES =
IABS(INTEQ)/10. INCHES.
IF INTEQ < 0 AND LINTYP < 0 THEN AS ABOVE EXCEPT LENGTH OF
SPACES = IABS(LINTYP)/10. INCHES.
IF INTEQ < 0 AND LINTYP > 0 THEN AS ABOVE BUT IN ADDITION
LINTYP REPRESENTS THE CHARACTER TO BE PLOTTED IN THE MIDDLE
OF THE SPACE. IF LINTYP > THAN OCTAL 37 THEN IT WILL BE
INTERPRETED AS A RIGHT JUSTIFIED ASCII CHARACTER.
NOTE: THE PEN POSITION MUST BE AT THE ORIGIN BEFORE CALLING
"LINE". THIS IS BECAUSE ON ENTERING THE "LINE" ROUTINE THE
CURRENT PEN POSITION MUST BE SET AS THE ORIGIN. THE "AXIS"
ROUTINE LEAVES THE PEN AT THE BEGINNING OF THE AXIS (USUALLY
THE ORIGIN).
PLOTS STANDARD PLOT PACKAGE Page 26
FLINE
FLINE
AUTHOR: SERGE SCHREMMER
***********************
THE "FLINE" SUBROUTINE PERFORMS THE SAME AS "LINE" WITH
ONE ADDITIONAL FEATURE.THE SEVENTH ARGUMENT SPECIFIES A
SMOOTH CURVE,RATHER THAN A STRAIGHT LINE,TO BE DRAWN BETWEEN
THE POINTS.THIS CURVE IS DRAWN USING A MODIFIED CUBIC
SPLINE-FITTING TECHNIQUE.
CALL FLINE(XARRAY,YARRAY,NPTS,INC,LINTYP,INTEQ,INCH)
THE FIRST SIX ARGUMENTS ARE THOSE DEFINED IN "LINE" ABOVE.
INCH = THE NUMBER OF POINTS/INCH TO BE INTERPOLATED.A RECOMMENDED
MINIMUM IS 10.IF 0 IS USED A DEFAULT VALUE OF 10 IS
INSERTED.
NOTE: THE SUBROUTINE WILL NOT WORK IF THE NUMBER OF GIVEN
POINTS IN RELATION TO THE CURVATURE IS TOO SMALL.THERE IS A
LIMIT OF 1000 INTERPOLATED POINTS.TO CALCULATE THIS VALUE
MULTIPLY YOUR AXIS LENTH BY "INCH".
PLOTS STANDARD PLOT PACKAGE Page 27
POINT
POINT
*****
AUTHOR: JACK LONDON
*******************
THIS SUBROUTINE ALLOWS THE USER TO DENOTE DATA POINTS
ON A GRAPH. THIS CALL IS EQUIVALENT TO THE (SPECIAL SYMBOL
CALL). AFTER MOVING TO THE DATA POINT (XPAGE,YPAGE) WITH
THE PEN EITHER UP OR DOWN, ANY ONE OF EIGHT SYMBOLS MAY BE
DRAWN. THE DATA POINT IS AT THE CENTER OF THE SYMBOL.
THE "POINT" CALL HAS SIX ARGUMENTS:
CALL POINT(XPAGE,YPAGE,HEIGHT,I,ANGLE,J)
XPAGE, ARE THE COORDINATES OF THE POINT TO BE PLOTTED AND
YPAGE AND THE CENTER OF THE SYMBOL TO BE DRAWN.
HEIGHT IS THE HEIGHT OF THE SYMBOL IN INCHES (MINIMUM=.07).
I IS THE CODE FOR THE SYMBOL DESIRED.
1. 5.
2. 6.
3. 7.
4. 8.
ANGLE IS THE ANGLE AT WHICH THE SYMBOL IS TO BE DRAWN.
J INDICATES WHETHER THE PEN IS TO BE UP OR DOWN WHEN MOVING TO
THE POINT.
J=2, PEN DOWN, (CONNECTED POINTS)
J=3, PEN UP, (UNCONNECTED POINTS)
PLOTS STANDARD PLOT PACKAGE Page 28
POINT
SPECIAL "POINT" CALL:
CALL POINT(XPAGE,YPAGE,SYM)
FOR THE CALCOMP THIS DRAWS THE LEFT JUSTIFIED (SYM=1H?)
SYMBOL IN "SYM" CENTERED AT POINT (XPAGE,YPAGE). THE SIZE
IS .15 INCHES WITH NO ROTATION.
FOR THE TEKTRONIX 4010-1 THE SYMBOL IS TYPED RATHER
THAN DRAWN (THIS IS MUCH FASTER), BUT IS STILL CENTERED AT
(XPAGE,YPAGE).
PLOTS STANDARD PLOT PACKAGE Page 29
WINDOW
******
WINDOW
AUTHOR:PETE CLARK
*****************
WINDOW This software allows the user to specify an area
______
of the screen (or plotter) as a "WINDOW". Movements outside
the window will not be shown, but the pen orientation will
be maintained correctly even if outside the window. This is
useful if you do not want wrap around on Tektronix to occur
for example.
There are two (2) calls to the "WINDOW" software.
CALL SETWIN (XMINX,XMINY,XMAXX,XMAXY)
All arguments must be real numbers. All values are in
inches.
XMINX Minimum X value of window
XMINY Minimum Y value of window
XMAXX Maximum X value of window
XMAXY Maximum Y value of window
The "SETWIN" call is used to specify that you wish to
invoke windowing and also to specify window.
CALL CLRWIN
This call is used to disable windowing. Default
condition.
INDEX
Axis . . . . . . . . . . . . . 21
Clrwin . . . . . . . . . . . . 29
Factor . . . . . . . . . . . . 11
Fline . . . . . . . . . . . . 26
Fsetof . . . . . . . . . . . . 13
Fseton . . . . . . . . . . . . 13
Lasplt . . . . . . . . . . . . 12
Line . . . . . . . . . . . . . 24
Mnumbr . . . . . . . . . . . . 17
Number . . . . . . . . . . . . 18
Offset . . . . . . . . . . . . 13
Plot . . . . . . . . . . . . . 8
Plots . . . . . . . . . . . . 10
Point . . . . . . . . . . . . 27
Scale . . . . . . . . . . . . 19
Setwin . . . . . . . . . . . . 29
Symbol . . . . . . . . . . . . 14
Where . . . . . . . . . . . . 11
Window . . . . . . . . . . . . 29