Previous: grfav Up: ../plot79_g.html Next: grfci


GRFAX3

       SUBROUTINE  GRFAX3 (KXYZ, X,Y,Z, TITLE,NCHAR, SIZE, VMIN,DV,VMAX,
      X     TICK, MODE)
 C$    (3-D Coordinate Axis)
 C$    Select an appropriate lettering plane and draw a 3-D  axis.
 C$    This routine provides a convenient interface to the general
 C$    3-D axis routine, PLTAX3.  The  axis will be suppressed  if
 C$    it lies along the view plane normal.  The arguments are:
 C$
 C$    KXYZ...........Axis selection code: 1 = X axis, 2 = Y axis,
 C$                   3 = Z axis.  Any other value will raise an
 C$                   error condition and cause immediate return.
 C$    (X,Y,Z)........3-D world coordinates of origin of axis.
 C$                   The coordinate system may be either
 C$                   right-handed or left-handed.
 C$
 C$    The remaining variables are exactly those passed to  PLTAX,
 C$    the descriptions of which follow:
 C$
 C$    TITLE...Hollerith label for the axis.  This is always drawn
 C$            centered along the axis in the direction away  from
 C$            (X,Y).  Very long titles will be drawn with smaller
 C$            characters in order  to fit on  one line.   Leading
 C$            and trailing blanks  are automatically ignored  for
 C$            the purposes of centering.
 C$
 C$    NCHAR... .GT. 0 - Number of characters in TITLE(*).  The
 C$                      current font will be used.
 C$             .LE. 0 - No title to be drawn.
 C$
 C$    SIZE....Length of the axis in world units.  SIZE .LE. 0.0
 C$            will be  assumed to  be bad  input and  will  cause
 C$            immediate return.
 C$
 C$    VMIN....Starting value of variable along axis.
 C$
 C$    DV......Increment of  variable  between  successive  ticks.
 C$            Numbering will be placed at each tick, if there  is
 C$            sufficient space.  Otherwise, numbering will be  at
 C$            intervals of 2, 5, or 10 ticks, or at some power of
 C$            ten  times  one  of  these.   It  is  the  caller's
 C$            responsibility to ensure  that (VMAX-VMIN)/DV is  a
 C$            positive integer.
 C$
 C$    VMAX....Ending value of variable along axis.
 C$
 C$    TICK.... .GT. 0.0 - Length of tick marks above
 C$                        (counterclockwise from) the axis.
 C$             .EQ. 0.0 - No tick marks to be drawn.
 C$             .LT. 0.0 - Length of tick marks below (clockwise
 C$                        from) the axis.
 C$            A usual  value will  be TICK  = 0.015  on the  unit
 C$            square, but choosing  TICK equal to  the length  of
 C$            the perpendicular axes will form a grid.
 C$
 C$    MODE......Option flags stored in the low-order bits of  the
 C$              integer value.  These are selected by adding  one
 C$              or more of the following option values, and  then
 C$              setting the sign of  the resulting sum to  select
 C$              numbering and titling above (+) or below (-)  the
 C$              axis.
 C$
 C$               1 - Number  the  axis.   Even  values  of   MODE
 C$                   suppress numbering,  but  still  affect  the
 C$                   choice of tick mark spacing.
 C$               2 - Numbering   perpendicular (i.e. rotated  -90
 C$                   degrees)  to  the  axis;  otherwise  it   is
 C$                   parallel to the axis.
 C$               4 - Omit the first number along the axis.   This
 C$                   can be useful to  prevent text overlap  when
 C$                   more than one axis is drawn from a point.
 C$               8 - Omit the last number along the axis.
 C$              16 - Omit any zero number  along the axis.   This
 C$                   can be useful for drawing axes  intersecting
 C$                   at the origin.
 C$
 C$              Any value outside the  legal range -31..+31  will
 C$              raise an error condition.  The usual choice for a
 C$              numbered left vertical  (Y) axis will  be MODE  =
 C$              +3, and for a numbered lower horizontal (X)  axis
 C$              will be  MODE  = -1.   The  usual choice  for  an
 C$              unnumbered right vertical axis will be MODE =  +2
 C$              or -2,  and for  an unnumbered  upper  horizontal
 C$              axis will be MODE =  0.
 C$
 C$              The sizes and positions of number labels, even if
 C$              they are not  drawn, affect the  choice of  where
 C$              longer tick marks are drawn.  In the common  case
 C$              where the four  sides of a  graph have axes,  but
 C$              two are  unnumbered,  for  the  unnumbered  axes,
 C$              simply subtract 1  from the  unsigned MODE  value
 C$              used for the opposite numbered axis.
 C$
 C$    See subroutine PLTAX for further remarks on axis plotting.
 C$
 C$    (19-MAR-84)