gram_polynomial


gram_polynomial, a MATLAB code which evaluates the Gram polynomials, also known as the discrete Chebyshev polyomials.

The Gram polynomial P(n,m,x) can be evaluated at a point x by:

        P(0,m,x) = 1
        P(1,m,x) = x
        P(n+1,m,x) = x * P(n,m,x) - beta(n,m) * P(n-1,m,x)
      
where beta(n,m) = (m^2-n^2)*n^2/m^2/(4*n^2-1).

The polynomials are orthogonal with respect to a discrete inner product

  (f,g) = sum ( 1 <= i <= m ) f(x(i)) * g(x(i))
where
  x(i) = - 1 + ( 2*i-1)/m, 1 <= i <= m.

Licensing:

The information on this web page is distributed under the MIT license.

Languages:

gram_polynomial is available in a MATLAB version and an Octave version and a Python version.

Related Data and Programs:

gram_polynomial_test

matlab_polynomial, a MATLAB code which analyzes a variety of polynomial families, returning the polynomial values, coefficients, derivatives, integrals, roots, or other information.

polpak, a MATLAB code which evaluates a variety of mathematical functions.

test_values, a MATLAB code which supplies test values of various mathematical functions.

Reference:

  1. Germund Dahlquist, Ake Bjorck,
    Numerical Methods in Scientific Computing, Volume 1,
    SIAM, 2008,
    ISBN: 978-0-898716-44-3,
    LC: QA297.D335 2008.

Source Code:


Last revised on 28 June 2019.