e01be computes a monotonicity-preserving piecewise cubic Hermite interpolant to a set of data points.
- Type: System..::..Int32On entry: , the number of data points.Constraint: .
- Type: array<System..::..Double>()On entry: must be set to , the th value of the independent variable (abscissa), for .Constraint: .
- Type: array<System..::..Double>()On entry: must be set to , the th value of the dependent variable (ordinate), for .
- Type: array<System..::..Double>()On exit: estimates of derivatives at the data points. contains the derivative at .
e01be estimates first derivatives at the set of data points , for , which determine a piecewise cubic Hermite interpolant to the data, that preserves monotonicity over ranges where the data points are monotonic. If the data points are only piecewise monotonic, the interpolant will have an extremum at each point where monotonicity switches direction. The estimates of the derivatives are computed by a formula due to Brodlie, which is described in Fritsch and Butland (1984), with suitable changes at the boundary points.
The method is derived from method PCHIM in Fritsch (1982).
Values of the computed interpolant, and of its first derivative and definite integral, can subsequently be computed by calling e01bf (E01BGF not in this release) (E01BHF not in this release), as described in [Further Comments].
Fritsch F N (1982) PCHIP final specifications Report UCID-30194 Lawrence Livermore National Laboratory
Fritsch F N and Butland J (1984) A method for constructing local monotone piecewise cubic interpolants SIAM J. Sci. Statist. Comput. 5 300–304
Errors or warnings detected by the method:
On entry, .
- The values of , for , are not in strictly increasing order.
The computational errors in the array d should be negligible in most practical situations.
The time taken by e01be is approximately proportional to .
The values of the computed interpolant at the points , for , may be obtained in the real array pf, of length at least m, by the call: where n, x and f are the input parameters to e01be and d is the output parameter from e01be.
The values of the computed interpolant at the points , for , together with its first derivatives, may be obtained in the real arrays pf and pd, both of length at least m, by the call: where n, x, f and d are as described above.