Nonlinear Program.Lagrangian Hessian Property
Definition
Assembly: Numerics.NET (in Numerics.NET.dll) Version: 10.9.0
public Action<Vector<double>, double, Vector<double>, Matrix<double>>? LagrangianHessian { get; set; }Property Value
Action<Vector<Double>, Double, Vector<Double>, Matrix<Double>>A callback receiving the point, objective weight, constraint multipliers, and destination matrix, or null to use the solver's approximation.
Remarks
The callback writes the Hessian of weight*f(x)-sum(lambda[i]*c[i](x)). The objective weight is 1 for minimization and -1 for maximization. Multipliers follow the original Constraints order. A positive multiplier corresponds to a lower bound, a negative multiplier to an upper bound; equality multipliers are unrestricted. Variable bounds have zero curvature.
The destination is a cleared symmetric matrix. Assign its lower triangle; entries that remain zero need not be assigned. Do not modify the point or multipliers, or retain any of the supplied buffers after the callback returns.
This matrix callback applies to the two dense SQP methods. Large-scale methods use ObjectiveHessianVectorProduct or SparseDerivatives. When supplied for dense SQP, this callback takes precedence over objective-only curvature. When it is null, a damped BFGS approximation based on first derivatives is used. A supplied Hessian must contain finite values. Invalid values cause solver failure; exceptions raised by the callback propagate to the caller.