next up previous 62
Next: ARRAYStructure
Up: Low-Level Structures
Previous: Low-Level Structures


$<$POLYNOMIAL$>$ Structure

The $<$POLYNOMIAL$>$ structure is used for storing the coefficients of an $n$-dimensional ordinary or Chebyshev polynomial. Evaluation of the polynomial yields a $<$float$>$ scalar result.


Table: Contents of the $<$POLYNOMIAL$>$ Structure
Component Name TYPE Brief Description
[VARIANT] $<$_CHAR$>$ registered variant
[DATA_ARRAY] $<$farray$>$ coefficients
[VARIANCE] $<$farray$>$ variance of the coefficients
[TMIN(NAXIS)] $<$float$>$ lower bound of co-ordinate range
[TMAX(NAXIS)] $<$float$>$ upper bound of co-ordinate range

[VARIANT]
At present, there are two variants. The base variant ([VARIANT] = `SIMPLE') is the ordinary polynomial, while [VARIANT] = `CHEBYSHEV' is used for storing Chebyshev polynomials.
[DATA_ARRAY]
This is mandatory. The interpretation depends on the value of [VARIANT]. The scalar (VALUE) which results from the evaluation of the polynomial inherits the equivalent primitive TYPE of the polynomial coefficients.

[VARIANT] =
`SIMPLE' The [DATA_ARRAY] is the $NAXIS$-dimensional array containing the $NAXIS$-dimensional polynomial coefficients. The function is evaluated as:

\begin{displaymath}{\rm VALUE} = \sum {\rm DATA\underline{~~}ARRAY}(I_1,I_2,\ldots,I_{\rm NAXIS}) \prod_{j=1}^{\rm NAXIS} {\rm AXIS}_j\!^{I_j-1} \end{displaymath}

summed over all elements of the DATA_ARRAY.

Here, AXIS$_n$ is the co-ordinate value along axis $n$, and NAXIS$_n$ is the dimension of axis $n$.

[VARIANT] =
`CHEBYSHEV' The [DATA_ARRAY] contains the NAXIS-dimensional array of Chebyshev-polynomial coefficients. The function is evaluated as:


\begin{displaymath}{\rm VALUE}=\sum {\rm DATA\underline{~~}ARRAY}(I_1,I_2,\ldots,I_{\rm NAXIS})\prod_{j=1}^{\rm NAXIS} T(I_{j-1},S_j) \end{displaymath}

summed over all elements of the DATA_ARRAY, where $T(m,x)$ is the Chebyshev polynomial of order $m$ evaluated at $x$ (in the range $-$1 to $+$1), and

\begin{displaymath}S_n = ({\rm AXIS}_n - {\rm TMIN}(n))/({\rm TMAX}(n) - {\rm TMIN}(n)) \end{displaymath}

If the polynomial is evaluated outside this interval, the result is bad, and set to the magic value.

[VARIANCE]
This optional component is used to describe the variance of the errors associated with the polynomial coefficients given by the [DATA_ARRAY] component, and it must be an array of the same dimension as [DATA_ARRAY].
NAXIS
The dimensionality of the [DATA_ARRAY] and therefore the dimensionality of the space over which the polynomial function is defined.
[TMIN($n$)], [TMAX($n$)]
These are the minimum and maximum values along AXIS number $n$. They represent the bounds of the normalised co-ordinate range. Only processed if [VARIANT] = `CHEBYSHEV', for which they are mandatory.


next up previous 62
Next: ARRAYStructure
Up: Low-Level Structures
Previous: Low-Level Structures

Starlink Standard Data Structures
Starlink General Paper 38
Malcolm J Currie, P T Wallace &
R F Warren-Smith
1989 January 20
E-mail:ussc@star.rl.ac.uk

Copyright © 2008 Science and Technology Facilities Council