E02DEF calculates values of a bicubic spline from its B-spline representation.
SUBROUTINE E02DEF ( |
M, PX, PY, X, Y, LAMDA, MU, C, FF, WRK, IWRK, IFAIL) |
INTEGER |
M, PX, PY, IWRK(PY-4), IFAIL |
REAL (KIND=nag_wp) |
X(M), Y(M), LAMDA(PX), MU(PY), C((PX-4)*(PY-4)), FF(M), WRK(PY-4) |
|
E02DEF calculates values of the bicubic spline
sx,y at prescribed points
xr,yr, for
r=1,2,…,m, from its augmented knot sets
λ and
μ and from the coefficients
cij, for
i=1,2,…,PX-4 and
j=1,2,…,PY-4, in its B-spline representation
Here
Mix and
Njy denote normalized cubic B-splines, the former defined on the knots
λi to
λi+4 and the latter on the knots
μj to
μj+4.
This routine may be used to calculate values of a bicubic spline given in the form produced by
E01DAF,
E02DAF,
E02DCF and
E02DDF. It is derived from the routine B2VRE in
Anthony et al. (1982).
Anthony G T, Cox M G and Hayes J G (1982)
DASL – Data Approximation Subroutine Library National Physical Laboratory
Cox M G (1978) The numerical evaluation of a spline from its B-spline representation
J. Inst. Math. Appl. 21 135–143
If on entry
IFAIL=0 or
-1, explanatory error messages are output on the current error message unit (as defined by
X04AAF).
The method used to evaluate the B-splines is numerically stable, in the sense that each computed value of
sxr,yr can be regarded as the value that would have been obtained in exact arithmetic from slightly perturbed B-spline coefficients. See
Cox (1978) for details.