# naginterfaces.library.fit.dim1_​cheb_​integ¶

naginterfaces.library.fit.dim1_cheb_integ(n, xmin, xmax, a, ia1, qatm1, iaint1)[source]

dim1_cheb_integ determines the coefficients in the Chebyshev series representation of the indefinite integral of a polynomial given in Chebyshev series form.

For full information please refer to the NAG Library document for e02aj

https://www.nag.com/numeric/nl/nagdoc_29.2/flhtml/e02/e02ajf.html

Parameters
nint

, the degree of the given polynomial .

xminfloat

The lower and upper end points respectively of the interval . The Chebyshev series representation is in terms of the normalized variable , where

xmaxfloat

The lower and upper end points respectively of the interval . The Chebyshev series representation is in terms of the normalized variable , where

afloat, array-like, shape

The Chebyshev coefficients of the polynomial . Specifically, element of must contain the coefficient , for . Only these elements will be accessed.

Unchanged on exit, but see , below.

ia1int

The index increment of . Most frequently the Chebyshev coefficients are stored in adjacent elements of , and must be set to . However, if for example, they are stored in , the value of must be . See also Further Comments.

qatm1float

The value that the integrated polynomial is required to have at the lower end point of its interval of definition, i.e., at which corresponds to . Thus, is a constant of integration and will normally be set to zero by you.

iaint1int

The index increment of . Most frequently the Chebyshev coefficients are required in adjacent elements of , and must be set to . However, if, for example, they are to be stored in , the value of must be . See also Further Comments.

Returns
aintcfloat, ndarray, shape

The Chebyshev coefficients of the integral . (The integration is with respect to the variable , and the constant coefficient is chosen so that equals ). Specifically, element of contains the coefficient , for . A call of the function may have the array name the same as , provided that note is taken of the order in which elements are overwritten when choosing starting elements and increments and : i.e., the coefficients, must be intact after coefficient is stored. In particular it is possible to overwrite the entirely by having , and the actual array for and identical.

Raises
NagValueError
(errno )

On entry, , and .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, , and .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, and .

Constraint: .

(errno )

On entry, .

Constraint: .

Notes

dim1_cheb_integ forms the polynomial which is the indefinite integral of a given polynomial. Both the original polynomial and its integral are represented in Chebyshev series form. If supplied with the coefficients , for , of a polynomial of degree , where

the function returns the coefficients , for , of the polynomial of degree , where

and

Here denotes the Chebyshev polynomial of the first kind of degree with argument . It is assumed that the normalized variable in the interval was obtained from your original variable in the interval by the linear transformation

and that you require the integral to be with respect to the variable . If the integral with respect to is required, set and .

Values of the integral can subsequently be computed, from the coefficients obtained, by using dim1_cheb_eval2().

The method employed is that of Chebyshev series (see Module 8 of Modern Computing Methods (1961)), modified for integrating with respect to . Initially taking , the function forms successively

The constant coefficient is chosen so that is equal to a specified value, , at the lower end point of the interval on which it is defined, i.e., , which corresponds to .

References

Modern Computing Methods, 1961, Chebyshev-series, NPL Notes on Applied Science (16), (2nd Edition), HMSO