Please note : This help page is not for the latest version of Enterprise Architect. The latest help can be found here.

Prev Next


Evaluate Chebyshev series.


  int N;
  double x, y, coef[N], chebevl();

  y = chbevl(x, coef, N);


Evaluates the series

          - '
   y  =   >   coef[i] T (x/2)
          -            i

of Chebyshev polynomials Ti at argument x/2.

Coefficients are stored in reverse order, i.e. the zero order term is last in the array. Note N is the number of coefficients, not the order.

If coefficients are for the interval a to b, x must have been transformed to x -> 2(2x - b - a)/(b-a) before entering the routine. This maps x from (a, b) to (-1, 1), over which the Chebyshev polynomials are defined.

If the coefficients are for the inverted interval, in which (a, b) is mapped to (1/b, 1/a), the transformation required is x -> 2(2ab/x - b - a)/(b-a).  If b is infinity, this becomes x -> 4a/x - 1.


Taking advantage of the recurrence properties of the Chebyshev polynomials, the routine requires one more addition per loop than evaluating a nested polynomial of the same degree.


var y = cephes.chbevl(x, coef, N);