To further shape a surface defined by a tensor product of B-splines, the routine SURFACE_FITTING will least squares fit data with equality, inequality and periodic constraints. These can apply to the surface function or its partial derivatives. Each constraint is packaged in the derived type ?_SURFACE_CONSTRAINTS. This function uses the data consisting of: the place where the constraint is to hold, the partial derivative indices, and the type of the constraint. This object is returned as the derived type function result ?_SURFACE_CONSTRAINTS. The function itself has two required and two optional arguments. In a list of constraints, the j-th item will be:
The square brackets enclose optional arguments. For each constraint the arguments ‘value =’ and ‘PERIODIC_POINT =’ are not used at the same time.
Required Arguments
The point in the data domain where a constraint is to be applied. Each point has an x and y coordinate, in that order.
The indicator for the type of constraint the tensor product spline function or its partial derivatives is to satisfy at the point: where_applied. The choices are the character strings ‘==’, ‘<=’, ‘>=’, ‘.=.’, and ‘.=-’. They respectively indicate that the spline value or its derivatives will be equal to, not greater than, not less than, equal to the value of the spline at another point, or equal to the negative of the spline value at another point. These last two constraints are called periodic and negative-periodic, respectively.
Optional Arguments
These are the number of the partial derivatives for the tensor product spline to apply the constraint. The array (/0,0/) corresponds to the function, the value (/1,0/) to the first partial derivative with respect to x, etc. If this argument is not present in the list, the value (/0,0/) is substituted automatically. Thus a constraint without the derivatives listed applies to the tensor product spline function.
This optional argument improves readability by identifying the second pair of independent variable values for periodic constraints.
FORTRAN 90 Interface
Specific: The specific interface names are S_SURFACE_CONSTRAINTS and D_SURFACE_CONSTRAINTS.