d03pzc interpolates in the spatial coordinate the solution and derivative of a system of partial differential equations (PDEs). The solution must first be computed using one of the finite difference schemes d03pcc,d03phcord03ppc, or one of the Keller box schemes
d03pec,d03pkcord03prc.
The function may be called by the names: d03pzc, nag_pde_dim1_parab_fd_interp or nag_pde_interp_1d_fd.
3Description
d03pzc is an interpolation function for evaluating the solution of a system of partial differential equations (PDEs), at a set of user-specified points. The solution of the system of equations (possibly with coupled ordinary differential equations) must be computed using a finite difference scheme or a Keller box scheme on a set of mesh points. d03pzc
can then be employed to compute the solution at a set of points anywhere in the range of the mesh. It can also evaluate the first spatial derivative of the solution. It uses linear interpolation for approximating the solution.
4References
None.
5Arguments
Note: the arguments x, m, u, npts and npde must be supplied unchanged from the PDE function.
1: – IntegerInput
On entry: the number of PDEs.
Constraint:
.
2: – IntegerInput
On entry: the coordinate system used. If the call to d03pzc follows one of the finite difference functions then m must be the same argument m as used in that call. For the Keller box scheme only Cartesian coordinate systems are valid and so mmust be set to zero. No check will be made by d03pzc in this case.
Indicates Cartesian coordinates.
Indicates cylindrical polar coordinates.
Indicates spherical polar coordinates.
Constraints:
following a finite difference function;
following a Keller box scheme function.
3: – const doubleInput
Note: the th element of the matrix is stored in .
On entry: the PDE part of the original solution returned in the argument u by the PDE function.
Constraint:
.
4: – IntegerInput
On entry: the number of mesh points.
Constraint:
.
5: – const doubleInput
On entry: , for , must contain the mesh points as used by the PDE function.
6: – const doubleInput
On entry: , for , must contain the spatial interpolation points.
Constraint:
.
7: – IntegerInput
On entry: the number of interpolation points.
Constraint:
.
8: – IntegerInput
On entry: specifies the interpolation to be performed.
The solutions at the interpolation points are computed.
Both the solutions and their first derivatives at the interpolation points are computed.
Constraint:
or .
9: – doubleOutput
Note: the dimension, dim, of the array
up
must be at least
.
the element is stored in the array element .
On exit: if , , contains the value of the solution , at the interpolation points , for and .
If , contains and contains at these points.
10: – NagError *Input/Output
The NAG error argument (see Section 7 in the Introduction to the NAG Library CL Interface).
6Error Indicators and Warnings
NE_ALLOC_FAIL
Dynamic memory allocation failed.
See Section 3.1.2 in the Introduction to the NAG Library CL Interface for further information.
NE_BAD_PARAM
On entry, argument had an illegal value.
NE_EXTRAPOLATION
On entry, interpolating point with the value is outside the x range.
NE_INT
On entry, .
Constraint: .
On entry, .
Constraint: or .
On entry, .
Constraint: , or .
On entry, .
Constraint: .
On entry, .
Constraint: .
NE_INTERNAL_ERROR
An internal error has occurred in this function. Check the function call and any array sizes. If the call is correct then please contact NAG for assistance.
See Section 7.5 in the Introduction to the NAG Library CL Interface for further information.
NE_NO_LICENCE
Your licence key may have expired or may not have been installed correctly.
See Section 8 in the Introduction to the NAG Library CL Interface for further information.