The .table line defines a tabulation of data points which can be referenced from other lines in the SPICE file. The data are listed in sequence with respect to the ordinate x_{N} . The elements are separated by white space or commas, and may optionally be surrounded by parentheses. Generally, the table construct consists of many lines, using the `+' or backslash line continuation mechanism. When a table is referenced, the data value returned is interpolated from the values in the table.
The x_{i} in the .table line are values of the independent variable (i.e., the variable given as an argument to the referencing function). The v_{i} entries can be numbers, or a reference to another table in the form
table subtab_namein which case that table will be referenced to resolve the data point.
If the ac keyword is given, the data numbers v_{i} are expected to be complex values, which are expressed as two values; the real value followed by the imaginary value. Any sub-tables referenced must also have the ac keyword given. The ac tables provide data for frequency-domain analysis. Without ac, all values are real, and the table is intended for use in dc or transient analysis.
A non-ac table is referenced through a tran-function (see 2.15.3). Tables with the ac keyword given are referenced through the ac keyword in dependent and independent sources (see 2.15 and 2.15.4).
Let x be the input variable associated with the device referencing a table. The table is evaluated as follows:
x < x_{0} | val = v_{0}(x_{0}) |
x_{0} < < x_{1} |
val = v_{0}()
if v_{0}
is a table
val = interpolation of v_{0}(x_{0}) and v_{1}(x_{1}) if v_{0} is a number ... |
x > x_{N} |
val = v_{N}()
if v_{N}
is a table
val = v_{N} if v_{N} a number val = v_{N-1}(x_{N}) if v_{N} is omitted |
See the section A.3 for sample input files which illustrate the use of the .table line.