naginterfaces.library.inteq.fredholm2_​smooth

naginterfaces.library.inteq.fredholm2_smooth(k, g, lamda, a, b, odorev, ev, n, data=None)[source]

fredholm2_smooth solves any linear nonsingular Fredholm integral equation of the second kind with a smooth kernel.

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

https://support.nag.com/numeric/nl/nagdoc_30.3/flhtml/d05/d05abf.html

Parameters
kcallable retval = k(x, s, data=None)

must compute the value of the kernel of the integral equation over the square , .

Parameters
xfloat

The values of and at which is to be calculated.

sfloat

The values of and at which is to be calculated.

dataarbitrary, optional, modifiable in place

User-communication data for callback functions.

Returns
retvalfloat

The value of the kernel evaluated at and .

gcallable retval = g(x, data=None)

must compute the value of the function of the integral equation in the interval .

Parameters
xfloat

The value of at which is to be calculated.

dataarbitrary, optional, modifiable in place

User-communication data for callback functions.

Returns
retvalfloat

The value of evaluated at .

lamdafloat

The value of the parameter of the integral equation.

afloat

, the lower limit of integration.

bfloat

, the upper limit of integration.

odorevbool

Indicates whether it is known that the solution is odd or even about the mid-point of the range of integration. If is then an odd or even solution is sought depending upon the value of .

evbool

Is ignored if is . Otherwise, if is , an even solution is sought, whilst if is , an odd solution is sought.

nint

The number of terms in the Chebyshev series which approximates the solution .

dataarbitrary, optional

User-communication data for callback functions.

Returns
ffloat, ndarray, shape

The approximate values , for , of the function at the first of Chebyshev points (see Notes), where

if and .

if and .

if .

cfloat, ndarray, shape

The coefficients , for , of the Chebyshev series approximation to . When is , this series contains polynomials of even order only or of odd order only, according to being or respectively.

Raises
NagValueError
(errno )

On entry, .

Constraint: .

(errno )

On entry, and .

Constraint: .

(errno )

A failure has occurred due to proximity of an eigenvalue.

Notes

fredholm2_smooth uses the method of El–Gendi (1969) to solve an integral equation of the form

for the function in the range .

An approximation to the solution is found in the form of an term Chebyshev series , where indicates that the first term is halved in the sum. The coefficients , for , of this series are determined directly from approximate values , for , of the function at the first of a set of Chebyshev points

The values are obtained by solving a set of simultaneous linear algebraic equations formed by applying a quadrature formula (equivalent to the scheme of Clenshaw and Curtis (1960)) to the integral equation at each of the above points.

In general . However, advantage may be taken of any prior knowledge of the symmetry of . Thus if is symmetric (i.e., even) about the mid-point of the range , it may be approximated by an even Chebyshev series with . Similarly, if is anti-symmetric (i.e., odd) about the mid-point of the range of integration, it may be approximated by an odd Chebyshev series with .

References

Clenshaw, C W and Curtis, A R, 1960, A method for numerical integration on an automatic computer, Numer. Math. (2), 197–205

El–Gendi, S E, 1969, Chebyshev solution of differential, integral and integro-differential equations, Comput. J. (12), 282–287