On exit: if
and
or
, the
th row of
cjac must contain the available elements of the vector
given by
where
is the partial derivative of the
th constraint with respect to the
th variable, evaluated at the point
. See also the parameter
nstate. The remaining rows of
cjac, corresponding to non-positive elements of
needc, are ignored.
If all elements of the constraint Jacobian are known (i.e.,
or
), any constant elements may be assigned to
cjac one time only at the start of the optimization. An element of
cjac that is not subsequently assigned in
confun will retain its initial value throughout. Constant elements may be loaded into
cjac either before the call to
e04us or during the first call to
confun (signalled by the value
). The ability to preload constants is useful when many Jacobian elements are identically zero, in which case
cjac may be initialized to zero and nonzero elements may be reset by
confun.
Note that constant nonzero elements do affect the values of the constraints. Thus, if
is set to a constant value, it need not be reset in subsequent calls to
confun, but the value
must nonetheless be added to
. For example, if
and
, then the term
must be included in the definition of
.
It must be emphasized that, if
or
, unassigned elements of
cjac are not treated as constant; they are estimated by finite differences, at nontrivial expense. If you do not supply a value for the optional parameter
Difference Interval, an interval for each element of
is computed automatically at the start of the optimization. The automatic procedure can usually identify constant elements of
cjac, which are then computed once only by finite differences.