class cobyqa.models.Quadratic(interpolation, values, debug)[source]#

Quadratic model.

This class stores the Hessian matrix of the quadratic model using the implicit/explicit representation designed by Powell for NEWUOA [1].



M. J. D. Powell. The NEWUOA software for unconstrained optimization without derivatives. In G. Di Pillo and M. Roma, editors, Large-Scale Nonlinear Optimization, volume 83 of Nonconvex Optim. Appl., pages 255–297. Springer, Boston, MA, USA, 2006. doi:10.1007/0-387-30065-1_16.


Number of variables.


Number of interpolation points used to define the quadratic model.


__call__(x, interpolation)

Evaluate the quadratic model at a given point.


Build the left-hand side matrix of the interpolation system.

curv(v, interpolation)

Evaluate the curvature of the quadratic model along a given direction.

grad(x, interpolation)

Evaluate the gradient of the quadratic model at a given point.


Evaluate the Hessian matrix of the quadratic model.

hess_prod(v, interpolation)

Evaluate the right product of the Hessian matrix of the quadratic model with a given vector.

shift_x_base(interpolation, new_x_base)

Shift the point around which the quadratic model is defined.

solve_systems(interpolation, rhs)

Solve the interpolation systems.

update(interpolation, k_new, dir_old, ...)

Update the quadratic model.