naginterfaces.library.ode.bvp_​coll_​nlin_​setup

naginterfaces.library.ode.bvp_coll_nlin_setup(m, nlbc, nrbc, ncol, tols, nmesh, mesh, ipmesh)[source]

bvp_coll_nlin_setup is a setup function which must be called prior to the first call of the nonlinear two-point boundary value solver bvp_coll_nlin_solve().

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

https://support.nag.com/numeric/nl/nagdoc_30.3/flhtml/d02/d02tvf.html

Parameters
mint, array-like, shape

must contain , the order of the th differential equation, for .

nlbcint

, the number of left boundary conditions defined at the left-hand end, ().

nrbcint

, the number of right boundary conditions defined at the right-hand end, ().

ncolint

The number of collocation points to be used in each mesh sub-interval.

tolsfloat, array-like, shape

must contain the error requirement for the th solution component.

nmeshint

The number of points to be used in the initial mesh of the solution process.

meshfloat, array-like, shape

The positions of the initial mesh points. The remaining elements of need not be set. You should try to place the mesh points in areas where you expect the solution to vary most rapidly. In the absence of any other information the points should be equally distributed on .

must contain the left boundary point, , and must contain the right boundary point, .

ipmeshint, array-like, shape

specifies whether or not the initial mesh point defined in , for , should be a fixed point in all meshes computed during the solution process. The remaining elements of need not be set.

Indicates that should be a fixed point in all meshes.

Indicates that is not a fixed point.

Returns
commdict, communication object

Communication structure.

Raises
NagValueError
(errno )

On entry, or for some .

(errno )

On entry, or does not equal .

(errno )

On entry, the elements of are not strictly increasing.

(errno )

On entry, , and .

Constraint: .

(errno )

On entry, and .

Constraint: and .

(errno )

On entry, and .

Constraint: .

(errno )

On entry, .

Constraint: for all .

(errno )

On entry, .

Constraint: for all .

(errno )

On entry, and .

Constraint: .

(errno )

On entry, .

Constraint: .

(errno )

On entry, .

Constraint: .

Notes

bvp_coll_nlin_setup and its associated functions (bvp_coll_nlin_solve(), bvp_coll_nlin_contin(), bvp_coll_nlin_interp() and bvp_coll_nlin_diag()) solve the two-point boundary value problem for a nonlinear system of ordinary differential equations

over an interval subject to () nonlinear boundary conditions at and () nonlinear boundary conditions at , where . Note that is the th derivative of the th solution component. Hence . The left boundary conditions at are defined as

and the right boundary conditions at as

where and

See Further Comments for information on how boundary value problems of a more general nature can be treated.

bvp_coll_nlin_setup is used to specify an initial mesh, error requirements and other details. bvp_coll_nlin_solve() is then used to solve the boundary value problem.

The solution function bvp_coll_nlin_solve() proceeds as follows. A modified Newton method is applied to the equations

and the boundary conditions. To solve these equations numerically the components are approximated by piecewise polynomials using a monomial basis on the th mesh sub-interval. The coefficients of the polynomials form the unknowns to be computed. Collocation is applied at Gaussian points

where is the th collocation point in the th mesh sub-interval. Continuity at the mesh points is imposed, that is

where is the right-hand end of the th mesh sub-interval. The linearized collocation equations and boundary conditions, together with the continuity conditions, form a system of linear algebraic equations, an almost block diagonal system which is solved using special linear solvers. To start the modified Newton process, an approximation to the solution on the initial mesh must be supplied via the procedure argument of bvp_coll_nlin_solve().

The solver attempts to satisfy the conditions

where is the approximate solution for the th solution component and is supplied by you. The mesh is refined by trying to equidistribute the estimated error in the computed solution over all mesh sub-intervals, and an extrapolation-like test (doubling the number of mesh sub-intervals) is used to check for (1).

The functions are based on modified versions of the codes COLSYS and COLNEW (see Ascher et al. (1979) and Ascher and Bader (1987)). A comprehensive treatment of the numerical solution of boundary value problems can be found in Ascher et al. (1988) and Keller (1992).

References

Ascher, U M and Bader, G, 1987, A new basis implementation for a mixed order boundary value ODE solver, SIAM J. Sci. Stat. Comput. (8), 483–500

Ascher, U M, Christiansen, J and Russell, R D, 1979, A collocation solver for mixed order systems of boundary value problems, Math. Comput. (33), 659–679

Ascher, U M, Mattheij, R M M and Russell, R D, 1988, Numerical Solution of Boundary Value Problems for Ordinary Differential Equations, Prentice–Hall

Gill, P E, Murray, W and Wright, M H, 1981, Practical Optimization, Academic Press

Keller, H B, 1992, Numerical Methods for Two-point Boundary-value Problems, Dover, New York

Schwartz, I B, 1983, Estimating regions of existence of unstable periodic orbits using computer-based techniques, SIAM J. Sci. Statist. Comput. (20(1)), 106–120