nlp_hessfcn

nlp_hessfcn(om, x, lambda, cost_mult, Hs)

nlp_hessfcn() - Evaluates Hessian of Lagrangian.

LXX = NLP_HESSFCN(OM, X, LAMBDA, COST_MULT)
LXX = NLP_HESSFCN(OM, X, LAMBDA, COST_MULT, HS)

Hessian evaluation function, suitable for use with MIPS, FMINCON, etc.

Inputs:
  OM : Opt-Model object
  X : optimization vector
  LAMBDA (struct)
    .eqnonlin : Lagrange multipliers on equality constraints
    .ineqnonlin : Kuhn-Tucker multipliers on inequality constraints
  COST_MULT : (optional) Scale factor to be applied to the cost
       (default = 1).
  HS : (optional) sparse matrix with tiny non-zero values specifying
       the fixed sparsity structure that the resulting LXX should match

Outputs:
  LXX : Hessian of the Lagrangian.

Examples:
    Lxx = nlp_hessfcn(om, x, lambda, cost_mult);
    Lxx = nlp_hessfcn(om, x, lambda, cost_mult, Hs);

See also nlp_costfcn(), nlp_consfcn().