INTTABLE8 - Interpolation of a uniformly-sampled complex function y(x) via a table of 8-coefficient interpolators intt8c interpolation of a uniformly-sampled complex function y(x) via a table of 8-coefficient interpolators intt8r interpolation of a uniformly-sampled real function y(x) via a table of 8-coefficient interpolators Function Prototype: void intt8c (int ntable, float table[][8], int nxin, float dxin, float fxin, complex yin[], complex yinl, complex yinr, int nxout, float xout[], complex yout[]); void intt8r (int ntable, float table[][8], int nxin, float dxin, float fxin, float yin[], float yinl, float yinr, int nxout, float xout[], float yout[]); Input: ntable number of tabulated interpolation operators; ntable>=2 table array of tabulated 8-point interpolation operators nxin number of x values at which y(x) is input dxin x sampling interval for input y(x) fxin x value of first sample input yin array of input y(x) values: yin[0] = y(fxin), etc. yinl value used to extrapolate yin values to left of yin[0] yinr value used to extrapolate yin values to right of yin[nxin-1] nxout number of x values a which y(x) is output xout array of x values at which y(x) is output Output: yout array of output y(x) values: yout[0] = y(xout[0]), etc. NOTES: ntable must not be less than 2. The table of interpolation operators must be as follows: Let d be the distance, expressed as a fraction of dxin, from a particular xout value to the sampled location xin just to the left of xout. Then, for d = 0.0, table[0][0:7] = 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0 are the weights applied to the 8 input samples nearest xout. Likewise, for d = 1.0, table[ntable-1][0:7] = 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0 are the weights applied to the 8 input samples nearest xout. In general, for d = (float)itable/(float)(ntable-1), table[itable][0:7] are the weights applied to the 8 input samples nearest xout. If the actual sample distance d does not exactly equal one of the values for which interpolators are tabulated, then the interpolator corresponding to the nearest value of d is used. Because extrapolation of the input function y(x) is defined by the left and right values yinl and yinr, the xout values are not restricted to lie within the range of sample locations defined by nxin, dxin, and fxin. AUTHOR: Dave Hale, Colorado School of Mines, 06/02/89