| 1 |
.\" RCSid "$Id: tabfunc.1,v 1.2 2003/12/09 15:59:07 greg Exp $" |
| 2 |
.TH TABFUNC 1 10/8/97 RADIANCE |
| 3 |
.SH NAME |
| 4 |
tabfunc - convert table to functions for rcalc, etc. |
| 5 |
.SH SYNOPSIS |
| 6 |
.B tabfunc |
| 7 |
[ |
| 8 |
.B \-i |
| 9 |
] |
| 10 |
func1 [func2 ..] |
| 11 |
.SH DESCRIPTION |
| 12 |
.I Tabfunc |
| 13 |
reads a table of numbers from the standard input and converts it to |
| 14 |
an expression suitable for |
| 15 |
.I icalc(1), |
| 16 |
.I rcalc(1) |
| 17 |
and their cousins. |
| 18 |
The input must consist of a M x N matrix of real numbers, with exactly |
| 19 |
one row per line. |
| 20 |
The number of columns must always be the same in each line, |
| 21 |
separated by whitespace and/or commas, with no missing values. |
| 22 |
The first column is always the independent variable, whose value |
| 23 |
indexes all of the other elements. |
| 24 |
This value does not need to be evenly spaced, but it must be either |
| 25 |
monotonically increasing or monotonically decreasing. |
| 26 |
(I.e. it cannot go up and then down, or down and then up.)\0 |
| 27 |
Maximum input line width is 4096 characters and the maximum number of |
| 28 |
data rows is 1024. |
| 29 |
Input lines not beginning with a numerical value will be silently ignored. |
| 30 |
.PP |
| 31 |
The command-line arguments given to |
| 32 |
.I tabfunc |
| 33 |
are the names to be assigned to each column. |
| 34 |
.I Tabfunc |
| 35 |
then produces a single function for each column given. |
| 36 |
If there are some columns which should be skipped, the dummy name |
| 37 |
"0" may be given instead of a valid identifier. |
| 38 |
(It is not necessary to specify a dummy name for extra columns at |
| 39 |
the end of the matrix.)\0 |
| 40 |
.PP |
| 41 |
The |
| 42 |
.I \-i |
| 43 |
option causes |
| 44 |
.I tabfunc |
| 45 |
to produce a description that will interpolate values in between |
| 46 |
those given for the independent variable on the input. |
| 47 |
.SH EXAMPLE |
| 48 |
To convert a small data table and feed it to rcalc for some |
| 49 |
calculation: |
| 50 |
.IP "" .2i |
| 51 |
rcalc -e `tabfunc f1 f2 < table.dat` -f com.cal |
| 52 |
.SH AUTHOR |
| 53 |
Greg Ward |
| 54 |
.SH "SEE ALSO" |
| 55 |
cnt(1), icalc(1), neaten(1), rcalc(1), rlam(1), total(1) |