> On 31/05/10 12:04 PM, Garrett D'Amore wrote:
>> I need a quickie code review... just Makefile and packaging really.
>> This cleans up graph and spline, which will enable a bunch of other
>> lpsched and postscript conversion cleanups.  (Ultimately this
>> facilitates removal of SysV lpched and replacement with CUPS. :-)
>>
>> http://cr.opensolaris.org/~gdamore/graph/
>>
>> I've filed a CR on this as well, but have not received the CR number
>> yet.
>
>
> 6957126
>
> I think the code is ok, but I'm not sure what the packaging
> scene is these days, sorry.
>

When I saw this I had my first cup of coffee and the thought passed across
my mind "hold on, are things like plot(4B) still around?" and now I almost
feel motivated to go look. I am surprised that graph(1) and spline(1) were
still around at all.

For the sake of the maillist .. here are the man pages from those very
very old guys ( from Solaris 8 ):

$ man graph
Reformatting page.  Please Wait... done

User Commands                                            graph(1)

NAME
     graph - draw a graph

SYNOPSIS
     graph [  -a spacing  [ start ]  ]  [ -b ]  [ -c string ]   [
     -g gridstyle  ]  [ -l label ]  [ -m connectmode ]  [ -s ]  [
     -x  [ l ]  lower  [   upper  [ spacing ]  ]  ]  [  -y  [ l ]
     lower   [   upper   [  spacing  ]   ]  ]  [ -h fraction ]  [
     -w fraction ]  [ -r fraction ]  [  -u fraction  ]   [  -t  ]
     ...

DESCRIPTION
     graph with no options takes pairs of numbers from the  stan-
     dard  input as abscissaes and ordinates of a graph.  Succes-
     sive points are connected by straight lines.   The  standard
     output  from  graph  contains plotting instructions suitable
     for input  to  plot(1B)  or  to  the  command  lpr  -g  (see
     lpr(1B)).

     If the coordinates of a point are followed by  a  nonnumeric
     string,  that  string is printed as a label beginning on the
     point. Labels may be surrounded with quotes "...", in  which
     case they may be empty or contain blanks and numbers; labels
     never contain NEWLINE characters.

     A legend indicating grid  range  is  produced  with  a  grid
     unless the -s option is present.

OPTIONS
     Each option is recognized  as  a  separate  argument.  If  a
     specified  lower  limit exceeds the upper limit, the axis is
     reversed.

     -a spacing[ start ]
           Supply abscissaes automatically (they are missing from
           the  input); spacing is the spacing (default 1). start
           is  the  starting  point  for   automatic   abscissaes
           (default 0 or lower limit given by -x).

     -b    Break (disconnect) the graph after each label  in  the
           input.

     -c string
           String is the default label for each point.

     -g gridstyle
           Gridstyle is the grid style: 0 no grid, 1  frame  with
           ticks, 2 full grid (default).

     -l label
           label is label for graph.

SunOS 5.8           Last change: 14 Sep 1992                    1

User Commands                                            graph(1)

     -m connectmode
           Mode (style) of connecting lines:  0  disconnected,  1
           connected  (default).   Some devices give distinguish-
           able line styles for other small integers.

     -s    Save screen, do not erase before plotting.

     -x [ l ] lower [ upper [ spacing ] ]
           If l is present, x  axis  is  logarithmic.  lower  and
           upper  are  lower  (and  upper) x limits.  spacing, if
           present, is grid spacing on x  axis.   Normally  these
           quantities are determined automatically.

     -y [ l ] lower [ upper [ spacing ] ]
           If l is present, y  axis  is  logarithmic.  lower  and
           upper  are  lower  (and  upper) y limits.  spacing, if
           present, is grid spacing on y  axis.   Normally  these
           quantities are determined automatically.

     -h fraction
           fraction of space for height.

     -w fraction
           fraction of space for width.

     -r fraction
           fraction of space to move right before plotting.

     -u fraction
           fraction of space to move up before plotting.

     -t    Transpose horizontal and vertical axes. Option -x  now
           applies to the vertical axis.

ATTRIBUTES
     See attributes(5) for descriptions of the  following  attri-
     butes:

     ____________________________________________________________
    |       ATTRIBUTE TYPE        |       ATTRIBUTE VALUE       |
    |_____________________________|_____________________________|
    | Availability                | SUNWesu                     |
    |_____________________________|_____________________________|

SEE ALSO
     lpr(1B), plot(1B), spline(1), plot(3PLOT), attributes(5)

BUGS
     graph stores all points internally and drops those for which
     there is no room.

SunOS 5.8           Last change: 14 Sep 1992                    2

User Commands                                            graph(1)

     Segments that run out of bounds are dropped, not windowed.

     Logarithmic axes may not be reversed.

SunOS 5.8           Last change: 14 Sep 1992                    3

$ man spline
Reformatting page.  Please Wait... done

User Commands                                           spline(1)

NAME
     spline - interpolate smooth curve

SYNOPSIS
     spline [ -aknpx ]   ...

DESCRIPTION
     spline takes pairs of numbers from  the  standard  input  as
     abcissas  and ordinates of a function. It produces a similar
     set, which is approximately equally spaced and includes  the
     input  set,  on the standard output. The cubic spline output
     (R.  W.  Hamming,  Numerical  Methods  for  Scientists   and
     Engineers,2nd  ed.,  349ff)  has two continuous derivatives,
     and sufficiently many points to look  smooth  when  plotted,
     for example by graph(1).

OPTIONS
     -a    Supply abscissas automatically (they are missing  from
           the  input); spacing is given by the next argument, or
           is assumed to be 1 if next argument is not a number.

     -k    The constant k used in the boundary value computation

           (2nd deriv. at end) = k*(2nd deriv. next to end)

           is set by the next argument. By default k = 0.

     -n    Space output points so that approximately n  intervals
           occur  between the lower and upper x limits.  (Default
           n = 100.)

     -p    Make output periodic, that is,  match  derivatives  at
           ends.  First  and  last  input  values should normally
           agree.

     -x    Next 1 (or 2) arguments are lower (and upper)  x  lim-
           its.   Normally  these  limits are calculated from the
           data. Automatic abcissas start at lower limit (default
           0).

ATTRIBUTES
     See attributes(5) for descriptions of the  following  attri-
     butes:

     ____________________________________________________________
    |       ATTRIBUTE TYPE        |       ATTRIBUTE VALUE       |
    |_____________________________|_____________________________|
    | Availability                | SUNWesu                     |
    |_____________________________|_____________________________|

SunOS 5.8           Last change: 14 Sep 1992                    1

User Commands                                           spline(1)

SEE ALSO
     graph(1), attributes(5)

     R.  W.  Hamming,  Numerical  Methods  for   Scientists   and
     Engineers, 2nd ed.

DIAGNOSTICS
     When data is not strictly monotonic in x, spline  reproduces
     the input without interpolating extra points.

BUGS
     A limit of 1000 input points is enforced silently.

SunOS 5.8           Last change: 14 Sep 1992                    2

$

Now I *almost* feel motivated to go looking for the oldest old-geek binary
hiding in there. I recall using plot(1B) once upon a time but again that
is from the UCB world.

Anyways ... good morning.

Dennis


_______________________________________________
opensolaris-code mailing list
opensolaris-code@opensolaris.org
http://mail.opensolaris.org/mailman/listinfo/opensolaris-code

Reply via email to