minor rewording, no fixes
[unix-history] / usr / src / usr.bin / spline / spline.1
CommitLineData
94bed826
KB
1.\" Copyright (c) 1990 The Regents of the University of California.
2.\" All rights reserved.
30e5e182 3.\"
94bed826
KB
4.\" %sccs.include.proprietary.roff%
5.\"
6.\" @(#)spline.1 6.3 (Berkeley) %G%
daacd5f0
CL
7.\"
8.TH SPLINE 1 "%Q"
30e5e182
KM
9.AT 3
10.SH NAME
11spline \- interpolate smooth curve
12.SH SYNOPSIS
13.B spline
14[ option ] ...
15.SH DESCRIPTION
16.I Spline
17takes pairs of numbers from the standard input as abcissas and ordinates
18of a function.
19It produces a similar set, which
20is approximately equally spaced and
21includes the input set, on the standard output.
22The cubic spline output
23(R. W. Hamming,
24.ft I
25Numerical Methods for Scientists and Engineers,
26.ft R
272nd ed., 349ff)
28has two continuous derivatives,
29and sufficiently many points to look smooth when plotted, for
30example by
203f7bf7 31.IR graph (1G).
30e5e182
KM
32.PP
33The following options are recognized,
34each as a separate argument.
35.TP 5
36.B \-a
37Supply abscissas automatically (they are missing from
38the input); spacing is given by the next
39argument, or is assumed to be 1 if next argument is not a number.
40.TP 5
41.B \-k
42The constant
43.IR k ""
44used in the boundary value computation
45.IP
46.if n .ig
47.ti +1.5i
48.ds ' \h'-\w'\(fm\(fm'u'
49.EQ
50.nr 99 \n(.s
51.nr 98 \n(.f
52'ps 10
53.ft I
54.ds 11 "y\(fm\(fm
55.nr 11 \w'\*(11'
56.ds 12 "\*'
57.nr 12 \w'\*(12'
58'ps 8
59.ds 13 "\fR0\fP
60.nr 13 \w'\*(13'
61.as 12 \v'18u'\s8\*(13\|\s10\v'-18u'
62'ps 10
63.nr 12 \n(12+\n(13+\w'\s8\|'
64.as 11 "\*(12
65.nr 11 \w'\*(11'
66.ds 12 "\|\|
67.nr 12 \w'\*(12'
68.as 11 "\*(12
69.nr 11 \w'\*(11'
70.ds 12 "\|=\|
71.nr 12 \w'\*(12'
72.as 11 "\*(12
73.nr 11 \w'\*(11'
74.ds 12 "\|\|
75.nr 12 \w'\*(12'
76.as 11 "\*(12
77.nr 11 \w'\*(11'
78.ds 12 "ky\(fm\(fm
79.nr 12 \w'\*(12'
80.as 11 "\*(12
81.nr 11 \w'\*(11'
82.ds 12 "\*'
83.nr 12 \w'\*(12'
84'ps 8
85.ds 13 "\fR1\fP
86.nr 13 \w'\*(13'
87.as 12 \v'18u'\s8\*(13\|\s10\v'-18u'
88'ps 10
89.nr 12 \n(12+\n(13+\w'\s8\|'
90.as 11 "\*(12
91.nr 11 \w'\*(11'
92.ds 12 ",
93.nr 12 \w'\*(12'
94.as 11 "\*(12
95.nr 11 \w'\*(11'
96.ds 12 "\|\|
97.nr 12 \w'\*(12'
98.as 11 "\*(12
99.nr 11 \w'\*(11'
100.ds 12 "\|\|
101.nr 12 \w'\*(12'
102.as 11 "\*(12
103.nr 11 \w'\*(11'
104.ds 12 "\|\|
105.nr 12 \w'\*(12'
106.as 11 "\*(12
107.nr 11 \w'\*(11'
108.ds 12 "y\(fm\(fm
109.nr 12 \w'\*(12'
110.as 11 "\*(12
111.nr 11 \w'\*(11'
112.ds 12 "\*'
113.nr 12 \w'\*(12'
114'ps 8
115.ds 13 "n
116.nr 13 \w'\*(13'
117.as 12 \v'18u'\s8\*(13\|\s10\v'-18u'
118'ps 10
119.nr 12 \n(12+\n(13+\w'\s8\|'
120.as 11 "\*(12
121.nr 11 \w'\*(11'
122.ds 12 "\|\|
123.nr 12 \w'\*(12'
124.as 11 "\*(12
125.nr 11 \w'\*(11'
126.ds 12 "\|=\|
127.nr 12 \w'\*(12'
128.as 11 "\*(12
129.nr 11 \w'\*(11'
130.ds 12 "\|\|
131.nr 12 \w'\*(12'
132.as 11 "\*(12
133.nr 11 \w'\*(11'
134.ds 12 "ky\(fm\(fm
135.nr 12 \w'\*(12'
136.as 11 "\*(12
137.nr 11 \w'\*(11'
138.ds 12 "\*'
139.nr 12 \w'\*(12'
140'ps 8
141.ds 13 "n\|\(mi\|\fR1\fP
142.nr 13 \w'\*(13'
143.as 12 \v'18u'\s8\*(13\|\s10\v'-18u'
144'ps 10
145.nr 12 \n(12+\n(13+\w'\s8\|'
146.as 11 "\*(12
147.nr 11 \w'\*(11'
148.ds 11 \x'0'\fI\*(11\s\n(99\f\n(98
149.ne 78u
150\*(11
151'ps \n(99
152.ft \n(98
153.EN
154..
155.if t .ig
156.ce
157(2nd deriv. at end) = k*(2nd deriv. next to end)
158..
159.IP
160.br
161is set by the next argument.
162By default
163.IR k ""
164= 0.
165.TP 5
166.B \-n
167Space output points
168so that approximately
169.I n
170intervals occur between the lower and upper
171.I x
172limits.
173(Default
174.I n
175= 100.)
176.TP 5
177.B \-p
178Make output periodic, i.e. match
179derivatives at ends.
180First and last input values should normally agree.
181.TP 5
182.B \-x
183Next
1841 (or 2) arguments are lower (and upper)
185.I x
186limits.
187Normally these limits are calculated from the data.
188Automatic abcissas start at lower limit
189(default 0).
190.SH "SEE ALSO"
daacd5f0 191graph(1), plot(1)
30e5e182
KM
192.SH DIAGNOSTICS
193When data is not strictly monotone in
194.I x,
195.I spline
196reproduces the input without interpolating extra points.
197.SH BUGS
198A limit of 1000 input points is enforced silently.